Structure preview

What complex numbers are for: oscillations, transformations and fractals

From formulas to phenomena: add oscillations, transform shapes and follow complex orbits. Examples, exercises, a lab and links to the fractals material.

Section: Complex numbers Updated:

Lab: what complex numbers are for

Learning-path index

Article: fractals, geometry and nature · Open the fractals lab

Articles /numeri-complessi-applicazioni-oscillazioni-trasformazioni-frattali
Three applications: phasors and a wave, transformed triangles and a small numerical Mandelbrot image
The same algebra describes periodic projections, geometric transformations and iteration. Each drawing has its own model and limitations.

22 min

Complex numbers do more than solve equations without real roots. They combine length and direction, amplitude and phase, or the two coordinates of an iterated calculation. We conclude the eight stages by using our tools to understand three concrete applications.

Illustration for the Complex numbers section
Section: Complex numbers

Learning-path index · Lab: what complex numbers are for · Stage 7: equations and polynomials

1. Not magic numbers: a compact language

A point (x,y) becomes z=x+iy; multiplication changes modulus and argument; a complex exponential describes rotation. We are not replacing real numbers with something mysterious: we organize two pieces of real information in a structure with useful rules.

Not every problem becomes easy, but some operations become simpler to express and compose. The lab distinguishes the exact mathematical model, approximate numerical values and a finite drawing. An attractive picture is not by itself a proof or a complete physical model.

Explore and explain

2. An oscillation is the projection of a rotation

A point rotating on a circle is Z(t)=A e^(i(ωt+φ)), with A≥0, ω=2πf and initial phase φ. Euler gives Z(t)=A cos(ωt+φ)+iA sin(ωt+φ). Its horizontal projection is x(t)=Re Z(t)=A cos(ωt+φ).

x(t)=A cos(2πft+φ), T=1/f for f>0.

A is amplitude, f frequency in hertz, T period in seconds and φ an angle in radians. For f=0 there is no rotation and x(t) is constant: we do not assign a period 1/0. For A=0 the projection is zero. This is an ideal sinusoid, not every real vibration.

Explore and explain

3. Add waves with the same frequency

For two sinusoids with the same ω, factor out the time dependence: Z₁(t)+Z₂(t)=[A₁e^(iφ₁)+A₂e^(iφ₂)]e^(iωt). Set C=A₁e^(iφ₁)+A₂e^(iφ₂). If C≠0, the sum is a sinusoid of amplitude |C| and phase Arg(C). C is the resultant phasor, using peak amplitudes here.

A_tot²=A₁²+A₂²+2A₁A₂ cos(φ₂−φ₁).

Expand |C|²=C·conj(C) to derive this formula. For A₁=2,A₂=1 and equal phases, amplitude is 3. If C=0 the sum is identically zero and has no defined resultant phase. Different frequencies cannot share a single e^(iωt); their sum is generally not one sinusoid of this form.

Explore and explain

4. Two examples: quadrature and cancellation

Problem: add 2cos(πt) and cos(πt+π/2). Their common frequency is f=1/2 Hz, so T=2 s. Phasors 2 and i give C=2+i, |C|=√5 and Arg(C)=atan2(1,2)≈0.463648 rad. The sum is √5 cos(πt+Arg(C)), not amplitude 3. At t=0 it is 2; at t=1/2 it is −1.

Second problem: 2cos(πt)+2cos(πt+π)=0 for every t. Cancellation requires both equal amplitudes and opposite phases. Phases π/3 and 4π/3 also cancel at equal amplitudes: the lab recognizes this relation instead of inventing a phase from a tiny numerical residual.

Explore and explain

5. Transform a shape with w=αz+β

The map w=αz+β acts on every point. For α=ρe^(iθ)≠0, multiplication rotates by θ about the origin and scales all lengths by ρ; β then translates. Angles are preserved and areas scale by |α|². Rotation about another centre h uses w=h+α(z−h), not the same origin-centred formula.

Example: α=i, β=1−i, z=2+i. i(2+i)=−1+2i, giving w=i. A 90° rotation followed by translation takes (2,1) to (0,1). The lab applies the map to a triangle and a chosen point; intermediate frames illustrate operations rather than additional final formulas.

Explore and explain

6. Reflection, orientation and inverse

Conjugation z↦conj(z) changes (x,y) to (x,−y): reflection in the real axis. Thus w=αconj(z)+β with α≠0 combines a mirror with rotation, scaling and translation, reversing triangle orientation. Multiplication by −1 instead rotates 180° without reversing orientation: it is not that reflection.

w=αz+β ⇒ z=(w−β)/α.
w=αconj(z)+β ⇒ z=conj((w−β)/α).

Both inverses require α≠0. For α=0 all points map to β: the shape collapses, area is zero and the original point cannot be recovered. The lab determinant is |α|² without reflection and −|α|² with reflection; zero signals loss of an inverse.

Explore and explain

7. Repeat a rule: z_(k+1)=z_k²+c

An orbit is a sequence produced by a rule: fix c and z₀, compute z₁=z₀²+c, then z₂=z₁²+c, and so on. Each new point comes from its predecessor, not an independent choice. For z_k=x+iy and c=a+ib:

x_next=x²−y²+a; y_next=2xy+b.

Example: c=1, z₀=0 give 0,1,2,5,26,… . For c=−1 the sequence is 0,−1,0,−1,… . Table rows are different calculation times; coincident points need not have the same index. The lab highlights z_k and explains the next step.

Explore and explain

8. Mandelbrot: vary parameter c

For the Mandelbrot set, fix z₀=0 and vary c. A parameter belongs when its orbit remains bounded. The image is the parameter plane c, not a single orbit’s path. Our lab follows one c at a time; the fractals lab repeats the test across many pixels.

