WIP
This project is a work in progress. The implementation is incomplete and subject to change. The documentation can be inaccurate.
Konstig
Konstig is a trigonometric strange attractor generator. It's name is simply weird, or strange, in Swedish.
Installation
go get github.com/karlek/konstig/cmd/konstig
Generate an image
$ konstig -a 4.663414 -b 1.502477 -c 3.351885 -d 2.894832 -i 1000000 -z 400 -w 5000 -h 5000 -f1 0.005 -f2 0.005 -f3 0.005 -p1 0 -p2 2 -p3 8 -o out.png
Equation
xn+1 = sin(y*b) + c*sin(x*b)
yn+1 = sin(x*a) + d*sin(y*a)
Flags:
- a, b, c, d:
A-,B-,C-,D-coefficient, see formula above. - i:
Number of iterations performed. - f1, f2, f3:
Color frequency. - p1, p2, p3:
Color phases. - z:
Zoom value. How many magnifications to make on the center point. - o:
Output filename. - w, h:
Width and height of created image.
Examples
Some pretty examples.
a = 1.364325
b = 0.441972
c = 3.868827
d = 4.301396
a = 0.860540
b = 1.602272
c = 4.690712
d = 2.123729
All images were created with:
$ konstig
Public domain
I hereby release this code into the public domain.