Category : UNIX Files
Archive   : MATH_CO.ZIP
Filename : MATH_CO.BC
/* File: MATH_CO.BC Additional Math Library for COHERENT version 3.1.0 */
/* See file MATH_CO.DOC for documentation of use. Victor Cummings */
py=3.14159
define sign(x) {
if (x>0) return(1)
if (x==0) return(0)
if (x<0) return(-1)
}
define sec(x) {
return (1/cos(x))
}
define csc(x) {
return (1/sin(x))
}
define tan(x) {
return (sin(x)/cos(x))
}
define cot(x) {
return (cos(x)/sin(x))
}
define abs(x) {
return(sqrt(x*x))
}
define arcsin(x) {
return (atan(x/sqrt(-x*x+1)))
}
define arccos(x) {
return(-atan(x/sqrt(-x*x+1))+1.5708)
}
define arcsec(x) {
return(atan(x/sqrt(x*x-1))+sign(sign(x)-1)*1.5708)
}
define arccsc(x) {
return(atan(x/sqrt(x*x-1))+(sign(x)-1)*1.5708)
}
define arccot(x) {
return(atan(x) + 1.5708)
}
define sinh(x) {
return((exp(x)-exp(-x))/2)
}
define cosh(x) {
return((exp(x)+exp(-x))/2)
}
define tanh(x) {
return((exp(x)-exp(-x))/(exp(x)+exp(-x)))
}
define coth(x) {
return((exp(x)+exp(-x))/(exp(x)-exp(-x)))
}
define log(x) {
return(ln(x)/ln(10))
}
define arcsinh(x) {
return(log(x+sqrt(x*x+1)))
}
define arccosh(x) {
return(log(x+sqrt(x*x-1)))
}
define arctanh(x) {
return(log((1+x)/(1-x))/2)
}
define arcsech(x) {
return(log((sqrt(-x*x+1)+1)/x))
}
define arccoth(x) {
return(log((x+1)/(x-1))/2)
}
Very nice! Thank you for this wonderful archive. I wonder why I found it only now. Long live the BBS file archives!
This is so awesome! 😀 I’d be cool if you could download an entire archive of this at once, though.
But one thing that puzzles me is the “mtswslnkmcjklsdlsbdmMICROSOFT” string. There is an article about it here. It is definitely worth a read: http://www.os2museum.com/wp/mtswslnk/