Difference between revisions of "Solution to UKCA Chemistry and Aerosol Tutorial 8 Task 8.1"
(Created page with " Back to UKCA Chemistry and Aerosol Tutorials [[UKCA Chemistry and Aerosol Tutorial 8#Task 8.1: Add a bimolecular reaction | Back to th…") |
|||
Line 1: | Line 1: | ||
[[UKCA Chemistry and Aerosol Tutorials | Back to UKCA Chemistry and Aerosol Tutorials]] |
[[UKCA Chemistry and Aerosol Tutorials | Back to UKCA Chemistry and Aerosol Tutorials]] |
||
− | [[UKCA Chemistry and Aerosol Tutorial 8#Task 8.1: Add |
+ | [[UKCA Chemistry and Aerosol Tutorial 8#Task 8.1: Add wet deposition of a species | Back to the adding wet deposition tutorial]] |
==Task== |
==Task== |
||
Line 8: | Line 8: | ||
<blockquote> |
<blockquote> |
||
+ | Add in wet deposition for '''BOB''', using the following values: |
||
− | You should now add in the bimolecular reaction of '''ALICE''' with '''OH''' to form '''BOB''' and a secondary organic compound (labelled in UKCA as '''SEC_ORG'''). This reaction is given by: |
||
+ | |||
− | <br/> |
||
− | <br/> |
||
− | <math> |
||
− | \textrm{ALICE} + \textrm{OH} \longrightarrow \textrm{BOB} + \textrm{SEC\_ORG} |
||
− | </math> |
||
− | <br/> |
||
− | <br/> |
||
{| border="1" |
{| border="1" |
||
+ | ! <math>\ k(298)\ </math> || <math>\ -\left({\Delta H}/R\right)\ </math> || <math>\ k(298)</math> for the 1st dissociation || <math>\ -\left({\Delta H}/R\right)</math> for the 1st dissociation || <math>\ k(298)</math> for the 2nd dissociation || <math>\ -\left({\Delta H}/R\right)</math> for the 2nd dissociation |
||
− | ! Parameter || Value |
||
− | |- |
||
− | | <math>k_{0}</math> || 2.70E-11 |
||
− | |- |
||
− | | <math>\alpha</math> || 0.00 |
||
|- |
|- |
||
+ | | <math>\ 0.21 \times 10^{+06}\ </math> || <math>\ 0.87 \times 10^{+04}\ </math> || <math>\ 0.2 \times 10^{+02}\ </math> || <math>\ 0.0\ </math> || <math>\ 0.0\ </math> || <math>\ 0.0\ </math> |
||
− | | <math>\beta</math> || -390.00 |
||
|} |
|} |
||
</blockquote> |
</blockquote> |
||
Line 31: | Line 21: | ||
===Changes to ukca_chem_strattrop.F90=== |
===Changes to ukca_chem_strattrop.F90=== |
||
+ | First, you will need to increase the value of '''nwet_strattrop''' from 29 to '''30'''. |
||
− | The only UKCA code changes that are required, are in '''ukca_chem_strattrop.F90'''. You should add the following line at the end of the '''ratb_defs_strattrop05''' array |
||
− | + | Then, you will need to change the 0 in the 7th column of the '''BOB''' entry in the '''chch_defs_strattrop_chem''' array to '''1''', e.g. |
|
− | ' ', 2.70E-11, 0.00, -390.00, 0.000, 0.000, 0.000, 0.000) & |
||
⚫ | |||
− | (remembering to add a comma at the end of the line above) and increase the size of the '''ratb_defs_strattrop05''' array to '''19''' and the size of the '''ratb_defs_strattrop_chem''' master array to '''199'''. |
||
+ | Finally, you will need to add the following to the end of the '''henry_defs_strattrop_chem''' array |
||
− | ===Hand-edit to increase JPBK and JPNR=== |
||
+ | 0.2100E+06, 0.8700E+04, 0.2000E+02, 0.0000E+00, 0.0000E+00, 0.0000E+00 & ! 30 BOB |
||
− | You will now need to make a hand-edit to increase the size of '''JPBK''' and '''JPNR''', which are set in '''CNTLATM'''. This should look like |
||
+ | |||
+ | (remembering to add a comma to the end of the preceding line). |
||
+ | |||
+ | ===Hand-edit=== |
||
+ | |||
+ | You will need to make a hand-edit containing |
||
ed CNTLATM<<\EOF |
ed CNTLATM<<\EOF |
||
− | / |
+ | /JPDW/ |
d |
d |
||
i |
i |
||
− | + | JPDW = 30, |
|
− | . |
||
− | /JPNR/ |
||
− | d |
||
− | i |
||
− | JPNR=284, |
||
. |
. |
||
w |
w |
||
Line 57: | Line 47: | ||
EOF |
EOF |
||
⚫ | |||
− | [[Image:UKCA_Tutorial_BOB_Surface.png|thumb|300px|right|Figure 1: Surface plot of the BOB tracer after bimolecular reaction has been applied.]] |
||
⚫ | |||
− | An example hand-edit can be found at |
+ | An example hand-edit can be found at |
− | /home/ukca/hand_edits/VN8.2/Tutorial/ |
+ | /home/ukca/hand_edits/VN8.2/Tutorial/Task8.1_incr_JPvals.ed |
− | |||
− | on PUMA. |
||
==Output== |
==Output== |
||
− | + | If you view the BOB (34065) field in the '''pb''' file (located in your '''[[UKCA & UMUI Tutorials: Things to know before you start#Archiving|archive]]''' directory) after these changes, and compare it to the equivalent field after the [[Solution to UKCA & UMUI Tutorial 7 Task 7.1 | previous Task (7.1)]] you will see that there are some differences. However, we will not be able to quantify these differences correctly until [[UKCA & UMUI Tutorial 9 | Tutorial 9: Adding new UKCA diagnostics]]. |
|
'''Sample output''' from this job can be found in |
'''Sample output''' from this job can be found in |
||
− | /work/n02/n02/ukca/Tutorial/sample_output/ |
+ | /work/n02/n02/ukca/Tutorial/sample_output/Task8.1/ |
on HECToR, and in |
on HECToR, and in |
||
− | /projects/ukca/Tutorial/sample_ouput/ |
+ | /projects/ukca/Tutorial/sample_ouput/Task8.1/ |
on MONSooN. |
on MONSooN. |
||
Line 82: | Line 69: | ||
==Worked Solution== |
==Worked Solution== |
||
− | There is a worked solution to this problem in the UMUI Tutorial experiment. This is job ''' |
+ | There is a worked solution to this problem in the UMUI Tutorial experiment. This is job '''i''': ''Tutorial: solution to Task 8.1 - add new wet deposition'' . |
− | The code changes can be viewed by using the following FCM command |
+ | The code changes can be viewed by using the following FCM command |
− | fcm diff -g fcm:um_br/dev/luke/vn8.2_UKCA_Tutorial_Solns@ |
+ | fcm diff -g fcm:um_br/dev/luke/vn8.2_UKCA_Tutorial_Solns@12214 fcm:um_br/dev/luke/vn8.2_UKCA_Tutorial_Solns@12227 |
− | This gives the following (non-graphical) output: |
+ | This gives the following (non-graphical) output: |
Index: src/atmosphere/UKCA/ukca_chem_strattrop.F90 |
Index: src/atmosphere/UKCA/ukca_chem_strattrop.F90 |
||
=================================================================== |
=================================================================== |
||
− | --- src/atmosphere/UKCA/ukca_chem_strattrop.F90 (revision |
+ | --- src/atmosphere/UKCA/ukca_chem_strattrop.F90 (revision 12214) |
− | +++ src/atmosphere/UKCA/ukca_chem_strattrop.F90 (revision |
+ | +++ src/atmosphere/UKCA/ukca_chem_strattrop.F90 (revision 12227) |
− | @@ - |
+ | @@ -60,7 +60,7 @@ |
− | + | INTEGER, PARAMETER, PUBLIC :: ndry_st_aer = 5 ! Aerosol chemistry |
|
⚫ | |||
+ | ! No of wet deposited species |
||
− | -TYPE(RATB_T), DIMENSION( 198) :: ratb_defs_strattrop_chem |
||
+ | -INTEGER, PARAMETER, PUBLIC :: nwet_strattrop = 29 ! Stratospheric chemistry |
||
− | +TYPE(RATB_T), DIMENSION( 199) :: ratb_defs_strattrop_chem |
||
+ | +INTEGER, PARAMETER, PUBLIC :: nwet_strattrop = 30 ! Stratospheric chemistry |
||
+ | INTEGER, PARAMETER, PUBLIC :: nwet_st_aer = 34 ! Aerosol chemistry |
||
⚫ | |||
− | ! reactions found in either Trop or Strat but not both |
||
⚫ | |||
− | TYPE(RATB_T), DIMENSION( 15),PARAMETER :: ratb_defs_strattrop_aer=(/ & |
||
⚫ | |||
⚫ | |||
⚫ | |||
− | TYPE(RATB_T), DIMENSION( 45 ) :: ratb_defs_strattrop02 |
||
+ | chch_t( 76,'ALICE ', 1,'TR ',' ', 1, 0, 0), & ! 76 |
||
− | TYPE(RATB_T), DIMENSION( 45 ) :: ratb_defs_strattrop03 |
||
+ | -chch_t( 77,'BOB ', 1,'TR ',' ', 0, 0, 0) & ! 77 |
||
− | TYPE(RATB_T), DIMENSION( 45 ) :: ratb_defs_strattrop04 |
||
+ | +chch_t( 77,'BOB ', 1,'TR ',' ', 0, 1, 0) & ! 77 |
||
− | -TYPE(RATB_T), DIMENSION( 18 ) :: ratb_defs_strattrop05 |
||
⚫ | |||
− | +TYPE(RATB_T), DIMENSION( 19 ) :: ratb_defs_strattrop05 |
||
− | + | TYPE(CHCH_T), DIMENSION( 87), PUBLIC :: chch_defs_strattrop_aer=(/ & |
|
⚫ | |||
− | REAL, DIMENSION( 360) :: depvel_defs_strattrop02 |
||
+ | 0.6900E+04, 0.5600E+04, 0.1800E-03,-0.1510E+04, 0.0000E+00, 0.0000E+00,& ! 26 HCOOH |
||
⚫ | |||
+ | 0.7500E+03, 0.5300E+04, 0.6300E-08, 0.0000E+00, 0.0000E+00, 0.0000E+00,& ! 27 MeCO3H |
||
⚫ | |||
− | + | 0.4700E+04, 0.6000E+04, 0.1800E-04, 0.0000E+00, 0.0000E+00, 0.0000E+00,& ! 28 MeCO2H |
|
+ | - 0.2300E+03, 0.4900E+04, 0.0000E+00, 0.0000E+00, 0.0000E+00, 0.0000E+00 & ! 29 MeOH |
||
⚫ | |||
− | + | + 0.2300E+03, 0.4900E+04, 0.0000E+00, 0.0000E+00, 0.0000E+00, 0.0000E+00,& ! 29 MeOH |
|
− | + |
+ | + 0.2100E+06, 0.8700E+04, 0.2000E+02, 0.0000E+00, 0.0000E+00, 0.0000E+00 & ! 30 BOB |
+ | /),(/ 6, nwet_strattrop/) ) |
||
⚫ | |||
− | +' ', 2.70E-11, 0.00, -390.00, 0.000, 0.000, 0.000, 0.000) & ! UKCA TUTORIAL RXN 01 |
||
− | /) |
||
⚫ | |||
− | !---------------------------------------------------------------------- |
||
---- |
---- |
Revision as of 16:49, 25 February 2014
Back to UKCA Chemistry and Aerosol Tutorials
Back to the adding wet deposition tutorial
Task
You were asked to
Add in wet deposition for BOB, using the following values:
for the 1st dissociation for the 1st dissociation for the 2nd dissociation for the 2nd dissociation
Solution
Changes to ukca_chem_strattrop.F90
First, you will need to increase the value of nwet_strattrop from 29 to 30.
Then, you will need to change the 0 in the 7th column of the BOB entry in the chch_defs_strattrop_chem array to 1, e.g.
chch_t( 77,'BOB ', 1,'TR ',' ', 0, 1, 0) & ! 77
Finally, you will need to add the following to the end of the henry_defs_strattrop_chem array
0.2100E+06, 0.8700E+04, 0.2000E+02, 0.0000E+00, 0.0000E+00, 0.0000E+00 & ! 30 BOB
(remembering to add a comma to the end of the preceding line).
Hand-edit
You will need to make a hand-edit containing
ed CNTLATM<<\EOF /JPDW/ d i JPDW = 30, . w q EOF
and add this to the UMUI in the Model Selection → Input/Output Control and Resource → User hand edit files by placing it in the table and putting a Y in the Include Y/N column.
An example hand-edit can be found at
/home/ukca/hand_edits/VN8.2/Tutorial/Task8.1_incr_JPvals.ed
Output
If you view the BOB (34065) field in the pb file (located in your archive directory) after these changes, and compare it to the equivalent field after the previous Task (7.1) you will see that there are some differences. However, we will not be able to quantify these differences correctly until Tutorial 9: Adding new UKCA diagnostics.
Sample output from this job can be found in
/work/n02/n02/ukca/Tutorial/sample_output/Task8.1/
on HECToR, and in
/projects/ukca/Tutorial/sample_ouput/Task8.1/
on MONSooN.
Worked Solution
There is a worked solution to this problem in the UMUI Tutorial experiment. This is job i: Tutorial: solution to Task 8.1 - add new wet deposition .
The code changes can be viewed by using the following FCM command
fcm diff -g fcm:um_br/dev/luke/vn8.2_UKCA_Tutorial_Solns@12214 fcm:um_br/dev/luke/vn8.2_UKCA_Tutorial_Solns@12227
This gives the following (non-graphical) output:
Index: src/atmosphere/UKCA/ukca_chem_strattrop.F90 =================================================================== --- src/atmosphere/UKCA/ukca_chem_strattrop.F90 (revision 12214) +++ src/atmosphere/UKCA/ukca_chem_strattrop.F90 (revision 12227) @@ -60,7 +60,7 @@ INTEGER, PARAMETER, PUBLIC :: ndry_st_aer = 5 ! Aerosol chemistry ! No of wet deposited species -INTEGER, PARAMETER, PUBLIC :: nwet_strattrop = 29 ! Stratospheric chemistry +INTEGER, PARAMETER, PUBLIC :: nwet_strattrop = 30 ! Stratospheric chemistry INTEGER, PARAMETER, PUBLIC :: nwet_st_aer = 34 ! Aerosol chemistry @@ -142,7 +142,7 @@ chch_t( 74,'O2 ', 1,'CT ',' ', 0, 0, 0), & ! 74 chch_t( 75,'N2 ', 1,'CT ',' ', 0, 0, 0), & ! 75 chch_t( 76,'ALICE ', 1,'TR ',' ', 1, 0, 0), & ! 76 -chch_t( 77,'BOB ', 1,'TR ',' ', 0, 0, 0) & ! 77 +chch_t( 77,'BOB ', 1,'TR ',' ', 0, 1, 0) & ! 77 /) TYPE(CHCH_T), DIMENSION( 87), PUBLIC :: chch_defs_strattrop_aer=(/ & @@ -689,7 +689,8 @@ 0.6900E+04, 0.5600E+04, 0.1800E-03,-0.1510E+04, 0.0000E+00, 0.0000E+00,& ! 26 HCOOH 0.7500E+03, 0.5300E+04, 0.6300E-08, 0.0000E+00, 0.0000E+00, 0.0000E+00,& ! 27 MeCO3H 0.4700E+04, 0.6000E+04, 0.1800E-04, 0.0000E+00, 0.0000E+00, 0.0000E+00,& ! 28 MeCO2H - 0.2300E+03, 0.4900E+04, 0.0000E+00, 0.0000E+00, 0.0000E+00, 0.0000E+00 & ! 29 MeOH + 0.2300E+03, 0.4900E+04, 0.0000E+00, 0.0000E+00, 0.0000E+00, 0.0000E+00,& ! 29 MeOH + 0.2100E+06, 0.8700E+04, 0.2000E+02, 0.0000E+00, 0.0000E+00, 0.0000E+00 & ! 30 BOB /),(/ 6, nwet_strattrop/) )
Written by Luke Abraham 2014