now next part isn't working
If you go step by step, it will become more clear. I assume this is what you wanted. This is for one solution from Solve
for illustration, as there are 4 solutions. You can do the same for the other 3 solutions. You also need to change x
to x[t]
to make an ode. Also it is better to use exact numbers with DSolve
. Also the first plot should be w.r.t. x
and not a
since a
is a number.
Clear["Global`*"]
eqns = {y[x]^2 - Sqrt[3] (a/b) y[x]*Sqrt[y[x]^2 - k x^-2 - f] -
k (1 - 2/(3 b)) x^-2 - f == 0};
a = 1; b = 24/100; f = 68/100; k = 2/1000;
(*use first solution for now *)
sol = y[x] /. First@FullSimplify[Solve[eqns, y[x]]]
Plot[Abs@sol, {x, 1, 10}]
y1 = sol /. x -> x[t]
ode = y1 == x'[t]/x[t]
But this ode can't be solved exactly (it is non linear) and the solution has an integral that can not be solved
DSolve[ode, x[t], t]
You might want to use NDSolve
instead.
DSolve
oneqns
. $\endgroup$DSolve
,Solve
,NDSolve
.... They return sets ofRule[]
objects, and usually users want to deal with scalar numeric expressions -- certainly forPlot
. You need to convert your solutions to such expressions or useDSolveValue
,SolveValues
[sic],NDSolveValue
.... $\endgroup$