Opened 21 months ago

Closed 8 weeks ago

#1807 closed help (answered)

new emissions file for new tracer

Reported by: s1374103 Owned by: luke
Priority: normal Component: UKCA
Keywords: Cc:
Platform: MONSooN UM Version: 8.4



I've added in a new tracer in slot 64 (ANT_VOC) and created a new emissions ancillary file (MEGAN_ANT_VOC_9) based on the original single level user ancillary file (AR5_2000_MEGAN-MeOH).

When I try to run the model it fails at compilation with the following error.

Error in routine: Rcf_Ancil_Atmos
Error Code:    10
Error Message: ITEMS namelist for Stash-Code 34   64 : No ANCILmaster record ?
Error generated from processor:     0
This run generated   1 warnings

Do you know what this error means?



Change History (13)

comment:1 Changed 21 months ago by luke

  • Owner changed from um_support to luke
  • Status changed from new to accepted

Hi Jamie,

Is this the same RUNID as your previous ticket - xmkhl?


comment:2 Changed 21 months ago by s1374103

Hi Luke,

The RUNID is now xmlne



comment:3 Changed 21 months ago by luke

Hi Jamie,

Rather than option 2 for the initialisation of the m01s34i064 field, you need option 7. You should then use the final column to specify the path to the file on the supercomputer. If you look in the Help text for this panel, you see that option 2 is only valid for STASH numbers m01s00i301-354:

If choosing option 2, make sure that you are using one of the
special unit  numbers for user-ancillary fields:
  This is a special feature to allow users to define new
  "prognostic" fields  and use them as ancillary fields. There are
  special STASH items numbers  reserved for such prognostics:
	301-320 Single-Level Atmospheric items.
	321-324 Multi-Level Atmospheric items.
	331-340 Single-Level Oceanic items
	351-354 Multi-Level Oceanic items.
This file must hold all the items of the type specified that are
required. These should be time-variant and updated. Simple
configuring can be done through  the windows in STASH that allow
specification of fields on files in a more  flexible way. 

Option 7 is a simpler method of doing this for any item number.
However, you cannot update the diagnostic or interpolate it in time.
The file (in ancillary file format) must only contain the field at a
single "time-level".

This file can be made using Xancil, as a generalised ancillary file. For more information, see

Have a go at this, and see how it goes.


comment:4 Changed 21 months ago by s1374103

Hi Luke,

Thanks for your patience. Can I just check if I’ve understood you and the tutorial correctly.
So s0i316 is emissions of my tracer, ANT_VOC. The initialisation is set to 2, so it’s initialised from the single user ancillary file that I created (MEGAN_ANT_VOC_9). I’ve edited ukca_chem_strattrop.F90 to include…

ELSEIF (em_chem_spec(i) == 'ANT_VOC ') THEN

UkcaD1Codes(J+i)%item = 316

Thefore, the emissions of s0i316 are being passed into s34i064 which is the concentration of my tracer. If this is true, I would have excpected not to need to define a path to it’s emissions file as it’s coming from s0i316, but you’re saying that I need to initialise it by selecting option 7 and again defining the path to MEGAN_ANT_VOC_9?



comment:5 Changed 21 months ago by luke

Hi Jamie,

The Initialisation of User Prognostics panel just deals with the initial condition of each of those fields. What happens to those fields within the code is then a Science/User question. The UM requires an initial condition for all fields which are considered prognostics - i.e. fields which the model needs prior knowledge of to run (this includes the User Single-/Multi-Level Ancillary Files which UKCA uses to hold emissions in this model version). For this reason, you need to specify option 2 for the single-/multi-level user fields.

Tracers are also prognostics, as the UM needs knowledge of the concentrations to be able to move them around, so these also need to be initialised to something. In fact, some tracer fields need to be initialised to a sensible field, close to what is expected of them, to make the chemical solver's work easier/possible - ozone is an example of this. Other tracers can just be initialised to a small number (i.e. 1.0e-15 or so - I wouldn't recommend initialising to zero), which is option 6. The tracer can then spin-up for a number of days/months/years. If you output m01s34i064 daily (or so) you should be able to see the emissions going in while the job is running.

The emissions are being emitted into the tracers within UKCA. They are not an initial condition, and the emissions occur every timestep. The emissions need to be in units of kg(substance)/m2/s, and then this field is emitted into the tracer in the call to TR_MIX, the boundary-layer mixing scheme. So long as you have done the code changes as per the emissions tutorial correctly

then you can initialise your tracer to a small number, and then have UKCA add-in the emissions. MEGAN_ANT_VOC_9 contains the emissions, not the tracer initial conditions. Indeed, if you tried to do this, the UM would most likely fail as MEGAN_ANT_VOC_9 doesn't contain a field with the STASH number m01s34i064.

Does this make sense?

In summary, the solution is likely to be:

  1. Initialise emissions (m01s00i316) to 2
  2. Initialise tracer (m01s34i064) to 6, with a value of 1.0e-15
  3. Let the code deal with the emissions


comment:6 Changed 20 months ago by s1374103

Hi Luke,

Yes, that makes sense. I successfully ran with my new tracer and emissions.

