sqrt

Function sqrt 

Source
pub fn sqrt(arg: &Expression) -> Expression
Expand description

Evaluate square root function

§Mathematical Definition

√x = x^(1/2)

§Arguments

  • arg - Expression to compute square root of

§Returns

Square root expression

§Examples

use mathhook_core::functions::elementary::sqrt_eval::sqrt;
use mathhook_core::expr;

let result = sqrt(&expr!(4));
assert_eq!(result, expr!(2));