pub fn tanh(arg: &Expression) -> ExpressionExpand description
Evaluate hyperbolic tangent tanh(x)
§Mathematical Definition
tanh(x) = sinh(x) / cosh(x) = (e^x - e^(-x)) / (e^x + e^(-x))
§Arguments
arg- Expression to compute tanh of
§Returns
Hyperbolic tangent expression
§Examples
use mathhook_core::functions::elementary::hyperbolic_eval::tanh;
use mathhook_core::expr;
let result = tanh(&expr!(0));
assert_eq!(result, expr!(0));