I've now added another tracer and emissions (job id = xmlyf). I've added BB_VOC to slot 65 and emissions to 317. The model compiles but fails to run. I repeated almost exacly what I did for adding the previous tracer (ANT_VOC, tracer slot 64) so am quite puzzled why it's not working. One query I came up with was what field code to select for this new emissions. I tried using the same field code as the previously added tracer (546) as well as 547 but neither jobs have worked.

The .leave file contains some warning messages however they also appear when the job runs successfully (c.f. .leave file for xmlnh).

Any thoughts would be greatly appreciated.



comment:7 Changed 20 months ago by luke

Hi Jamie,

If you look near the top of this .leave file it gives the routine/line where the code fails:

ATP Stack walkback for Rank 42 starting:
  tcmalloc::ThreadCache::ReleaseToCentralCache(tcmalloc::ThreadCache::FreeList*, unsigned long, int)@0x21
ATP Stack walkback for Rank 42 done
Process died with signal 11: 'Segmentation fault'
Forcing core dumps of ranks 42, 52, 0
View application merged backtrace tree with: stat-view
You may need to: module load stat

_pmiu_daemon(SIGCHLD): [NID 00097] [c0-0c1s8n1] [Wed Feb 17 20:20:12 2016] PE RANK 321 exit signal Killed
[NID 00097] 2016-02-17 20:20:12 Apid 411449: initiated application termination
xmlyf: Run failed

looking in the file, you can see that the code is actually dying on the following line:

! Deallocate arrays, if are able to
      DO i=1,n_chemdiags
         IF (asad_chemdiags(i)%can_deallocate) &
      END DO

(on the DEALLOCATE line)

I'm not sure exactly why this is causing a problem. You are selected the same diagnostics that are processed through this section of code in both xmlnh and xmlyf, and the code changes are very minimal (essentially removal of a reaction and some changes to conversion factors and reaction rates). One thing that I'm a bit confused about is the changes in UKCA_SETD1DEFS as these are essentially changes in whitespace, despite the fact that there should be an additional tracer and emissions in one branch (the + branch):

--- src/atmosphere/UKCA/ukca_setd1defs.F90	(.../vn8.4_SOA_VOC)	(revision 20778)
+++ src/atmosphere/UKCA/ukca_setd1defs.F90	(.../vn8.4_ANT_BB)	(revision 20778)
@@ -282,11 +282,11 @@
                    'C2H6      ','C3H8      ','Me2CO     ','MeCHO     ', &
                    'C5H8      ','BC_fossil ','BC_biofuel','OC_fossil ', &
                    'OC_biofuel','Monoterp  ','NVOC      ','ANT_VOC   ', &
-                   'BB_VOC    ','SO2_low   ', &  
-                   'SO2_high  ','DMS       ','NH3       ','SO2_nat   ', &
-		   'BC_biomass','OC_biomass','NO_aircrft'/)		   
+		   'BB_VOC    ','SO2_low   ', &      
+		   'SO2_high  ','DMS       ','NH3       ','SO2_nat   ', &
+                   'BC_biomass','OC_biomass','NO_aircrft'/)
              n_aero_tracers = 12
-             n_chem_tracers = 73         ! No. chem tracers
+             n_chem_tracers = 73         ! #tracers - 71 (+ ANT and BB)
              IF (L_ukca_trophet) THEN
                nr_therm     = 241        ! thermal reactions

Given that xmlyf should have an extra tracer and emission, these lines should be different. However, that shouldn't cause the error that you're seeing! (I'm not sure what should be). I've taken a copy the job (xmlyf) and will take a look.


comment:8 Changed 17 months ago by s1374103

Hi Luke,

I've attempted this again.

First, I added and activated two tracers (xmroc).
Second, I added the emission of the first tracer (xmrod).
Thirdly, I added the emissions of the second tracer and at this point the model crashes with segmentation fault (xmrog).

For these runs I've kept the field code constant and has used identical NetCDF files to create the new ancillary file.

Do you have any ideas on what I'm doing wrong? I'm not quite sure what to attempt next.



comment:9 Changed 10 months ago by luke

Dear Jamie,

Are you still having issues with your emissions?


comment:10 Changed 10 months ago by s1374103

Hi Luke,

Yes, the issue still exists.

I spent some time trying to understand asad_chem_flux_diags.f90 to see if I could figure out why this was happening but didn't get anywhere.

Later, I found that manually adding ' +1' to the value of molmass allowed the model to run. However, I wasn't sure if this was just allowing the model to run as opposed to fixing the problem.

After discussing with my supervisors (Ruth Doherty and Fiona O'Connor) we decided to lump both my new species into one tracer and one emissions file and this is how we intend to continue.



comment:11 Changed 10 months ago by luke

I'm sorry that you're still having problems. Unfortunately I won't be able to look at this in detail until after the UKCA training course in January. Sorry about this - I do realise that it's been going on for a while.

Best wishes,

comment:12 Changed 6 months ago by luke

Hi Jamie,

Can I check - is this still an issue?

Many thanks,

comment:13 Changed 8 weeks ago by willie

  • Component changed from UM Model to UKCA
  • Resolution set to answered
  • Status changed from accepted to closed
Note: See TracTickets for help on using tickets.