/[MITgcm]/MITgcm/pkg/autodiff/active_file_control_slice.F
ViewVC logotype

Diff of /MITgcm/pkg/autodiff/active_file_control_slice.F

Parent Directory Parent Directory | Revision Log Revision Log | View Revision Graph Revision Graph | View Patch Patch

revision 1.1 by heimbach, Sun Mar 25 22:33:53 2001 UTC revision 1.2 by heimbach, Fri Sep 28 04:19:27 2001 UTC
# Line 21  c Line 21  c
21  c     ==================================================================  c     ==================================================================
22    
23    
24    CBOP
25    C     !ROUTINE: active_read_xz_rl
26    C     !INTERFACE:
27        subroutine active_read_xz_rl(        subroutine active_read_xz_rl(
28       I                           active_var_file,       I                           active_var_file,
29       O                           active_var,       O                           active_var,
# Line 33  c     ================================== Line 36  c     ==================================
36       I                           mythid       I                           mythid
37       &                         )       &                         )
38    
39    C     !DESCRIPTION: \bv
40  c     ==================================================================  c     ==================================================================
41  c     SUBROUTINE active_read_xz_rl  c     SUBROUTINE active_read_xz_rl
42  c     ==================================================================  c     ==================================================================
43  c  c     o Read an active sliced xz _RL variable from file.
 c     o Read an active variable from file.  
 c  
 c     The variable *globalfile* can be used as a switch, which allows  
 c     to read from a global file. The adjoint files are, however, always  
 c     treated as tiled files.  
 c  
44  c     started: heimbach@mit.edu 05-Mar-2001  c     started: heimbach@mit.edu 05-Mar-2001
 c  
45  c     ==================================================================  c     ==================================================================
46  c     SUBROUTINE active_read_xz_rl  c     SUBROUTINE active_read_xz_rl
47  c     ==================================================================  c     ==================================================================
48    C     \ev
49    
50    C     !USES:
51        implicit none        implicit none
52    
53  c     == global variables ==  c     == global variables ==
   
54  #include "EEPARAMS.h"  #include "EEPARAMS.h"
55  #include "SIZE.h"  #include "SIZE.h"
56  #include "PARAMS.h"  #include "PARAMS.h"
57    
58    C     !INPUT/OUTPUT PARAMETERS:
59  c     == routine arguments ==  c     == routine arguments ==
60    c     active_var_file: filename
61    c     active_var:      array
62    c     irec:            record number
63    c     myOptimIter:     number of optimization iteration (default: 0)
64    c     mythid:          thread number for this instance
65    c     doglobalread:    flag for global or local read/write
66    c                      (default: .false.)
67    c     lAdInit:         initialisation of corresponding adjoint
68    c                      variable and write to active file
69    c     mynr:            vertical array dimension
70    c     theSimulationMode: forward mode or reverse mode simulation
71        character*(*) active_var_file        character*(*) active_var_file
   
72        logical  globalfile        logical  globalfile
73        logical  lAdInit        logical  lAdInit
74        integer  irec        integer  irec
# Line 70  c     == routine arguments == Line 78  c     == routine arguments ==
78        integer  mythid        integer  mythid
79        _RL     active_var(1-olx:snx+olx,mynr,nsx,nsy)        _RL     active_var(1-olx:snx+olx,mynr,nsx,nsy)
80    
81    C     !LOCAL VARIABLES:
82  c     == local variables ==  c     == local variables ==
   
83        character*(2)  adpref        character*(2)  adpref
84        character*(80) adfname        character*(80) adfname
   
85        integer bi,bj        integer bi,bj
86        integer i,j,k        integer i,j,k
87        integer oldprec        integer oldprec
88        integer prec        integer prec
89        integer il        integer il
90        integer ilnblnk        integer ilnblnk
   
91        logical writeglobalfile        logical writeglobalfile
   
92        _RL  active_data_t(1-olx:snx+olx,nsx,nsy)        _RL  active_data_t(1-olx:snx+olx,nsx,nsy)
93    
94  c     == functions ==  c     == functions ==
   
95        external ilnblnk        external ilnblnk
96    
97  c     == end of interface ==  c     == end of interface ==
98    CEOP
99    
100  c     force 64-bit io  c     force 64-bit io
101        oldPrec        = readBinaryPrec        oldPrec        = readBinaryPrec
# Line 222  c     Reset default io precision. Line 227  c     Reset default io precision.
227    
228  c     ==================================================================  c     ==================================================================
229    
230    CBOP
231    C     !ROUTINE: active_write_xz_rl
232    C     !INTERFACE:
233        subroutine active_write_xz_rl(        subroutine active_write_xz_rl(
234       I                            active_var_file,       I                            active_var_file,
235       I                            active_var,       I                            active_var,
# Line 233  c     ================================== Line 241  c     ==================================
241       I                            mythid       I                            mythid
242       &                          )       &                          )
243    
244    C     !DESCRIPTION: \bv
245  c     ==================================================================  c     ==================================================================
246  c     SUBROUTINE active_write_xz_rl  c     SUBROUTINE active_write_xz_rl
247  c     ==================================================================  c     ==================================================================
248  c  c     o Write an active xz _RL variable to a file.
 c     o Write an active variable to a file.  
 c  
