# How can I animate the plot of solutions to this system with different initial conditions?

I would like to plot the curves given by $\alpha(s) = (u(s), v(s))$, where $u$ and $v$ are like below.

Clear[u, v];
{u, v} = {u[t], v[t]} /.
NDSolve[{u'[t]^2 + v'[t]^2 == 1,
u'[t] v''[t] - u''[t] v'[t] == u[t] v'[t] - v[t] u'[t],
u'[0] == Sin[0.18], v'[0] == Cos[0.18]}, {u[t], v[t]}, {t, -7.5,
7.5}][[1]];


What I want to do is, for each different initial conditions $u'(0) = \cos(\theta)$, $v'(0) = \sin(\theta)$, $u'(t)v''(t) - u''(t)v'(t) = -c(u'(t)v(t) - u(t)v'(t))$ with $\theta$ varying in $[0, 2\pi]$ and $c$ varying in, say, $(0, 10]$, plot a new curve. I'm new to Mathematica so I still have a hard time doing these little things.

ClearAll[u, v, θ, c]
pndsv = ParametricNDSolveValue[{u'[t]^2 + v'[t]^2 == 1,
u'[t] v''[t] - u''[t] v'[t] == -c (-u[t] v'[t] + v[t] u'[t]),
u'[0] == Cos[θ], v'[0] == Sin[θ]}, {u, v}, {t, -7.5, 7.5}, {c, θ}]


An alternative visualization of the solution:

Manipulate[ParametricPlot[Evaluate@Through@pndsv[c, θ][t], {t, -7.5, 7.5},
PlotRange -> {{-3, 3}, {-3, 3}}], {c, 0, 10}, {θ, 0, 2 Pi}]


• Thanks! In the image you posted it appears I could type the parameters of $c$ and $\theta$, but when I run the code I only have slider controls. Why is that? Sep 13, 2018 at 23:08
• @MatheusAndrade, i used Autorun from the + menu to get the picture. You can also use the + button next to the slider to get the input field and other animation controls.
– kglr
Sep 13, 2018 at 23:22

Use ParametricNDSolveValue instead:

sol=ParametricNDSolveValue[
{
u'[t]^2 + v'[t]^2 == 1,
u'[t] v''[t] - u''[t] v'[t] == c (u[t] v'[t] - v[t] u'[t]),
u'[0] == Sin[θ],v'[0] == Cos[θ]
},
{u,v},
{t, -7.5, 7.5},
{c, θ}
];


Then, you can use Manipulate to explore the plot for different values of the parameters:

Manipulate[
Plot[{sol[c,θ][[1]][x],sol[c,θ][[2]][x]}, {x,-7.5,7.5}],
{{c, 1}, 0, 10},
{{θ, .18}, 0, 2Pi}
]