thx函数在c语言里怎么调用?
双曲正切函数吗。
双曲正切的定义为 sinh(x)/cosh(x)
用到c里边的话,
头文件:#include
tanh() 用来求一个数的双曲正切值,其原型为:
double tanh(double x);
参数x 为双曲正切上的某点。
返回 x 的双曲正切值,取值范围为 -1 到 1。
给你举个栗子
#include
main(){
double answer = tanh(0.5);
printf("tanh(0.5) = %f\n", answer);
}