249  c     started: heimbach@mit.edu 05-Mar-2001  c     started: heimbach@mit.edu 05-Mar-2001
 c  
250  c     ==================================================================  c     ==================================================================
251  c     SUBROUTINE active_write_xz_rl  c     SUBROUTINE active_write_xz_rl
252  c     ==================================================================  c     ==================================================================
253    C     \ev
254    
255    C     !USES:
256        implicit none        implicit none
257    
258  c     == global variables ==  c     == global variables ==
   
259  #include "EEPARAMS.h"  #include "EEPARAMS.h"
260  #include "SIZE.h"  #include "SIZE.h"
261  #include "PARAMS.h"  #include "PARAMS.h"
262    
263    C     !INPUT/OUTPUT PARAMETERS:
264  c     == routine arguments ==  c     == routine arguments ==
265    c     active_var_file: filename
266    c     active_var:      array
267    c     irec:            record number
268    c     myOptimIter:     number of optimization iteration (default: 0)
269    c     mythid:          thread number for this instance
270    c     doglobalread:    flag for global or local read/write
271    c                      (default: .false.)
272    c     lAdInit:         initialisation of corresponding adjoint
273    c                      variable and write to active file
274    c     mynr:            vertical array dimension
275    c     theSimulationMode: forward mode or reverse mode simulation
276        character*(*) active_var_file        character*(*) active_var_file
   
277        integer  mynr        integer  mynr
278        logical  globalfile        logical  globalfile
279        integer  irec        integer  irec
# Line 265  c     == routine arguments == Line 282  c     == routine arguments ==
282        integer  mythid        integer  mythid
283        _RL     active_var(1-olx:snx+olx,mynr,nsx,nsy)        _RL     active_var(1-olx:snx+olx,mynr,nsx,nsy)
284    
285    C     !LOCAL VARIABLES:
286  c     == local variables ==  c     == local variables ==
   
287        integer  i,j,k        integer  i,j,k
288        integer  bi,bj        integer  bi,bj
289        _RL  active_data_t(1-olx:snx+olx,nsx,nsy)        _RL  active_data_t(1-olx:snx+olx,nsx,nsy)
# Line 274  c     == local variables == Line 291  c     == local variables ==
291        integer  prec        integer  prec
292    
293  c     == end of interface ==  c     == end of interface ==
294    CEOP
295    
296  c     force 64-bit io  c     force 64-bit io
297        oldPrec        = readBinaryPrec        oldPrec        = readBinaryPrec
# Line 359  c     Reset default io precision. Line 377  c     Reset default io precision.
377    
378  c     ==================================================================  c     ==================================================================
379    
380    CBOP
381    C     !ROUTINE: active_read_yz_rl
382    C     !INTERFACE:
383        subroutine active_read_yz_rl(        subroutine active_read_yz_rl(
384       I                           active_var_file,       I                           active_var_file,
385       O                           active_var,       O                           active_var,
# Line 371  c     ================================== Line 392  c     ==================================
392       I                           mythid       I                           mythid
393       &                         )       &                         )
394    
395    C     !DESCRIPTION: \bv
396  c     ==================================================================  c     ==================================================================
397  c     SUBROUTINE active_read_yz_rl  c     SUBROUTINE active_read_yz_rl
398  c     ==================================================================  c     ==================================================================
399  c  c     o Read an active sliced yz _RL variable from file.
 c     o Read an active variable from file.  
 c  
 c     The variable *globalfile* can be used as a switch, which allows  
 c     to read from a global file. The adjoint files are, however, always  
 c     treated as tiled files.  
 c  
400  c     started: heimbach@mit.edu 05-Mar-2001  c     started: heimbach@mit.edu 05-Mar-2001
 c  
401  c     ==================================================================  c     ==================================================================
402  c     SUBROUTINE active_read_yz_rl  c     SUBROUTINE active_read_yz_rl
403  c     ==================================================================  c     ==================================================================
404    C     \ev
405    
406    C     !USES:
407        implicit none        implicit none
408    
409  c     == global variables ==  c     == global variables ==
   
410  #include "EEPARAMS.h"  #include "EEPARAMS.h"
411  #include "SIZE.h"  #include "SIZE.h"
412  #include "PARAMS.h"  #include "PARAMS.h"
413    
414    C     !INPUT/OUTPUT PARAMETERS:
415  c     == routine arguments ==  c     == routine arguments ==
416    c     active_var_file: filename
417    c     active_var:      array
418    c     irec:            record number
419    c     myOptimIter:     number of optimization iteration (default: 0)
420    c     mythid:          thread number for this instance
421    c     doglobalread:    flag for global or local read/write
422    c                      (default: .false.)
423    c     lAdInit:         initialisation of corresponding adjoint
424    c                      variable and write to active file
425    c     mynr:            vertical array dimension
426    c     theSimulationMode: forward mode or reverse mode simulation
427        character*(*) active_var_file        character*(*) active_var_file
   
