Functions

Download as pptx, pdf, or txt
Download as pptx, pdf, or txt
You are on page 1of 30

FUNCTIONS

CPE203
FUNCTIONS
A function is a mathematical rule that
assigns each input exactly one output.
The output produced by applying the
function to an input is referred to as the
image of that input.
Example: If 𝑓 is a function and 𝑥 is an
input, then 𝑓(𝑥) is the image of 𝑥.
Describing a Function
Domain: The complete set of possible inputs for a function.
Example: For f(x)=x^2+3, the domain is the set of natural numbers
N.
Codomain: The set of all allowable outputs that the function can
potentially produce.
Example: For f(x), the codomain is also N.
Notation: A function can be denoted as f : X → Y, where:
f: Name of the function.
X: Domain.
Y: Codomain.
Describing a Function
Domain: Natural numbers N = {1,2,3,...}.
Codomain: Also natural numbers N.
Rule: For any input x, the output is calculated as:
◦ Multiply x by itself (square it).
◦ Add 3 to the result.
Example Calculation: For x=2:
f(2) = 2^2 + 3 = 4 + 3 = 7
Describing a Function
Domain: Natural numbers N = {1,2,3,...}.
Codomain: Also natural numbers N.
Rule: For any input x, the output is calculated as:
◦ Multiply x by itself (square it).
◦ Add 3 to the result.
Example Calculation: For x=2:
f(2) = 2^2 + 3 = 4 + 3 = 7
Describing a Function
The function f(x) = x^2 + 3 can be applied to every
natural number.
All results are guaranteed to be natural numbers
(outputs are in the codomain).

Sample Outputs:
f(1) = 1^2 + 3 = 4
f(2) = 7
f(3) = 12
f(4) = 19
Range
The range is the actual set of outputs produced by the
function.

Outputs: Not every natural number is an output of 𝑓(there


is no way to get 0, 1, 2, 5, etc.).

Example Range:{3, 4, 7, 12, 19, 28,...}

Outputs are all the natural numbers that are 3 more than
perfect squares (e.g., 0^2+3, 1^2+3, 2^2+3,...).
Importance of Function
Rules
A function must have exactly one output for
each input to qualify as a function.

This one-to-one mapping ensures clarity and


consistency.

Key Principle: If an input is provided, the


function must return a single, definitive output.
Analysis
What output do we assign to the input 7?

We need to determine f(7):


Calculation: f(7) = 7^2 + 3 = 49 + 3 = 52.

Conclusion: There can only be one answer


for the output corresponding to the input 7.
Example
f : Z → Z defined by Domain: The domain is the set of all integers, denoted
as 𝑍. This means any integer 𝑛 can be used as an input.
f(n) = 3n.
Codomain: The codomain is also the set of all integers
𝑍. This indicates that the outputs are intended to
The domain and belong to the set of integers.
codomain are both
Rule: The rule of the function is given by the
the set of integers. equation 𝑓(𝑛)=3𝑛. This means for any integer input 𝑛,
the output is three times that integer.
However, the range Range: The range of a function is the set of all actual
is only the set of outputs produced by the function when the rule is
integer multiples of applied to every element in the domain. In this case,
since 𝑓(𝑛)=3𝑛, the outputs will be all integer multiples
3. of 3 (e.g., …,−6,−3,0,3,6,9,…)
Example
g : {1, 2, 3} → {a, b, c} defined by g(1) = c, g(2) = a
and g(3) = a.

The domain is the set {1, 2, 3}, the codomain is the set
{a, b, c} and the range is the set {a, c}.

Note that g(2) and g(3) are the same element of the
codomain. This is okay since each element in the
domain still has only one output.
Not Function
f : N → N defined by f (n) = n/2.

The reason this is not a function is because


not every input has an output.

Where does f send 3? The rule says that f (3)


= 3/2 , but 3/2 is not an element of the
codomain.
Not Function
Consider the rule that matches each person to their
phone number. If you think of the set of people as the
domain and the set of phone numbers as the
codomain, then this is not a function, since some
people have two phone numbers. Switching the
domain and codomain sets doesn’t help either, since
some phone numbers belong to multiple people
(assuming some households still have landlines when
you are reading this)
Example
f:Z→Z
𝑓(𝑛) = 2𝑛 + 1

Domain:
Codomain:
Rule:
Range:
Example
f: R → R defined by f(x)=2x + 3

f: R → R defined by
DESCRIBING FUNCTIONS
Function:
An abstract mathematical entity that exists independently of how
we express it.
Example: The function f(x)=x^2 exists regardless of our
methods of communication.

Description:
The various methods used to convey information about a
function.
Essential for understanding and applying functions in different
contexts.
DESCRIBING FUNCTIONS
Functions can be described in four primary ways:
Algebraically:
◦ Using a formula or equation to define the relationship
between inputs and outputs.
◦ Example: f(x) = 2x + 3
Numerically:
◦ Presenting input-output pairs in a table format.
◦ Provides a clear view of how each input maps to an
output.
DESCRIBING FUNCTIONS
Graphically:
◦ Plotting points on a coordinate plane to visualize the
function's behavior.
◦ Useful for understanding trends and relationships.
In Words:
◦ Describing the function's behavior verbally.
◦ Helps clarify the purpose and application of the
function
DESCRIBING FUNCTIONS
In discrete math, the focus is primarily on functions with:
Domain:
The set of natural numbers N or finite subsets of N.

Importance:
Allows for specific analysis and applications in combinatorics and graph theory.

All Four Descriptions:


Remain valid and can be tailored to specific mathematical contexts, enhancing
clarity and understanding.
Algebraically
One way to express this function is through a
piecewise function:

This format provides a clear mathematical expression


that shows how each input corresponds to an output.
Numerically
Provides a clear overview of the input-output pairs:

Easy to read and understand, particularly useful for


discrete sets.
Graphically
Graphing a Function:
Involves plotting points that represent the function's inputs and outputs on a
coordinate plane.
Example: For the function f : {1, 2, 3} → {1, 2, 3}
Points: (X, Y)
(1,2)
(2,1)
(3,3)
Graph Visualization:
Helps identify patterns, such as whether the function is increasing or
decreasing.
Graphically
It would be absolutely WRONG to connect the dots or try to fit
them to some curve. There are only three elements in the
domain. A curve would mean that the domain contains an entire
interval of real numbers. Here is another way to represent that
same function:

This shows that the function f sends 1 to 2, 2 to 1 and 3 to 3:


just follow the arrows.
In Words
"The function f takes an input of 1 and produces
an output of 2; when the input is 2, the output is
1; and for an input of 3, the output is 3.“

This provides an intuitive understanding of the


function's behavior, useful for explaining to
those unfamiliar with mathematical notation.
Example
Example
Example
Example
Example
Conclusion
Summary:
Functions can be described through various methods,
each providing unique insights.

Understanding These Descriptions:


Enhances comprehension and application across
mathematical disciplines.
A well-rounded understanding of functions aids in solving
real-world problems and advancing mathematical
knowledge.

You might also like

pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy