vunits.convert.energy_to_temp

vunits.convert.energy_to_temp(energy, units_in='J', return_quantity=False, units_out='K')

Converts energy to temperature

Parameters
  • energy (float) – Energy

  • units_in (str, optional) – Units corresponding to energy. Default is ‘J’.

  • return_quantity (bool, optional) – If True, returns Quantity. Otherwise, returns float.

  • units_out (str, optional) – Units corresponding to temp. Default is ‘K’.

Returns

temp – Temperature corresponding to units_out.

Return type

float or Quantity obj