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
3 answers

Show that if $f \circ g$ is surjective, then $f$ is surjective, and $g$, the function applied first, needs not to be.

Show that if $f \circ g$ is surjective, then $f$ is surjective, and $g$, the function applied first, needs not to be. (Note:$f \circ g=f(g(s))$, $f$ and $g$ are well defined) This statement originates from…
pxc3110
  • 1,410
3
votes
5 answers

Why surjectivity is defined by "for every $y$,there exist $x$ such that$ f(x)=y$" instead of "$x_1=x_2\Rightarrow f(x_1)=f(x_2)$"

I think injective and surjective is a dual concept. Injective: $f(x_1)=f(x_2) \Rightarrow x_1=x_2$ But the definition of surjective is so different. It's "for every $y$,there exist $x$ such that $f(x)=y$". so why we define surjective by "for every…
amateur
  • 997
3
votes
1 answer

Edges and Vertices

Three missionaries and three cannibals start on the left bank of a river. They have a rowboat with them that holds at most two people that can be used to transport people across the river (assume the rowboat can be rowed by either a missionary or a…
Adam
  • 223
3
votes
2 answers

Why maximize the reciprocal instead of minimizing the negative?

Is there some property which makes it preferable to find the maximum $1/x$ of x in a set, rather than directly finding the minimum of x in a set? The context is a homework project, where the maximizing the reciprocal is hinted at in the problem…
Rag
  • 279
3
votes
1 answer

An invariant subset problem

let $f$ be a surjective mapping on the set of positive integers $\mathbb{Z}^{+}$. My question is that does there always exist a proper subset $A$ of $\mathbb{Z}^{+}$, such that $f(A)\subset A$?
Wei Xia
  • 892
3
votes
2 answers

Showing that $f: \mathbb{R} \rightarrow (-1,1): x \mapsto \frac{x}{1+|x|}$ is surjective

I am having real difficulty to show that $f: \mathbb{R} \rightarrow (-1,1): x \mapsto \frac{x}{1+|x|}$ is a surjective function. I have trouble seeing that every $y \in (-1,1)$ can be written as $\frac{x}{1+|x|}$ for some $x$. Could anyone give me…
sxd
  • 3,504
3
votes
2 answers

How do I prove an inequality of a strict concave function?

The function $f(x)$ is strict concave, strict increasing, and $f(0) = 0$. $a, b \in \mathbf R \; and \; a < b$, how can I get that $\frac{a}{b} < \frac{f(a)}{f(b)}$? Thank you! Oh sorry I forgot to mention that $f:\mathbf R_{+} \rightarrow \mathbf…
3
votes
1 answer

Process For Building a Function?

I’m trying to write a function that grows somewhat logarithmically from an initial value to a final value. I know only roughly what the initial and final values should be and how I want the function’s shape of the graph to look, but everything I’ve…
Ceiu
  • 33
3
votes
2 answers

La fonction $f$ admet-elle une fonction réciproque?

Bonsoir j'ai un petit problème avec un exercice. On considère la function $f:[-1,1] \to [-\frac{1}{2},\frac{1}{2}]$ définie par $f(x) = \frac{x}{1+x²}$. Je dois montrer que f admet une fonction réciproque et définir cette fonction. Merci pour votre…
3
votes
1 answer

Can a function be found to fit any set of points?

Could a function be found for any set of points, assuming those points didn't contradict the definition of function? I mean, given a bunch of (x, y) pairs, could a function be found where when you input the x given in each pair, the output is the…
Peter
  • 1,021
3
votes
1 answer

associative R-algebra A, center

I would like to know why here http://en.wikipedia.org/wiki/Algebra_%28ring_theory%29 in the sentence An equivalent definition of an associative R-algebra is a ring homomorphism f:R\to A such that the image of f is contained in the center of A. im f…
user122424
  • 3,926
3
votes
4 answers

What function is this?

I'm trying to find a function. And although it seems to be very simple at first I can't figure it out. Maybe I just need some sleep, and maybe someone could help me out. given an Integer x between 0 and 100: if x is between 0-10 then f(x)=0 if x is…
3
votes
3 answers

Finding value of the function $f(x)f(y) = f(x) + f(y) + f(xy) - 2$?

So here is the question If $f(x)$ is a polynomial satisfying $$f(x)f(y) = f(x) + f(y) + f(xy) - 2$$ for all real $x$ and $y$ and $f(3) = 10$, then $f(4)$ is equal to ? here what i have tried Putting $x=y=1$ in the given solution,$$(f(1)^2) =…
Deiknymi
  • 383
3
votes
1 answer

Stuck with functions

I was doing home work but I am stuck with some questions, here is the question with subparts, Let $A=B=C=\Bbb R$, and let $f:A\to B,g:B\to C$ be defined by $f(a)=a-1$ and $g(b)=b^2$. Find $\text{(a)}\,\,\,\,(f\circ…
user2857
3
votes
4 answers

How do I find out whether a function is onto or not?

I understand that $f$ from $A$ to $B$ is called onto if for all $b$ in $B$ there is an $a$ in $A$ such that $f (a) = b$. All elements in $B$ are used. Thus, the function $f (x) = 3x - 4$ is onto where $f:\mathbb{R}\rightarrow \mathbb{R}$. Here we…
Masroor
  • 1,811