]>
Commit | Line | Data |
---|---|---|
0795afa3 | 1 | #include "isajet/pilot.h" |
2 | SUBROUTINE DBLVEC(P,DP) | |
3 | C | |
4 | C Calculate double precision vector DP for 5-vector P. | |
5 | C Exact components are 1,2,5 and larger of +,- | |
6 | C Ver 6.44: Always use this, even if IF=SINGLE. | |
7 | C | |
8 | #if defined(CERNLIB_IMPNONE) | |
9 | IMPLICIT NONE | |
10 | #endif | |
11 | REAL P(5) | |
12 | DOUBLE PRECISION DP(5),DPPL,DPMN | |
13 | INTEGER K | |
14 | C | |
15 | DO 100 K=1,5 | |
16 | 100 DP(K)=P(K) | |
17 | IF(DP(4)+ABS(DP(3)).EQ.0.) RETURN | |
18 | IF(DP(3).GT.0.) THEN | |
19 | DPPL=DP(4)+DP(3) | |
20 | DPMN=(DP(1)**2+DP(2)**2+DP(5)**2)/DPPL | |
21 | ELSE | |
22 | DPMN=DP(4)-DP(3) | |
23 | DPPL=(DP(1)**2+DP(2)**2+DP(5)**2)/DPMN | |
24 | ENDIF | |
25 | DP(3)=0.5D0*(DPPL-DPMN) | |
26 | DP(4)=0.5D0*(DPPL+DPMN) | |
27 | RETURN | |
28 | END |