code: def moist_static_energy(heights, temperature, specific_humidity):
      r
      return (dry_static_energy(heights, temperature)
              + mpconsts.Lv * specific_humidity.to('dimensionless')).to('kJ/kg')
docs: r"""Calculate the moist static energy of parcels.
  
      This function will calculate the moist static energy following
      equation 3.72 in [Hobbs2006]_.
      Notes
      -----
      .. math::\text{moist static energy} = c_{pd} * T + gz + L_v q
  
      * :math:`T` is temperature
      * :math:`z` is height
      * :math:`q` is specific humidity
  
      Parameters
      ----------
      heights : array-like
          Atmospheric height
      temperature : array-like
          Atmospheric temperature
      specific_humidity : array-like
          Atmospheric specific humidity
  
      Returns
      -------
      `pint.Quantity`
          The moist static energy