# Ocean Acidification

Do you have questions or comments about this model? Ask them here! (You'll first need to log in.)

## WHAT IS IT?

Today's average ocean pH has dropped from 8.2 to about 8.1 as the ocean has taken up a large amount of CO2 from human activities since the industrial revolution. One aspect of ocean acidification that has confused many students is the decrease in carbonate ion concentration in the ocean resulting from the increase in oceanic CO2 uptake. This model provides students with an established oceanic carbon system. Students may uncouple the three reactions involving the changes in three inorganic carbon species as well as explore the long-term system dynamics resulting from the coupled reactions.

## HOW IT WORKS

Six particles are presented in the model: Carbon dioxide, Carbonic acid, bicarbonate ion, carbonate ion, hydronium ion, and hydroxide ion. Two visual styles are provided in the model. The icon visual is more user-friendly and the molecule visual provides more authentic molecule properties. The numbers of particles are transformed from the corresponding ion concentrations in the model. Since the H3O+ concentration is much lower than those of carbon species, a different equation is used to increase the number of H3O+ and OH- so that their changes are more visible.

In the model, a total DIC concentration of 0.002 (mol kg-1) is used initially. The values of two equilibrium constants, Ka1 = 10 ^ (-5.903) and Ka2 = 10 ^ (-9.702), obtained from Millero et al. (2006), are used to calculate the concentrations of three species in a closed system where salinity is 3.3758% and temperature is 20 degree Celsius. The concentrations of Carbonic acid (H2CO3), bicarbonate ion (HCO3-), carbonate ion (CO3(2-)) are calculated using the following equations:

1) [H2CO3] = K-co2 * P-co2 (partial pressures of carbon dioxide) 2) [HCO3-][H+]/[H2CO3]=Ka1 3) [CO3--][H+]/[HCO3]=Ka2

The initial ocean pHs and partial pressures of carbon dioxide were obtained from CO2SYS (https://cdiac.ess-dive.lbl.gov/ftp/co2sys/). The resulting pH in the model is calibrated based on CO2SYS and the average pH deviation is 0.5%.

## HOW TO USE IT

Choose a visual style, and then click on the

**set up/restart**button the confirm the setting.Use the

**Run 3 coupled reactions continuously**to run the three reactions in sequence, i.e.,[CO2+H2O<-->H2CO3; H2CO3<-->(HCO3-)+(H+);(HCO3-)<-->(CO3--)+(H+)] repeatedly. While the model is running, you may change the**P-CO2**slider, representing the partial pressures of carbon dioxide, to view the corresponding changes in oceanic pH and the concentrations of three carbon species.The

**Run 3 coupled reactions 1000 times**button and**Run 3 coupled reactions once**button allow you to run the three reactions in sequence 1000 times or once per click.To observe the dynamic changes in depth, you may also run the three reactions individually using the buttons

**1-(CO2) + (H2O) <--> (H2CO3)**,**2-(H2CO3) <--> (H+) + (HCO3-)**, and**3-(HCO3-) <--> (H+) + (CO3(2-))**

## THINGS TO TRY AND NOTICE

Run the system using the

**Run 3 coupled reactions continuously**button. Drag the**P-CO2**slider to increase or decrease the partial pressures of carbon dioxide in the air. Observe 1) how the concentrations of three carbon species changes accordingly and 2) how oceanic pH value change accordingly.The changes in HCO3- might not be very visible in plots. Use the numeric monitors to track the changes in ion concentrations.

Use switches to show/hide some ions to focus your observation. For example, only show H2CO3 and hide the rest ions.

Apply equilibrium constants and reaction quotients to explain the concentration changes in the model.

## RELATED MODELS

Find the **learning activity worksheets** and more chemistry models at https://sites.google.com/view/3d-science-abm/physics-chemistry

## CREDITS AND REFERENCES

Dr. Lin Xiang created this module at the University of Kentucky in 2022. If you mention this model in a publication, we ask that you include the citations below.

Xiang, L. (2022). Ocean Acidification. Department of STEM Education, University of Kentucky, Lexington, KY.

This work is licensed under the Creative Commons Attribution-NonCommercial-ShareAlike 4.0 License. To view a copy of this license, visit https://creativecommons.org/licenses/by-nc-sa/4.0/.

References: Millero, F. J.; Graham, T. B.; Huang, F.; Bustos-Serrano, H.; Pierrot, D. Dissociation constants of carbonic acid as a function of salinity and temperature. (2006). Marine Chemistry, 100 (1-2), 80-94.

This model is inspired by the KCVS applets from the 2100 C.E. RCP projections. https://applets.kcvs.ca/OceanAcidification/oceanAcid.html?rcp=2.6

