lit
    JINRLIB

tVADD, tVCPY, tVDIV, tVMPA... -

F002

: H.Lipps :

popa poo ap opa c opa.
pa a t ao popa aa SUBROUTINE FUNCTION FUNCTION:

t = D DOUBLE PRECISION
t = C COMPLEX*16

:

: - SUBROUTINE FUNCTION
: - tVADD tVCPY tVDIV  tVMPA
tVMPY tVMUL tVMULA tVMUNA
tVRAN tVSCA tVSCL  tVSCS
tVSET tVSUB tVSUM  tVXCH
(t=D,C)
: - D_RANDOM (V107)

: t = D C

CALL tVSET (N,S,Z1,Z2) zj=s
CALL tVRAN (N,A,B,Z1,Z2) zj=ca (.a 2)
CALL tVCPY (N,X1,X2,Z1,Z2) zj=xj
CALL tVXCH (N,X1,X2,Y1,Y2) (.a 3)
CALL tVADD (N,X1,X2,Y1,Y2,Z1,Z2) zj=xj+yj
CALL tVSUB (N,X1,X2,Y1,Y2,Z1,Z2) zj=xj-yj
CALL tVMUL (N,X1,X2,Y1,Y2,Z1,Z2) zj=xj*yj
CALL tVMULA (N,X1,X2,Y1,Y2,Z1,Z2) zj=xj*yj+zj
CALL tVMUNA (N,X1,X2,Y1,Y2,Z1,Z2) zj=-xj*yj+zj
CALL tVDIV (N,X1,X2,Y1,Y2,Z1,Z2,IFAIL) zj=xj/yj (.a 4)
CALL tVSCL (N,S,X1,X2,Z1,Z2) zj=s*xj
CALL tVSCA (N,S,X1,X2,Y1,Y2,Z1,Z2) zj=s*xj+yj
CALL tVSCS (N,S,X1,X2,Y1,Y2,Z1,Z2) zj=s*xj-yj
F = tVSUM (N,X1,X2) F=x1+...+xn
F = tVMPY (N,X1,X2,Y1,Y2) F=x1*y1+...+xn*yn
F = tVMPA (N,X1,X2,Y1,Y2,S) F=x1*y1+...+xn*yn+s

:

N - (INTEGER) papoc opo (j=1,...,N);
S,A,B - ( cooc c t) cap ;
X1,X2 - ( cooc c t) acca,
copa x1,x2 opa (xj);
Y1,Y2 - ( cooc c t) acca,
copa y1,y2 opa (yj);
Z1,Z2 - ( cooc c t) acca,
copa z1,z2 (zj);
IFAIL - (INTEGER) a o IFAIL = 0, c c yj pa 0.
poo ca IFAIL pa a c k,
oopoo yk=0.

N<1 c opopa opaa pa o opa, tVSUM tVMPY pa a 0, a tVMPA - a S.

:

  1. op (xj) p ac ao:
    o cao pacoo o.
    popa op oo opa (xj) o ac X1 X2.
  2. tVRAN pcaa zj a caoo ca a t, paopo pacpoo pa (A,B).
    CVRAN ca a ac zj paopo aco pacp paa (DBLE(A),DBLE(B)) (DIMAG(A),DIMAG(B)).
  3. tVXCH ca xj yj.
  4. c yk=0, y1,...,yk-1 pa 0, tVDIV c oo z1,...,zk-1 IFAIL=k.
  5. a a opa ocaoo aa, ca N=10, cooa o DO a popa opa c opa.

pa:

c op (zj) pcac c opo (xj) (yj), o pa pa aoo a zj , coaao c o xk yk , c k<j.

:
       IMPLICIT REAL*8 (A-H,O-Z)
       DIMENSION X(6),Z(3)
       DATA X/-5.0D0,1.0D0,1.0D0,4.0D0,0.0D0,2.0D0/,
      *Z/-5.0D0,4.0D0,0.0D0/
       CALL DVMULA(3,X(1),X(3),X(2),X(4),Z(1),Z(2))
       . . .
:
       Z(1)= -10.00  Z(2)=   8.00  Z(3)=    .00


home up e-mail