Scheduled Downtime
On Tuesday 24 October 2023 @ 5pm MT the forums will be in read only mode in preparation for the downtime. On Wednesday 25 October 2023 @ 5am MT, this website will be down for maintenance and expected to return online later in the morning.
Normal Operations
The forums are back online with normal operations. If you notice any issues or errors related to the forums, please reach out to help@ucar.edu

"Chunk" Help

Hi to All,

I am trying to insert numerically anomaly of SST in South the Atlantic Ocean in model CAM 2.02. This exactly work already had been made in the CCM 3.2. However, in the CAM I am finding difficulties in relation of the parallel source code. I created a routine (attached in the end of the message) to make compatible coordinates x and y of the anomaly with the coordinates of the CAM. Aparently the compatibilization is correct, but the anomaly is being generated in some regions and in the wrong coordinates. I inserted the anomaly in the routine sst_data.f90. I am very grateful with any aid to decide this problem. I running the model in a SGI with 4 processors .

Thanks a lot,

Marcio Cataldi

PROGRAM paralelo_certo
IMPLICIT NONE
c ***** Declaracao de variaveis

INTEGER novoi,novoj,lchnk,i, flagi


C ***** i (longitude-No colunas) vai de 1 a 16 enquanto que ni vai de 1 a 128
C ***** lchnk (latitude-No Linhas) vai de 65 a 576 enquanto que nj vai de 1 a 64

OPEN (2,FILE='saida2.txt')
c ***********************
flagi=0
novoj=1
C************************
DO lchnk=65,576
C***************
if (novoj.gt.64) then
novoj=1
flagi=flagi+1
write(*,*) flagi
endif
C **************
do i=1,16
C *************

novoi=i+flagi*16
write (2,*) 'lchnk:',lchnk,' ','novoj:',novoj
write(2,*) ' I:', i, ' Novo i:',novoi

enddo

C***************************
novoj=novoj+1

C**********************
ENDDO

STOP
END
 

eaton

CSEG and Liaisons
If your modifications to the SST data can be done to the input monthly mean data then it is probably easiest to make the modifications at the point in the code where the global 2D fields are read. Note that even when MPI is being used (i.e., SPMD is defined) the global 2D SST field is read on the master process before being scattered to the slave processes. There is no parallel I/O. So you have access to the global data at that point in the code.

If your modifications to the SST data must be done to the time interpolated data, this is only available in the "chunked" format. In that case you can access either the latitude/longitude values, or the global lat/lon indices for each column in a chunk by using the get_xxx_all_p methods in phys_grid.F90.
 
Dear Eaton,

Thank´s for your message. In my case I am using a gaussian function that depends on the integration in time. I am using get_nstep() to have access the time step. I already had attemped to have access the values of lat and lon of the model, but he had not found the access reference ind de source code.

Thank you Again,

Marcio Cataldi
 
Top