Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion data-raw/input_params.csv
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@ ocean,twi,n,n,y,1.25E+07,m3 s-1,Ocean warm-intermediate exchange
ocean,tid,n,n,y,2.00E+08,m3 s-1,Ocean intermediate-deep exchange
ocean,preind_surface_c,n,n,n,900,Pg C,Initial surface ocean carbon
ocean,preind_interdeep_c,n,n,n,37100,Pg C,Initial intermediate + deep ocean carbon
simpleNbox,atmos_co2,n,n,y,588.071,Pg C,Initial atmospheric CO2
simpleNbox,C0,n,n,y,277.15,Pg C,Initial atmospheric C pool
simpleNbox,pf.veg_c,y,n,n,55,Pg C,Initial vegetation C pool
simpleNbox,nonpf.veg_c,y,n,n,495,Pg C,Initial vegetation C pool
Expand Down
Binary file modified data/inputstable.rda
Binary file not shown.
1 change: 0 additions & 1 deletion inst/input/hector_picontrol.ini
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,6 @@ preind_interdeep_c=37100 ; intermediate and deep ocean C, IPCC AR6 Figure 5.12
; - the nppv, nppd, and litterd partitioning parameters
; - beta and q10_rh

atmos_co2=590.33 ; initial atmospheric carbon pool Pg C of CO2 size used in spin up, consistent with C0
C0=277.15 ; preindustrial CO2 from table 7.SM.1 IPCC AR6, CO2 radiative forcing question is calibrated to this value
npp_flux0=56.2 ; preindustrial net primary production, Pg C/yr from Ito et al. 2011

Expand Down
3 changes: 1 addition & 2 deletions inst/input/hector_ssp119.ini
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,6 @@ preind_interdeep_c=37100 ; intermediate and deep ocean C, IPCC AR6 Figure 5.12
; - the nppv, nppd, and litterd partitioning parameters
; - beta and q10_rh

atmos_co2=590.33 ; initial atmospheric carbon pool Pg C of CO2 size used in spin up, consistent with C0
C0=277.15 ; preindustrial CO2 from table 7.SM.1 IPCC AR6; CO2 radiative forcing is calibrated to this value
npp_flux0=56.2 ; preindustrial net primary production, Pg C/yr from Ito et al. 2011
;pf.npp_flux0=5.6 ; cf. Figure 3 in Chen et al. 2017 10.1088/1748-9326/aa8978
Expand Down Expand Up @@ -180,7 +179,7 @@ RF_misc[1750]=0
;------------------------------------------------------------------------
[temperature]
S=3.0 ; equilibrium climate sensitivity for 2xCO2 degC (A.4.4 of IPCC AR6)
diff=1.042 ; ocean heat diffusivity, cm2/s calibrated to historical observations see PR 789 for details
diff=1.042 ; ocean heat diffusivity, cm2/s calibrated to historical observations see PR 789 for details
qco2=3.75 ; 2×CO2 RF (7.3.2 of IPCC AR6)

; Optional global temperature constraint
Expand Down
3 changes: 1 addition & 2 deletions inst/input/hector_ssp126.ini
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,6 @@ preind_interdeep_c=37100 ; intermediate and deep ocean C, IPCC AR6 Figure 5.12
; - the nppv, nppd, and litterd partitioning parameters
; - beta and q10_rh

atmos_co2=590.33 ; initial atmospheric carbon pool Pg C of CO2 size used in spin up, consistent with C0
C0=277.15 ; preindustrial CO2 from table 7.SM.1 IPCC AR6; CO2 radiative forcing is calibrated to this value
npp_flux0=56.2 ; preindustrial net primary production, Pg C/yr from Ito et al. 2011
;pf.npp_flux0=5.6 ; cf. Figure 3 in Chen et al. 2017 10.1088/1748-9326/aa8978
Expand Down Expand Up @@ -180,7 +179,7 @@ RF_misc[1750]=0
;------------------------------------------------------------------------
[temperature]
S=3.0 ; equilibrium climate sensitivity for 2xCO2 degC (A.4.4 of IPCC AR6)
diff=1.042 ; ocean heat diffusivity, cm2/s calibrated to historical observations see PR 789 for details
diff=1.042 ; ocean heat diffusivity, cm2/s calibrated to historical observations see PR 789 for details
qco2=3.75 ; 2×CO2 RF (7.3.2 of IPCC AR6)

; Optional global temperature constraint
Expand Down
3 changes: 1 addition & 2 deletions inst/input/hector_ssp245.ini
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,6 @@ preind_interdeep_c=37100 ; intermediate and deep ocean C, IPCC AR6 Figure 5.12
; - the nppv, nppd, and litterd partitioning parameters
; - beta and q10_rh

