Coding self similar fractals in computer graphics using C
Can anyone help me with the programming code for self similar fractals in computer graphics using c language? ...
Can anyone help me with the programming code for self similar fractals in computer graphics using c language? ...
Usual rules for the code golf. Here is an implementation in python as an example from PIL import Image im = Image.new("RGB", (300,300)) for i in xrange(300): print "i = ",i for j in xrange(300): x0 = float( 4.0*float(i-150)/300.0 -1.0) y0 = float( 4.0*float(j-150)/300.0 +0.0) x=0.0 y=0.0 ...
For my problem it would be best to find a numeric representation of kazakh national ornaments for generating new ones. But other approaches are also fine. The ornaments essentially consist of combinations of relatively basic ornaments. Usually the ornaments are symmetrical. Here are few examples of basic elements: (The images ...
How to draw pythagoras tree in swing ? http://mathworld.wolfram.com/images/eps-gif/PythagorasTree_825.gif ...
I'm trying to build my first fractal (Pythagoras Tree): in Java using Graphics2D. Here's what I have now : import java.awt.*; import java.awt.geom.*; import javax.swing.*; import java.util.Scanner; public class Main { public static void main(String[] args) { int i=0; Scanner scanner = new Scanner(System.in); System.o...
I am looking for a decent fractal based compression algorithm for images. So far I only find dead links to the FIF image format and dead links pointing to Iterated Systems Inc which then became MediaBin which then became nothing from what I can see. ...
Hello. I have written program for drawing pythagoras tree fractal. Can anybody see any way of improving it ? Now it is 89 LOC. import java.awt.*; import java.util.Scanner; import javax.swing.*; public class Main extends JFrame {; public Main(int n) { setSize(900, 900); setTitle("Pythagoras tree"); add(new D...
I'm trying to get a simple 1D fractal terrain generator to work for a 2D game. But for some reason it always either makes a hill, a valley, or a flat line, as seen in this output of the segments (x1, x2, y2): 0.0 4.0 -0.02771158460407615 4.0 8.0 -0.052252824583875854 8.0 12.0 -0.07902285133059965 12.0 16.0 -0.1055590812...
I'm interested in experimenting with equations for 3D fractals (a la Mandelbulb). Does anyone know of a framework that will allow me to supply a 3-coordinate, Mandelbrot-style function, identifying a point as being contained or not contained within a set, and render the surface form of the resulting set in 3D? Obviously, a solution tha...
however, is there a nice way to simply enter the data/equations on the stack and look at the answers? I guess that I am trying to "see" how one grows and perhaps even plot it manually. The Koch I think would be possible, but I just don't know. ...
I want to generate (an image of) a single branch of a tree (the "woody plant" kind). Maybe similar to this branch, or this one. I need it to be interesting but simple, so just one branch, with a few turns, and only a few splits (where it changes from one limb into two). It should start with one fat branch and split off into a few thin b...
I'm reading a chapter in this fascinating book about using genetic programming to interactively evolve images. Most of the function set is comprised of simple arithmetic and trig functions (which really operation on and return images). These functions make up the internal nodes of the parse trees that encode our images. The leaves of the...
Hi, I'm reading a book on OpenGL, "Interactive Computer Graphics" by Edward Angel. In it, he asks you to modify a Sierpinski gasket algorithm to yield fractal mountains. To do so, it says to find the midpoint of each side, then perturb this location before subdivision. He doesn't explain at all how to "perturb" the location, and looking...
How can you make a Koch Snowflake Fractal using php gd so that it comes out like this... Is it possible? Is there another resource I can use? ...
I'm currently experimenting with rendering a Mandelbrot set and I've quickly come to realize that it would be useful to not have to recalculate the maximum iteration count for each rendering...on the other hand it's a lot of data to keep track of. It seems to me (based on my limited experience with RDMSes) that a relational database is p...
For a while now I've been interested in fractals, the math behind them and the visuals they can produce. I just can't really figure out how to map the mathematical formula to a piece of code that draws the picture. Given this formula for the mandelbrot set: Pc(z) = z * z + c How does that compare to the following code: $outer_adder = (...
I'm trying to visualize Mandelbrot set with OpenGL and have found very strange behaviour when it comes to smooth coloring. Let's assume, for the current complex valueC, algorithm have escaped after n iterations when Z had been proven to be more than 2. I programmed coloring part like this: if(n==maxIterations){ color=0.0; //0.0 is ...
I have this homework which required to print asterick to make draw a triangle. When drawTriangle(0); * When drawTriangle(1); * ** When drawTriangle(2); * ** * * **** when drawTriangle(3); * ** * * **** * * ** ** * * * * ******** when drawTriangle(4); * **...