Free lesson · Differential calculus
Core derivative rules: constants, powers and sums
Open interactive lessonPractice calculationsExplore labs
Start with the idea
- A derivative is a local slope.
- Start with one constant, one power and one sum before combining functions.
Symbols, units & horizon
- x: dimensionless input in this example
- f(x): dimensionless output
- f′(x): output change per input change locally
- d/dx: differentiate with respect to x
- n: positive integer power
- a: constant multiplier
- g: another differentiable function
- h: nonzero input increment before the limit
When and why to use this
Use these rules to differentiate a simple cost curve or loss function before tackling product, quotient and chain rules.
- Constant rule: . The output never changes.
- Identity rule: . Output and input change equally.
- Power rule: for positive integer n.
- Constant multiple: when a is fixed.
- Sum rule: .
- Apply each rule to one term. Leave products and nested functions for the next lesson.
Core derivative rules: constants, powers and sums
- Constant: the change quotient is . Identity: .
- Square: expand ; its limit is .
- For a positive integer power, the binomial expansion starts . Higher terms contain at least h²; after dividing by h they tend to zero.
- Split the change quotient of a sum into separate quotients; fixed multipliers can be taken outside the limit.
- Apply these rules: .
At x=2, the derivative is 6×2+2=14. The function value is 3×4+4+7=23; value and slope are different quantities.
Use the rule
- Name the inputs and units.
- Work the small example by hand.
- Check the result before continuing to the next lesson.
Before moving on
Explain the core rule in one sentence, reproduce the worked calculation and solve both practice variations.
Further reading: OpenStax · Differentiation rules · textbook checked 12 September 2026 ↗
Python implementation
Self-contained teaching example. Python 3.10+; dependencies and input conventions are shown in the code and notation. Run in your own Python environment.
def polynomial(x): return 3*x*x+2*x+7
def polynomial_derivative(x): return 6*x+2
def positive_integer_power_derivative(x, n):
if not isinstance(n,int) or n < 1: raise ValueError("Positive integer power required")
return n*x**(n-1)
print(polynomial(2), polynomial_derivative(2))Continue learning
Differential Calculus: Limits & Derivatives — all lessons- Start with a straight line: input, output and slope
- Functions, limits and continuity
- The derivative: from an average slope to an instantaneous rate
- Core derivative rules: constants, powers and sums
- Derivative rules: powers, products, quotients and compositions
- Second derivatives, Taylor expansions and numerical error
- Stationary points, optimisation and Newton’s method
Quantitative finance and development glossary · Python resources and libraries · Research sources and limitations