May 11, 2015, Japanese-French model studies of planetary atmospheres, CPS	Model development
in GFD Dennou Club	
Yoshiyuki O. Takahashi,
collaborators in GFD Dennou Club	dcmodel project	
http://www.gfd-dennou.org/library/dcmodel/	
Development ofmodels and tools forstudy and education ofa variety ofgeophysical fluid,– planetaryatmospheres, ocean& climate,– planetary cores,– idealized systems ofabove-mentionedfluid.

Difficulty in numerical studies	• Current simulation models (climate models) arevery complex.
• It is difficult for us to understand what is goingon in simulations.
– It is difficult• to check validity of the model,• to understand the code.

– If we use a comprehensive model, which
reproduce the reality, the use of the model isalmost the same as (high density) observation.

• “The Gap between Simulation andUnderstanding in Climate Modeling” (Held,2005)	

Target features of models/tools
development	•Models and programs that anyone can use– Anyone can freely download, edit, and redistribute them.
– Anyone can perform the same experiments shown in papers.

•Models with a variety of complexities.
– Comparison between the results from simple (conceptual) modeland those from complex model enable us to understand thephenomena.

•Models which are written in the same “style”– Common• variable naming rule,• Input/Output library– data format, NetCDF• spectral transform library.

– These features would enable us to use several models, easily.

•Models that can run on a variety of computers– One can run a model on a supercomputer as well as a PC.

•Models with documents– Documents help education.

dcmodel tool/model line-up	
• Input/Output library– gtool5• Spectral transformation library– ispack– spml (wrapper of ispack)• Models– spmodel sample programs• models of spectral transformation method– deepconv• cloud resolving model– DCPAM• general circulation model• Utility for documentation– rdoc-f95• Those tools/models can be downloaded from GFD
Dennou Club web site http://www.gfd-dennou.org/.

Hierarchy of models
developed in dcmodel project	
1D	
• adv.-diff. eq. 	

• SCM (DCPAM)	

2D	

3D	

• barotropic, shallow wat. eq.	 • MHD eq. for sphericalshell	• 2D/3D primitive eq. (DCPAM)	

using ispack/spml	
• 2D/3D quasi-compressible eq. (deepconv)

using gtool	gtool5	
http://www.gfd-dennou.org/library/gtool/gtool5.htm	

• Input/Output library written in Fortran90• Design for easy input/output of data with
self-descriptive format NetCDF– Metadata can be put on the data with a few
steps– Common use in multiple models• This may enable us to use multiple models easily.

– NetCDF:• http://www.unidata.ucar.edu/software/netcdf/	

ispack/spml	
• ispack:

http://www.gfd-dennou.org/library/ispack/	

– Spectral transformation library written inFortran77• FFT in ispack is the fastest over the world on Intelprocessors• spml:http://www.gfd-dennou.org/library/spmodel/	– Fortran90 wrapper library of ispack– Design for “Program like mathematicalexpressions”• Systematic naming rules• Use of Fortran90 array-valued functions

spml naming rules and library functions	• Naming rules for variables– Dimensions are represented with identifiers• (dimension identifiers)_(variable name)• Examples:– x_Temp: x 1D temperature– xyz_Temp : xyz 3D temperature– e_Temp: wavenumber space 1D temperature– w_Press : spherical harmonics pressure• Library functions– Examples of functions:• e_g( x_Data ): Conversion from grid to spectral data
• g_e( e_Data ): Conversion from spectral to grid data
• e_Dx_e( e_Data ) : Differentiation of spectral data with x– Example of combination of functions:• x_Data2 = g_e( e_Dx_e( e_g( x_Data1 ) ) )Example of program using spml 1	
Example : 1D KdV equation
1D KdV equation∂ς∂ς ∂ 3ς= −ς
− 3,∂t∂x ∂x

is transformed to⎧⎪ ⎡ ∂ς ⎤τ ⎡ ∂ 3ς ⎤τ ⎫⎪ς~mτ +1 = ς~mτ + (Δt )× ⎨− ⎢ς ⎥ − ⎢ 3 ⎥ ⎬,⎪⎩ ⎣ ∂x ⎦ m ⎣ ∂x ⎦ m ⎪⎭where the Euler scheme is applied to time derivative and1 L~ (t )e −2πimx / L
2πimx / L~()
ςx,t=
ςς m (t ) = ∫ ς (x, t )edx,∑mm
L 0Example of program using spml 2	
By the use of spml, the discretized equation shownin a previous slide is coded as follows:	
do it=1,nt
e_Zeta = e_Zeta + dt * &( -e_g(g_e(e_Zeta)*g_e(e_Dx_e(e_zeta))) &- e_Dx_e(e_Dx_e(e_Dx_e(e_zeta))) )end do⎧⎪ ⎡ ∂ς ⎤τ ⎡ ∂ 3ς ⎤τ ⎫⎪
ς~mτ +1 = ς~mτ + (Δt )× ⎨− ⎢ς ⎥ − ⎢ 3 ⎥ ⎬,⎪⎩ ⎣ ∂x ⎦ m ⎣ ∂x ⎦ m ⎪⎭

