I want to replace the symbol with a function to later take derivatives:
var("L r rdot theta thetadot t e d c G M r_s")
r = function("r")(t)
K2=(1-(rdot**2+r**2*thetadot)/c**2)/(1-rdot/c)**2
eq1=diff(K2,rdot)
eq1
yielding:
-2*rdot/(c^2*(rdot/c - 1)^2) + 2*((thetadot*r(t)^2 + rdot^2)/c^2 - 1)/(c*(rdot/c - 1)^3)
Now, I want to replace rdot, thetadot with derivatives of functions of time.
rdot = function("rdot")(t)
theta = function ('theta')(t)
thetadot=diff(theta,t)
rdot=diff(r,t)
eq2=diff(eq1,t)
I get a result but it is nonsense. 4thetadotr(t)diff(r(t), t)/(c^3(rdot/c - 1)^3)
How to do this properly?
Thank you
Marco
view(eq2)