Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
M
Méso-NH code
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Méso-NH
Méso-NH code
Commits
827ca243
Commit
827ca243
authored
3 years ago
by
WAUTELET Philippe
Browse files
Options
Downloads
Patches
Plain Diff
Philippe 01/07/2021: budgets: treat NMNHDIM_BUDGET_LES_PDF dimension in diachronic files
parent
0d05cfcd
No related branches found
No related tags found
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
src/MNH/mode_les_diachro.f90
+28
-4
28 additions, 4 deletions
src/MNH/mode_les_diachro.f90
src/MNH/write_diachro.f90
+7
-0
7 additions, 0 deletions
src/MNH/write_diachro.f90
src/MNH/write_lesn.f90
+8
-0
8 additions, 0 deletions
src/MNH/write_lesn.f90
with
43 additions
and
4 deletions
src/MNH/mode_les_diachro.f90
+
28
−
4
View file @
827ca243
...
...
@@ -842,8 +842,8 @@ end subroutine Les_diachro_3D
subroutine
Les_diachro_4D
(
tpdiafile
,
tpfield
,
hgroup
,
hgroupcomment
,
odoavg
,
odonorm
,
pfield
,
hsuffixes
,
hmasks
)
!#################################################################################################################
use
modd_field
,
only
:
NMNHDIM_BUDGET_LES_LEVEL
,
NMNHDIM_BUDGET_LES_MASK
,
NMNHDIM_BUDGET_LES_SV
,
&
NMNHDIM_BUDGET_LES_TIME
,
NMNHDIM_BUDGET_TERM
,
NMNHDIM_UNUSED
,
&
use
modd_field
,
only
:
NMNHDIM_BUDGET_LES_LEVEL
,
NMNHDIM_BUDGET_LES_MASK
,
NMNHDIM_BUDGET_LES_PDF
,
NMNHDIM_BUDGET_LES_SV
,
&
NMNHDIM_BUDGET_LES_TIME
,
NMNHDIM_BUDGET_TERM
,
NMNHDIM_UNUSED
,
&
tfield_metadata_base
use
modd_io
,
only
:
tfiledata
...
...
@@ -880,10 +880,13 @@ if ( tzfield%ndimlist(1) == NMNHDIM_BUDGET_LES_LEVEL&
call
Print_msg
(
NVERB_ERROR
,
'IO'
,
'Les_diachro_4D'
,
&
'optional dummy argument hmasks is needed for tpfield ('
//
Trim
(
tzfield
%
cmnhname
)
//
')'
)
if
(
Present
(
hsuffixes
)
)
&
call
Print_msg
(
NVERB_ERROR
,
'IO'
,
'Les_diachro_4D'
,
&
'optional dummy argument hsuffixes is not needed for tpfield ('
//
Trim
(
tzfield
%
cmnhname
)
//
')'
)
if
(
Size
(
hmasks
)
/
=
Size
(
pfield
,
3
)
)
&
call
Print_msg
(
NVERB_FATAL
,
'IO'
,
'Les_diachro_4D'
,
'wrong size for hmasks ('
//
Trim
(
tzfield
%
cmnhname
)
//
')'
)
call
Les_diachro_common
(
tpdiafile
,
tzfield
,
hgroup
,
hgroupcomment
,
pfield
,
odoavg
,
odonorm
,
hmasks
=
hmasks
)
else
if
(
tzfield
%
ndimlist
(
1
)
==
NMNHDIM_BUDGET_LES_LEVEL
&
.and.
tzfield
%
ndimlist
(
2
)
==
NMNHDIM_BUDGET_LES_TIME
&
.and.
tzfield
%
ndimlist
(
3
)
==
NMNHDIM_BUDGET_TERM
&
...
...
@@ -892,15 +895,36 @@ else if ( tzfield%ndimlist(1) == NMNHDIM_BUDGET_LES_LEVEL &
call
Print_msg
(
NVERB_ERROR
,
'IO'
,
'Les_diachro_4D'
,
&
'optional dummy argument hsuffixes is needed for tpfield ('
//
Trim
(
tzfield
%
cmnhname
)
//
')'
)
if
(
Present
(
hmasks
)
)
&
call
Print_msg
(
NVERB_ERROR
,
'IO'
,
'Les_diachro_4D'
,
&
'optional dummy argument hmasks is not needed for tpfield ('
//
Trim
(
tzfield
%
cmnhname
)
//
')'
)
if
(
Size
(
hsuffixes
)
/
=
Size
(
pfield
,
3
)
)
&
call
Print_msg
(
NVERB_FATAL
,
'IO'
,
'Les_diachro_4D'
,
'wrong size for hsuffixes ('
//
Trim
(
tzfield
%
cmnhname
)
//
')'
)
call
Les_diachro_common
(
tpdiafile
,
tzfield
,
hgroup
,
hgroupcomment
,
pfield
,
odoavg
,
odonorm
,
hsuffixes
=
hsuffixes
)
else
if
(
tzfield
%
ndimlist
(
1
)
==
NMNHDIM_BUDGET_LES_LEVEL
&
.and.
tzfield
%
ndimlist
(
2
)
==
NMNHDIM_BUDGET_LES_TIME
&
.and.
tzfield
%
ndimlist
(
3
)
==
NMNHDIM_BUDGET_LES_MASK
&
.and.
tzfield
%
ndimlist
(
4
)
==
NMNHDIM_BUDGET_LES_PDF
)
then
if
(
.not.
Present
(
hmasks
)
)
&
call
Print_msg
(
NVERB_ERROR
,
'IO'
,
'Les_diachro_4D'
,
&
'optional dummy argument hmasks is needed for tpfield ('
//
Trim
(
tzfield
%
cmnhname
)
//
')'
)
if
(
Present
(
hsuffixes
)
)
&
call
Print_msg
(
NVERB_ERROR
,
'IO'
,
'Les_diachro_4D'
,
&
'optional dummy argument hsuffixes is not needed for tpfield ('
//
Trim
(
tzfield
%
cmnhname
)
//
')'
)
if
(
Size
(
hmasks
)
/
=
Size
(
pfield
,
3
)
)
&
call
Print_msg
(
NVERB_FATAL
,
'IO'
,
'Les_diachro_4D'
,
'wrong size for hmasks ('
//
Trim
(
tzfield
%
cmnhname
)
//
')'
)
else
call
Print_msg
(
NVERB_ERROR
,
'IO'
,
'Les_diachro_4D'
,
&
'ndimlist configuration not yet implemented for '
//
Trim
(
tzfield
%
cmnhname
)
)
end
if
call
Les_diachro_common
(
tpdiafile
,
tzfield
,
hgroup
,
hgroupcomment
,
pfield
,
odoavg
,
odonorm
,
&
hsuffixes
=
hsuffixes
,
hmasks
=
hmasks
)
end
subroutine
Les_diachro_4D
!#####################################################################################################################
...
...
This diff is collapsed.
Click to expand it.
src/MNH/write_diachro.f90
+
7
−
0
View file @
827ca243
...
...
@@ -1272,6 +1272,13 @@ select case ( idims )
do
ji
=
1
,
Size
(
pvar
,
6
)
call
Diachro_one_field_write_nc4
(
tzfile
,
tpbudiachro
,
tpfields
(
ji
),
pvar
(:,:,:,:,:,
ji
:
ji
),
[
3
,
4
],
gsplit
,
gdistributed
)
end
do
else
if
(
tpfields
(
1
)
%
ndimlist
(
3
)
==
NMNHDIM_BUDGET_LES_LEVEL
&
.and.
(
tpfields
(
1
)
%
ndimlist
(
4
)
==
NMNHDIM_BUDGET_LES_TIME
&
.or.
tpfields
(
1
)
%
ndimlist
(
4
)
==
NMNHDIM_BUDGET_LES_AVG_TIME
)
&
.and.
tpfields
(
1
)
%
ndimlist
(
5
)
==
NMNHDIM_BUDGET_LES_PDF
)
then
if
(
Size
(
tpfields
)
/
=
1
)
call
Print_msg
(
NVERB_FATAL
,
'IO'
,
'Write_diachro_nc4'
,
&
'wrong size of tpfields (variable '
//
trim
(
tpfields
(
1
)
%
cmnhname
)//
')'
)
call
Diachro_one_field_write_nc4
(
tzfile
,
tpbudiachro
,
tpfields
(
1
),
pvar
,
[
3
,
4
,
5
],
gsplit
,
gdistributed
)
else
if
(
tpfields
(
1
)
%
ndimlist
(
3
)
==
NMNHDIM_BUDGET_LES_LEVEL
&
.and.
(
tpfields
(
1
)
%
ndimlist
(
4
)
==
NMNHDIM_BUDGET_LES_TIME
&
.or.
tpfields
(
1
)
%
ndimlist
(
4
)
==
NMNHDIM_BUDGET_LES_AVG_TIME
)
&
...
...
This diff is collapsed.
Click to expand it.
src/MNH/write_lesn.f90
+
8
−
0
View file @
827ca243
...
...
@@ -80,6 +80,7 @@ subroutine Write_les_n( tpdiafile )
use
modd_conf_n
,
only
:
luserv
,
luserc
,
luserr
,
luseri
,
lusers
,
luserg
,
luserh
use
modd_io
,
only
:
tfiledata
use
modd_field
,
only
:
NMNHDIM_BUDGET_LES_TIME
,
NMNHDIM_BUDGET_LES_LEVEL
,
NMNHDIM_BUDGET_LES_SV
,
NMNHDIM_BUDGET_LES_MASK
,
&
NMNHDIM_BUDGET_LES_PDF
,
&
NMNHDIM_SPECTRA_2PTS_NI
,
NMNHDIM_SPECTRA_2PTS_NJ
,
NMNHDIM_SPECTRA_LEVEL
,
NMNHDIM_UNUSED
,
&
TYPEREAL
use
modd_grid_n
,
only
:
xdxhat
,
xdyhat
...
...
@@ -386,6 +387,13 @@ if ( lles_pdf ) then
cgroup
=
'PDF'
cgroupcomment
=
''
tfield
%
ndims
=
4
!tfield%ndimlist(1) = NMNHDIM_BUDGET_LES_LEVEL
!tfield%ndimlist(2) = NMNHDIM_BUDGET_LES_TIME
!tfield%ndimlist(3) = NMNHDIM_BUDGET_LES_MASK
tfield
%
ndimlist
(
4
)
=
NMNHDIM_BUDGET_LES_PDF
tfield
%
ndimlist
(
5
:)
=
NMNHDIM_UNUSED
call
Les_diachro_write
(
tpdiafile
,
XLES_PDF_TH
,
'PDF_TH'
,
'Pdf potential temperature Profiles'
,
'1'
,
ymasks
)
call
Les_diachro_write
(
tpdiafile
,
XLES_PDF_W
,
'PDF_W'
,
'Pdf vertical velocity Profiles'
,
'1'
,
ymasks
)
call
Les_diachro_write
(
tpdiafile
,
XLES_PDF_THV
,
'PDF_THV'
,
'Pdf virtual pot. temp. Profiles'
,
'1'
,
ymasks
)
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment