diff options
Diffstat (limited to 'math.c')
-rw-r--r-- | math.c | 28 |
1 files changed, 28 insertions, 0 deletions
@@ -113,6 +113,30 @@ math_tanh(obj, x) } static VALUE +math_acosh(obj, x) + VALUE obj, x; +{ + Need_Float(x); + return rb_float_new(acosh(RFLOAT(x)->value)); +} + +static VALUE +math_asinh(obj, x) + VALUE obj, x; +{ + Need_Float(x); + return rb_float_new(asinh(RFLOAT(x)->value)); +} + +static VALUE +math_atanh(obj, x) + VALUE obj, x; +{ + Need_Float(x); + return rb_float_new(atanh(RFLOAT(x)->value)); +} + +static VALUE math_exp(obj, x) VALUE obj, x; { @@ -212,6 +236,10 @@ Init_Math() rb_define_module_function(rb_mMath, "sinh", math_sinh, 1); rb_define_module_function(rb_mMath, "tanh", math_tanh, 1); + rb_define_module_function(rb_mMath, "acosh", math_acosh, 1); + rb_define_module_function(rb_mMath, "asinh", math_asinh, 1); + rb_define_module_function(rb_mMath, "atanh", math_atanh, 1); + rb_define_module_function(rb_mMath, "exp", math_exp, 1); rb_define_module_function(rb_mMath, "log", math_log, 1); rb_define_module_function(rb_mMath, "log10", math_log10, 1); |