0
$\begingroup$

I'm trying to figure out how to make a ball oscillate straight up and down using an equation such as Cos[Pi*x*3]. I want to use the Manipulate feature to act as the x value, but I don't want the x value represented graphically at all. How can I essentially create a one dimensional plot using Mathematica?

$\endgroup$
1
  • $\begingroup$ At first I tried to use only the plot function (minus the dot), but when i couldn't alter the x coordinates, I figured I'd have to use the graphics feature. $\endgroup$ – user2379694 Dec 21 '16 at 1:13
0
$\begingroup$
Animate[Graphics[{Red, PointSize[0.02], Point[{0, Cos[3 Pi p]}]}, 
  PlotRange -> {-1, 1}, Axes -> True], {p, 0, 1}]

enter image description here

$\endgroup$
0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.