Improving Basic Water Calculator

hairycheese

New Member
Trial Member
Joined
Jul 26, 2017
Messages
1
Reaction score
0
Points
1
The basic water calculator can be improved to automatically determine the mass of salts that need to be added to hit a profile. This is because there are six target ions and six source salts so you can write a 6x6 matrix that converts input salts to output ions. Inverting this matrix and multiplying it against the goal change in ions returns the quantities of salts that must be added to hit the target profile. This may also apply to the more advanced calculator by limiting the salt choices and iteratively calculating solutions to deal with the non-linear equilibria calculations.
 
Thanks for the input. That's not something that has been asked for before (as far as I know), but it's something to keep in mind.
 
Thanks for the input. That's not something that has been asked for before (as far as I know), but it's something to keep in mind.

Just noticed this, similar to something I mocked up last year. I used a slightly different method, but have actually written it up in PHP if that's helpful. It wouldn't be hard to integrate that in to the calculator, though you might want to use GSL or some well-known library for the simplex algorithm rather than my barely-tested implementation.

Suggestion was https://www.brewersfriend.com/forum/threads/optimal-salt-addition-calculator.3117/

Code is at https://github.com/pruby/brew-salt-optimiser
 

Back
Top