Skip to content

Main content

Proportional Mixture Conservation Residual

Compare a supplied mixture total with explicitly recorded compatible component masses, preserving signed imbalance.

Loading tool…

Description

Calculate a mixture mass residual against supplied component masses.

Proportions depend on the order of a ratio, its denominator and whether an input is a decimal fraction or a percentage number. Inverting a zero-crossing interval is undefined, and rounding an ideal share to a quantum can exceed a total. Supplied conservation, tax or mixing assumptions need explicit units and boundaries before interpretation.

Calculate a mixture mass residual against supplied component masses.

When to use this tool

Use Proportional Mixture Conservation Residual when you already have componentMasses, suppliedTotalMass and need to calculate a mixture mass residual against supplied component masses.

How to use the tool and how it works

  1. Enter componentMasses, suppliedTotalMass. Use the units and conventions below.
  2. Run the tool. Correct any format, range, or cross-field input error before interpreting the output.
  3. Read summedComponentMass, residual. Use the output convention below.

Require totalMass>=0 and each component>=0; sum components and return total-sum without clamping.1

Input fieldMeaning and unitsAccepted input
componentMassesComponent MassesRequired. Array of finite number; maximum items 256.
suppliedTotalMassSupplied Total MassRequired. Finite number; minimum 0.
Output fieldInterpretationReturned shape
summedComponentMassSummed Component MassRequired. Finite number.
residualResidualRequired. Finite number.
json
{
  "input": {
    "componentMasses": [
      2,
      3,
      4
    ],
    "suppliedTotalMass": 10
  },
  "output": {
    "summedComponentMass": 9,
    "residual": 1
  }
}

Limitations and assumptions

  • An empty component list sums to zero; the tool does not verify conservation, component identity, losses or a physical mixing process.
  • Inputs must satisfy both the field types and the cross-field conditions above. Invalid input causes an error; a successful false flag or documented placeholder is a different result.
  • Numeric calculations use binary floating point unless exact decimal-integer arithmetic is explicitly stated. No hidden measurement tolerance or decimal rounding is added; nonfinite or out-of-contract results are rejected. Numeric signed-zero results are exported as zero.

Alternative or Complementary methods

Write the numerator, denominator and ratio direction explicitly before rebasing or inverting a quantity. Use a full allocation or mass balance for multiple components, and account for quantum remainders jointly when rounded shares must add to a fixed total.

References

  1. Calculation and input contract: proportions/proportional-mixture-conservation-residual — tool.io

Similar or alternative tools