# Function cbrt

Source

    pub fn cbrt(x: f64) -> f64

🔬This is a nightly-only experimental API. (`core_float_math` #137578)
Expand description

Experimental version of `cbrt` in `core`. See `f64::cbrt` for details.

## §Examples

    #![feature(core_float_math)]

    use core::f64;

    let x = 8.0_f64;

    // x^(1/3) - 2 == 0
    let abs_difference = (f64::math::cbrt(x) - 2.0).abs();

    assert!(abs_difference < 1e-10);

This standalone function is for testing only. It will be stabilized as an inherent method.