spmodel (sample programs)	
• http://www.gfd-dennou.org/library/spmodel/• Sample programs using spml for various
Geophysical Fluid Dynamics problems– Advection eq., Shallow water eq., Boussinesq eq.,and so on.

• Purpose– Understanding Geophysical Fluid Dynamics• Understanding basic properties of geophysical fluid, suchatmosphere, planetary internal fluid, and so on.
• Easy connection of our understanding on GFD frommathematical expressions to numerical experiments

Examples of spmodel experiments(http://www.gfd-dennou.org/library/spmodel/gallery/index.htm.en)	

Density current	Rossby wave on a sphere	

Convection in a sphericalshell (MHD Bousinessq eq.)	
Another example for atmosphere of giant planets
will be shown by Takehiro-san on Thursday.	

deepconv	
•

http://www.gfd-dennou.org/library/deepconv/•

Cloud resolving model for planetary atmospheres– 2D / 3D quasi-compressible eq.

•Purpose– Understanding of cloud convection in a various planetaryatmospheres•

Brief description– Dynamics• Quasi-compressible eq.
– Some terms except advection are linearized.

– Turbulent mixing• 1.5 order closure (Klemp and Wilhelmson, 1978)• Surface flux based on bulk method– Cloud micro-physics• “warm rain” parameterization (Kessler, 1969 ; Nakajima, 1998)– Simple thermal forcing

Examples of deepconv experiments	
Jupiter	Ancient Mars	

Cloud density	

Idealized thermal experiment	
Cloud mixing ratio	

Results of Jupiter and ancient Mars experiments
will be shown by Sugiyama-san and Odaka-san,respectively.	

Potential temperature	DCPAM	•

http://www.gfd-dennou.org/library/dcpam/•

General Circulation model for planetary atmospheres• Brief description

Mars	

Earth	– Dynamics• Primitive eq.
– Vertical hydrostaticequilibrium– Radiation••••

Earth modelMars model
grey atmosphere model
New model is being
developed by Onishi-san.

– Turbulent mixing– Cumulus convection– Soil model, Bucket modelExamples of DCPAM experiments 1:Venus, Earth, Mars	Venus

Earth	Mars	

Zonalwind

Temperature

T10L50(Newtonian cooling)

T42L26

Color code and vertical axes are different in three figures.

T31L36

Examples of DCPAM experiments 2:
Idealized calculation/Virtual planets	
• Virtual planets

Tidally-locked planet– Aqua-planet– Tidally-locked planet• Results will be give byHayashi-sensei.

• Idealized calculation

Tiime mean Surface temperature, T42L22 （Ishiwatari et al.）– inviscid calculation• baroclinic wave
calculation (Polvani etal., 2004)

Baroclinic wave

– dynamical core test
(Held and Suarez,1994)
Temperature at lowest level, T341L20	

Examples of DCPAM experiments 3:
1, 2, 3D calculation of Mars atmosphere	
vertical 1D	

axisymmetric 2D	

3D	

Color codes are different in three figures.

Examples of DCPAM experiments 4:
1D experiment of tropical convection	
• Intercomparison ofEarth’s tropicalobservation campaign
1D experiment

Precipitation	

– TWP-ICE SCMintercomparison(Davies et al., 2013)
Relative humidity	
DCPAM 1D experiment	Observation		dcmodel documentation	
Explanation of governing eq.
(TeX)	

Reference manual(rdoc-f95)	

Summary	• We are working on the development of tools andmodels for research and education of a variety ofgeophysical fluids, including planetaryatmospheres.
– Anyone can use the model/programs.	
– Hierarchical models	– Documentation (hopefully)• Line-up– gtool5– ispack / spml (wrapper program of ispack)	
– spmodel sample programs	
– deepconv (cloud resolving model)	
– DCPAM (general circulation model)– rdoc-f95 (documentation utility)