0
$\begingroup$

I'm new tho mathematica.

I have a complex sequence ${z_n}$ with

$z_0:=c$

$z_{n+1}=(z_n)^2+c$ for all $n\in N$

where c is some complex number, I need to plot the first 20 terms of this sequence where $c=-0.5+0.2i$, print the plot and for the value of $c$ in $(a)$ determin it's limit.

The main problem is that i don't know from where to start...

$\endgroup$
2
$\begingroup$

For basic function construction see: http://reference.wolfram.com/language/tutorial/MakingDefinitionsForFunctions.html

You did not explain how you want to plot a complex valued function but here's a start:

c = -0.5 + 0.2 I;
z[0] := c
z[n_Integer?Positive] := z[n - 1]^2 + c

Array[z, 20]
{-0.29 + 0. I, -0.4159 + 0.2 I, -0.367027 + 0.03364 I, -0.366423 + 
  0.175306 I, -0.396467 + 0.0715275 I, -0.34793 + 0.143283 I, -0.399475 + 
  0.100295 I, -0.350479 + 0.11987 I, -0.391533 + 0.115976 I, -0.360152 + 
  0.109183 I, -0.382211 + 0.121355 I, -0.368642 + 0.107233 I, -0.375602 + 
  0.120939 I, -0.373549 + 0.10915 I, -0.372375 + 0.118454 I, -0.375368 + 
  0.111781 I, -0.371594 + 0.116082 I, -0.375393 + 0.11373 I, -0.372015 + 
  0.114613 I, -0.374741 + 0.114724 I}

For plotting complex values perhaps start here: Plotting complex Sine

$\endgroup$
  • 1
    $\begingroup$ The now built-in functions for plotting Julia and Mandelbrot sets might also be of interest to the OP. $\endgroup$ – J. M. will be back soon May 12 '15 at 23:37

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.