0
$\begingroup$

I have an equation:

e == m*c^2 + (1/2)*c^2*m*v^2

$$e==m c^2 + \frac{1}{2}c^2\space m\space v^2$$

I need to remove the $v$ variable and replace it with $p$. I also know that $p=m\space v$. If I multiply the second expression of this equation by $m/m$, I can get:

$$e==m c^2 + \frac{1}{2}\frac{c^2\space m^2\space v^2}{m}$$And then I can make the substitution $p=mv$ to get: $$e==m c^2 + \frac{1}{2}\frac{c^2\space p^2}{m}$$ How do I make force Mathematica to make this substitution for me?

$\endgroup$
2
  • 4
    $\begingroup$ /. v -> p/m ? $\endgroup$ – Szabolcs Mar 20 at 20:01
  • $\begingroup$ Now that I see it, it looks simple. Thank you. $\endgroup$ – Quarkly Mar 20 at 20:04

Browse other questions tagged or ask your own question.