import matplotlib.pyplot as plt

Let’s look at some textbook applications of nonlinear functions (and models).

Stock Prices and Prime Rate

It is theorized that the price per share of a stock is inversely proportional to the prime (interest) rate. In January 2010, the price per share \(S\) of Apple Inc. stock was $205.93, and the prime rate \(R\) was 3.25%. The prime rate rose to 4.75% in March 2010. What was the price per share in March 2010 if the assumption of inverse proportionality is correct?

The equation of variation has the form \(S = k / R\). Given the information we have, we can figure out the rate of change, \(k = 205.93 \times 0.0325\), so \(k = 6.692725\), check the steps on Symbolab.

def price(R):
  return 6.692725 / R
## 140.89947368421053


The quantity sold \(x\) of a plasma television is inversely proportional to the price \(p\). If 85,000 plasma TVs sold for $2900 each, how many will be sold if the price is $850 each?

We can write the demand function as \(x = k / p\). This lead to \(k = 85,000 \times 2,900\), which is \(k = 246,500,000\).

def quantity(p):
  return 246500000 / p
## 290000.0

Zipf’s Law

According to Zipf’s Law, the number of cities \(N\) with a population greater than \(S\) is inversely proportional to \(S\). In 2008, there were 52 U.S cities with a population greater than 350,000. Estimate the number of U.S cities with a population between 350,000 and 500,000; between 300,000 and 600,000.

We can write the relation as \(N = k / S\). \(k = 52 \times 350,000 = 18,200,000\).

def cities(S):
  return 18200000 / S
cities(350000) - cities(500000) # cities between 350,000 and 500,000
## 15.600000000000001
cities(300000) - cities(600000) # cities between 300,000 and 600,000
## 30.333333333333332


We’ve mostly looked at inverse functions in this case, but we can apply the same reasoning principle with any problem that might require another type of function. It comes down to understanding the characteristics of the modeling function and extracting the information necessary to answer the question.