The physics
Measure every distance from the mirror's pole. Take the way the light travels as +. So a real object has u < 0. A concave mirror has f < 0, and a convex mirror f > 0.
f = R/2 1/v + 1/u = 1/f m = −v/u = f/(f − u)
Parallel rays meet at the focus F, halfway to the centre of curvature C. A negative v means a real image in front of the mirror. A positive v means a virtual image behind it.
A negative m means the image is upside down. A rod along the axis needs each end imaged on its own.
Along the axis, the image moves at m² times the object's speed. A moving mirror also carries the image with it.
vimage = vm − m²(vo − vm)