## Comments and Questions

;Dr. Lin Xiang created this module at the University of Kentucky in 2022. If you mention this model in a publication, we ask that you include the citations below. ; ;Xiang, L. (2022). Ocean Acidification. Department of STEM Education, University of Kentucky, Lexington, KY. ; ;This work is licensed under the Creative Commons Attribution-NonCommercial-ShareAlike 4.0 License. To view a copy of this license, visit https://creativecommons.org/licenses/by-nc-sa/4.0/. ; ;References: ;Millero, F. J.; Graham, T. B.; Huang, F.; Bustos-Serrano, H.; Pierrot, D. Dissociation constants of carbonic acid as a function of salinity and temperature. (2006). Marine Chemistry, 100 (1-2), 80-94. ; ;This model is inspired by the KCVS applets from the 2100 C.E. RCP projections. https://applets.kcvs.ca/OceanAcidification/oceanAcid.html?rcp=2.6 ;;------------------------------ breed [factories factory] breed [CO2s CO2] breed [H2CO3s H2CO3] breed [HCO3s HCO3] breed [CO3s CO3] breed [H3OS H30] breed [OHs OH] breed [legends legend] turtles-own[ ] globals [ Num-H Num-OH Num-CO2 Num-H2CO3 Num-HCO3 Num-CO3 current-ph current-pOH current-conc-H current-conc-OH current-conc-H2CO3s current-conc-HCO3s current-conc-CO3s M-H2CO3 M-HCO3 M-CO3 M-H M-OH K-co2 Ka1 Ka2 change-1 change-2 reaction-num ] to setup ca set-bk set-legends set-shapes set-tt display-particles hiding-ions output reset-ticks end to set-bk ask patches with [pycor > 35 ] [set pcolor 86] ask patches with [pycor <= 35 and pycor >= 30] [set pcolor (-0.5 * pycor + 104)] ask patches with [pycor < 30 ] [set pcolor 96.5] ask patches with [ pycor = max-pycor or pycor < 6] [set pcolor 101] ask patches with [ pxcor = min-pxcor or pxcor = max-pxcor] [set pcolor 101] end to set-tt set K-co2 3.886647 * 10 ^ (-8) ;calculater based on T CO2 0.002 and 250 ppm set Ka1 10 ^ (-5.903) ;from Millero et al. (2006) set Ka2 10 ^ (-9.702) ;;from Millero et al. (2006) ;set CO2 in air set p-co2 250 ;when initiating model, PCO2 is always 250. This helps fix students' beginning exploration. It could be less convenient during exploration. set current-conc-H 6.29624889 * 10 ^ (-9) set current-ph (- log current-conc-H 10) ; 8.201 ;set the initital ph based on p-CO2 referenced from CO2sys 2.1 set num-CO2 round (P-CO2 / 10) create-CO2s num-CO2 [set-tt-properties-air] ;set initial carbon species set current-conc-H2CO3s 0.0000097166175 ; based on Total C 0.002 set current-conc-HCO3s 0.00192942933173 ; based on Total 0.002 set current-conc-CO3s 0.00006086210779 ; based on Total 0.002 ;reach equlibria CO2-dissolve Ka1-equilibrium Ka2-equilibrium ;set visual numbers set num-H2CO3 round (5000 * 3 ^ (log current-conc-H2CO3s 10)) set num-HCO3 round (5000 * 3 ^ (log current-conc-HCO3s 10)) set num-CO3 round (5000 * 3 ^ (log current-conc-CO3s 10)) create-H2CO3s Num-H2CO3 [set-tt-properties-aq] create-HCO3s Num-HCO3 [set-tt-properties-aq] create-CO3s Num-CO3 [set-tt-properties-aq] set num-H round (500 * 1.3895 ^ (-1 * current-ph)) set num-OH round (500 * 1.3895 ^ (-1 * (14 - current-ph))) create-h3os num-H [set-tt-properties-aq ] create-ohs num-OH [set-tt-properties-aq ] ;set factory create-factories 1 [setxy 12 32 set color 35 set size 6 ] end to set-tt-properties-aq setxy 1 + random-float (max-pxcor - 2) 6 + random-float (max-pycor - 15) (ifelse choose-a-visual = "Molecule visual" [set size 1.25] choose-a-visual = "Symbolic visual" [set size 1.75]) end to set-tt-properties-air setxy 1 + random-float (max-pxcor - 2) (30 + random-float 7) (ifelse choose-a-visual = "Molecule visual" [set size 1.25] choose-a-visual = "Symbolic visual" [set size 1.75]) end to set-legends create-legends 12 [set label-color white] ask legend 0[setxy 4 3.5] ask legend 1 [set shape "blank" set size 1.5 set label "Hydroxide(OH-)" setxy 13.3 3.9] ask legend 2 [setxy 4 1] ask legend 3 [set shape "blank" set size 1.5 set label "Hydronium (H3O+)" setxy 14.5 1.3] ask legend 4[setxy 20 3.5] ask legend 5 [set shape "blank" set size 1.5 set label "Carbon dioxide (CO2)" setxy 32.4 3.9] ask legend 6 [setxy 39 3.5] ask legend 7 [set shape "blank" set size 1.5 set label "Carbonic acid (H2CO3)" setxy 52 3.9] ask legend 8 [setxy 20 1] ask legend 9 [set shape "blank" set size 1.5 set label "Bicarbonate (HCO3-)" setxy 32 1.3] ask legend 10[setxy 39 1] ask legend 11 [set shape "blank" set size 1.5 set label "Carbonate (CO3(2-))" setxy 50.5 1.3] end to go set-shapes-1 aq-move H2CO3-move CO2-move repeat 1000 [ CO2-dissolve Ka1-equilibrium Ka2-equilibrium set reaction-num reaction-num + 1] display-particles hiding-ions output tick end to go-1 set-shapes-1 aq-move H2CO3-move CO2-move CO2-dissolve tick Ka1-equilibrium tick Ka2-equilibrium display-particles hiding-ions output tick end to hiding-ions if Hide-CO2-&-Carbonic-acid? = true [if any? H2CO3s [ask H2CO3s [die]] if any? CO2s [ask CO2s [die]]] if Hide-Bicarbonate-ions? = true [if any? HCO3s [ask HCO3s [die]]] if Hide-Carbonate-ions? = true [if any? CO3s [ask CO3s [die]]] if Hide-H-&-OH-ions? = true [if any? H3Os [ask H3Os [die]] if any? OHs [ask OHs [die]]] end to display-particles set num-CO2 round (P-CO2 / 10) set num-H2CO3 round (5000 * 3 ^ (log current-conc-H2CO3s 10)) set num-HCO3 round (5000 * 3 ^ (log current-conc-HCO3s 10)) set num-CO3 round (5000 * 3 ^ (log current-conc-CO3s 10)) ifelse hide-CO2-&-Carbonic-acid? = false [ let current-CO2 count CO2s let current-H2CO3 count H2CO3s (ifelse current-CO2 > num-CO2 [ask up-to-n-of (current-CO2 - num-CO2) CO2s [die]] current-CO2 < num-CO2 [create-CO2s (num-CO2 - current-CO2) [ifelse random 2 = 0 [setxy 10 33 set size 1.25 set heading -90 + random 180] [set-tt-properties-air] ]]) (ifelse current-H2CO3 > num-H2CO3 [ask up-to-n-of (current-H2CO3 - num-H2CO3) H2CO3s [die]] current-H2CO3 < num-H2CO3 [create-H2CO3s (num-H2CO3 - current-H2CO3) [set-tt-properties-aq]]) ] [if any? H2CO3s [ask H2CO3s [die]] if any? CO2s [ask CO2s [die]]] ifelse Hide-Bicarbonate-ions? = false [let current-HCO3 count HCO3s (ifelse current-HCO3 > num-HCO3 [ask up-to-n-of (current-HCO3 - num-HCO3) HCO3s [die]] current-HCO3 < num-HCO3 [create-HCO3s (num-HCO3 - current-HCO3) [set-tt-properties-aq]])] [if any? HCO3s [ask HCO3s [die]]] ifelse Hide-Carbonate-ions? = false [let current-CO3 count CO3s (ifelse current-CO3 > num-CO3 [ask up-to-n-of (current-CO3 - num-CO3) CO3s [die]] current-CO3 < num-CO3 [create-CO3s (num-CO3 - current-CO3) [ set-tt-properties-aq]])] [if any? CO3s [ask CO3s [die]]] ifelse Hide-H-&-OH-ions? = false [ H-OH-equilibrium] [if any? H3Os [ask H3Os [die]] if any? OHs [ask OHs [die]]] end to CO2-dissolve set current-conc-H2CO3s (P-CO2 * K-co2) end to Ka1-equilibrium set current-conc-H 10 ^ (- current-ph) let Q1 current-conc-H * current-conc-HCO3s / current-conc-H2CO3s (ifelse (Q1 - Ka1) < Ka1 * -0.00001 ; if Q1 < Ka1 , reaction forward [set change-1 ((-1 * (current-conc-HCO3s + current-conc-H) + sqrt ((current-conc-HCO3s + current-conc-H) ^ 2 + 4 * (Ka1 * current-conc-H2CO3s - current-conc-HCO3s * current-conc-H))) / 2) set current-conc-H current-conc-H + change-1 set current-conc-HCO3s current-conc-HCO3s + change-1 set current-conc-H2CO3s current-conc-H2CO3s - change-1 set current-ph (- log current-conc-H 10) ] (Q1 - Ka1) > Ka1 * 0.00001 ; if Q1 > Ka1 , reaction reverse [set change-1 ((current-conc-HCO3s + current-conc-H + Ka1) - sqrt ((current-conc-HCO3s + current-conc-H + Ka1) ^ 2 + 4 * (Ka1 * current-conc-H2CO3s - current-conc-HCO3s * current-conc-H))) / 2 set current-conc-H current-conc-H - change-1 set current-conc-HCO3s current-conc-HCO3s - change-1 set current-conc-H2CO3s current-conc-H2CO3s + change-1 set current-ph (- log current-conc-H 10) ]) end to Ka2-equilibrium set current-conc-H 10 ^ (- current-ph) let Q2 current-conc-H * current-conc-CO3s / current-conc-HCO3s (ifelse (Q2 - Ka2) < Ka2 * -0.00001 ;if Q2 < Ka2 , reaction forward [set change-2 (-0.5 * ((current-conc-H + current-conc-CO3s + Ka2) - sqrt ((current-conc-H + current-conc-CO3s + Ka2) ^ 2 + 4 * (Ka2 * current-conc-HCO3s - current-conc-H * current-conc-CO3s)))) set current-conc-H current-conc-H + change-2 set current-conc-CO3s current-conc-CO3s + change-2 set current-ph (- log current-conc-H 10) set current-conc-HCO3s current-conc-HCO3s - change-2] (Q2 - Ka2) > Ka2 * 0.00001 ;if Q2 > Ka2 , reaction reverse [set change-2 ((current-conc-H + current-conc-CO3s + Ka2) - sqrt ((current-conc-H + Ka2 + current-conc-CO3s) ^ 2 + 4 * (Ka2 * current-conc-HCO3s - current-conc-H * current-conc-CO3s))) / 2 set current-conc-H current-conc-H - change-2 set current-conc-CO3s current-conc-CO3s - change-2 set current-ph (- log current-conc-H 10) set current-conc-HCO3s current-conc-HCO3s + change-2]) end to H-OH-equilibrium set num-H round (500 * 1.3895 ^ (-1 * current-ph)) set num-OH round (500 * 1.3895 ^ (-1 * (14 - current-ph))) let current-H count H3Os let current-OH count OHs (ifelse num-H > current-H [create-h3os abs (num-H - current-H) [set-tt-properties-aq ]] num-H < current-H [ask n-of abs (num-H - current-H) h3os [die]]) (ifelse num-OH > current-OH [create-ohs abs (num-OH - current-OH) [set-tt-properties-aq ]] num-OH < current-OH [ask n-of abs (num-OH - current-OH) OHs [die]]) end to CO2-move ask CO2s [(ifelse [pcolor] of patch-at dx dy = 101 [rt random 360] ;if it's boundary ahead, rotate [pcolor] of patch-at dx dy <= 89 and [pcolor] of patch-at dx dy >= 86 [fd 0.2]; rt random 360] ;if the patch-ahead has the proper color,move forward [pcolor] of patch-at dx dy = 96.5 ;if water ahead, [ifelse random 100 < 20 [set heading 180 fd 1 set breed H2CO3s] [rt random 360]])] ;dissolve at a certain rate, create the animation end to H2CO3-move ask H2CO3s [if [pcolor] of patch-at dx dy = 89 ;if air aheas, [ifelse random 100 < 20 [set heading 0 fd 1 set breed CO2s] [rt random 360] ]] end to aq-move ask turtles with [breed != CO2s and breed != legends] ;ask aq turtles [(ifelse [pcolor] of patch-at dx dy = 101 or [pcolor] of patch-at dx dy = 89 [rt random 360] ;if it's boundary ahead, rotate [pcolor] of patch-at dx dy = 96.5 [fd 0.2 rt random 360 if ycor < 6 [set ycor 6]] ;if the patch-ahead has the proper color, move forward.If ycor is low, put ycor higher )] end to set-shapes (ifelse choose-a-visual = "Molecule visual" [set-default-shape ohs "ab-oh-1" set-default-shape H3Os "ab-h3o-1" set-default-shape CO2s "ab-CO2" set-default-shape H2CO3s "ab-H2CO3" set-default-shape HCO3s "ab-HCO3" set-default-shape CO3s "ab-CO3" set-default-shape factories "factory" ask legend 0 [set shape "ab-oh-1" set size 1.75] ask legend 2 [set shape "ab-h3o-1" set size 1.75] ask legend 4 [set shape "ab-CO2" set size 1.75] ask legend 6 [set shape "ab-H2CO3" set size 1.75] ask legend 8 [set shape "ab-HCO3" set size 1.75] ask legend 10 [set shape "ab-CO3" set size 1.75] ] choose-a-visual = "Symbolic visual" [set-default-shape ohs "ab-oh-2" set-default-shape H3Os "ab-h3o-2" set-default-shape CO2s "ab-CO2-1" set-default-shape H2CO3s "ab-H2CO3-1" set-default-shape HCO3s "ab-HCO3-1" set-default-shape CO3s "ab-CO3-1" set-default-shape factories "factory" ask legend 0 [set shape "ab-oh-2" set size 1.75] ask legend 2 [set shape "ab-h3o-2" set size 1.75] ask legend 4 [set shape "ab-CO2-1" set size 1.75] ask legend 6 [set shape "ab-H2CO3-1" set size 1.75] ask legend 8 [set shape "ab-HCO3-1" set size 1.75] ask legend 10 [set shape "ab-CO3-1" set size 1.75] ]) end to set-shapes-1 (ifelse choose-a-visual = "Molecule visual" [set-default-shape ohs "ab-oh-1" set-default-shape H3Os "ab-h3o-1" set-default-shape CO2s "ab-CO2" set-default-shape H2CO3s "ab-H2CO3" set-default-shape HCO3s "ab-HCO3" set-default-shape CO3s "ab-CO3" set-default-shape factories "factory" ask ohs [set shape "ab-oh-1" set size 1.25] ask H3Os [set shape "ab-h3o-1" set size 1.25] ask CO2s [set shape "ab-CO2" set size 1.25] ask H2CO3s [set shape "ab-H2CO3" set size 1.25] ask HCO3s [set shape "ab-HCO3" set size 1.25] ask CO3s [set shape "ab-CO3" set size 1.25] ask legend 0 [set shape "ab-oh-1" set size 1.75] ask legend 2 [set shape "ab-h3o-1" set size 1.75] ask legend 4 [set shape "ab-CO2" set size 1.75] ask legend 6 [set shape "ab-H2CO3" set size 1.75] ask legend 8 [set shape "ab-HCO3" set size 1.75] ask legend 10 [set shape "ab-CO3" set size 1.75] ] choose-a-visual = "Symbolic visual" [set-default-shape ohs "ab-oh-2" set-default-shape H3Os "ab-h3o-2" set-default-shape CO2s "ab-CO2-1" set-default-shape H2CO3s "ab-H2CO3-1" set-default-shape HCO3s "ab-HCO3-1" set-default-shape CO3s "ab-CO3-1" set-default-shape factories "factory" ask ohs [set shape "ab-oh-2" set size 1.75] ask H3Os [set shape "ab-h3o-2" set size 1.75] ask CO2s [set shape "ab-CO2-1" set size 1.75] ask H2CO3s [set shape "ab-H2CO3-1" set size 1.75] ask HCO3s [set shape "ab-HCO3-1" set size 1.75] ask CO3s [set shape "ab-CO3-1" set size 1.75] ask legend 0 [set shape "ab-oh-2" set size 1.75] ask legend 2 [set shape "ab-h3o-2" set size 1.75] ask legend 4 [set shape "ab-CO2-1" set size 1.75] ask legend 6 [set shape "ab-H2CO3-1" set size 1.75] ask legend 8 [set shape "ab-HCO3-1" set size 1.75] ask legend 10 [set shape "ab-CO3-1" set size 1.75] ]) end to output output-type P-CO2 repeat 3 [output-type " "] output-write precision (current-conc-H2CO3s * 1000000) 5 repeat 3 [output-type " "] output-write precision (current-conc-HCO3s * 1000000) 5 repeat 3 [output-type " "] output-type precision (current-conc-CO3s * 1000000) 5 repeat 3 [output-type " "] output-type precision (current-conc-H) 12 repeat 3 [output-type " "] output-type precision current-ph 3 repeat 3 [output-type " "] output-type precision (current-conc-H * current-conc-HCO3s / current-conc-H2CO3s) 9 repeat 3 [output-type " "] output-print precision (current-conc-H * current-conc-CO3s / current-conc-HCO3s) 13 end

There are 14 versions of this model.

This model does not have any ancestors.

This model does not have any descendants.