- 论坛徽章:
- 0
|
格式为:
$echo $((sqrt(2)))
1.41421356237309505
$
ksh中函数有:
abs acos acosh asin asinh atan atan2 atanh cbrt copysign cos cosh erf erfc exp exp2 expm1 fabs fdim
finite floor fma fmax fmod hypot ilogb int isinf isnan lgamma log log2 logb nearbyint nextafter nexttoward
pow remainder rint round sin sinh sqrt tan tanh tgamma trunc
每一个函数的用法都可以通过man的方式获得,如
$man nexttoward
The nextafter() functions return the next representable neighbor of x in the direction towards y. The
size of the step between x and the result depends on the type of the result. If x = y the function sim-
ply returns y. If either value is NaN, then NaN is returned. Otherwise a value corresponding to the
value of the least significant bit in the mantissa is added or subtracted, depending on the direction.
The nexttoward() functions do the same as the nextafter() functions, except that they have a long double
second argument.
...... |
|