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

adding variables, aerosols

Hi everyone, I want to ask some questions

I want to add all the aerosols and dust too,which exactly is the procedure with namelist, configuration and building model

In general how I build the model

How i define from the namelist the runtime? (which is the variable)

Thanks Nikitas
 

rneale

Rich Neale
CAM Project Scientist
Staff member
Can you give me a little more information?
-Do you mean you want to add the aerosols into the model so that they are used by radiation etc?
--By default aerosols species are included diagnostically (4 dust sizes, sulphate, carbon, volcancics and sea salt)
-- Or do you just want to output the quantities to the history files?
 
Hi Rich,

Thanks for replying, I heard from S.Levis that you have a lot of work. Here is what I need. I only want to have aerosols output in several pressure levels. I do not need the climatic effects of aerosols in this phase of the project. Later it would be good to have radiation effects of aerosols in global climate. As I saw from the manual I had to add the variables name in any fincl I wanted. The question is do I need to have extra configuration settings?
(for example do I have to make ./configure --extra flags)?
Do I have to change something in the code (anywhere)? I mean specifically in aerosol_intr.F90 where dust is not fully declared as it is easily understood from the subroutine above.

character(len=16), private, parameter :: def_prognostic_sulfur = 'off' ! default einai off
! Set this flag to .TRUE. to turn on sulfur
logical, private :: sulfur = .FALSE.
! Set this flag to .TRUE. to turn on sulfur feedback in
! set_aerosol_from_prognostics()
logical, private :: feedback_sulfur = .FALSE.

! Set this flag to .TRUE. to turn on carbon
logical, private, parameter :: def_carbon = .FALSE. ! default
logical, private :: carbon = def_carbon
! Set this flag to .TRUE. to turn on carbon feedback in
! set_aerosol_from_prognostics()
logical, private, parameter :: def_feedback_carbon = .FALSE. ! default
logical, private :: feedback_carbon = def_feedback_carbon

! Set this flag to .TRUE. to turn on sea salt
logical, private, parameter :: def_sea_salt = .FALSE. ! default
logical, private :: sea_salt = def_sea_salt
! Set this flag to .TRUE. to turn on sea salt feedback in
! set_aerosol_from_prognostics()
logical, private, parameter :: def_feedback_sea_salt = .FALSE. ! default
logical, private :: feedback_sea_salt = def_feedback_sea_salt

Another problem that I have is that I want to control the frequency of the output that I want to have. Here is the namelist that I use. I read the frequency parameter nhtfrq() and for example nhtfrq(1)=-24,-24... means that the first two variables in h0 file will be written in the first history file every 24 hours. That unfortunately did not happen. Maybe I lost something and I made command variable wrongly used.

My namelist is this

