I was suggesting something simpler than the google
search above. What I seem to run into are situations
where there are alternate methods of computing the
function over parts of the range.
Here are two examples. One is
2*csch(x)^2*(x*coth(x)-1)
and the other is
(1/x - 1/(2*sinh(x/2)))/x.
The second might be reasonably efficient for x sufficiently
far from 0, which might not need to be too far to be useful.
For x near 0, either the power series or a procedure to
calculate sinh(z)-z to precision accuracy would be a possibiliy.
For the first, I would not use the stated expression for
computation anywhere. For x large, express the function
in exp(-2*x), or even in z = 1/(exp(2*x) - 1), whence the
function to be calculated becomes z*(z+1)*(x*(1+2*z)-1).
but this is not good near 0. Here I would calculate
coth(x) - 1/x, either by series or by the excellent
continued fraction
x/3/(1+x^2/(3*5)/(1+x^2/(5*7)/(1+ ...
and use the identity csch(x)^2 = coth(x)^2-1.
You users of CAS, tell me how you would instruct the system,
if you can. And more, tell me how you would go about designing
the system so that the user would not need to supply that much
information. If we are going to automate it, that needs to be
done; I do not see that much automation at this time.