https://5dok.org/document/oz1dl4pz-technical-reproduction-canister-calculations-residual-scenario-illustrate-functions.html