Table Of Contents
TANH Function in Excel
Last Updated :
-
Blog Author :
Edited by :
Reviewed by :
How to Use TANH Formula in Excel?
Example #1
Let us consider a set of angles (in radian) 0, 0.5, 1, 1.5, 2, 2.5, 3, 3.5, 4, and 5 to understand the working of TANH.
Now, apply the TANH in the cell, as shown in the below table. TANH will return the hyperbolic tangent function of all the supplied values as 0, 0.46, 0.76, 0.91, 0.96, 0.99, 1.00, 1.00, 1.00 and 1.00.
Example #2
In this TANH example, we take the sample of negative angles (in radian) and then apply the TANH formula to them.
Let us consider a set of positive integers -0.1, -0.5, -1, -1.5, -2, -2.5, -3, -3.5, -4 and -5 to understand the working of TANH. Now, apply the TANH in the cell as shown in the below table. The TANH function provides the hyperbolic tangent function as -0.10, -0.46, -0.76, -0.91, -0.96, -0.99, -1.00, -1.00, -1.00 and -1.00.
Example #3
Suppose you have the angle in degree, then you have to convert the degree to radian by using the RADIAN function as shown below table, then apply the TANH formula to calculate the hyperbolic tangent function of the given angle.
Example #4
Suppose you have the angle in degree, then you have to convert the degree to radian, multiplying the degree angle to PI/180, as shown in the below table, then apply the TANH formula to calculate the hyperbolic tangent function of the given angle.
Example #5
Suppose the given angle is in degree, and you want a hyperbolic tangent function. Then, you must first convert the degree angle to radian by RADIAN() function or multiply it by PI()/180 and apply the TANH formula. Now, the output will be in radian at the end, reverse the process and multiply the output angle 180/PI() to convert the output angle into the degree.
TANH Function can be used as a VBA function.
Dim TANHnumber As Long
TANHnumber = Application.worksheetfunction.TANH(“0”)
Msgbox(TANHnumber) // Return the nearest TANH value in message box.
The output will be “0” and printed in the message box.
Things to Remember
- If the supplied number is a non-numeric value, then TANH will return the #VALUE! Error.
- The number is the angle in radians.
- If the number is in degrees, multiply it by PI/180 to convert it into radians.
- If you want the result in a degree, multiply the result by 180/PI.
Recommended Articles
This article has been a guide to TANH Function in Excel. We discuss using TANH in Excel, examples, and downloadable templates here. You may also look at these useful functions in Excel:-
- TAN Function
- LEN Excel Function
- CEILING Function in Excel
- Examples of DAY Excel Function
- Excel Reverse Order