repo.or.cz
/
eigenmath-fx.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
blame
|
history
|
raw
|
HEAD
Little fix after the last commit (mostly a git fail)
[eigenmath-fx.git]
/
arcsinh.cpp
blob
d6534fab708c5b8f4b74a7b6f8a998e939144cf5
1
#include
"stdafx.h"
2
#include
"defs.h"
3
4
void
5
eval_arcsinh
(
void
)
6
{
7
push
(
cadr
(
p1
));
8
eval
();
9
arcsinh
();
10
}
11
12
void
13
arcsinh
(
void
)
14
{
15
double
d
;
16
save
();
17
p1
=
pop
();
18
if
(
car
(
p1
) ==
symbol
(
SINH
)) {
19
push
(
cadr
(
p1
));
20
restore
();
21
return
;
22
}
23
if
(
isdouble
(
p1
)) {
24
d
=
p1
->
u
.
d
;
25
d
=
log
(
d
+
sqrt
(
d
*
d
+
1.0
));
26
push_double
(
d
);
27
restore
();
28
return
;
29
}
30
if
(
iszero
(
p1
)) {
31
push
(
zero
);
32
restore
();
33
return
;
34
}
35
push_symbol
(
ARCSINH
);
36
push
(
p1
);
37
list
(
2
);
38
restore
();
39
}