Calculates the arc cosine of x, returning a value ranging from 0 to π.
import std.math.operations : isClose; import std.math.traits : isNaN; import std.math.constants : PI; assert(acos(0.0).isClose(1.570796327)); assert(acos(0.5).isClose(PI / 3)); assert(acos(PI).isNaN);
See Implementation
Calculates the arc cosine of x, returning a value ranging from 0 to π.