rad2deg

koadrobot/math/rad2deg

Convert radian to degree .
rad2deg
@/rad2deg
Convert radian to degree .
RADnumber
Angle in radians.
rad2deg
RAD
DEG
DEGnumber
Angle in degrees.
To use the node in your project you should have the koadrobot/math library installed. Use the “File → Add Library” menu item in XOD IDE if you don’t have it yet. See Using libraries for more info.

C++ implementation

#pragma XOD dirtieness disable

struct State {
};

{{ GENERATED_CODE }}

void evaluate(Context ctx)
{
    Number x = getValue<input_RAD>(ctx);
    emitValue<output_DEG>(ctx, x * 57.295779513);
}

Tabular tests

RADDEG
NaNNaN
InfInf
-Inf-Inf
1.57079690~
3.141592180~
00
6.283185360~
0.78539845~
4.712388270~
0.0174531~