Hi,
I want to introduce a four-dimensional array, with the fourth dimension acting as a kind of time dimension, e.g., THETAstore(i,k,j,t). This array is then gradually filled with values at every time step and once the array is fully filled, time-averaged values are calculated, e.g. THETAmean(i,k,j) = SUM(i,k,j,/COUNTER
I managed to realize this with adding a dimension to registry.dimspec and dimensioning my variables THETAstore and THETAmean with "ikjt"
As Fortran uses Column-major ordering of arrays, this procedure is really slow and increases the run time tremendously. Therefore, I want to move the time dimension to be the first one to speed up looping over these arrays: THETAstore(t,i,k,j)
I tried to use
and dimensioned THETAstore as "tikj" in the registry. Although the model compiles without errors, I do not see valid results for THETAmean(i,k,j) = SUM,i,k,j)/COUNTER in my output. Furthermore, I cannot output the THETAstore to the wrfout-files with activating history output in the registry or with using run-time IO.
- Is it possible to output 4-dimensional arrays to netcdf?
- Is it possible to just add a dimension before the default i,k,j indexing or would that require major modifications of the WRF code?
cheers and thanks in advance
I want to introduce a four-dimensional array, with the fourth dimension acting as a kind of time dimension, e.g., THETAstore(i,k,j,t). This array is then gradually filled with values at every time step and once the array is fully filled, time-averaged values are calculated, e.g. THETAmean(i,k,j) = SUM(i,k,j,/COUNTER
I managed to realize this with adding a dimension to registry.dimspec and dimensioning my variables THETAstore and THETAmean with "ikjt"
Code:
dimspec t 4 namelist=les_nst c time_average
I tried to use
Code:
dimspec t 1 namelist=les_nst c time_average
- Is it possible to output 4-dimensional arrays to netcdf?
- Is it possible to just add a dimension before the default i,k,j indexing or would that require major modifications of the WRF code?
cheers and thanks in advance