&camexp
absems_data = '/mnt/skiron5/chrispana/cam3//atm/cam2/rad/abs_ems_factors_fastvx.c030508.nc'
aeroptics = '/mnt/skiron5/chrispana/cam3//atm/cam2/rad/AerosolOptics_c040105.nc'
bndtvaer = '/mnt/skiron5/chrispana/cam3//atm/cam2/rad/AerosolMass_V_64x128_clim_c031022.nc'
bndtvdms = '/mnt/skiron5/chrispana/cam3//atm/cam2/scyc/DMS_emissions_64x128_c030722.nc'
bndtvghg = '/mnt/skiron5/chrispana/cam3//atm/cam2/ggas/ghg_1870_2100_c040122.nc'
bndtvo = '/mnt/skiron5/chrispana/cam3//atm/cam2/ozone/pcmdio3.r8.64x1_L60_clim_c970515.nc'
bndtvoxid = '/mnt/skiron5/chrispana/cam3//atm/cam2/scyc/oxid_3d_64x128_L26_c030722.nc'
bndtvs = '/mnt/skiron5/chrispana/cam3//atm/cam2/sst/sst_HadOIBl_bc_64x128_clim_c020411.nc'
bndtvscon = '/mnt/skiron5/chrispana/cam3//atm/cam2/rad/scon_1870_2100_c040122.nc'
bndtvsox = '/mnt/skiron5/chrispana/cam3//atm/cam2/scyc/SOx_emissions_64x128_L2_1870-1871_c040520.nc'
bndtvvolc = '/mnt/skiron5/chrispana/cam3//atm/cam2/rad/VolcanicMass_1870-1999_64x1_L18_c040115.nc'
caseid = 'testrun_ozone_sulf'
fincl1 = 'ALDIF:I', 'ALDIR:I', 'O3VMR:I','MSO4:I','MSSLT_V:I','MVOLC:I'
fincl2 = 'PRECT:I', 'PRECSL:I', 'T850:I', 'Z050:I', 'Q850:I', 'Q200:I', 'T300:I', 'TREFHT:I', 'TREFHTMN:I', 'TREFHTMX:I', 'TS:I', 'TS1:I', 'TS2:I', 'TS3:I', 'TS4:I', 'TSICE:I', 'U200:I', 'U850:I', 'V200:I', 'V850:I', 'Z300:I', 'Z500:I', 'Z700:I', 'O3VMR:I', 'MSO4:I', 'MSSLT_V:I', 'MSUL_V:I', 'MVOLC:I', 'ICEFRAC:I', 'OCNFRAC:I', 'OMEGA500:I', 'OMEGA850:I', 'PRECCINT:I', 'PSL:I', 'QFLX:I', 'SNOWHICE:I', 'SNOWHLND:I', 'T300:I', 'PS:I'
fincl3 = 'PRECT:A','T850:A','TSMN:A','TSMX:A','TS:A','Z500:A'
inithist = 'DAILY'
iyear_ad = 1950
ncdata = '/mnt/skiron5/chrispana/cam3//atm/cam2/inic/gaus/cami_0000-09-01_64x128_L26_c030918.nc'
nelapse = -3
nsrest = 0
nhtfrq(1) = -24,-24,-24,-24,-24,-24
nhtfrq(2) = -24
!nhtfrq(3) = -24
! sxolia
/
&clmexp
finidat = '/mnt/skiron5/chrispana/cam3//lnd/clm2/inidata_2.1/cam/clmi_0000-09-01_64x128_T42_USGS_c030609.nc'
fpftcon = '/mnt/skiron5/chrispana/cam3//lnd/clm2/pftdata/pft-physiology'
fsurdat = '/mnt/skiron5/chrispana/cam3//lnd/clm2/srfdata/cam/clms_64x128_USGS_c030605.nc'
/

I can not understand what do you mean by saying diagnostically? (for the aerosoles)


One question that I wanted to ask you is which variable declare the carbon emissions (black, CO2, CO etc)? Is there any carbon emission path? (I need the corresponding for carbon variablebndtvsox (variable of SOx) and the corresponding path for Carbon ( Here is forSOx emissions) '/mnt/skiron5/chrispana/cam3//atm/cam2/scyc/SOx_emissions_64x128_L2_1870-1871_c040520.nc')

Is it possible to activate in CAM3.0 all the carbon species?

How can I have CH4, CO2 output because I can not understand the usage of CH4VMR and CO2VMR (How they are used? and where are the results come out since they are not declared in a history file)

Sorry for the amount of questions that I made

Thanks in advance for your time, but I am a new CAM user............

I use CAM3.0, portland compiler and GNU/Linux

My core is

2.6.16-1.2069_FC4smp

And I use gcc (GCC) 4.0.2 20051125 (Red Hat 4.0.2-8)

Nik
 

rneale

Rich Neale
CAM Project Scientist
Staff member
For the namelist questions I can see two problems
Instead of
nhtfrq(1) = -24,-24,-24,-24,-24,-24
you just need to set
nhtfrq(1) = -24

Also in
fincl3 = 'PRECT:A','T850:A','TSMN:A','TSMX:A','TS:A','Z500: A'
there seems to be a space before the final A. That needs to be removed.

I think that should be it.
For each variable you output as long as you can see
an addfld and outfld for each one then it will be output.

For example if I do a 'grep' for 'ALDIF'
in models/atm/cam/source/physics/cam1
I get
diagnostics.F90: call addfld ('ALDIF', '1', 1, 'A','albedo: longwave, diffuse', phys_decomp)
diagnostics.F90: call outfld('ALDIF', srfflx%aldif, pcols, lchnk)

Good luck!
Rich
 
Hi Rich,

I am still trying to put out some things......(during summer).

As you wrote in your last answer for daily frequency output for the variables we have to put for every history file nhtfrq(1) = -24, nhtfrq(2) = -24, nhtfrq(3) = -24 in the namelist. Here is my namelist

