C examples for complex.h:tanh
function template
<complex> <complex.h>
Hyperbolic tangent of complex
template<class T> complex<T> tanh (const complex<T>& x);
Parameter | Description |
---|---|
x | Complex value, representing an angle expressed in radians. |
Hyperbolic tangent of x.
#include <iostream> // std::cout #include <complex> // std::complex, std::real int main ()//from www .j a va 2 s . com { std::complex<double> mycomplex (10.0,1.0); std::cout << std::tanh(mycomplex) << '\n'; return 0; }