Contents
Deep Breakdown
What it tells me (Situation Awareness): A hyperbola is the set of all points in the plane where the difference of distances to two fixed foci is constant. The standard form opens left and right, with vertices at and asymptotes . In DA/DS: hyperbolas appear as the level curves of multiplicative relationships between two variables (e.g., is a rectangular hyperbola), in supply-demand economic modeling, in time-series with exponential divergence, and in the geometry of SVMs with hyperbolic kernels. The rectangular hyperbola is central to interpreting elasticity and power-law trade-offs.
Flowchart
Real-world use
Where it is used
Economic elasticity and trade-off curves (constant revenue ), hyperbolic discounting in behavioral economics, bifurcation points in dynamical systems, level curves in contour plots of multiplicative objective functions, and calibration curves in spectroscopy/chemistry (Beer-Lambert law at high concentrations shows hyperbolic saturation).
Problem it solves
When a relationship between two variables is multiplicative (), their level curves are rectangular hyperbolas. Recognizing this shape tells you the relationship is a power-law trade-off: as increases, must decrease proportionally to maintain constant product. The standard hyperbola also models systems where two diverging behaviors co-exist (two branches).
How it solves the problem
The equation is a conic section formed by a plane cutting a double cone at a steep angle. Re-arranging: , defined only for . The two branches diverge toward the asymptotes as .
Example in a business
A DS models the price-quantity trade-off in a pricing experiment. At constant revenue , the curve is a rectangular hyperbola: . The DS fits this to historical data to identify the constant-revenue curve and uses it to find the price point that maximizes profit margin while staying on the same revenue level. Deviations from the hyperbola indicate price sensitivity changes.
The formula, piece by piece
- : real semi-axis — half the distance between the two vertices ( on the -axis)
- : imaginary semi-axis — controls the steepness of the asymptotes
- : standard form, horizontal transverse axis
- Asymptotes: (lines the hyperbola approaches but never reaches)
- Vertices:
- Foci: where (note: for hyperbola, vs. for ellipse)
- Eccentricity: (vs. ellipse , parabola )
- Conjugate (vertical) hyperbola: (opens up/down)
- Rectangular hyperbola: — asymptotes are coordinate axes;
The formula in words
"The hyperbola equation says: the normalized -contribution exceeds the normalized -contribution by exactly 1. Points exist only where (the two branches). The curve curves away from the origin and approaches (but never touches) the straight lines ." Tiny example: , . Vertex: . Asymptotes: . Check: , .
Critical Concepts
- Conic classification: (ellipse), (hyperbola). The sign change between terms is what distinguishes them.
- Asymptotes don't cross: the hyperbola approaches its asymptotes as but never intersects them (for finite ). This is key for understanding model behavior at extremes.
- Rectangular hyperbola : rotating the standard hyperbola by 45° gives . This is the form most common in economics (constant elasticity demand) and optimization trade-offs.
- Eccentricity : the defining property of a hyperbola. Eccentricity measures how "open" the conic is: is a parabola, is a hyperbola, is an ellipse.
- Two branches: unlike the ellipse, the hyperbola has two separate branches. In data, this can represent two distinct regimes.
- Parametric form: for the right branch; uses hyperbolic functions (hence the name "hyperbolic" functions).
Step-by-step calculation (tiny example)
Step 1: Identify parameters , . Vertices at . Asymptotes: . . Eccentricity .
Step 2: Find a point on the hyperbola : .
Step 3: Verify focus property For the right branch, for any point : . Foci at .
Code examples
Beginner example (Python)
import numpy as np
import matplotlib
matplotlib.use('Agg')
import matplotlib.pyplot as plt
def hyperbola_y(x: np.ndarray, a: float, b: float) -> np.ndarray:
"""Compute y values for hyperbola x^2/a^2 - y^2/b^2 = 1 (upper branch)."""
return b * np.sqrt((x**2 / a**2) - 1.0)
a, b = 2.0, 3.0
c = np.sqrt(a**2 + b**2)
ecc = c / a
print(f"Hyperbola: a={a}, b={b}")
print(f" Vertices: (+-{a}, 0)")
print(f" Foci: (+-{c:.4f}, 0)")
print(f" Asymptotes: y = +-(b/a)*x = +-{b/a:.4f}*x")
print(f" Eccentricity: e = {ecc:.4f}")
# Sample points on the right branch
x_vals = np.linspace(a, 10, 200)
y_upper = hyperbola_y(x_vals, a, b)
print(f"\nSample points (right branch, upper):")
for x_pt in [2.0, 4.0, 6.0, 10.0]:
y_pt = float(hyperbola_y(np.array([x_pt]), a, b)[0])
check = x_pt**2/a**2 - y_pt**2/b**2
print(f" x={x_pt}: y={y_pt:.4f}, check x^2/a^2-y^2/b^2 = {check:.6f}")
# Rectangular hyperbola xy = k
K = 6.0
x_r = np.linspace(0.5, 12, 100)
y_r = K / x_r
print(f"\nRectangular hyperbola xy={K}: at x=3, y={K/3:.2f}; at x=6, y={K/6:.2f}")Beginner example (R)
# -- Hyperbola ---
a <- 2; b <- 3
c_focal <- sqrt(a^2 + b^2)
ecc <- c_focal / a
cat(sprintf("Hyperbola: a=%g, b=%g\n", a, b))
cat(sprintf(" Vertices: (+-%.4f, 0)\n", a))
cat(sprintf(" Foci: (+-%.4f, 0)\n", c_focal))
cat(sprintf(" Asymptotes: y = +-%.4f * x\n", b/a))
cat(sprintf(" Eccentricity: %.4f\n", ecc))
# Sample points
for (x_pt in c(2, 4, 6, 10)) {
if (x_pt^2/a^2 > 1) {
y_pt <- b * sqrt(x_pt^2/a^2 - 1)
check <- x_pt^2/a^2 - y_pt^2/b^2
cat(sprintf(" x=%.0f: y=%.4f, check=%.6f\n", x_pt, y_pt, check))
}
}Professional example (Python)
import numpy as np
import pandas as pd
np.random.seed(42)
# -- Business scenario: constant-revenue hyperbola for pricing analysis ---
# Model price-quantity relationship at different revenue levels.
# Rectangular hyperbola: price * quantity = revenue (constant).
TARGET_REVENUE_LEVELS = [10000, 15000, 20000]
QUANTITY_RANGE = np.linspace(100, 2000, 100)
rows = []
for rev in TARGET_REVENUE_LEVELS:
prices = rev / QUANTITY_RANGE
rows.append({
"revenue_target": rev,
"qty_at_price_10": rev / 10.0,
"qty_at_price_20": rev / 20.0,
"qty_at_price_50": rev / 50.0,
"price_at_qty_500": rev / 500.0,
"price_elasticity": -1.0, # constant for rectangular hyperbola
})
df = pd.DataFrame(rows)
print("Constant-revenue curves (rectangular hyperbola: price * quantity = revenue):")
print(df.to_string(index=False))
# Simulate noisy price-quantity data and fit a rectangular hyperbola (xy = k)
TRUE_REVENUE = 12000.0
qty_data = np.random.uniform(200, 1800, 30)
price_data = TRUE_REVENUE / qty_data + np.random.normal(0, 0.5, 30)
# Fit: xy = k; estimate k as mean(price * quantity)
k_hat = np.mean(price_data * qty_data)
residuals = price_data - k_hat / qty_data
print(f"\nFitted rectangular hyperbola (price * quantity = k):")
print(f" True k = {TRUE_REVENUE:.0f}")
print(f" Estimated k = {k_hat:.2f}")
print(f" RMSE of price residuals: {np.sqrt(np.mean(residuals**2)):.4f}")Source: 1300 p. 162