Free degree-level computing lessons for careful independent study.

Degree Level Programmes · Formal Computing Foundations · Lesson 8

Real-Valued Functions and Graph Interpretation

Read real-valued functions as mappings with graphical behaviour.

Lesson overview

Read real-valued functions as mappings with graphical behaviour.

CourseFundamentals of Computing
Topic strandFunctions
Assessment styleDigital exam practice
EvidenceWorked answer plus justification

Starter: make the model explicit

Before reading the worked example, write down the objects involved, the claim being made and the notation you expect to use. This prevents the common error of calculating before modelling.

Learning objectives

  • Identify input, output, domain and codomain for a real-valued function.
  • Interpret increasing, decreasing and constant regions on a graph.
  • Relate a graph shape to a computing scenario.

Learning outcomes

  • By the end of this lesson, you can identify input, output, domain and codomain for a real-valued function.
  • By the end of this lesson, you can interpret increasing, decreasing and constant regions on a graph.
  • By the end of this lesson, you can relate a graph shape to a computing scenario.

Key vocabulary

domaincodomainfunctiongraph

What this lesson is about

A real-valued function maps each input in a chosen domain to exactly one real-number output. The graph of the function shows how outputs change as inputs vary.

For computing, real-valued functions can model latency, cost, probability, growth, resource use or continuous measurements. Interpreting the graph means connecting shape to behaviour.

Terms, acronyms and named methods

These are the phrases and named techniques used in this lesson. Read this section before the worked example so the notation and examples have a clear meaning.

Real-valued functionPhrase. A function whose outputs are real numbers. The inputs may also be real numbers, but the domain must still be stated.
DomainPhrase. The permitted input set for a function.
CodomainPhrase. The declared output set for a function. The range is the part of the codomain actually reached.
GraphPhrase. For a real-valued function, the set of points (x, f(x)) showing input-output behaviour.

Formal notation and definitions

f: A → B maps each input a ∈ A to exactly one output f(a) ∈ B.For real-valued functions, f: D → ℝ with D ⊆ ℝ.The graph is {(x, f(x)) | x ∈ D}.

How to read the symbols

f:DRf:D\to\mathbb{R}Function f maps each input in domain D to one real-number output.
DDThe domain: the permitted input values.
(x,f(x))(x,f(x))A point on the graph pairing an input with its output.

Use function notation to separate the input domain from the output values. A graph is valid only for the domain being modelled.

Degree-level reasoning

A function is a rule with a contract: each domain element has exactly one output. Many computing bugs come from leaving the domain or codomain vague.

Properties such as injective and surjective only make sense relative to the specified domain and codomain.

Do not stop at a correct-looking answer. State why the method is valid, whether the result depends on a hidden assumption, and what would count as a counterexample.

Worked formal model

This section shows the model, notation, calculation and interpretation as one worked answer. The notation is part of the reasoning, not decoration.

1. Context and objects

A response-time function might map request size to expected latency, letting us compare growth patterns before measuring a full system.

Objects: the input domain D, an input x or s, the output f(x), and the graph points (x, f(x)).

Model cue: Use an input-output mapping diagram alongside a graph. The mapping diagram stresses that each input has one output; the graph shows how outputs vary over a numeric domain.

2. Mathematical working

f:DR,D={sRs0}f:D\to\mathbb{R},\quad D=\{s\in\mathbb{R}\mid s\ge 0\}f(s)=2s+10f(s)=2s+10f(5)=25+10=20,(5,20) is a point on the graphf(5)=2\cdot5+10=20,\quad (5,20)\text{ is a point on the graph}
Plain text version
f: A → B maps each input a ∈ A to exactly one output f(a) ∈ B.
For real-valued functions, f: D → ℝ with D ⊆ ℝ.
The graph is {(x, f(x)) | x ∈ D}.

Worked use: Let f(s) be expected response time for request size s. If f is increasing on a region, larger requests in that region have larger expected response times. The graph supports a performance claim only for the domain actually modelled.

3. How to read the working

  1. Start with f: D → R. This says f accepts inputs only from D and produces real-number outputs.
  2. The domain D = {s ∈ R | s ≥ 0} excludes impossible negative request sizes before any graph is interpreted.
  3. Evaluate f(5) by substituting the input 5 into the formula; the pair (5, 20) is then a graph point.
  4. Translate the result as a performance claim only inside the domain. The graph does not justify behaviour for inputs outside D.

