user1120190
user1120190

Reputation: 691

Plotting Complex Numbers in Python?

For a math fair project I want to make a program that will generate a Julia set fractal. To do this i need to plot complex numbers on a graph. Does anyone know how to do this? Remember I am using complex numbers, not regular coordinates. Thank You!

Upvotes: 2

Views: 1924

Answers (2)

Marcelo Cantos
Marcelo Cantos

Reputation: 185852

Julia set renderings are generally 2D color plots, with [x y] representing a complex starting point and the color usually representing an iteration count.

Upvotes: 0

sarnold
sarnold

Reputation: 104050

You could plot the real portion of the number along the X axis and plot the imaginary portion of the number along the Y axis. Plot the corresponding pixel with whatever color makes sense for the output of the Julia function for that point.

Upvotes: 2

Related Questions