1

custom unit conversion from GJ to Kwh

Hello Everyone, I am trying to make a reporting measure to display things like EUI and Energy use in Kill-watt Hour(Kwh) but the openstudio unit conversion is limited to GJ and J. How do I convert the unit to Kwh?

https://nrel.github.io/OpenStudio-use...

Sourav Ganguli's avatar
13
Sourav Ganguli
asked 2018-06-06 03:18:43 -0500
__AmirRoth__'s avatar
4.4k
__AmirRoth__
updated 2018-06-07 19:36:59 -0500
edit flag offensive 0 remove flag close merge delete

Comments

add a comment see more comments

1 Answer

4

OpenStudio unit converter does do GJ to kWh:

OpenStudio.convert(1,"GJ","kWh").get
#=> 277.77777777777777

Or you can hardcode it since you aren't changing unit systems. A watt is a joule per second, so a kilowatt-hour is (1000 joules / second) * (3600 seconds / hour) = 3.6*10^6 joules = 0.0036 gigajoules. (1/0.0036) = 277.77. So just divide GJ by 0.0036 to get kWh.

mdahlhausen's avatar
9.5k
mdahlhausen
answered 2018-06-07 17:27:19 -0500
edit flag offensive 0 remove flag delete link

Comments

add a comment see more comments