GNU Octave  9.1.0
A high-level interpreted language, primarily intended for numerical computations, mostly compatible with Matlab
zdiv.f
Go to the documentation of this file.
1  SUBROUTINE zdiv(AR, AI, BR, BI, CR, CI)
2 C***BEGIN PROLOGUE ZDIV
3 C***REFER TO ZBESH,ZBESI,ZBESJ,ZBESK,ZBESY,ZAIRY,ZBIRY
4 C
5 C DOUBLE PRECISION COMPLEX DIVIDE C=A/B.
6 C
7 C***ROUTINES CALLED XZABS
8 C***END PROLOGUE ZDIV
9  DOUBLE PRECISION AR, AI, BR, BI, CR, CI, BM, CA, CB, CC, CD
10  DOUBLE PRECISION XZABS
11  bm = 1.0d0/xzabs(br,bi)
12  cc = br*bm
13  cd = bi*bm
14  ca = (ar*cc+ai*cd)*bm
15  cb = (ai*cc-ar*cd)*bm
16  cr = ca
17  ci = cb
18  RETURN
19  END
subroutine zdiv(AR, AI, BR, BI, CR, CI)
Definition: zdiv.f:2