Last change
on this file was
2759,
checked in by aslmd, 2 years ago
|
adding unmodified code from WRFV3.0.1.1, expurged from useless data +1M size
|
File size:
2.0 KB
|
Rev | Line | |
---|
[2759] | 1 | !CCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCC |
---|
| 2 | ! |
---|
| 3 | ! FFTPACK 5.0 |
---|
| 4 | ! Copyright (C) 1995-2004, Scientific Computing Division, |
---|
| 5 | ! University Corporation for Atmospheric Research |
---|
| 6 | ! Licensed under the GNU General Public License (GPL) |
---|
| 7 | ! |
---|
| 8 | ! Authors: Paul N. Swarztrauber and Richard A. Valent |
---|
| 9 | ! |
---|
| 10 | ! $Id: costmi.f,v 1.2 2004/06/15 21:29:19 rodney Exp $ |
---|
| 11 | ! |
---|
| 12 | !CCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCC |
---|
| 13 | |
---|
| 14 | SUBROUTINE COSTMI (N, WSAVE, LENSAV, IER) |
---|
| 15 | INTEGER N, LENSAV, IER |
---|
| 16 | REAL WSAVE(LENSAV) |
---|
| 17 | ! |
---|
| 18 | IER = 0 |
---|
| 19 | ! |
---|
| 20 | IF (LENSAV .LT. 2*N + INT(LOG(REAL(N))) +4) THEN |
---|
| 21 | IER = 2 |
---|
| 22 | CALL XERFFT ('COSTMI', 3) |
---|
| 23 | GO TO 300 |
---|
| 24 | ENDIF |
---|
| 25 | ! |
---|
| 26 | IF (N .LE. 3) RETURN |
---|
| 27 | NM1 = N-1 |
---|
| 28 | NP1 = N+1 |
---|
| 29 | NS2 = N/2 |
---|
| 30 | PI = 4.*ATAN(1.) |
---|
| 31 | DT = PI/FLOAT(NM1) |
---|
| 32 | FK = 0. |
---|
| 33 | DO 101 K=2,NS2 |
---|
| 34 | KC = NP1-K |
---|
| 35 | FK = FK+1. |
---|
| 36 | WSAVE(K) = 2.*SIN(FK*DT) |
---|
| 37 | WSAVE(KC) = 2.*COS(FK*DT) |
---|
| 38 | 101 END DO |
---|
| 39 | LNSV = NM1 + INT(LOG(REAL(NM1))) +4 |
---|
| 40 | CALL RFFTMI (NM1, WSAVE(N+1), LNSV, IER1) |
---|
| 41 | IF (IER1 .NE. 0) THEN |
---|
| 42 | IER = 20 |
---|
| 43 | CALL XERFFT ('COSTMI',-5) |
---|
| 44 | ENDIF |
---|
| 45 | 300 CONTINUE |
---|
| 46 | RETURN |
---|
| 47 | END |
---|
Note: See
TracBrowser
for help on using the repository browser.