For c=0 the orbit is fixed; for c=−1 periodic; for c=−2 it is 0,−2,2,2,… . In the Mandelbrot test, modulus strictly greater than 2 indicates escape. Equality is insufficient, as c=−2 shows. The definition concerns boundedness for all steps, not just the first hundred.

Explore and explain

9. Julia: vary the starting point

Now fix c and vary z₀. Starting points with bounded orbits form the filled Julia set K_c; its boundary is the Julia set J_c. A Mandelbrot pixel represents c; a Julia pixel represents z₀. The formula is the same, the question is different.

For c=0, |z_k|=|z₀|^(2^k). If |z₀|<1 it tends to zero; if |z₀|=1 it stays one; if |z₀|>1 it diverges. Thus K₀ is the unit disk and J₀ its circle: not every Julia set has a jagged boundary. Compare z₀=i, z₀=1/2 and z₀=2 in the lab without confusing an orbit point with the whole set.

Explore and explain

10. A finite test does not prove infinity

For fixed c and arbitrary starting point use escape radius R=max(2,|c|). If r=|z|>R, then |z²+c|≥r²−|c|>r(r−1)>r. Subsequent moduli grow at least by a factor greater than one, so the orbit diverges. Use strict inequality. For Mandelbrot’s special orbit z₀=0, threshold 2 suffices; do not transfer it blindly to every variant.

No observed escape within N steps means “not escaped within N”, not proven membership. Image colours encode escape times or other chosen data, not inherent colours of an abstract set. Floating-point calculation also rounds; boundary decisions need further precision and checks.

Explore and explain

11. Connect to the existing fractals material

The existing fractals article and lab explore Sierpiński, Cantor, Koch, trees, Mandelbrot and Julia. We do not replace them: we explain the complex operations behind them. Open the existing lab and choose Mandelbrot or Julia to move from one orbit to many points in a plane.

The connection is not limited to z²+c. Sierpiński’s triangle uses three contractions: f₁(z)=z/2, f₂(z)=z/2+1/2, f₃(z)=z/2+(1+i√3)/4. Each halves lengths and places a copy at a vertex. These are three maps acting on copies of a set, not the single quadratic orbit above.

Article: fractals, geometry and nature · Open the fractals lab

Explore and explain

12. Conclusions: choose the useful representation

We began with i²=−1 and connected arithmetic, geometry, powers, roots and equations. Now choose Cartesian form for sums and checks, polar or exponential form for rotations and powers, factors for roots and multiplicities, iteration for dynamics. There is no single formula for everything.

A good experiment changes one input, predicts an outcome and compares picture and calculation. Ask what is fixed, what varies and what the computer can really certify. All eight agreed stages are available; this concludes the introductory path, not all of complex analysis. More general oscillations, signals and dynamics need further models and theorems.

Explore and explain

Twelve exercises to try

1. For x(t)=3cos(4πt), find the period and x(1/8).

Show the explained solution

ω=4π=2πf gives f=2 Hz and T=1/2 s. At t=1/8 the angle is π/2, so x=0. Amplitude remains 3 despite a zero instantaneous projection.

2. Add 2cos(ωt+φ) and 3cos(ωt+φ).

Show the explained solution

The phasors point in one direction: C=(2+3)e^(iφ). The sum is 5cos(ωt+φ), with unchanged frequency and phase.

3. Do opposite phases with amplitudes 2 and 1 cancel?

Show the explained solution

No. C=2e^(iφ)+e^(i(φ+π))=(2−1)e^(iφ). A sinusoid of amplitude 1 remains. Total cancellation requires equal amplitudes.

4. For phasors 2 and i, find resultant amplitude and phase.

Show the explained solution

C=2+i, |C|=√5, Arg(C)=atan2(1,2)≈0.463648 rad. Adding moduli gives 3, which is not the resultant amplitude.

5. Apply w=iz to z=1+i.

Show the explained solution

w=i+i²=−1+i: a 90° rotation preserving lengths. Coordinates (1,1) become (−1,1), not a translation or reflection.

6. For w=2z+1−i and z=3i, find image and area factor.

Show the explained solution

w=6i+1−i=1+5i. Lengths double and areas scale by |2|²=4. Translation changes neither lengths nor areas.

7. Compare conj(2−3i) and −(2−3i).

Show the explained solution

Conjugation gives 2+3i, reflection in the real axis. The opposite is −2+3i, a 180° rotation about the origin. The maps differ.

8. Does w=0·z+(1+2i) have an inverse?

Show the explained solution

No: every point maps to 1+2i. A unique original z cannot be recovered. Determinant and image-triangle area are zero.

9. Compute five terms of z²−1 from z₀=0.

Show the explained solution

z₀=0,z₁=−1,z₂=0,z₃=−1,z₄=0. A period-two cycle: five terms do not mean five distinct points.

10. For Mandelbrot with c=1, when is threshold 2 exceeded?

Show the explained solution

0→1→2→5: step 3. Step 2 reaches 2 but does not exceed it. For c=−2 the orbit reaches 2 and stays there, so ≥2 would be wrong.

11. What does a pixel represent in Mandelbrot and Julia?

Show the explained solution

Mandelbrot varies c with fixed z₀=0. Julia varies z₀ with fixed c. Both use z_next=z²+c, but the question and plotted plane differ.

12. Does no escape in 100 steps prove a bounded orbit?

Show the explained solution

No: it records only what a finite test observed at its working precision. For c=0 we can separately prove K₀ is the unit disk and J₀ its circle using |z_k|=|z₀|^(2^k).

Learning-path index · Lab: what complex numbers are for

Further reading

MIT OpenCourseWare · Complex Arithmetic and Exponentials

Complex Dynamics · The filled Julia set