atmos_co2=590.33 ; initial atmospheric carbon pool Pg C of CO2 size used in spin up, consistent with C0
C0=277.15 ; preindustrial CO2 from table 7.SM.1 IPCC AR6; CO2 radiative forcing is calibrated to this value
npp_flux0=56.2 ; preindustrial net primary production, Pg C/yr from Ito et al. 2011
;pf.npp_flux0=5.6 ; cf. Figure 3 in Chen et al. 2017 10.1088/1748-9326/aa8978
Expand Down Expand Up @@ -180,7 +179,7 @@ RF_misc[1750]=0
;------------------------------------------------------------------------
[temperature]
S=3.0 ; equilibrium climate sensitivity for 2xCO2 degC (A.4.4 of IPCC AR6)
diff=1.042 ; ocean heat diffusivity, cm2/s calibrated to historical observations see PR 789 for details
diff=1.042 ; ocean heat diffusivity, cm2/s calibrated to historical observations see PR 789 for details
qco2=3.75 ; 2×CO2 RF (7.3.2 of IPCC AR6)

; Optional global temperature constraint
Expand Down
3 changes: 1 addition & 2 deletions inst/input/hector_ssp370.ini
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,6 @@ preind_interdeep_c=37100 ; intermediate and deep ocean C, IPCC AR6 Figure 5.12
; - the nppv, nppd, and litterd partitioning parameters
; - beta and q10_rh

atmos_co2=590.33 ; initial atmospheric carbon pool Pg C of CO2 size used in spin up, consistent with C0
C0=277.15 ; preindustrial CO2 from table 7.SM.1 IPCC AR6; CO2 radiative forcing is calibrated to this value
npp_flux0=56.2 ; preindustrial net primary production, Pg C/yr from Ito et al. 2011
;pf.npp_flux0=5.6 ; cf. Figure 3 in Chen et al. 2017 10.1088/1748-9326/aa8978
Expand Down Expand Up @@ -180,7 +179,7 @@ RF_misc[1750]=0
;------------------------------------------------------------------------
[temperature]
S=3.0 ; equilibrium climate sensitivity for 2xCO2 degC (A.4.4 of IPCC AR6)
diff=1.042 ; ocean heat diffusivity, cm2/s calibrated to historical observations see PR 789 for details
diff=1.042 ; ocean heat diffusivity, cm2/s calibrated to historical observations see PR 789 for details
qco2=3.75 ; 2×CO2 RF (7.3.2 of IPCC AR6)

; Optional global temperature constraint
Expand Down
3 changes: 1 addition & 2 deletions inst/input/hector_ssp434.ini
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,6 @@ preind_interdeep_c=37100 ; intermediate and deep ocean C, IPCC AR6 Figure 5.12
; - the nppv, nppd, and litterd partitioning parameters
; - beta and q10_rh

atmos_co2=590.33 ; initial atmospheric carbon pool Pg C of CO2 size used in spin up, consistent with C0
C0=277.15 ; preindustrial CO2 from table 7.SM.1 IPCC AR6; CO2 radiative forcing is calibrated to this value
npp_flux0=56.2 ; preindustrial net primary production, Pg C/yr from Ito et al. 2011
;pf.npp_flux0=5.6 ; cf. Figure 3 in Chen et al. 2017 10.1088/1748-9326/aa8978
Expand Down Expand Up @@ -180,7 +179,7 @@ RF_misc[1750]=0
;------------------------------------------------------------------------
[temperature]
S=3.0 ; equilibrium climate sensitivity for 2xCO2 degC (A.4.4 of IPCC AR6)
diff=1.042 ; ocean heat diffusivity, cm2/s calibrated to historical observations see PR 789 for details
diff=1.042 ; ocean heat diffusivity, cm2/s calibrated to historical observations see PR 789 for details
qco2=3.75 ; 2×CO2 RF (7.3.2 of IPCC AR6)

; Optional global temperature constraint
Expand Down
3 changes: 1 addition & 2 deletions inst/input/hector_ssp460.ini
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,6 @@ preind_interdeep_c=37100 ; intermediate and deep ocean C, IPCC AR6 Figure 5.12
; - the nppv, nppd, and litterd partitioning parameters
; - beta and q10_rh

atmos_co2=590.33 ; initial atmospheric carbon pool Pg C of CO2 size used in spin up, consistent with C0
C0=277.15 ; preindustrial CO2 from table 7.SM.1 IPCC AR6; CO2 radiative forcing is calibrated to this value
npp_flux0=56.2 ; preindustrial net primary production, Pg C/yr from Ito et al. 2011
;pf.npp_flux0=5.6 ; cf. Figure 3 in Chen et al. 2017 10.1088/1748-9326/aa8978
Expand Down Expand Up @@ -180,7 +179,7 @@ RF_misc[1750]=0
;------------------------------------------------------------------------
[temperature]
S=3.0 ; equilibrium climate sensitivity for 2xCO2 degC (A.4.4 of IPCC AR6)
diff=1.042 ; ocean heat diffusivity, cm2/s calibrated to historical observations see PR 789 for details
diff=1.042 ; ocean heat diffusivity, cm2/s calibrated to historical observations see PR 789 for details
qco2=3.75 ; 2×CO2 RF (7.3.2 of IPCC AR6)

; Optional global temperature constraint
Expand Down
3 changes: 1 addition & 2 deletions inst/input/hector_ssp534-over.ini
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,6 @@ preind_interdeep_c=37100 ; intermediate and deep ocean C, IPCC AR6 Figure 5.12
; - the nppv, nppd, and litterd partitioning parameters
; - beta and q10_rh

