Back to home page

MITgcm

 
 

    


Warning, /verification/solid-body.cs-32x32x1/README.md is written in an unsupported language. File is not indexed.

view on githubraw file Latest commit 6b4f212f on 2024-06-05 16:55:17 UTC
aef96ed361 Jean*0001 Simple solid-body rotation test on cubed-sphere grid
                0002 ========================================================
                0003 
                0004 ### Overview:
6b4f212f67 Jean*0005 This is a single level, steady-state atmospheric example
                0006 (`bouyancyRelation='ATMOSPHERIC'`) on cubed-sphere (cs-32) grid with initial
                0007 zonal wind field $U(\phi)$ and surface pressure anomaly $\eta(\phi)$,
                0008 both dependent on latitude $\phi$ only, that corresponds to an additional
                0009 relative rotation ($\omega\'$) on top of the solid-planet rotation ($\Omega$)
                0010 and around the same axis:
aef96ed361 Jean*0011 
                0012 $$ U(\phi) = U_{eq} ~ \cos( \phi ) ~~~ \mathrm{with:} ~~~ U_{eq} = \omega' \times R $$
                0013 
                0014 $$ \eta(\phi) = \rho_{const} ~ U_{eq} ~ ( \Omega R + U_{eq} / 2 ) ~~ ( \cos^{2}(\phi) - 2/3 ) $$
                0015 
6b4f212f67 Jean*0016 The parameters used here are slightly different from Earth (an opportunity to
                0017 test this capability) with a smaller planet radius (`rSphere`) $R = 5500 km$,
                0018 a slower rotation ( 30 h period, `rotationPeriod=108000.`) and an equatorial
                0019 zonal wind $U_{eq} = 80 m/s$ which corresponds to a 5 day revolution time.
aef96ed361 Jean*0020 
6b4f212f67 Jean*0021 The set-up uses linear free-surface with uniform density $\rho_{const} = 1$,
                0022 no viscosity and no bottom friction so that the solution is expected to remain
                0023 unchanged over time.
                0024 A bell-shape patch of passive tracer centered at mid-latitude
                0025 ($\phi_{0} = 45^{o}$) is advected with the simulated wind field.
aef96ed361 Jean*0026 
                0027 ## Instructions
                0028 Configure and compile the code:
                0029 
                0030 ```
                0031   cd build
                0032   ../../../tools/genmake2 -mods ../code [-of my_platform_optionFile]
                0033   make depend
                0034   make
                0035   cd ..
                0036 ```
                0037 
                0038 To run:
                0039 
                0040 ```
                0041   cd run
                0042   ln -s ../input/* .
                0043   ln -s ../build/mitgcmuv .
                0044   ./mitgcmuv > output.txt
                0045   cd ..
                0046 ```
                0047 
                0048 There is comparison output in the directory:
                0049 
                0050 ```
                0051   results/output.txt
                0052 ```
                0053 
                0054 ## Setup details
                0055 In the current setup, the initial wind field and initial surface pressure anomaly are computed
                0056 from customized versions of
                0057 [ini_vel.F](https://github.com/MITgcm/MITgcm/blob/master/verification/solid-body.cs-32x32x1/code/ini_vel.F)
                0058  and [ini_psurf.F](https://github.com/MITgcm/MITgcm/blob/master/verification/solid-body.cs-32x32x1/code/ini_psurf.F), respectively.
6b4f212f67 Jean*0059 Note that $(1/3 - \sin^2)$ is used instead of $(\cos^2 - 2/3)$ in `ini_psurf.F`
                0060 for $\eta(\phi)$ expression; and the two horizontal components of the wind
                0061 `uVel,vVel` along the local grid direction are computed from a stream-function
                0062 $\Psi$ which is naturally defined at the grid-cell corner of the C-grid mesh
                0063 (`XG,YG`) so that the initial flow is divergence free:
aef96ed361 Jean*0064 
                0065 $$ \Psi( \phi ) = R \times U_{eq} ~ \sin( \phi ) $$
                0066 
                0067 $$ \mathrm{uVel} = + \delta^j \Psi / \mathrm{dyG} ~~ ; ~~ \mathrm{vVel} = - \delta^i \Psi / \mathrm{dxG} $$
                0068 
6b4f212f67 Jean*0069 Alternatively, one could generate initial condition binary files by running
                0070 matlab script `gendata.m` (after changing `kwr=1` to `kwr=2` in gendata.m,
                0071 line 75) and use these binary files instead of customized source code (just by
                0072 un-commenting lines 67-69 in main parameter file `data`).
aef96ed361 Jean*0073 
                0074 ## Comments
6b4f212f67 Jean*0075 This set-up uses the "compact format" for all I/O (i.e., one facet after the
                0076 other, stacked along the second dimension, as opposed to the default old format
                0077 with all 6 facets stacked along the first dimension) by setting `W2_mapIO = 1`
                0078 in `data.exch2`.
                0079 The initial passive tracer (here "salinity") input file
                0080 (`hydrogSaltFile='S_init.bin'`) is `real*8` and generated using the MATLAB
                0081 script `gendata.m`. Note that `gendata.m` uses scripts
                0082 from `MITgcm/utils/matlab/` and `MITgcm/utils/matlab/cs_grid/`.