y1[x_,t_,A1_,v1_,f1_]=A1*Cos[2*π*f1*((x/v1)-t)];
y2[x_,t_,A2_,v2_,f2_,ϕ_]=A2*Cos[2*π*f2*((x/v2)-t)-ϕ];
y[x_,t_,A1_,A2_,v1_,v2_,f1_,f2_,ϕ_]=y1[x,t,A1,v1,f1]+y2[x,t,A2,v2,f2,ϕ];
Manipulate[
GraphicsGrid[
{
{Plot[
y1[x,t,A1,v1,f1],{x,0,40},
ImageSize->300,
PlotRange->{{0,40},{-0.4,0.4}},
PlotStyle->{RGBColor[0, 0.501961, 1],Thickness[0.005]},
AxesLabel->{x[m],(Subscript[y, 1])[m]},
LabelStyle->(FontSize->12),
Mesh->{Range[0,20,20]},
MeshStyle->{PointSize[0.02],Red}
]
},
{Plot[
y2[x,t,A2,v2,f2,ϕ],{x,0,40},
ImageSize->300,
PlotRange->{{0,40},{-0.4,0.4}},
PlotStyle->{RGBColor[0, 0.501961, 1],Thickness[0.005]},
AxesLabel->{x[m],(Subscript[y, 2])[m]},
LabelStyle->(FontSize->12),
Mesh->{Range[0,20,20]},
MeshStyle->{PointSize[0.02],Red}
]
},
{Plot[
y[x,t,A1,A2,v1,v2,f1,f2,ϕ],{x,0,40},
ImageSize->300,
PlotRange->{{0,40},{-0.4,0.4}},
PlotStyle->{RGBColor[0, 0.501961, 1],Thickness[0.005]},
AxesLabel->{x[m],((Subscript[y, 1])+(Subscript[y, 2]))[m]},
LabelStyle->(FontSize->12),
Mesh->{Range[0,20,20]},
MeshStyle->{PointSize[0.02],Red}
]
}
}
],
{{A1,0.2,"(Subscript[A, 1])"},0,0.4, 0.05,Appearance->"Labeled"},
{{v1,10,"(Subscript[v, 1])"},-50,50,5,Appearance->"Labeled"},
{{f1,0.5,"(Subscript[f, 1])"},0.1,5,0.1,Appearance->"Labeled"},
Delimiter,
{{A2,0.0,"(Subscript[A, 2])"},0,0.4, 0.05,Appearance->"Labeled"},
{{v2,10,"(Subscript[v, 2])"},-50,50,5,Appearance->"Labeled"},
{{f2,0.5,"(Subscript[f, 2])"},0.1,5,0.1,Appearance->"Labeled"},
Delimiter,
 {{ϕ,0,"ϕ"},-π,π,(π/8),Appearance->"Labeled"},
Delimiter,
 {{t,0,"t"},0,20,0.01,ControlType-> Animator, AnimationRunning-> False, AnimationRate->.25},
ControlPlacement->Right,
SaveDefinitions->True
]