]> www.ginac.de Git - cln.git/blob - src/complex/algebraic/cl_C_abs_aux.cc
98ba4660e2090d115be071bf33b8f2c33579d992
[cln.git] / src / complex / algebraic / cl_C_abs_aux.cc
1 // abs().
2
3 // General includes.
4 #include "cl_sysdep.h"
5
6 // Specification.
7 #include "cl_C.h"
8
9
10 // Implementation.
11
12 #include "cl_real.h"
13
14 MAYBE_INLINE
15 const cl_R abs (const cl_C& x)
16 {
17         var const cl_R& a = realpart(x);
18         var const cl_R& b = imagpart(x);
19         return cl_hypot(a,b);
20 }