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
2
votes
1 answer

How to call a monotonic function that takes a value?

I'm looking for a name for a family of functions that are characterized by: $f: \mathbb{N} \rightarrow \mathbb{N}$ $f$ monotonic $\exists x \in \mathbb{N} \;.\; f(x) = 0$ (Assuming $0 \in \mathbb{N}.$)
thpani
  • 123
  • 5
2
votes
3 answers

Why is $y$ not defined as a function of $x$ in $x=4y^2$?

$$x = 4y^2$$ This equation confuses me, how is $y$ not defined as a function of $x$? I manipulated the function and it works just fine, but my book says "Explain why the given equation does not define $y$ as a function of $x$." $$\frac{x}{4} = y^2…
2
votes
1 answer

One to one function proof

Let $A$ be a nonempty set and let $f:A\rightarrow B$ be a function. Prove that $f$ is one to one if and only if there exists a function $g:B\rightarrow A$ such that $g \circ f=i_a$ ($g \circ f$ is function composition and $i_a$ is the identity…
user60887
  • 2,935
2
votes
1 answer

Expressing a cubic equation

Suppose I have a cubic equation $y=ax^3+bx^2+cx+d$, how could I express it as a Bézier curve in parametric form? That is, how could I find the 4 points $P_i$ for the parametric form $$Bézier(t)=\sum_{i=0}^3\binom{3}{i}\times (1-t)^{3-i}\times…
MathV
  • 25
2
votes
1 answer

What else can we conclude about $f$ given this information?

Consider a function $f: \mathbb{R} \mapsto \mathbb{R} $, with the following property: Consider the sequence $x, f(x), f(f(x)), f(f(f(x))), ...$. This sequences converges for all values of $x$. For completeness, this sequence is $a_0=x,…
whoisit
  • 3,069
2
votes
1 answer

Describing a third variable with two other variables, using combination of elementary functions.

I have an array of three variables as follows: $$ \begin{array}{ccccccc} X & Y & Z \\ 0 & 0 & 0 \\ 0 & 1 & 0 \\ 0 & 2 & 1 \\ 1 & 0 & 0 \\ 1 & 1 & 1 \\ 1 & 2 & 1 \\ 2 & 0 & 1 \\ 2 & 1 & 1 \\ 2 & 2 & 1 \\ \end{array} $$ I am looking…
qed
  • 1,083
2
votes
2 answers

Even or Odd symmetry

What type of symmetry does the function $y=\frac{1}{|x|}$ have? Specify the intervals over which the function is increasing and the intervals where it is decreasing.
Aly
  • 21
  • 1
  • 2
2
votes
0 answers

Injection from A to B given injection from A^2 to B^2

I wonder if given an injection $A^2 \rightarrow B^2$, there necesarrily exists an injection $A \rightarrow B$. And if there is, can you construct it canonically? If we assume the axiom of choice, then non-existence of an injection implies existence…
2
votes
2 answers

The number of real solutions of the equation $e^x=3x$

The number of real solutions of the equation $e^x=3x$ is ______. I have checked the solution in desmos.com the answer is "2". But I am not able to solve it I tried using $x=\ln(3x)$ but could not proceed further. As there any general method I could…
2
votes
1 answer

name of the maths function that gives one if two inputs are similar

What is the name of this function? ${\delta\left(y_j,c_k\right) = 1}$ if ${y_j = c_k}$, ${0}$ otherwise.?
2
votes
1 answer

Is there an isomorphism between the set of all bijective functions and the induced set-valued functions?

Given any function $f: X \to Y$ (and consider in general the set of functions with this domain and codomain), there is an induced function $f': \mathcal{P}(X) \to \mathcal{P}(Y)$ such that $f': A \mapsto f(A)$ etc. My question is about what…
EE18
  • 1,211
2
votes
5 answers

Find 1-1 and onto mapping from {0,1}* to the integers

My idea was to essentially use ordering by the length of the string (and for strings with the same length, order them is ascending order) to map a string to a number, numbers that start with a $0$ go to a negative integer and things that start with…
larry
  • 1,486
2
votes
3 answers

Can a well-defined function have a smaller codomain than range?

If I define a function with a domain such that its range is bigger than its codomain, is it necessarily ill-defined? For example, consider $f: \mathbb{R} \rightarrow \mathbb{Z}\\ f(x) = x.$ Clearly, some values of $f(x)$ are not in the codomain; can…
2
votes
1 answer

What happens to $y=\ln x$ when it is translated and then dilated?

I am struggling to understand my teacher's answer for the following question. The curve $y=\ln x$ is translated to the left by $\pi$ units and then dilated horizontally by a scale factor of 3. What is the equation that describes the new curve? I…
2
votes
1 answer

The range of a constraint for function to be surjective

Consider the following function $f(x)=\dfrac{x^2+2x+a}{x^2+4x+3a}$ Now the question states for us to find the constraint that limits $a$ so that $f(x)$ becomes surjective. My Attempt This can be further written as…