&camexp
absems_data = '/mnt/skiron5/chrispana/cam3//atm/cam2/rad/abs_ems_factors_fastvx.c030508.nc'
aeroptics = '/mnt/skiron5/chrispana/cam3//atm/cam2/rad/AerosolOptics_c040105.nc'
bndtvaer = '/mnt/skiron5/chrispana/cam3//atm/cam2/rad/AerosolMass_V_64x128_clim_c031022.nc'
bndtvdms = '/mnt/skiron5/chrispana/cam3//atm/cam2/scyc/DMS_emissions_64x128_c030722.nc'
bndtvghg = '/mnt/skiron5/chrispana/cam3//atm/cam2/ggas/ghg_1870_2100_c040122.nc'
bndtvo = '/mnt/skiron5/chrispana/cam3//atm/cam2/ozone/pcmdio3.r8.64x1_L60_clim_c970515.nc'
bndtvoxid = '/mnt/skiron5/chrispana/cam3//atm/cam2/scyc/oxid_3d_64x128_L26_c030722.nc'
bndtvs = '/mnt/skiron5/chrispana/cam3//atm/cam2/sst/sst_HadOIBl_bc_64x128_clim_c020411.nc'
bndtvscon = '/mnt/skiron5/chrispana/cam3//atm/cam2/rad/scon_1870_2100_c040122.nc'
bndtvsox = '/mnt/skiron5/chrispana/cam3//atm/cam2/scyc/SOx_emissions_64x128_L2_1870-1871_c040520.nc'
bndtvvolc = '/mnt/skiron5/chrispana/cam3//atm/cam2/rad/VolcanicMass_1870-1999_64x1_L18_c040115.nc'
caseid = 'testrun_ozone_sulf'
iyear_ad = 1950
fincl1 = 'ALDIF:I', 'ALDIR:I', 'O3VMR:I','MSO4:I','MSSLT_V:I','MVOLC:I'
fincl2 = 'PS:I', 'O3VMR:I', 'MSO4:I', 'MSSLT_V:I', 'MSUL_V:I'
fincl3 = 'PRECT:A','T850:A','TSMN:A','TSMX:A','TS:A','Z500:A'
! ola ta fincl history files mexri edw htan ok
inithist = 'DAILY'
nhtfrq(1) = -24 ! gia history 0
nhtfrq(2) = -24
nhtfrq(3) = -24
!PROGNOSTIC_SULFUR = passive
!AERO_CARBON = .true.

ncdata = '/mnt/skiron5/chrispana/cam3//atm/cam2/inic/gaus/cami_0000-09-01_64x128_L26_c030918.nc'
nelapse = -5
nsrest = 0
/
&clmexp
finidat = '/mnt/skiron5/chrispana/cam3//lnd/clm2/inidata_2.1/cam/clmi_0000-09-01_64x128_T42_USGS_c030609.nc'
fpftcon = '/mnt/skiron5/chrispana/cam3//lnd/clm2/pftdata/pft-physiology'
fsurdat = '/mnt/skiron5/chrispana/cam3//lnd/clm2/srfdata/cam/clms_64x128_USGS_c030605.nc'

and the output files :

