Questions tagged [functions]

For elementary questions about functions, notation, properties, and operations such as function composition. Consider also using the (graphing-functions) tag.

A function $f$ defined on a set $X$ is an assignment of an element in some set $Y$ to each element of $X$. The set $X$ is called the domain of the function and $Y$ is called the codomain. The elements of $X$ are the inputs to the function and the elements of $Y$ are the potential outputs. For some input $x \in X$, its corresponding output in $Y$ is denoted $f(x)$. Not every element of $Y$ needs to be the output corresponding to some input though: the subset of $Y$ containing the elements that are an output of the function is called the range of $f$. When a function $f$ has domain $X$ and codomain $Y$, this is signified by writing $f \colon X \to Y$, and the assignments of inputs to outputs is signified by writing $f\colon x \mapsto f(x)$.

If you have a function whose codomain is the domain of another function, you can compose those two functions. In symbols if you have a function $f\colon X \to Y$ and a function $g \colon Y \to Z$, their composite is a function $g\circ f\colon X\to Z$ defined by the assignment $g\circ f\colon x \mapsto g(f(x))$.

For many examples of functions, the domain and range of the function are topological spaces, meaning that they are equipped with some notion of geometry. In this case we like to think of the function $f\colon X\to Y$ geometrically as the subset of the points $(x,f(x))$ in the topological space $X \times Y$. This subset of all the input-output pairs is called the graph of $f$.

Often mathematics textbooks will define a function slightly more rigorously than this though. They'll say that a function $f \colon X \to Y$ is a relation $R$ on the set $X \times Y$ such that

  1. For each $x \in X$ there is some $y \in Y$ such that $xRy$. Each input needs an output.
  2. If $xRy$ and $xRz$, then $y=z$. Each input needs exactly one output.

Here are a bunch of examples of functions:

  • Many examples of functions covered in elementary and high school have as their domain and codomain the real numbers $\mathbf{R}$. A basic example is the function $f \colon \mathbf{R} \to \mathbf{R}$ defined by the rule $f(x) = x^2$. Thinking geometrically, the graph of $f$ is the set of all points $(x,x^2)$ in the plane $\mathbf{R}^2$, and this forms a parabola. Note that while the codomain of this function is $\mathbf{R}$, the range consists of only the non-negative real numbers.

  • Here's a silly example. For any set $X$ we can define an identity function $\mathbf{1}_X$ with domain and codomain $X$ such that $\mathbf{1}_X \colon x \mapsto x$.

  • Let $W$ denote the set of all strings of letters of the alphabet, so like $\text{npr}$ or $\text{asdfasdf}$ or $\text{butt}$ for example. And let $\mathbf{N}$ denote the set of natural numbers. We can define a function $\ell\colon W \to \mathbf{N}$ such that $\ell$ assigns to each word it's length. So $\ell(\text{defenestration}) = 14$. Also $\ell(\text{butt})=4$.

  • Using the same set $W$ in the last example, let's define another function $\tau\colon W \to W$ such that $\tau$ "reverses" a word. So $\tau(\text{defenestration}) = \text{noitartsenefed}$, and $\tau(\text{butt}) = \text{ttub}$. A few neat properties of $\tau$ that deserve to be pointed out, $\tau \circ \tau = \mathbf{1}_W$, and also $\ell\circ\tau = \ell$.

33723 questions
3
votes
2 answers

Logarithm of a Convex Function

Consider a strictly increasing convex function $f(x)$ defined on the interval $[0,1)$ such that $f(0)=1$ and $\lim_{x\to 1^{-}}{f(x)}=+\infty$. My question: Is the function $f(x)$ logarithmically convex (also called super-convex) in the interval…
ght
  • 729
3
votes
5 answers

Is there a bijective function which maps an integer vector onto a single number?

I am looking for a function that maps an integer vector onto a single number. Actually it is a algorithmic problem I am having. But there must be such functions around, especially when thinking of cryptography.
steffi
  • 151
3
votes
2 answers

Proving a noninvertible function is onto?

