Hi Jonathan,
The function passed to FindRoot
needs an argument
equilibriumPrice = FindRoot[Difference[price], {price, 60}]
(* {price -> 58.1167} *}
The Print
does not have a terminating ;
so it is implicitly multiplied by whatever follows, and equilibriumPrice
is not extracted correctly
Print["Equilibrium price:", equilibriumPrice[[1, 2]]];
demand[maxDemand, rateChangeDemand, price, priceAtHalfMaxDemand] -
supply[maxSupply, rateChangeSupply, price, priceAtHalfMaxSupply]