Mass balance calculator
This mass balance calculator solves the material balances you meet most often in chemical engineering: the outlet flow and composition of a mixer, the flow of a second stream needed to blend to a target composition, the top and bottom products of a separator from recovery and purity, and the accumulation rate and fill or drain time of a tank.
Mass balance calculator for a mixer
Blending mass balance calculator: stream 2 flow for a target
Separator mass balance calculator: recovery and purity
Mass balance calculator with accumulation: tank fill or drain time
How to use the mass balance calculator
Each panel is a different unit operation. The mixer panel adds up to three streams and returns the outlet flow and composition. The blending panel works backwards from a target composition to the flow of the second stream you need, for example the water required to dilute a caustic solution. The separator panel splits a feed into top and bottom products from two specifications, the recovery of the key component and the top purity, and checks that the split is physically possible. The last panel is the general balance with accumulation, for tanks that are filling or draining. Flows can be entered in kg/s, kg/h, t/h or lb/h; the mass balance calculator converts them and shows each step with the numbers substituted.
The general balance equation behind the mass balance calculator
Every material balance is a bookkeeping statement about a chosen system boundary. For total mass or for any single component:
Generation and consumption only apply to component balances when chemical reactions occur; total mass is never generated or consumed. For a continuous process at steady state there is no accumulation, and for a process without reaction the equation reduces to the familiar input = output, written once for the total flow and once for each component. A batch process has no flow during the run, so the balance becomes initial content + generation = final content + consumption. The mass balance calculator panels cover the steady-state cases and the tank with accumulation.
| Process type | Balance on total mass | Balance on a component |
|---|---|---|
| Continuous, steady, no reaction | in = out | in = out |
| Continuous, steady, with reaction | in = out | in + generation = out + consumption |
| Batch | initial = final | initial + generation = final + consumption |
| Transient (tank filling or draining) | in − out = dM/dt | in − out + generation − consumption = d(M·x)/dt |
Degrees of freedom and choosing a basis
Before solving, count the unknowns and the independent equations. For a process without reaction involving N components you can write N independent balances (the total balance plus N − 1 component balances, or N component balances). The degrees of freedom are the number of unknowns minus the number of independent equations, including specifications such as a recovery, a purity or a flow ratio. Zero degrees of freedom means the problem can be solved; a positive number means you need more information. A separator, for example, has unknown top and bottom flows and the bottom composition (three unknowns), two balances (total and A) and needs one more specification; the mass balance calculator uses the recovery and the top purity, which with the two balances fix all three.
When no flow is given, choose a basis of calculation, such as 100 kg of feed or 100 mol of feed, solve the balances, then scale all flows to the real throughput. Because steady-state balances are linear, every flow scales by the same factor while the compositions stay unchanged.
Worked examples with the mass balance calculator
Mixer. Stream 1 is 100 kg/h with 20% A, stream 2 is 50 kg/h with 50% A and stream 3 is 50 kg/h of pure water (0% A). Total: 100 + 50 + 50 = 200 kg/h. Component A: 100 × 0.20 + 50 × 0.50 + 50 × 0 = 45 kg/h. Outlet composition: 45 / 200 = 22.5% A.
Blending (dilution). 500 kg/h of 40% NaOH solution is diluted with water to 25%. The A balance gives 500 × 0.40 = (500 + ṁ₂) × 0.25, so ṁ₂ = 500 × (40 − 25) / (25 − 0) = 300 kg/h of water and the product is 800 kg/h. Check: 0.25 × 800 = 200 kg/h of NaOH, the same as in the feed.
Separator. A feed of 1000 kg/h with 40% A goes to a column that recovers 95% of A in the top product at 90% purity. A in the feed = 400 kg/h; A to the top = 380 kg/h; top flow D = 380 / 0.90 = 422.2 kg/h; bottom flow B = 1000 − 422.2 = 577.8 kg/h; A in the bottom = 20 kg/h, so the bottom contains 20 / 577.8 = 3.46% A. The other components are 92.96% recovered in the bottom. If you asked for 95% recovery at only 30% purity, the top product would be 380 / 0.30 = 1267 kg/h, more than the whole feed, and the mass balance calculator reports the specification as infeasible. In general the split is feasible only when the “other” components sent to the top, D·(1 − xD), do not exceed those in the feed.
Tank. 500 kg/h flows in and 300 kg/h out, so the tank accumulates 200 kg/h. Going from 2000 kg to 10,000 kg takes (10,000 − 2000) / 200 = 40 h. To relate mass to liquid level, divide by density and use the Tank Volume Calculator.
All four examples are the default values of the mass balance calculator panels, so you can reproduce each one and then change the numbers to match your own problem.
Mass fractions, mole fractions and percentages
The mass balance calculator works with mass percentages; convert first if your data are molar.
Mass balances are always valid on a mass basis, and on a molar basis when there is no reaction. Converting between them needs the molar masses: xi (mole) = (wi/Mi) / Σ(wj/Mj). A 50/50 mass mixture of ethanol (46.07 g/mol) and water (18.02 g/mol) is only 28.1 mol% ethanol. Liquid blending specifications are usually by mass or volume, gas compositions usually by mole (which equals volume for ideal gases). For simple percentage arithmetic the Percentage Calculator is handy.
Common mistakes the mass balance calculator helps you avoid
Mixing mass and mole fractions in the same balance. Convert everything to one basis first. Forgetting the basis or changing it halfway through a problem. Balancing volumes. Volumes are not conserved when liquids mix (ethanol and water shrink by a few percent) or when gases change temperature and pressure; balance mass or moles instead. Writing too many equations. With N components only N balances are independent; the extra one is a useful check, not new information. Ignoring feasibility. A recovery and a purity can be chosen that no separator could achieve; the separator panel of this mass balance calculator tests this, and the Distillation Column Calculator tells you how many stages a feasible split needs.
Further reading
The standard textbook is Felder and Rousseau, Elementary Principles of Chemical Processes (Wiley), chapter 4 on fundamentals of material balances, including degrees-of-freedom analysis, recycle and bypass. A concise online treatment of steady-state balances on mixers, splitters and separators is the University of Edinburgh notes on basic steady-state material balances.
Related calculators
After the mass balance calculator has fixed the flows, the Energy Balance Calculator gives heating and cooling duties. For hold-up time in a vessel use the Residence Time Calculator.
- Energy Balance Calculator
- Distillation Column Calculator
- Tank Volume Calculator
- Residence Time Calculator
- Enthalpy Calculator
- All chemical engineering calculators
Frequently asked questions
What is a mass balance in chemical engineering?
An accounting of material crossing a system boundary: input − output + generation − consumption = accumulation. At steady state without reaction it reduces to input = output for the total flow and for each component.
How do I calculate the outlet composition of a mixer?
Add the flows to get the outlet flow, add the component flows (flow × fraction) to get the outlet component flow, then divide. The mixer panel of the mass balance calculator does this for up to three streams.
How much water do I need to dilute a solution?
Use ṁ₂ = ṁ₁·(x₁ − x_T)/(x_T − x₂) with x₂ = 0 for water. Diluting 500 kg/h of 40% solution to 25% needs 300 kg/h of water.
Why does the separator panel say my specification is infeasible?
Because the requested top product would contain more of the non-key components than the feed provides, or would take the whole feed. Raise the purity or lower the recovery.
Is this mass balance calculator free?
Yes. It runs in your browser, needs no sign-up and does not store or send the values you enter.