Function nth_root

Source
pub fn nth_root(func: Function, n: f64) -> Function
Expand description

Creates a Function equal to the nth root of the passed Function

i.e f(x) ⟹ √f(x)

Example:

    let x = function::default();
    let nth_root_of_x = nth_root(x, 3);
    assert_eq!(nth_root_of_x.call(8.), 2.);