428        logical  globalfile        logical  globalfile
429        logical  lAdInit        logical  lAdInit
430        integer  irec        integer  irec
# Line 408  c     == routine arguments == Line 434  c     == routine arguments ==
434        integer  mythid        integer  mythid
435        _RL     active_var(1-oly:sny+oly,mynr,nsx,nsy)        _RL     active_var(1-oly:sny+oly,mynr,nsx,nsy)
436    
437    C     !LOCAL VARIABLES:
438  c     == local variables ==  c     == local variables ==
   
439        character*(2)  adpref        character*(2)  adpref
440        character*(80) adfname        character*(80) adfname
   
441        integer bi,bj        integer bi,bj
442        integer i,j,k        integer i,j,k
443        integer oldprec        integer oldprec
444        integer prec        integer prec
445        integer il        integer il
446        integer ilnblnk        integer ilnblnk
   
447        logical writeglobalfile        logical writeglobalfile
   
448        _RL  active_data_t(1-oly:sny+oly,nsx,nsy)        _RL  active_data_t(1-oly:sny+oly,nsx,nsy)
449    
450  c     == functions ==  c     == functions ==
   
451        external ilnblnk        external ilnblnk
452    
453  c     == end of interface ==  c     == end of interface ==
454    CEOP
455    
456  c     force 64-bit io  c     force 64-bit io
457        oldPrec        = readBinaryPrec        oldPrec        = readBinaryPrec
# Line 560  c     Reset default io precision. Line 583  c     Reset default io precision.
583    
584  c     ==================================================================  c     ==================================================================
585    
586    CBOP
587    C     !ROUTINE: active_write_yz_rl
588    C     !INTERFACE:
589        subroutine active_write_yz_rl(        subroutine active_write_yz_rl(
590       I                            active_var_file,       I                            active_var_file,
591       I                            active_var,       I                            active_var,
# Line 571  c     ================================== Line 597  c     ==================================
597       I                            mythid       I                            mythid
598       &                          )       &                          )
599    
600    C     !DESCRIPTION: \bv
601  c     ==================================================================  c     ==================================================================
602  c     SUBROUTINE active_write_yz_rl  c     SUBROUTINE active_write_yz_rl
603  c     ==================================================================  c     ==================================================================
604  c  c     o Write an active yz _RL variable to a file.
 c     o Write an active variable to a file.  
 c  
605  c     started: heimbach@mit.edu 05-Mar-2001  c     started: heimbach@mit.edu 05-Mar-2001
 c  
606  c     ==================================================================  c     ==================================================================
607  c     SUBROUTINE active_write_yz_rl  c     SUBROUTINE active_write_yz_rl
608  c     ==================================================================  c     ==================================================================
609    C     \ev
610    
611    C     !USES:
612        implicit none        implicit none
613    
614  c     == global variables ==  c     == global variables ==
   
615  #include "EEPARAMS.h"  #include "EEPARAMS.h"
616  #include "SIZE.h"  #include "SIZE.h"
617  #include "PARAMS.h"  #include "PARAMS.h"
618    
619    C     !INPUT/OUTPUT PARAMETERS:
620  c     == routine arguments ==  c     == routine arguments ==
621    c     active_var_file: filename
622    c     active_var:      array
623    c     irec:            record number
624    c     myOptimIter:     number of optimization iteration (default: 0)
625    c     mythid:          thread number for this instance
626    c     doglobalread:    flag for global or local read/write
627    c                      (default: .false.)
628    c     lAdInit:         initialisation of corresponding adjoint
629    c                      variable and write to active file
630    c     mynr:            vertical array dimension
631    c     theSimulationMode: forward mode or reverse mode simulation
632        character*(*) active_var_file        character*(*) active_var_file
   
633        integer  mynr        integer  mynr
634        logical  globalfile        logical  globalfile
635        integer  irec        integer  irec
# Line 603  c     == routine arguments == Line 638  c     == routine arguments ==
638        integer  mythid        integer  mythid
639        _RL     active_var(1-oly:sny+oly,mynr,nsx,nsy)        _RL     active_var(1-oly:sny+oly,mynr,nsx,nsy)
640    
641    C     !LOCAL VARIABLES:
642  c     == local variables ==  c     == local variables ==
   
643        integer  i,j,k        integer  i,j,k
644        integer  bi,bj        integer  bi,bj
645        _RL  active_data_t(1-oly:sny+oly,nsx,nsy)        _RL  active_data_t(1-oly:sny+oly,nsx,nsy)
# Line 612  c     == local variables == Line 647  c     == local variables ==
647        integer  prec        integer  prec
648    
649  c     == end of interface ==  c     == end of interface ==
650    CEOP
651    
652  c     force 64-bit io  c     force 64-bit io
653        oldPrec        = readBinaryPrec        oldPrec        = readBinaryPrec

Legend:
Removed from v.1.1  
changed lines
  Added in v.1.2

  ViewVC Help
Powered by ViewVC 1.1.22