I have a 3-D data set (linked in the comment below) obtained via numerical integration. I would like to generate an interpolating function, and then use this function to numerically solve an ODE. For reference, the 3-D function looks like this:
The data set is used to create the interpolated function:
int = Interpolation[Flatten[Data1,1]]
I then sought to use NDSolve for the ODE xtraj'[T]==int[X,T]
, making the replacement X->xtraj[T]
. I then sought to solve the ODE for T=[-1,1]
for example. However I have not been successful in plotting the solution; using ParametricPlot
does not yield anything.
ode = {xtraj'[T] == int[X, T] /. {X -> xtraj[T]}, xtraj[-2] == -2}
trajectories = NDSolve[ode, xtraj[T], {T, -1, 1}]
ParametricPlot[trajectories, {T, -1, 1}]
Any help as to why the solution is not plotting, or fixes re: syntax errors or a better solution would be much appreciated.
42/25
which can't be evaluated! $\endgroup$