Skip to content

Fractol is a graphical C program that offers an immersive journey into fractals - intricate shapes with self-similarity across scales, born from iterative mathematics. Users interactively explore different fractals and watch mesmerising patterns unfold in real time.

Notifications You must be signed in to change notification settings

mfk-ayoub/fractol

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

📜 About Project

One of the first graphical projects at 42 School, fract-ol generates beautiful fractals from the complex numbers of
an iterative mathematical construct. A fractal is a fragmented geometrical figure that infinitely repeats itself at
smaller scales. This project uses the school's graphical library, MiniLibX.

🚀 TLDR: The fract-ol project is one of the three "beginner" graphical projects of the 
	 cursus. It teaches you about using graphic library, advanced math, and more.

Note

Because of 42 School norm requirements:

  • Each function can't have more than 25 lines of code.
  • All variables are declared and aligned at the top of each function.
  • Project should be created just with allowed functions otherwise it's cheating.

📑 Fractals List

The program supports these fractal sets:

Name Formula
Mandelbrot $z_{n+1} = z_n^2 + c, z_0 = 0$
Julia $z_{n+1} = z_n^2 + c, z_0 = c$
Burning Ship $z_{n+1} = abs(z_n^2) + c, z_0 = 0$
Tricorn $z_{n+1} = \frac{}{z_n}^2 + c, z_0 = 0$

🎮 Controls

The program supports the following controls:

Key Description
ESC Close the program window
Mouse Scroll Zoom in and out of the fractal
⬆️ ⬇️ ⬅️ ➡️ Change the viewpoint
espace Reset the fractal to its initial state

👨‍💻 Usage

Requirements

The program is written in C language and thus needs the gcc compiler and some standard C libraries to run.

Instructions

1. Compiling the program

To compile the program, run:

$ cd path/to/fractol && make

2. How to run the program

Run the executable too see the help message:

./fractol

Or run with some supported fractal:

./fractol m

CONTRIBUTING

If you find any issues or have suggestions for improvements, feel free to fork the repository and open an issue or submit a pull request.

About

Fractol is a graphical C program that offers an immersive journey into fractals - intricate shapes with self-similarity across scales, born from iterative mathematics. Users interactively explore different fractals and watch mesmerising patterns unfold in real time.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published