
def calcFluidLevel(intake_pressure, specific_gravity=1.011, ft_above_intake=0.0, pressure_offset=0.0):
    fluid_level = (intake_pressure - pressure_offset) * (1.0 / 0.433) * (1.0 / specific_gravity) + ft_above_intake
    return fluid_level

def calcPressureAtLevel(fluid_level, specific_gravity=1.011, ft_above_intake=0.0, pressure_offset=0.0):
    intake_pressure = 0.433 * specific_gravity * (fluid_level - ft_above_intake) + pressure_offset
    return intake_pressure
