# Visualizing interference of two waves on the plane

I need to make an animation of interfering coherent waves on the plane, that are produced by two sources. I would really appreciate if I am able to change the wavelength.

I am quite new to Wolfram, so I have completely no idea on how to make these "two" waves react to each other and show that to the user.

• Take a look at this Wolfram Demonstration for a start: demonstrations.wolfram.com/WaveInterference. You can get the source code of the demonstration as well – MarcoB Jul 17 '16 at 20:11
• What kind of sources (points, apertures, ...), what kind of time dependence? What have you tried? – Jens Jul 17 '16 at 20:17
• Here's a starting point: ReliefImage[ Table[ Sin[Norm[{x + 4, y}]] + Sin[Norm[{x - 4, y}]], {x, -30., 30., .1}, {y, -30., 30, .1} ], ColorFunction -> "Aquamarine" ] Also look up DensityPlot. – Szabolcs Jul 17 '16 at 20:23

I guess you're looking for something like this:

wave[x_, y_, x0_, y0_, l_, t_] :=
Sin[Sqrt[(x - x0)^2 + (y - y0)^2]/l + t];

Manipulate[
DensityPlot[
wave[x, y, d, 0, l1, t l1 l2] +
wave[x, y, -d, 0, l2, t l1 l2], {x, -100, 100}, {y, -100, 100},
Mesh -> 10, PlotPoints -> 50],
{d, 5, 20},
{l1, 5, 20},
{l2, 5, 20},
{t, 0, 1}]


d controls the distance between sources, l1 and l2 changes their wavelengths.

Another example

Manipulate[
ContourPlot[
wave[x, y, d, 0, l1, t l1 l2] +
wave[x, y, -d, 0, l2, t l1 l2], {x, -100, 100}, {y, -100, 100},
Mesh -> 10, PlotPoints -> 100, Contours -> {-0.5, 0.5}], {d, 5,
20}, {l1, 5, 20}, {l2, 5, 20}, {t, 0, 1}]


• Thanks. But I want waves to move to see the process of interferrence itself. Do I add "Dynamic" or sth of this kind? – Michael Freimann Jul 18 '16 at 5:12
• I didn't include it because it might be kind of slow. – Lucas Jul 18 '16 at 15:14
• @MichaelFreimann I've updated it, I just included a additional Manipulate field for t (with the right period). Use the + then just press play. – Lucas Jul 18 '16 at 15:23
• Thanks a lot! I now about the density plot. – Michael Freimann Jul 19 '16 at 15:58
• @MichaelFreimann see updated answer – Lucas Jul 19 '16 at 22:50