Calculator Demand Curve: How It Works
The calculator for this page is switched off while it is checked. The formula is below, and the worked example in the article shows how to use it by hand.
This calculator works out the quantity demanded at a given price using a linear demand curve, and it also gives you the slope and intercept of that curve from two price-quantity points you enter. You input two known price-quantity pairs, and the calculator returns the demand equation, the quantity demanded at any price you specify, and the price elasticity of demand along that segment.
Formula
The linear demand curve is written as Q = a – bP, where Q is quantity demanded, P is price, a is the intercept (quantity demanded when price is zero), and b is the slope (the change in quantity per one-unit change in price). The slope b is calculated as (Q2 – Q1) / (P2 – P1). The intercept a is then Q1 – b × P1. To find quantity at a target price, plug that price into the equation: Q_target = a – b × P_target.
Price elasticity of demand (arc elasticity) measures how responsive quantity is to a price change between two points. It is calculated as the percentage change in quantity divided by the percentage change in price, using the midpoint formula: elasticity = |(ΔQ / average Q) / (ΔP / average P)|.
Worked Example
Using the default values: P1 = $10, Q1 = 100 units; P2 = $8, Q2 = 120 units; target price = $9.
- Slope b = (120 – 100) / (8 – 10) = 20 / (-2) = -10 units per dollar.
- Intercept a = 100 – (-10 × 10) = 100 + 100 = 200 units.
- Demand equation: Q = 200 – 10P.
- At P = $9: Q = 200 – 10 × 9 = 200 – 90 = 110 units.
- Arc elasticity = |(20 / 110) / (-2 / 9)| = |0.1818 / -0.2222| = 0.82 (inelastic).
The calculator shows quantity demanded = 110.00, slope = -10.00, intercept = 200.00, and elasticity = 0.82.
What a Demand Curve Actually Shows
A demand curve is a graph that plots price on the vertical axis and quantity demanded on the horizontal axis. It slopes downward because, all else equal, as price falls, consumers are willing to buy more. The curve itself is a snapshot of consumer behavior at a given time, holding income, tastes, and the prices of related goods constant. When those factors change, the entire curve shifts left or right, rather than moving along the curve.
The linear model is a simplification. Real demand curves can be curved (non-linear), but a straight line is often a good approximation over a narrow range of prices. The slope and intercept you calculate from two points give you a line that passes through both points, but it may not accurately predict demand far outside that range.
How to Use the Calculator
- Enter two known price-quantity pairs. These could come from historical sales data, a survey, or a market study.
- Set a target price to see the predicted quantity demanded at that price.
- Read the slope and intercept to write the full demand equation.
- Check the elasticity value to see whether demand is elastic (greater than 1), inelastic (less than 1), or unit elastic (equal to 1).
For example, if you run a small bakery and you know that at $3 you sell 200 loaves and at $2.50 you sell 240 loaves, you can estimate sales at $2.75. The calculator does this instantly, saving you from doing the algebra by hand.
Common Mistakes and Limitations
- Reversing the points: The slope formula works regardless of which point is first, as long as you stay consistent. But if you mix up which price goes with which quantity, the line will be wrong.
- Ignoring the ceteris paribus assumption: The demand curve assumes nothing else changes. If a competitor changes prices or a new trend emerges, the curve shifts, and your old equation is outdated.
- Extrapolating too far: A line fitted to two points may be wildly inaccurate at prices far from those points. For example, if your data covers $8-$10, predicting demand at $50 is unreliable.
- Confusing demand with quantity demanded: A change in price moves along the curve (quantity demanded). A change in income or preferences shifts the whole curve (demand). The calculator only handles movement along the curve.
Another common error is using the slope as a percentage. The slope is in units per dollar, not a percentage. To talk about responsiveness in percentage terms, use elasticity, which is unit-free.
Elasticity and Revenue Implications
Knowing whether demand is elastic or inelastic helps predict how a price change affects total revenue (price × quantity). If demand is elastic (elasticity > 1), a price decrease increases total revenue because the percentage increase in quantity is larger than the percentage decrease in price. If demand is inelastic (elasticity < 1), a price increase raises total revenue. If elasticity equals 1, total revenue is unchanged.
For example, with the default values, demand is inelastic (0.82). If you lower price from $10 to $8, quantity rises from 100 to 120, but total revenue falls from $1,000 to $960. The calculator’s elasticity output helps you see that effect without doing the revenue math separately.
How to Choose the Right Demand Model
Linear demand is the simplest model, but it is not always the best fit. If you have more than two data points, you can use regression analysis to fit a line that minimizes errors. If the relationship looks curved, a log-linear model (where the natural log of quantity is a linear function of price) might fit better. The calculator is a starting point; for serious forecasting, use statistical software with more data.
Also consider the market structure. In a monopoly, the demand curve is the market demand curve. In perfect competition, a single firm faces a horizontal demand curve at the market price, so a downward-sloping curve would not apply to that firm’s individual output decisions.
Frequently Asked Questions
What if I only have one price-quantity point?
You cannot determine a unique linear demand curve with one point, because infinite lines pass through a single point. You would need either a second point or knowledge of the slope from other sources (e.g., a published elasticity estimate). If you know the elasticity, you can solve for the slope using the formula: slope = elasticity × (Q/P).
Why does the demand curve slope downward?
It reflects the law of demand: as price falls, consumers are willing and able to buy more, holding other factors constant. This happens because of the substitution effect (consumers switch from more expensive alternatives) and the income effect (lower prices effectively increase purchasing power).
What is the difference between a movement along and a shift of the demand curve?
A movement along the curve occurs when the price of the good itself changes, and we read a new quantity from the same curve. A shift occurs when a non-price factor changes, such as consumer income, preferences, or the price of a substitute or complement. A shift means a new quantity is demanded at every price, so the entire curve moves.
Can the demand curve slope upward?
In rare cases, some goods (called Giffen goods) may have an upward-sloping demand curve, where quantity demanded increases as price rises. This is a theoretical exception that requires the good to be an inferior good with a large income effect and few substitutes. Empirically, such cases are extremely rare and hard to verify.
How do I calculate market demand from individual demand curves?
Market demand is the horizontal sum of all individual demand curves. At each price, you add the quantities demanded by each consumer. If you have two consumers with demand curves Q1 = 10 – P and Q2 = 15 – 2P, the market demand is Q = 25 – 3P for prices where both consumers are active.
Related
Formula used
in p1 | Price at point 1 | $ | 10 | 0 in q1 | Quantity at point 1 | units | 100 | 0 in p2 | Price at point 2 | $ | 8 | 0 in q2 | Quantity at point 2 | units | 120 | 0 in p_target | Target price | $ | 9 | 0 out q_target | Quantity demanded at target price | units | q1 + (q2 - q1) / (p2 - p1) * (p_target - p1) | 2 out slope | Slope (ΔQ/ΔP) | units per $ | (q2 - q1) / (p2 - p1) | 2 out intercept | Intercept (Q at P=0) | units | q1 - ((q2 - q1) / (p2 - p1)) * p1 | 2 out elasticity | Price elasticity (arc) | - | abs(((q2 - q1) / ((q1 + q2) / 2)) / ((p2 - p1) / ((p1 + p2) / 2))) | 2
Each line is one input (in, sel, list) or one result (out: label, unit, formula, decimals). How the calculators work
Method: the standard formula for this calculation, rounded as each result states. See how the calculators work or report an error.