Cash runway in integer cents: gross margin, a reserve line, and months-to-days without drift
A runway calculator looks like one division. For an operating business it is three decisions about what to divide, and one about how to round. Work from gross margin, not total cost When sales fall, the direct costs of the lost sales fall too. Fixed outflows do not. So the monthly cash result is: // money in integer cents, margin in basis points const sales = 4_000_000n ; // $40,000.00 const…
A calculator for measuring how long a business can operate before running out of cash relies on three key decisions. When sales decline, the direct costs linked to those lost sales also decrease. Fixed expenses, such as payroll, rent, loans, and owner pay, remain constant. The monthly cash outcome is calculated by multiplying sales by the gross margin in basis points, then subtracting other outflows.
The formula uses integer cents for money and basis points for margin. Gross profit is determined by multiplying sales by margin, dividing by 10,000. To ensure a conservative estimate, truncating toward zero is recommended for gross profit. The reserve line is subtracted from the available cash to determine spendable funds. If spendable funds equal zero, the business is already below the reserve line.
Stress should be placed on the sales line rather than total costs when evaluating the impact of sales drops. For example, a 20% sales drop results in a monthly cash shortfall of -340,000 (approximately 12.4 months of runway). If there are no sales at all, the shortfall is -2,100,000 (exactly 2 months of runway).
To convert the runway from months to days, the ratio is kept exact, and rounding is performed once, rounding down to ensure a full day of safety. Two months of runway translates to 60 days. When testing the boundary case where loss equals spendable funds, the result should be one month and 30 days. The Cash Runway Calculator utilizes this methodology, accounting for the reserve and rounding to zero.
Rewritten by urgent.news; may contain errors — check the original.
Source: dev.to