How do I prove that $f:\mathbb R\longrightarrow\mathbb R, \;f(x) = x^3 - 3x$ is onto? Is it always necessary to find an inverse function? I guess there is some way to restrict such a function's domain so it's outside the overlapping parts $x <…
Matt Gregory
  • 2,027
2
votes
1 answer

An Injective binary function

So I work with theoretical chemistry and time and again we end up walking into what is, for us, uncharted mathematical territories in our search for the patterns and symmetries of nature and its atomic arrays (crystals, molecules and…
urquiza
  • 887
2
votes
2 answers

Inverse of a function - $f^-(x)$ in a restricted domain

I have a function $f(x) = y = x^2(3-2x)$, $0\le x\le 1$, I would like to find the inverse of this function on this restricted domain. ,This seems to be the answer for one of the problems that I have been scratching my head for a day. I used online…
2
votes
6 answers

In f:A→B, surely A and B are redundant

If a function is a set of ordered pairs, it defines its own proper domain and codomain. f determines A; a minimal B. If we extend B, do we have a different function?
Thumbnail
  • 563
2
votes
1 answer

What are the advantages of using f(x) instead of y=x.

Yeah, It's a pretty simple question. The only thing I know is that it is far more convenient and clear as to what is being inputted. ex. F(x)=x+3 F(2)=5 the input was 2, output was 5. Are there any other advantages or is that all?
2
votes
2 answers

Solving this functional equation

Find all functions $f(x)$ for $x\in \mathbb{R},$ such that $f(1+x) = f(1-x)$ and $f(2+x) = f(2-x)$. A little bit of arrangement in the first equality will give $f(x) = f(2-x)$. $\implies f(x) = f(x+2)$. This is a function with periodicity…
2
votes
2 answers

Function which graph looks looks like the plane

Does there exist a function which is surjective from $[a,b]\to\mathbb R$ for any $a,b\in\mathbb R$ such that $a\ne b$? Of course such a function would have a graph which looks like the plane. I can see that it is, of course, not continuous. Do you…
Alice Ryhl
  • 7,853
2
votes
1 answer

Basic set notation - Concept Clarification

Why is the set notation {3,6} ∈ Z false ? Is it because {3,6} represents a set but not two individual element?
Sam
  • 21
2
votes
1 answer

right/left inverse mappings

Need some hints to solve Ex6a from V. Zorich course of Analysis vol.1 chap.1 §3. If mappings $f:X\to Y$ and $g:Y\to X$ are such that $g \circ f=id_X$ where $id_X$ - identity map X, then $g$ is called left inverse for $f$ and $f$ is called right…
Arteom.k
  • 187
2
votes
2 answers

Given $f:[0,1]\to[0,1]$ and $q:[0,1]\to\mathbb{R}$, is there a $g$ such that $q(f(x))\equiv g(q(x))$?

Let $f$ is a bijection and $q$ a given function, is there some function $g:\mathbb{R}\to\mathbb{R}$? It is no need to be continuous or differentiable function. $\matrix{ [0,1] & \to^{f} & [0,1] \\ q\downarrow & & q\downarrow \\ \mathbb{R} &…
melomm
  • 444
  • 2
  • 11
2
votes
1 answer

Is $f(x) = \infty$ a function?

Recently, while solving a problem where a certain set of functions $f:\mathbb Z^+ \rightarrow \mathbb Z^+$ had to be found given a number of conditions, I noticed that $f(n)=\lim_{a\to+\infty} a$, where $n\in \mathbb Z^+$, was a solution. My…
TheR
  • 142
2
votes
4 answers

proving that if $f(x)$ odd then $f(0)=0$

Need to prove that if $f(x)$ is an odd function that defined in the point: $x=0$, So $f(0)=0$. I know that odd function is: $f(-x)=-f(x)$ And that $f(x)=0$ is an odd function but dont know how to prove. Thanks.
dave
  • 135
2
votes
1 answer

show a cartesian product in function is injective or surjective?

I had previously figured out injectivity/surjectivity on basic functions but I am stumpted when it comes to showing functions which are cartesian products are injective/surjective. The first one: $$f: \Bbb{Z} \to \Bbb{Z}\times\Bbb{Z},$$ where…
jn025
  • 989