Changeset 10409
- Timestamp:
- 2018-12-18T12:53:24+01:00 (4 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
NEMO/branches/2018/dev_r10164_HPC09_ESIWACE_PREP_MERGE/src/OCE/LBC/mppini.F90
r10397 r10409 149 149 INTEGER :: iarea0 ! - - 150 150 INTEGER :: ierr, ios ! 151 INTEGER :: inbi, inbj, iimax, ijmax ! 151 152 INTEGER, ALLOCATABLE, DIMENSION(:) :: iin, ii_nono, ii_noea ! 1D workspace 152 153 INTEGER, ALLOCATABLE, DIMENSION(:) :: ijn, ii_noso, ii_nowe ! - - … … 181 182 ! If dimensions of processor grid weren't specified in the namelist file 182 183 ! then we calculate them here now that we have our communicator size 183 IF( jpni < 1 .OR. jpnj < 1 ) CALL mpp_init_bestpartition( mppsize, jpni, jpnj ) 184 !!$ IF( jpni < 1 .OR. jpnj < 1 ) THEN 185 !!$ CALL mpp_init_bestpartition( mppsize, jpni, jpnj ) 186 !!$ ELSE 187 !!$ CALL mpp_init_bestpartition( mppsize, inbi, inbj ) 188 !!$ CALL mpp_basic_decomposition( jpni, jpnj, jpimax, jpjmax ) 189 !!$ CALL mpp_basic_decomposition( inbi, inbj, iimax, ijmax ) 190 !!$ IF( iimax*ijmax < jpimax*jpjmax ) THEN 191 !!$ WRITE(ctmp1,*) ' The chossen domain decomposition ', jpni, jpnj 192 !!$ WRITE(ctmp2,*) ' exceeds the maximum number of ocean subdomains = ', inijmin 193 !!$ WRITE(ctmp3,*) ' we suppressed ', jpni*jpnj - mppsize, ' land subdomains ' 194 !!$ WRITE(ctmp4,*) ' BUT we had to keep ', mppsize - inijmin, ' land subdomains that are useless...' 195 !!$ CALL ctl_warn( 'mpp_init:', '~~~~~~~~ ', ctmp1, ctmp2, ctmp3, ctmp4 ) 196 !!$ ENDIF 197 !!$ ENDIF 184 IF( jpni < 1 .OR. jpnj < 1 ) THEN 185 CALL mpp_init_bestpartition( mppsize, jpni, jpnj ) 186 ELSE 187 CALL mpp_init_bestpartition( mppsize, inbi, inbj ) 188 CALL mpp_basic_decomposition( jpni, jpnj, jpimax, jpjmax ) 189 CALL mpp_basic_decomposition( inbi, inbj, iimax, ijmax ) 190 IF( iimax*ijmax < jpimax*jpjmax ) THEN 191 WRITE(ctmp1,*) ' The chosen domain decomposition ', jpni, jpnj 192 WRITE(ctmp2,*) ' has larger MPI subdomains ', jpimax, jpjmax, jpimax*jpjmax 193 WRITE(ctmp3,*) ' than the following domain decompostion ', inbi, inbj 194 WRITE(ctmp4,*) ' which MPI subdomains size is ', iimax, ijmax, iimax*ijmax 195 CALL ctl_warn( 'mpp_init:', '~~~~~~~~ ', ctmp1, ctmp2, ctmp3, ctmp4, ' --- YOU ARE WASTING CPU... ---' ) 196 ENDIF 197 ENDIF 198 198 199 199 ! look for land mpi subdomains... … … 653 653 !! klcj : second dimension 654 654 !!---------------------------------------------------------------------- 655 INTEGER, INTENT(in ) :: knbi, knbj656 INTEGER, INTENT( out) :: kimax, kjmax657 INTEGER, DIMENSION(knbi,knbj), INTENT( out) :: kimppt, kjmppt658 INTEGER, DIMENSION(knbi,knbj), INTENT( out) :: klci, klcj655 INTEGER, INTENT(in ) :: knbi, knbj 656 INTEGER, INTENT( out) :: kimax, kjmax 657 INTEGER, DIMENSION(knbi,knbj), OPTIONAL, INTENT( out) :: kimppt, kjmppt 658 INTEGER, DIMENSION(knbi,knbj), OPTIONAL, INTENT( out) :: klci, klcj 659 659 ! 660 660 INTEGER :: ji, jj … … 664 664 ! 665 665 #if defined key_nemocice_decomp 666 jpimax = ( nx_global+2-2*nn_hls + (knbi-1) ) / knbi + 2*nn_hls ! first dim.667 jpjmax = ( ny_global+2-2*nn_hls + (knbj-1) ) / knbj + 2*nn_hls ! second dim.666 kimax = ( nx_global+2-2*nn_hls + (knbi-1) ) / knbi + 2*nn_hls ! first dim. 667 kjmax = ( ny_global+2-2*nn_hls + (knbj-1) ) / knbj + 2*nn_hls ! second dim. 668 668 #else 669 669 kimax = ( jpiglo - 2*nn_hls + (knbi-1) ) / knbi + 2*nn_hls ! first dim. 670 670 kjmax = ( jpjglo - 2*nn_hls + (knbj-1) ) / knbj + 2*nn_hls ! second dim. 671 671 #endif 672 IF( .NOT. PRESENT(kimppt) ) RETURN 672 673 ! 673 674 ! 1. Dimension arrays for subdomains
Note: See TracChangeset
for help on using the changeset viewer.