(*Isthishowtodefineafuncwithafuncargument?*)​​(*CanitbewrittentoconformtoMathematicaconvention​​wherelastthreevariablesarealist?*)​​myPlot[f_,var_,a_,b_]:=​​Manipulate[​​Show[​​Plot[f[var],{var,a,b}],​​Graphics[{PointSize[.02],Point[{pnt,f[pnt]},​​VertexColorsRed]}]],​​{pnt,a,b}]​​​​(*Itworkswithoneindependentvariable*)​​f[x_]:=x^2​​myPlot[f,x,-2,2]​​​​(*Butwhataboutmultipleindependentvariables?*)​​ff[x,t,z]:=x^3/t+z​​(*Orwhatifit'sjustanexpression,say,x^3?*)​​​​(*HowdoIgetmyPlottoimagef[x]ANDff[x,3,7]andx^3?*)​​
Out[]=
​
pnt
-2
-1
1
2
-1.0
-0.5
0.5
1.0