I had to store the molar gas constant in a place where I had to write the type of the variable for Rust. The SI unit is "joule per kelvin per mole". Heat capacity is "joule per kelvin" and molar energy is "joule per mole", so neither will do directly.
What I finally came up with much trial and error was:
I had to store the molar gas constant in a place where I had to write the type of the variable for Rust. The SI unit is "joule per kelvin per mole". Heat capacity is "joule per kelvin" and molar energy is "joule per mole", so neither will do directly.
What I finally came up with much trial and error was:
However, this is not really user friendly. Perhaps there could be a macro to help with this?