See the figure below for the ray diagram.
The equation that relates the position of the object, image and focal distance for a spherical mirror is
`1/(x1) +1/(x2) =1/f`
using the following conventions
x1 (the position of the object) is positive if the object is to the left of the mirror
x2 (the position of the image) is positive if the image is to the left of the mirror
f (focal distance) is positive for concave mirrors
By definition the magnification is
`M =-(y2)/(y1) =-(x2)/(x1)`
With the data in text one has
`1/(x1) -1/(4*x1) =1/f`
`f = (4*x1)/3 =(4*5)/3 =6.67 m`
Because the magnification is positive the image is behind the mirror which means it is virtual.