Yields, purification factor and mass-balance closure of a purification train
dsp_purification_yield
Works out step and overall yields, purity, purification factor and mass-balance closure from masses.
- Runs
- On the server
- Level
- Checked against a reference: Python's exact rational arithmetic, and mpmath at 50 digits for the logarithms
What it is
Returns step and overall yields, mass-balance closure, purity, purification factor and clearance, from masses. Use when tabulating a purification run: product in, out and side fractions per step, with impurity masses where measured. Not for binding capacity from a breakthrough curve: use `dsp_dbc_breakthrough`. Masses only, never titres; yields above 1 are flagged, not refused; an impurity of zero out is refused: state its quantitation limit.
Field: Downstream processing.
What it does
You give
steps(required): The steps in order.
No request is recorded for this tool.
Limits
- Research and education arithmetic for downstream process development on the values you supply.
- Binding capacities, fluxes, Vmax, sieving and correction factors are yours and are never looked up or defaulted.
- Each result holds only under the assumptions stated with it, and sizing or scale-up from a model is given without a prediction error, because none is available.
- Not a process design, validation, batch-release or regulatory calculation; makes no compliance claim.
- From the masses you supply; purity counts only the product and the one impurity you state, and the purification factor is a ratio of those mass purities, not of specific activities.
- Every computed number a reply returns, other than an integer or an exact decimal, is rounded once to 12 significant figures: to the nearest, a change of at most 5 × 10⁻¹² of its value, except that a lower bound is rounded down and an upper bound up, a change of less than 1 × 10⁻¹¹; the method computes, and decides any pass or fail, on the unrounded value.
It will not answer when
- no impurity is stated going in, so no clearance is defined for this step.
- an impurity of zero out gives no finite clearance; a quantitation limit, marked as one, gives a lower bound.
Every input, with its units1 input
steps(required): The steps in order.
Every refusal, with its code2 refusals
| Code | When |
|---|---|
IMPURITY_IN_ZERO | no impurity is stated going in, so no clearance is defined for this step. |
IMPURITY_OUT_ZERO | an impurity of zero out gives no finite clearance; a quantitation limit, marked as one, gives a lower bound. |
The calculation
The method's equations, constants and worked example.
Equation 1
Y_overall = m_out,last/m_in,first
product of step yields = product over steps of Y_step. Blaber's yields are by activity units
the record's are by mass, the same form.
| Symbol | Meaning |
|---|---|
m_in | product mass into the step, g |
m_out | product mass out, g |
Y_step | step yield |
Y_overall | overall yield across the train |
Source 1.
Equation 2
P_in = m_in/(m_in + m_imp,in)
CF = m_imp,in/m_imp,out
LRV_imp = log10(CF). The record's own definitions, not from the source
Blaber's 'Purification' is a ratio of specific activities, and PF here is its analogue by mass purity. impurityIn and impurityOut are given together or not at all
one without the other is MISSING_ARGUMENT. IMPURITY_OUT_ZERO is decided before IMPURITY_IN_ZERO. A step with productOut 0 and impurityOut above 0 has purity out 0 and PF 0. CF below 1 (more impurity out than in) gives a negative log10 clearance, reported as such. YIELD_ABOVE_ONE marks each step yield above one and the overall yield above one (result.overallYield), decided exactly on the stated masses. Flags are listed one entry per step they mark, in step order (YIELD_ABOVE_ONE, CLOSURE_ABOVE_ONE, IMPURITY_LOWER_BOUND within a step), then TRAIN_NOT_CHAINED, then YIELD_ABOVE_ONE on the overall yield
an IMPURITY_LOWER_BOUND entry lists its four paths (purity out, purification factor, clearance fold, clearance). Refusals are decided step by step in order
within a step, IMPURITY_OUT_ZERO before IMPURITY_IN_ZERO.
| Symbol | Meaning |
|---|---|
m_in | product mass into the step, g |
m_out | product mass out, g |
m_side | product mass in side fractions, g |
m_imp | impurity mass, g |
Y_closure | mass balance closure of the step |
P | purity, product over product plus impurity |
PF | purification factor |
CF | impurity clearance fold |
LRV_imp | impurity clearance as a log10, log10(1) |
A definition, not a model: the equation states what the quantity means. A different convention gives a different number.
Worked example
Worked example: one case of purification-yield@1.1.0, from its inputs through each step to the answer. Values are written as a person writes them; the working carries more digits, so your own figure may differ in the last digit shown.
Inputs
- steps[0].name = capture
- steps[0].productIn = 10 g
- steps[0].productOut = 9.2 g
- steps[0].sideFractions[0] = 0.3 g
- steps[0].sideFractions[1] = 0.25 g
- steps[0].impurityIn = 40 g
- steps[0].impurityOut = 0.46 g
- steps[1].name = polish 1
- steps[1].productIn = 9.2 g
- steps[1].productOut = 8.5 g
- steps[1].sideFractions[0] = 600 mg
- steps[1].impurityIn = 0.46 g
- steps[1].impurityOut = 50 mg
- steps[2].name = UF/DF
- steps[2].productIn = 8.5 g
- steps[2].productOut = 8.3 g
Steps
- yield = 0.9199999999999999, from steps[0].productOut, steps[0].productIn; by equation 1; gives perStep[0].stepYield.
- closure = 0.975, from steps[0].productOut, steps[0].sideFractions[0], steps[0].sideFractions[1], steps[0].productIn; by equation 2; gives perStep[0].massBalanceClosure.
- purity-in = 0.2, from steps[0].productIn, steps[0].impurityIn; by equation 2; gives perStep[0].purityIn.
- purity-out = 0.9523809523809523, from steps[0].productOut, steps[0].impurityOut; by equation 2; gives perStep[0].purityOut.
- purification-factor = 4.761904761904762, from purity-out, purity-in; by equation 2; gives perStep[0].purificationFactor.
- clearance-fold = 86.95652173913044, from steps[0].impurityIn, steps[0].impurityOut; by equation 2; gives perStep[0].impurityClearanceFold.
- clearance = 1.9393021596463882 log10(1), from clearance-fold; by equation 2; gives perStep[0].impurityClearance.
The working, as the case writes it:
Capture: 9.2/10 = 0.92
closure (9.2 + 0.3 + 0.25)/10 = 0.975
purity 10/50 = 0.2 to 9.2/9.66 = 0.95238
factor 4.7619
clearance 40/0.46 = 86.957 (1.9393 log10). Overall 8.3/10 = 0.83 (worked by hand by the raising builder, 14 November 2026)
Answer
perStep[0].stepYield = 0.9199999999999999
perStep[0].massBalanceClosure = 0.975
perStep[0].purityIn = 0.2
perStep[0].purityOut = 0.9523809523809523
perStep[0].purificationFactor = 4.761904761904762
perStep[0].impurityClearanceFold = 86.95652173913044
perStep[0].impurityClearance = 1.9393021596463882 log10(1)
Where these values came from: our own exact-arithmetic script and a hand-worked case; the second implementation's run(arguments).
At build the tool returned this answer within the tolerance the file states: yields, purities, factors and clearances relative 1e-15 (absolute 1e-305 below 1e-290, in each value's unit); flags, notes, names, statuses and codes exact; where one path carries more than one unit, or a logarithmic unit, absolute at the relative value times the smallest nonzero magnitude under it (the largest, for a logarithm).
Sources
Blaber M. 3.1: Protein purification. LibreTexts, Chem 4320/5320 Biochemistry 1 (read for the definitions only)
Used for: Purification table from masses: yields, closure, purity and clearance. At: section Monitoring the Purification Process.
Read in full, 11 November 2026
How it is checked
- Level
Checked against a reference.
- Checked against
Our own exact-arithmetic script and a hand-worked case.
- Cases
No case set is linked to this version.
- Not checked
The definitions against a primary source with formulas (Burgess, Methods in Enzymology, unread); assay error in the masses supplied. Activity-based purification (specific activity) is not computed; Burgess and Deutscher (eds), Methods in Enzymology 463 (2009), unread; Blaber's page changes bytes per request, so no SHA-256 can be matched.
Changes to its methods0 changes
No change is logged for these method versions.