Jul 23 18:42 testrun_ozone_sulf.cam2.h0.0000-09-01-00000.nc
-rw-r--r-- 1 chrispana users 20653400 Jul 23 18:42 testrun_ozone_sulf.cam2.h1.0000-09-01-00000.nc
-rw-r--r-- 1 chrispana users 1189600 Jul 23 18:42 testrun_ozone_sulf.cam2.h2.0000-09-01-00000.nc
-rw-r--r-- 1 chrispana users 18359704 Jul 23 17:59 testrun_ozone_sulf.cam2.i.0000-09-02-00000.nc
-rw-r--r-- 1 chrispana users 18359704 Jul 23 18:09 testrun_ozone_sulf.cam2.i.0000-09-03-00000.nc
-rw-r--r-- 1 chrispana users 18359704 Jul 23 18:20 testrun_ozone_sulf.cam2.i.0000-09-04-00000.nc
-rw-r--r-- 1 chrispana users 18359704 Jul 23 18:31 testrun_ozone_sulf.cam2.i.0000-09-05-00000.nc
-rw-r--r-- 1 chrispana users 18359704 Jul 23 18:42 testrun_ozone_sulf.cam2.i.0000-09-06-00000.nc
-rw-r--r-- 1 chrispana users 61349743 Jul 23 18:42 testrun_ozone_sulf.cam2.r.0000-09-06-00000
-rw-r--r-- 1 chrispana users 64619936 Jul 22 19:25 testrun_ozone_sulf.cam2.rh0.0000-09-06-00000
-rw-r--r-- 1 chrispana users 25613588 Jul 23 18:42 testrun_ozone_sulf.clm2.h0.0000-09-01-00000.nc
-rw-r--r-- 1 chrispana users 4504520 Jul 23 17:58 testrun_ozone_sulf.clm2.i.0000-09-02-00000.nc
-rw-r--r-- 1 chrispana users 4504520 Jul 23 18:09 testrun_ozone_sulf.clm2.i.0000-09-03-00000.nc
-rw-r--r-- 1 chrispana users 4504520 Jul 23 18:20 testrun_ozone_sulf.clm2.i.0000-09-04-00000.nc
-rw-r--r-- 1 chrispana users 4504520 Jul 23 18:31 testrun_ozone_sulf.clm2.i.0000-09-05-00000.nc
-rw-r--r-- 1 chrispana users 4504520 Jul 23 18:42 testrun_ozone_sulf.clm2.i.0000-09-06-00000.nc
-rw-r--r-- 1 chrispana users 6260172 Jul 23 18:42 testrun_ozone_sulf.clm2.r.0000-09-06-00000

and the only .nc file that contains MSUL_V for example is the
testrun_ozone_sulf.cam2.h1.0000-09-01-00000.nc (MSUL_V is been declared as fincl1). I did grep -i "MSUL_V" * and I reached in this file. Why is this happening (the other files for 9-2-00,9-3-00 etc until 9-6-00 have not the added variables such O3MVR, MSUL_V etc). The only variables that are daily outputted are TS, TS1, TS2. TS3,TS4,SNOWICE,LANDFRAC,TBOT,ICEFRACT etc...

tag : When I am trying to add aerosols with different configuration (example ./configuration -nadv 4 or 16 there are running problems because the execute file does not cooperate with the execute file

Do I have to do something to the source code? (physics/cam1/aerosol_intr.F90) Such as declaration of DUST?

In aerosol_intr.F90 do I have to turn on sulfates, dust etc.....

I saw from a member a configuration option very strange:
configure -cppdefs "-DDUST" -nadv 16 -cam_bld "path_name" (bandy) and the problem was in declaration of DUST in aerosol_intr.F90. What is your opinion for this?

What exactly is cppdefs option (I saw that cppdefs User specified CPP defines to append to Makefile defaults.) Appended to
Makefile defaults. E.g. -cppdefs '-DVAR1 -DVAR2'

Except from DDUST what other options does it have? (My opinion is that I will have to put all the aerosol variables in the form -DO3VMR -DSSLT_V etc)

You said that every variable which has an addfld and outfld can have output. Try doing a grep in physic/cam directory for MSO4 and you will see that this message will appear :
prescribed_aerosols.F90: call outfld('MSO4 ',so4mass,pcols,lchnk)
?????????
 

rneale

Rich Neale
CAM Project Scientist
Staff member
You have some strange comments in your namelist file beginning with !. The fortran code will not be able to interpret this when reading the namelist and so the run will fail.
Unfortunately I am not able to view CAM code at this time but if you need to search all code under models/atm/cam in order to find all the addflds and outflds.
 
Hi Rich,

I can assure you that the comments are not the problem. This conclusion is made with trial and error efforts. Something else is the creating the problem

Thanks in advance

Nik
 
Hello to everyone and especially in Rich,

The question with the frequency of the output was rather not fully declared by me. When I mean daily output I mean for every history file that is produced, a daily output for every day to be included in it. More specifically, in testrun_ozone_sulf.cam2.h0.2008-04-18-00000.nc
I want to have the data of fincl1 (h0) for the day 18/4/2008 etc. Any suggestions?

if that is not possible and....
If in testrun_ozone_sulf.cam2.h0.2008-04-18-00000.nc are all the values of 5 day(the number is picked by chance) run then can you suggest an ncl program to plot dust(or an another variable) vertically and horizontally which will pick out every day for a specific variable?

Thanks in advance

Nik
 
Top