Calculation order of bulk density and voidage

Hi, everyone. In calc_vol_fr.f, the voidage(ep_g) is calculated like this:
image
So ep_g is equal to rop_g divided by ro_g.
But in the physical_prop.f file, rop_g is calculated by ro_g*ep_g.


Which of ep_g and rop_g is calculated first in the calculation process?