PrevUpHomeNext

esv::cbrt


The smell of birds and flowers is better than the smell of wine.

esv::cbrt

Calculate the cube root of value.

Calling Sig:

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

esv::cbrt(value)

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

Header

#include <esvcpp/math.hpp>

Example

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

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

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

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

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

See Also

esv::print

esv::sqrt

esv::fact

esv::i32

esv::ix32


PrevUpHomeNext

esv::print