Posted Tue, 10 Mar 2020 13:04:24 GMT by Rodríguez Sánchez, Alberto
Hi, and yet another experiment in my training with WEST.

I've modeled the very same sample plant in ASM1Temp and ASM2dModTemp with the very same influent (same flow, same COD, same N, same fractionation). And I've adjusted ALL kinetic, composition and stoichiometric parameters in ASM2d to make it fully equivalent to ASM1.

More over, as I don't actually care about phosphorus, I've set S_A to 0 in influent (therefore ASM1 S_S is fully equivalent to ASM2d S_F) and an extremely low fermentation rate (Q_fe = 0.0001) effectively killing PAO generation as there's just residual S_A generation.

More over, as ASM1 doesn't have different decay ratios in aerobic or anoxic conditions, I've set all ASM2d n_NO_xxx_d ratios to 1. (I hope effectively kiling ASM2d[b][u]Mod[/u][/b]Temp feature as Enrico confirmed here: https://forum.mikepoweredbydhi.com/index.php/topic,21895.0.html ).

And of course every dimension in tanks and flows through the plant are exactly the same (Anoxic tank [b]100 m3[/b], Aerated tank [b]350 m3[/b], influent [b]500 m3/d[/b], SST down flow [b]510 m3/d[/b] with [b]f_ns = 0.005[/b], excess of sludge [b]6 m3/d[/b] -external recycle is 504 m3/d-, internal recycle [b]1500 m3/d[/b], DWU flow [b]1.1 m3/d[/b] with [b]e_X = 0.96[/b] and Centrifuge flow [b]0.16 m3/d[/b] with [b]e_X=0.96[/b]). Aerated tank is working at [b]1.5 g_O2/m3[/b] in both models.

And as I'm not analizing temperature behaviour, I've also set T=20ºC. I'm running a steady simulation for 200 days in order to get that, the steady stabilized result.

Well, the results are similar but with some key differences. And I cannot understand why they are happening.

[b]1. The "missing" ammonification reaction in ASM2d which leads to less TKN in effluent[/b]
This is the "only" difference I can explain. ASM1 has independent lysis cycles in COD and N and, because of the low rate in the ammonification reaction, there's quite noticeable amount of N entrapped in S_ND at the end, which is "useless" for biological growth. Therefore TKN in effluent is higher in ASM1 than in ASM2d. I've even set the k_a rate in ASM1 at its maximum possible value (0.25, this is the [i][u]ONLY[/u][/i] change I've made to ASM1 default values), but it cannot compensate the low S_ND generated/accounted for in ASM2d from its residual S_F and i_N_S_F values.

[b]2. Greater amount of biomass in ASM2d which I just cannot understand[/b]
This is, I think, the key difference which probably generates the rest of them. (As example smaller S_NH in effluent in ASM2d because there's more active nitrification biomass).

Looking at Multi_BioOut the values I get are:
[list]
[li]ASM1[list]
[li]X_BH = 1404.6 g/m3[/li]
[li]X_BA = 79.7 g/m3[/li]
[/list][/li]
[li]ASM2d[list]
[li]X_H = 1643.7 g/m3[/li]
[li]X_AUT = 91.8 g/m3[/li]
[/list][/li]
[/list]
And I swear every single growth, decay and lysis rates, halfsaturation coefficients, growth yields, whatever, are exactly the same ones in both models. More over, ASM2d has alkalinity "switches" in both heterotrophic and autotrophic growths which might cause even smaller growths, not a greater ones. (I've checked it n times).

[i][b][u]So, please, could any one spend some time analyzing and explaining what's going on?[/u][/b][/i] (I mean what I'm doing wrong) I upload WEST reports for both plants with the key elements, but if you need/want the full built models, or any other further info, I can provide them through OneDrive, or zipping and attaching the key files you tell me.

Thanks in advance.
Posted Tue, 10 Mar 2020 14:27:53 GMT by Enrico Remigi WEST Product Owner
Hi and thank you for this thorough comparison.
Overall, by just looking at the biomass concentration - that you indicate as the most worrying discrepancy between the results in ASM1 vs. ASM2Mod, I would say that it is not all that significant, as a different, given the substantially different model structure.
I acknowledge that you set all the relevant conditions (parameters et al.) to be the same for both implementations.
However, as I say, the model structure is different.
For instance if you consider hydrolysis, ASM1 vs. ASM2 have 2 vs. 3 processes which are conceptually different: you may have set n_h (ASM1) and n_NO_Hyd (ASM2) to 0.4, which will of course result in the same rate expression, but there's a third process in ASM2 (in anaerobic condition, n_fe = 0.4) and, most importantly, the stoichiometry is different in ASM1 vs. ASM2.
The same applies to other processes of course.
So I don't believe you can compare the two models, even by setting all the relevant quantities, and expect exactly the same output - because the structures are inherently different. And that is something you cannot change, by altering parameter values in the project.
Posted Tue, 10 Mar 2020 18:52:44 GMT by Rodríguez Sánchez, Alberto
Many thanks for your quick answer but I think, (I'm not sure), I disagree...

[quote]but there's a third process in ASM2 (in anaerobic condition, n_fe = 0.4)[/quote]
[b]Ooops, my fault.[/b] I forgot it. I'll kill it ASAP (n_fe = 0.0001) and I'll retest and post the results.

[quote]and, most importantly, the stoichiometry is different in ASM1 vs. ASM2.[/quote]
[quote]So I don't believe you can compare the two models, even by setting all the relevant quantities, and expect exactly the same output - because the structures are inherently different.[/quote]
Here is where I disagree. As example hydrolysis may seem different but it is exactly the same in ASM1 vs ASM2d.
[list]
[li][b]Stoichiometry.[/b] In ASM1 you have X_S (-1) which goes to S_S (1). In ASM2d, as f_S_I = 0, you also have X_S (-1) which goes to S_F (1). So it's exactly the same.[/li]
[li][b]Rate.[/b] For the sake of clarity I'm going to call Monod(xx) = xx / (Halfsat. of xx + xx) and Monod-1(xx) = Halfsat. of xx / (Halfsat. of xx + xx)
[list]
[li]ASM1. k_h · Monod(X_S/X_BH) · ( Monod(S_O) + n_h · Monod-1(S_O) · Monod(S_NO) ) · X_BH.[/li]
[li]ASM2d. There are three reactions but the anaerobic one is going to be killed (n_fe = 0.0001). Therefore:
[list]
[li]Aerobic. k_h · Monod(X_S/X_H) · Monod(S_O) · X_H[/li]
[li]Anoxic. k_h · n_NO_Hyd · Monod(X_S/X_H) · Monod-1(S_O) · Monod(S_NO) · X_H[/li]
[/list]
So in fact, Aerobic + Anoxic = ASM1.
[/li][/list]
[/li][/list]
I'd swear that I checked all the processes in this very same way. But maybe I'm wrong (look at my error with n_fe). I'll thoroughly re-evaluate all of them again...
[i](If I'm not wrong, the only reaction which is quite different is ammonification as I previously said. ASM2d ammonification is "embedded" in hydrolysis and decay. But COD reactions, when all PAO and S_A parts are killed, should be exactly the same if the parameterization is adequately selected).[/i]
Posted Wed, 11 Mar 2020 09:34:14 GMT by Rodríguez Sánchez, Alberto
[quote][quote]but there's a third process in ASM2 (in anaerobic condition, n_fe = 0.4)[/quote]
[b]Ooops, my fault.[/b] I forgot it. I'll kill it ASAP (n_fe = 0.0001) and I'll retest and post the results.[/quote]
It was more sensible than I expected (as there's actually no anaerobic tank, just residual anaerobic reaction in the anoxic and aerated tanks).

The new comparison in Multi_BioOut is:
[list]
[li]ASM1[/li]
[list]
[li]X_BH = 1404.6 g/m3[/li]
[li]X_BA = 79.7 g/m3[/li]
[/list]
[li]ASM2d[/li]
[list]
[li]X_H = 1559.8 g/m3 (previously 1643.7 g/m3)[/li]
[li]X_AUT = 87.8 g/m3 (previously 91.8 g/m3)[/li]
[/list]
[/list]

It's nearer (and in other parameters too) but it's still a bit off. As promised, I'm going to thorougly revise all the reactions according to IWA matrix to check that they are actually the same in stoichiometry and rate (but the ammonification one).

Nevertheless and in case this deviation is caused by the slower explicit ammonification in ASM1: [b][u][i]is it possible to either remove or edit the maximum possible value for k_a (0.25)? How?[/i][/u][/b] (In order to test a "fake" ASM1 model with extremely fast ammonification reaction and therefore nearly no residual unused S_ND that is what the ASM2d model is actually doing. Although I don't actually think this is going to be the case because with ASM1 default value, k_a = 0.08, I get quite similar biomass values, X_BH = 1404.4 g/m3 and X_BA = 78.9 g/m3).
Posted Wed, 11 Mar 2020 13:53:42 GMT by Rodríguez Sánchez, Alberto
I swear I've checked all relevant reactions and they are exactly the same but:
[list]
[li]Growth reaction rates in ASM2d have Monod terms on Alkalinity and Phosphorus, therefore they should be slightly slower than ASM1 ones.[/li]
[li][b]The most relevant difference[/b]. Growth of heterotrophs takes N not only from NH4 but also from S_F. I mean, S_S (ASM1) has no N content, but S_F (ASM2d) has got i_N_S_F. (And of course, Decay/Lysis and Hydrolysis generate NH4 rather than X_ND or S_ND, and always taking in account the N content of COD parts). Because of that, the used amount of NH4 is:
[list]
[li]ASM1. i_X_BM (I'm using ASM2d names).[/li]
[li]ASM2d. i_X_BM - i_N_S_F / Y_H.[/li]
[/list]
Therefore NH4 half-saturation value for the rate Monod correction must be greater in ASM2d than in ASM1 (ASM2d should be more sensible about NH4 presence). As a first test I've done a direct scalation. I mean, a i_X_BM / (i_X_BM - i_N_S_F / Y_H) factor. The ASM2d model I've built has i_X_BM = 0.086, i_N_S_F = 0.03 and Y_H =  0.67. That gives a 2.086 factor. Therefore I've increased K_NH from 0.05 to 0.10431.

Well, it does something (I'll explain in a moment), but there's something more going on because biomass in the reactor remains nearly unchanged:
[list]
[li]ASM1
[list]
[li]X_BH = 1404.6 g/m3[/li]
[li]X_BA = 79.7 g/m3[/li]
[/list][/li]
[li]ASM2d
[list]
[li]X_H = 1559.6 g/m3 (previously 1559.8 g/m3 and 1643.7 g/m3)[/li]
[li]X_AUT = 87.8 (previously 87.8 g/m3 and 91.8 g/m3)[/li]
[/list][/li]
[/list]

The real effect this increased K_NH has is that S_F comsumption is slightly lower and therefore residual S_F is closer to ASM1 residual S_S one:
[list]
[li]ASM1. S_S = 2.492 g/m3[/li]
[li]ASM2d. S_F (before) = 2.224 g/m3, S_F (after) = 2.472 g/m3.[/li]
[/list]
I suppose we can call it a match.
[/li][/list]

Summary: I still don't understand what's happening because the underlying mathematical models are (nearly) identical. I cannot understand how the biomass difference between them is generated (even if it's not relevant from a pure waste water treatment point of view).
Posted Tue, 17 Mar 2020 10:37:08 GMT by Rodríguez Sánchez, Alberto
[b]AT LAST!!!![/b]

I think I've found the [u]last[/u] root reason for the model differences. It's basically this: https://forum.mikepoweredbydhi.com/index.php/topic,21895.0.html

I mean, no matter what you do, even with n_NO_xxxx_d = 1.0, biomass decay/lysis is slower in ASM2d[u][b]Mod[/b][/u]Temp because of that extra S_NO Monod term. But if you compensate it with a bit higher b_xxxx values, then you get pretty much the same results.

As a summary. The main differences between ASM1 and ASM2d are:
[list]
[li][b]The lack of ammonification in ASM2d (it's embedded in COD hydrolysis)[/b]. Even with the highest possible value of k_a (0.25) in ASM1, I get a pretty high residual S_ND. In fact, residual S_ND to residual S_S ratio is 0.104 gN/gCOD much higher than the predefined i_N_S_F value in ASM2d: 0.03 gN/gCOD. (Influent ratio is 0.03 gN/gCOD in both models).[/li]
[li][b]Decay/Lysis is slower in WEST ASM2d implementation[/b]. But I've been able to more or less compensate it with higher b_H (0.69 vs original 0.62) and b_AUT (0.1675 vs original 0.15) values.[/li]
[li]Not so important (at least in this example). ASM2d growth reactions take nitrogen from S_F, not only from S_NH. Therefore half-saturation K_NH might need to be raised. But, in the end I've used the very same value, [u][i]I've undone what I said in my previous post.[/i][/u][/li]
[li](I haven't noticed any effect but in ASM2d there are S_ALK Monod terms in a lot of reaction rates not present in ASM1. Therefore, ASM2d reaction rates might be slightly slower).[/li]
[/list]

So my final "calibrated" ASM2d model vs the ASM1 one have this biomass values in aerated ASU:
[list]
[li]ASM1:[list]
[li]X_BH = 1404.6 g/m3[/li]
[li]X_BA = 79.7 g/m3[/li]
[/list][/li]
[li]ASM2d:[list]
[li]X_H = 1409.2 g/m3[/li]
[li]X_AUT = 79.9 g/m3[/li]
[/list][/li]
[/list]

In fact, the Multi_Efluente (effluent) relevant values are:

[table]
[tr]
[td][b]Value[/b][/td]
[td][b]ASM1[/b][/td]
[td][b]ASM2d[/b][/td]
[/tr]
[tr]
[td]TKN[/td]
[td]2.569[/td]
[td]2.386[/td]
[/tr]
[tr]
[td]TN[/td]
[td]11.859[/td]
[td]11.765[/td]
[/tr]
[tr]
[td]S_NH[/td]
[td]0.569[/td]
[td]0.574[/td]
[/tr]
[tr]
[td]S_NO[/td]
[td]9.289[/td]
[td]9.379[/td]
[/tr]
[tr]
[td]S_ND (i_N_S_F · S_F)[/td]
[td]0.261[/td]
[td]0.075[/td]
[/tr]
[tr]
[td]i_N_X_BM · Biomass[/td]
[td]0.638[/td]
[td]0.640[/td]
[/tr]
[tr]
[td]COD[/td]
[td]45.742[/td]
[td]45.758[/td]
[/tr]
[tr]
[td]S_I[/td]
[td]20.996[/td]
[td]20.996[/td]
[/tr]
[tr]
[td]S_S (S_F)[/td]
[td]2.492[/td]
[td]2.485[/td]
[/tr]
[tr]
[td]S_A[/td]
[td]---[/td]
[td]0.003[/td]
[/tr]
[tr]
[td]X_I + X_P[/td]
[td]14.740[/td]
[td]14.736[/td]
[/tr]
[tr]
[td]X_S[/td]
[td]0.093[/td]
[td]0.094[/td]
[/tr]
[tr]
[td]X_BH (X_H)[/td]
[td]7.023[/td]
[td]7.046[/td]
[/tr]
[tr]
[td]X_BA (X_AUT)[/td]
[td]0.398[/td]
[td]0.400[/td]
[/tr]
[/table]
Posted Wed, 18 Mar 2020 11:55:32 GMT by Enrico Remigi WEST Product Owner
Brilliant !
Thanks a lot for your persistence. I am sure this will be of great value for other WEST users.

You must be signed in to post in this forum.