source: trunk/fsource/pypowder.for @ 94

Last change on this file since 94 was 94, checked in by vondreel, 13 years ago

move all fortran to fsource
add gray for readonly textctrl
do polygon insert, show in imageGUI and make mask
fix to ReadPDBphase to use correct crystal to cartesian transformation matrix

File size: 1.7 KB
Line 
1      SUBROUTINE PYPSVFCJ(YCALC,DTT,TTHETA,SIG,GAM,SPH,SMH,
2     1  PRFUNC,DPRDT,DPRDY,SIGPART,GAMPART,SPHPART,SMHPART)
3C DTT in degrees
4C TTHETA in degrees
5C SPH is S/L + H/L
6C SML is S/L - H/L (frequently zero)
7Cf2py intent(in) YCALC
8Cf2py intent(in) DTT
9Cf2py intent(in) TTHETA
10Cf2py intent(in) SIG
11Cf2py intent(in) GAM
12Cf2py intent(in) SPH
13Cf2py intent(in) SMH
14Cf2py intent(out) PRFUNC
15Cf2py intent(out) DPRDT
16Cf2py intent(out) DPRDY
17Cf2py intent(out) SIGPART
18Cf2py intent(out) GAMPART
19Cf2py intent(out) SPHPART
20Cf2py intent(out) SMHPART
21      SL = (SPH+SMH)/2.0
22      HL = (SPH-SMH)/2.0
23      FW = (2.355*SQRT(SIG)+GAM)/100.0
24      FMIN = 10.0*(-FW-SPH*COSD(TTHETA))
25      FMAX = 15.0*FW
26      IF ( DTT .GE. FMIN .AND. DTT .LE. FMAX ) THEN
27        CALL PSVFCJ(DTT*100.,TTHETA*100.,SL,HL,SIG,GAM,
28     1    PRFUNC,DPRDT,SLPART,HLPART,SIGPART,GAMPART)
29        DPRDT = DPRDT*YCALC*100.0
30        DPRDY = PRFUNC
31        SIGPART = SIGPART*YCALC
32        GAMPART = GAMPART*YCALC
33        SPHPART = 0.5*(SLPART+HLPART)*YCALC
34        SMHPART = 0.5*(SLPART-HLPART)*YCALC
35      ELSE
36        PRFUNC = 0.0
37        DPRDT = 0.0
38        DPRDY = 0.0
39        SIGPART = 0.0
40        GAMPART = 0.0
41        SPHPART = 0.0
42        SMHPART = 0.0
43      END IF
44      RETURN
45      END
46
47      SUBROUTINE BUILDMV(WDELT,W,M,DP,A,V)
48Cf2py intent(in) WDELT
49Cf2py intent(in) W
50Cf2py intent(in) M
51Cf2py intent(in) DP
52Cf2py depend(M) DP
53Cf2py intent(in,out) A
54Cf2py depend(M) a
55Cf2py intent(in,out) V
56Cf2py depend(M) V
57      REAL*4 DP(M),A(M,M),V(M)
58      DO I=1,M
59        V(I) = V(I)+WDELT*DP(I)
60        DO J=1,M
61          A(I,J) = A(I,J)+W*DP(I)*DP(J)
62        END DO
63      END DO
64      RETURN
65      END
66     
Note: See TracBrowser for help on using the repository browser.