I'm trying to do part a) of this calculus 1 problem in Mathematica V9:
http://tutorial.math.lamar.edu/Classes/CalcI/RelatedRates.aspx#Deriv_Rates_Ex4
Warning noob code below!
st = 5/14 == r/h; (* 1. Similiar triangles to relate radius and height *)
radius = Solve[st, r][[1]]; (* 2. Get radius in terms of height *)
dr = Dt[radius]; (* 3. Get dr in terms of dh *)
dv = Dt[v == (1/3) r^2 h]; (* 4. Implicitly diff the volume of our leaky cone *)
dv /. { Dt[v] -> -2, dr[[1]], radius[[1]], h -> 6 } (* replace unknowns with knowns *)
My problem is in the last line above. There's still an h remaining. Why didn't it get replaced? If I could properly replace it, I can then take one more step and solve this related rates problem by solving for Dt[h].
