Hello everyone,
While working on my global compound diffusion model, I realised that the gaseous compounds in the patches (nitrogen/dioxygen/carbon dioxyde) were encoded as proportions relative to one another, e.g. 70% N, 21% O_2, 9% CO_2, summing to 100%. This approach is very close to the one used in describing atmospheric composition (and you may note the proportions are roughly similar to Earth’s).
Note
I realized while writing this that people also mentionned it on the community forum, so I link it here for reference : Quick Question Thread - #1323 by hhyyrylainen - Current Game - Thrive Community Forum
Also, I use the term gas for dissolved compounds, although under specific temperature/pressure conditions they may not be in a gaseous state.
The problem
However this falls short for our use cases: we are not describing atmospheric patches (mostly made of gas) but aquatic patches (mostly made of pure water, H_2O molecules). As such, while relative proportions work for atmosphere (because it is, in the end, a proportion relative to the total volume, sum of each gas’ volume), it does not for water (the total volume is, first and foremost, dependent on water volume).
In other words, 70% N might as well represent, at a given volume of water, 7 molecule of N per liter (if you have 10 gas molecules), or 7 billion (if you have 10 billions). As such, this proportion is not, of itself, sufficient to determine the influence of gases in the patch (this influence relies on the concentration of gases, i.e. how many molecules are in the immediate vicinity of a cell).
For this approach to work, we need another factor: the total amount of gas molecules. And the very reason why relative proportions have been working so long, is precisely because we assume a constant and similar total concentration of gases in every patch, a not very precise hypothesis: chemosynthesis, as an example, consumes both CO_2 and O_2 but does not produce N, effectively diminishing the total amount, and thus concentration.
18H_2S+6CO_2+3O_2 \rightarrow C_6H_{12}O_6+12H_2O+18S (chemosynthesis)
How to fix this?
The obvious solution is to replace this proportion with the actual gas concentration. Note that absolute amount could be then obtained by multiplying the concentration by the volume of the patch. Given that there is no reason to assume similar volumes for patches (the estuary is probably smaller than the ocean), I therefore propose the following solution:
1. Introduce a measure of dissolved compounds related to their concentration (quantity/liter)
2. Introduce volume as a property of the patches
The reason why I propose a measure related to, and not equal to the concentration, is based on a remark from Buckly: 70% N means a 70% efficiency factor for N-based. As such, it is very convenient, both for display and settings, to have a percentage value, which we may call efficiency.
As such, we could still keep the current values system by decoupling the proportion values for dissolved compounds (which I think is not enforced in the code anyways?). This would mean that you could have 70% N, 70% O_2, 70% CO_2, as all three would be (initially) independent.
But the question is: what quantity of, say, N atoms would actually be 100% N efficiency? There is also probably no reason not to have efficiency going over 100% (because you may have more quantity than the organelle can process). So, we either have to add a cap or just say that base efficiency is not an upper limit, but just a necessary reference value.
Fixed efficiency limit?
An answer could be, in accordance with our theorists, that we have a constant concentration x_N, so that a concentration \alpha x_N directly and linearly translates into efficiency \alpha (potentially over 100%). Depending on whether or not we want a hard cap on organelle efficiency, we could then, when running process computations, cap this to 100% if needed. This would still allow for an easier definition (linearity) and visibility (showing excess of a compound) to the player.
Summary
To sum this up, I raised the issue of compound density not clearly reflecting an actual physico-chemical reality, hindering integration of parameters in populations. I proposed an alternative concentration-based measure, which we may call theoretical efficiency, reflecting a proportion (potentially greater) of a base concentration. This change, along with the addition of volumes to patches, would allow us to give our current parameters a clear relationship with real physical values, and therefore simplify integration of several simulation computations. Nonetheless, the use of an efficiency measure would still allow for a simple understanding of input and display values about concentration.
A few questions remain open:
- Should process efficiency be capped? This answer would perhaps be the most important one given that it will influence following answers.
- What base concentration should we choose? If we choose a cap concentration, after which process efficiency does not increase anymore, then what about several processes using the same compound with different cap concentration?
- How to display efficiency to the player? Should we show the capped version (loosing information on whether this value may decrease easily or not)? If we don’t, how to tell the player that process efficiency will be capped?
- How to integrate this dissolved compound logic with cloud compounds and sunlight? If this is possible, of course, especially for sunlight which is very particular a “compound” (and is actually labeled dissolved, but not distributed).