-1

I want to plot Sin[a*x] and have used the following code:

Plot[Sin[a*x], {a,0,10},{x, 0, 10}]

But I am not getting any plot. Any Ideas?

Priyesh Sharma
  • 359
  • 1
  • 3

2 Answers2

3

Are you looking for something like this?

Manipulate[Plot[Sin[a*x], {x, 0, 10}], {a, 0, 10}]

or this?

Plot[Evaluate@Table[Sin[a*x], {a, 0, 2}], {x, 0, 10}]
zhk
  • 11,939
  • 1
  • 22
  • 38
  • Yes, something like the first one. Thanks – Priyesh Sharma Mar 03 '19 at 16:21
  • I tried f[max_] := Plot[Sin[a*x], {x, 0, max}] Manipulate[f[max], {a, 1, 5}, {max, 10, 20}]. But, that wasn't giving me the desired result either. Didn't understand why though – Priyesh Sharma Mar 03 '19 at 16:28
  • @Maria because https://mathematica.stackexchange.com/questions/10604/how-are-parameters-evaluated-for-a-plot-in-manipulate – Kuba Mar 03 '19 at 18:40
1
Plot3D[Sin[a*x], {a,0,10},{x, 0, 10}]
Roman
  • 47,322
  • 2
  • 55
  • 121