atmos_co2=590.33 ; initial atmospheric carbon pool Pg C of CO2 size used in spin up, consistent with C0
C0=277.15 ; preindustrial CO2 from table 7.SM.1 IPCC AR6; CO2 radiative forcing is calibrated to this value
npp_flux0=56.2 ; preindustrial net primary production, Pg C/yr from Ito et al. 2011
;pf.npp_flux0=5.6 ; cf. Figure 3 in Chen et al. 2017 10.1088/1748-9326/aa8978
Expand Down Expand Up @@ -180,7 +179,7 @@ RF_misc[1750]=0
;------------------------------------------------------------------------
[temperature]
S=3.0 ; equilibrium climate sensitivity for 2xCO2 degC (A.4.4 of IPCC AR6)
diff=1.042 ; ocean heat diffusivity, cm2/s calibrated to historical observations see PR 789 for details
diff=1.042 ; ocean heat diffusivity, cm2/s calibrated to historical observations see PR 789 for details
qco2=3.75 ; 2×CO2 RF (7.3.2 of IPCC AR6)

; Optional global temperature constraint
Expand Down
3 changes: 1 addition & 2 deletions inst/input/hector_ssp585.ini
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,6 @@ preind_interdeep_c=37100 ; intermediate and deep ocean C, IPCC AR6 Figure 5.12
; - the nppv, nppd, and litterd partitioning parameters
; - beta and q10_rh

atmos_co2=590.33 ; initial atmospheric carbon pool Pg C of CO2 size used in spin up, consistent with C0
C0=277.15 ; preindustrial CO2 from table 7.SM.1 IPCC AR6; CO2 radiative forcing is calibrated to this value
npp_flux0=56.2 ; preindustrial net primary production, Pg C/yr from Ito et al. 2011
;pf.npp_flux0=5.6 ; cf. Figure 3 in Chen et al. 2017 10.1088/1748-9326/aa8978
Expand Down Expand Up @@ -180,7 +179,7 @@ RF_misc[1750]=0
;------------------------------------------------------------------------
[temperature]
S=3.0 ; equilibrium climate sensitivity for 2xCO2 degC (A.4.4 of IPCC AR6)
diff=1.042 ; ocean heat diffusivity, cm2/s calibrated to historical observations see PR 789 for details
diff=1.042 ; ocean heat diffusivity, cm2/s calibrated to historical observations see PR 789 for details
qco2=3.75 ; 2×CO2 RF (7.3.2 of IPCC AR6)

; Optional global temperature constraint
Expand Down
18 changes: 4 additions & 14 deletions src/simpleNbox.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -69,9 +69,9 @@ SimpleNbox::SimpleNbox() : CarbonCycleModel(8), masstot(0.0) {
// earth_c keeps track of how much fossil C is pulled out
// so that we can do a mass-balance check throughout the run
// 2020-02-05 With the introduction of non-negative 'fluxpool' class
// we can't start earth_c at zero. Value of 5500 is set to avoid
// overdrawing in RCP 8.5
earth_c.set(5500, U_PGC, false, D_EARTHC);
// we can't start earth_c at zero. Value of 6400 is set to avoid
// overdrawing in esm-flat20
earth_c.set(6400, U_PGC, false, D_EARTHC);

// We keep a running total of LUC emissions from (and uptake to) vegetation
// This is used in slowparameval() to calculate npp_luc_adjust
Expand Down Expand Up @@ -246,17 +246,7 @@ void SimpleNbox::setData(const std::string &varName, const message_data &data) {
}
try {
// Initial pools
if (varNameParsed == D_ATMOSPHERIC_CO2) {
// Hector input files specify initial atmospheric CO2 in terms of
// the carbon pool, rather than the CO2 concentration. Since we
// don't have a place to store the initial carbon pool, we convert
// it to initial concentration and store that. It will be converted
// back to carbon content when the state variables are set up in
// prepareToRun.
H_ASSERT(data.date == Core::undefinedIndex(), "date not allowed");
H_ASSERT(biome == SNBOX_DEFAULT_BIOME, "atmospheric C must be global");
set_c0(data.getUnitval(U_PGC).value(U_PGC) * PGC_TO_PPMVCO2);
} else if (varNameParsed == D_PREINDUSTRIAL_CO2) {
if (varNameParsed == D_PREINDUSTRIAL_CO2) {
H_ASSERT(data.date == Core::undefinedIndex(), "date not allowed");
H_ASSERT(biome == SNBOX_DEFAULT_BIOME,
"preindustrial CO2 must be global");
Expand Down
1 change: 0 additions & 1 deletion tests/testthat/input/luc_pulse.ini
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,6 @@ tid=200000000 ; 2.0e8 intermediate-deep exchange, m3/s
; - the nppv, nppd, and litterd partitioning parameters
; - beta and q10_rh

atmos_co2=588.071 ; Pg C in CO2, from Murakami et al. (2010)
C0=277.15 ; preindustrial CO2 from table 7.SM.1 IPCC AR6
;boreal.veg_c=100 ; e.g.
;tropical.veg_c=450
Expand Down
Loading