4. Computing meaning and check

The function model turns performance data into a claim about input-output behaviour. The domain matters because the graph says nothing reliable outside it.

Now check: State a domain for a response-time function and explain why negative request sizes should not be included.

Worked example

From scenario to formal reasoning

Scenario: A response-time function might map request size to expected latency, letting us compare growth patterns before measuring a full system.

Method: Use the definitions and notation introduced above, then state what the result means in this computing scenario.

Reveal model answer

Let f(s) be expected response time for request size s. If f is increasing on a region, larger requests in that region have larger expected response times. The graph supports a performance claim only for the domain actually modelled.

Worked solution structure

How a strong answer should be written

  1. Define: State the domain and the objects under discussion. For this lesson, begin from f: A → B maps each input a ∈ A to exactly one output f(a) ∈ B.
  2. Apply: Use the relevant definition from functions; do not rely on the diagram, wording or intuition alone.
  3. Check: Test a boundary case, counterexample candidate or representation limit.
  4. Conclude: Write one sentence that connects the formal result back to the computing scenario.

Common misconception

A common mistake is thinking a graph is just a picture. For a function, the graph is evidence about input-output behaviour.

Guided practice

  1. Define a response-time function f(s) with domain s ≥ 0 and explain why negative request sizes are excluded.
  2. If f(s) = 2s + 10, calculate f(5) and interpret the point (5, 20).
  3. Describe what an increasing region on a latency graph means for system behaviour.
  4. Give one reason a graph should not be used to justify claims outside its stated domain.

Quick checks

1. Why should a request-size domain exclude negative values?

2. For f(s) = 2s + 10, what point corresponds to s = 5?

Digital exam practice

Example exam task

Model expected latency as f(s) = 2s + 10 for request size s ≥ 0. State domain and codomain, calculate f(5), identify the graph point and interpret increasing behaviour.

Notation toolkit

f:DRf:D\to\mathbb{R}

Means: f maps inputs from domain D to real-number outputs

How to use: Use it before interpreting a graph.

D={xRx0}D=\{x\in\mathbb{R}\mid x\ge0\}

Means: set-builder notation for allowed real inputs

How to use: Use it to exclude impossible values such as negative sizes.

(x,f(x))(x,f(x))

Means: a point on the graph of f

How to use: Use it when translating a calculation into graph evidence.

What a good answer is expected to show

A strong answer for this lesson defines the input domain D, an input x or s, the output f(x), and the graph points (x, f(x)), applies the functions method with visible working, and finishes by interpreting the result in the computing scenario.

How to solve it

  1. Start with f: D → R. This says f accepts inputs only from D and produces real-number outputs.
  2. The domain D = {s ∈ R | s ≥ 0} excludes impossible negative request sizes before any graph is interpreted.
  3. Evaluate f(5) by substituting the input 5 into the formula; the pair (5, 20) is then a graph point.
  4. Translate the result as a performance claim only inside the domain. The graph does not justify behaviour for inputs outside D.

Model answer

Reveal model answer
D={sRs0},f:DRD=\{s\in\mathbb{R}\mid s\ge0\},\quad f:D\to\mathbb{R}f(s)=2s+10,f(5)=20,(5,20)graph(f)f(s)=2s+10,\quad f(5)=20,\quad (5,20)\in\operatorname{graph}(f)

Let D = {s ∈ ℝ | s ≥ 0} and f: D → ℝ with f(s) = 2s + 10. Then f(5) = 20, so (5, 20) is a point on the graph. On this model, increasing request size increases expected latency inside the stated domain; the graph does not justify negative request sizes.

Practise next

  1. Define a response-time function f(s) with domain s ≥ 0 and explain why negative request sizes are excluded.
  2. If f(s) = 2s + 10, calculate f(5) and interpret the point (5, 20).

Self-marking criteria

  • States a non-negative domain.
  • States real-valued output/codomain language.
  • Calculates f(5) = 20.
  • Connects (5, 20) to graph interpretation.
  • Does not extrapolate outside the stated domain.

Extension

Change one assumption in the worked scenario and decide whether the same method still applies. If it does not, name the exact point where the reasoning breaks.

Study route

Save one clean worked answer from this lesson. Include the problem statement, notation, working, final answer and a short note explaining the computing meaning of the result.

Next lesson: Function Properties: Domain, Range, Composition and Inverses.