TransWikia.com

How to plot a function using a table particular values

Mathematica Asked by irondonio on December 27, 2020

I would like to plot the following function in terms of kR, but using specific different values, I think the best easy way is using a Table. This is a common useful problem to explore numerical the behavior in a particular function, this is the code

k = 2 Pi; R = 1; 
f =  Sin[ Sqrt[π] /Sqrt[ n k R] ] E^(-((I k (R^2 + z^2))/(2 R))) ;

Change R, this code generates k R= 2Pi, 3 Pi, 4 Pi. But, The idea is to plot , let say plot k R = 2Pi, 50 Pi, and 100 Pi

Of course it is simple for this case since could be evaluated, and show a legend. Interesting suggestions are welcome, thanks

Plot[Evaluate[Table[Re[f], {n, 3}]], {z, 0, 20}, 
Filling -> Axis, 
PlotRange -> All, 
AxesLabel -> {z, f }]


 

Add your own answers!

Ask a Question

Get help from others!

© 2024 TransWikia.com. All rights reserved. Sites we Love: PCI Database, UKBizDB, Menu Kuliner, Sharing RPP