PrevUpHomeNext

utx::cbrt


utx::cbrt

Calculate the cube root of value.

Calling Sig:

constexpr auto result = utx::cbrt(value);
constexpr auto result = utx::cbrt.fn<return_type>(value);

utx::cbrt(value)

utx::cbrt.fn<return_type>(value)

Header

#include <utxcpp/math.hpp>

Example

#include <utxcpp/core.hpp>
#include <utxcpp/math.hpp>

int main()
{
	constexpr auto x = utx::cbrt(-8); // return utx::f32
	utx::print(x); // -2.000000

	constexpr auto y = utx::cbrt(8.12f); // return utx::f32
	utx::print(y); // 2.009950

	constexpr auto z = utx::cbrt(-8.12); // return utx::f64
	utx::print(z); // -2.009950

	constexpr auto a = utx::cbrt(utx::ix32{8}); // return utx::fx32
	utx::print(a); // 2.000000
}

See Also

utx::print

utx::sqrt

utx::fact

utx::i32

utx::ix32


PrevUpHomeNext

utx::print

esv::print