Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

new functions for P-adsorp from salinity/temperature #47

Open
aed-modeller opened this issue Feb 18, 2022 · 2 comments
Open

new functions for P-adsorp from salinity/temperature #47

aed-modeller opened this issue Feb 18, 2022 · 2 comments

Comments

@aed-modeller
Copy link

aed-modeller commented Feb 18, 2022

Kpo4p = data%Kpo4p * Kpo4p_fT_fSal(data%theta_Kpo4, data%K_sal, salt, temp)

Below is a new function for the Kpo4p prediction as function of salinity and temperature. This function comes out directly from Zhang and Huang 2011, and is much more accurate and reliable than the previous one.

Note this function calculate the Kpo4p directly, not a scale factor. So in the aed_phosphorus.f90 the line 308
Kpo4p = data%Kpo4p * Kpo4p_fT_fSal(data%theta_Kpo4, data%K_sal, salt, temp)

should be changed to
Kpo4p = Kpo4p_fT_fSal(data%Pexch, salt, temp)

The function only requirs one parameter, which is the exchangable phosphate content in the particles (Pexch).

!###############################################################################
PURE AED_REAL FUNCTION Kpo4p_fT_fSal(Pexch, sal, temp)
!-------------------------------------------------------------------------------
! Kpo4P values as interpolated from Eq(9) and Eq(10) of 
!  Zhang and Huang 2011, in Floriday bay
!-------------------------------------------------------------------------------
!ARGUMENTS

AED_REAL,INTENT(in) :: temp
AED_REAL,INTENT(in) :: sal
AED_REAL,INTENT(in) :: Pexch  ! exchangable phosphate content in the particles in unit of umol/g, default = 0.78 for Coorong
AED_REAL :: parA, parB           ! parameters in Eq(9) and Eq(10)
AED_REAL :: EPC0, Ppar          !  PO4 partition in the water and particles

!
!-------------------------------------------------------------------------------
!BEGIN

! the Zhang's experiment and function only valid for temperature range of 15 to 35 degrees
! when temp<15 the function goes funny, so need to assume the the Kpo4p for
!          temperature under 15 is the same to 15
IF (temp<15.0) temp=15.0;

! Eq(9) and Eq(10) from Zhang and Huang 2011      
parA=-140.5 + 1098.2/temp + 30.67*log(temp)+0.0907*salt;
parB=1225.96 - 6880.49/temp - 278.77*log(temp)+0.4561*salt;

! calculate the equilibrium P content in the water as uM
EPC0=A*Pexch + B*(Pexch)**2;

! Equilibrium P content in the particles(100 mg)
Ppar=60-EPC0;      ! initial P is 60 uM
IF (Ppar<0) Ppar=0  ! add a limitation to avoid Ppar goes negative

! calculate the Kpo4p, defined as the ratio of the particulate P concentration
!         to the dissolved P concentration per mg of SS
Kpo4p_fT_fSal = Ppar/EPC0/100;

END FUNCTION Kpo4p_fT_fSal
@aed-modeller
Copy link
Author

aed-modeller commented Feb 18, 2022

A plot of Kpo4p values from this function, with Pexch = 0.78 for the Coorong

P_adsorp_Zhang_test

@matthipsey
Copy link
Contributor

Hi Peisheng

I think this is actually a whole new adsorption model, rather than a salinity correction to the existing model

This needs to be added as a new PO4AdsorptionModel

CALL PO4AdsorptionFraction(data%PO4AdsorptionModel, & ! Dependencies

The issue is also that the Pexch is changing dynamically and is not a constant at 0.78.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants