Wave Interference

Manipulate[
DensityPlot[q1 Cos[f Norm[{x,y}-xy1]-p]+q2 Cos[f Norm[{x,y}-xy2]-p],{x,-5,5},{y,-5,5},ImageSize->{420,420},MeshFunctions->{#3&},Mesh->If[ms,10,None],ImagePadding->None,ImageMargins->None,PlotRangePadding->None,Frame->False,PlotPoints->If[hq,Round[7f+5],Round[3f+5]],MaxRecursion->1,PlotRange->All,ColorFunction->(Blend[{White,RGBColor[.13, .35, .9]},#]&)],{{xy1,{-3,0},"position of source 1"},{-5,-5},{5,5},ControlType->Locator},{{q1,10,"amplitude of source 1"},-10,10,1},{{xy2,{3,0},"position of source 2"},{-5,-5},{5,5},ControlType->Locator},{{q2,10,"amplitude of source 2"},-10,10,1},Delimiter,
{{f,6,"frequency"},1,15},
{{p,1,"phase"},1,12 Pi},Delimiter,{{hq,False,"high quality"},{True,False},ControlPlacement->Left},{{ms,False,"show mesh"},{True,False},ControlPlacement->Left},AutorunSequencing->{{1,8},{3,8},{4,4},{5,8},{6,6},{7,4}},TrackedSymbols:>{xy1,xy2,q1,q2,p,f,hq}]

CAPTION

Interference patterns made by waves from two sources.

THIS NOTEBOOK IS THE SOURCE CODE FROM

"Wave Interference" from the Wolfram Demonstrations Project
 http://demonstrations.wolfram.com/WaveInterference/

Contributed by: Stephen Wolfram

A full-function Wolfram Mathematica system (Version 6 or higher) is required to edit this notebook.
GET WOLFRAM MATHEMATICA »

© Wolfram Demonstrations Project & Contributors   |   Terms of Use   |   Make a new version of this Demonstration »