Hacker News new | ask | show | jobs
by FnuGk 1983 days ago

  You have: 1 kelvin
  You want: degcelsius
     * 1
     / 1
This does not seem right
4 comments

It is. The unit Kelvin is equal to the degree Celsius. If you want to convert temperatures, you need to use tempK and tempC:

    You have: tempK(1)
    You want: tempC
            -272.15
Makes sense because temperatures don't have a linear conversion.

From the man page: Nonlinear units are represented using functional notation. They make possible nonlinear unit conversions such as temperature.

  You have: tempK(1)
  You want: tempC
 -272.15
Edit: seems i am not alone :D
It's right in the sense that the units are the same size. IE if something increases 10 deg K it also increases 10 deg C. But it's obvious to humans that that isn't what you where asking.

Compare:

   You have: 1 degF
   You want: degcelsius
           * 0.55555556
           / 1.8
Nitpick: There are no "deg K", because it is an absolute system it doesn't have degrees.

Notice you also don't need degrees metre, degrees watt or degrees newton, because those are absolute units they are metres, watts and newtons. It is Celsius (and Fahrenheit) which are weird because they aren't absolute but instead have this arbitrary zero point.

https://www.gnu.org/software/units/manual/units.html#Tempera...

> Conversions between temperatures are different from linear conversions between temperature increments—see the example below. The absolute temperature conversions are handled by units starting with ‘temp’, and you must use functional notation. The temperature-increment conversions are done using units starting with ‘deg’ and they do not require functional notation.