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

Closed form expression for modulo function?

I wonder if there is a closed form expression that returns the values of modulo function for integers $(n \mod m)$? I mean, the modulo operation is not really analytic since one chops off the number after division. But maybe there is a continuous…
Kagaratsch
  • 2,239
7
votes
1 answer

A question about showing $f(x)=0$

Let $f$ be a function from the set of real numbers to itself that satisfies $f(x + y) ≤ yf(x) + f(f(x))$ for all real numbers $x$ and $y$. Prove that $f(x) = 0$ for all $x ≤ 0$. I tried to show that $f(x)\ge 0$ and $f(x)\le 0$ for all $x\le 0$ but i…
Mathematics
  • 4,521
7
votes
4 answers

The function $(-1)^{-x}$

I was bored so I put functions in Wolfram Alpha. And I got something that looks like a sin function. And in addition to that, the real part was continuous and the imaginary part was a cos function. It might be obvious to most of you but the only…
7
votes
3 answers

Is there a bijective function $f: \mathbb{R}\to\mathbb{R}$ that is discontinuous?

Is there a bijective function that is discontinuous?
M94
  • 69
7
votes
6 answers

Is there a simpler function with this shape?

I need a function that has the shape shown below. I don't care what the function does for $x < 0$ or $x > 1$. I've experimented with a lot of different functions, configured first and second derivatives, and came up with this little monster. But I…
mhwombat
  • 310
7
votes
1 answer

Bijective functions

If $A$ has $n$ elements, how many functions are there from $A$ to $A$? How many bijective functions are there from $A$ to $A$. So for the first part of the question since A isn't bijective, doesn't that mean there are $n^n$ possibilities? So for…
kero
  • 1,814
7
votes
3 answers

Difference between a dependent variable and a function

I know that functions and dependent variables are two fundamentally different things, one "produces" results based on its input(s), and the other "represents" values. But is there any practical differences between them, since both represent a value…
seininn
  • 73
7
votes
6 answers

Why is it that $f(x)$ is even if $f(-x) = f(x)$?

I found this definition in this PDF file on page 17: http://math.byu.edu/home/sites/default/files/u107/proofs_crash_course.pdf I couldn't quite grasp it. I tried substituting x for a value in both f(x) and f(-x) but the result wasn't equal. So then,…
Anfernee
  • 243
6
votes
1 answer

Inverse function of $x+\ln(x)$

How can I find the inverse function of $$f(x)=x+\ln(x).$$ This function has an inverse function (I can prove it) but I couldn't find it. Help please!
6
votes
5 answers

How prove $f(x)$ is a monotonic function if $f(x+y)=f(x)f(y)$

Let $f(x)$ be a real valued, differentiable function such that for any $x,y \in \mathbb{R}$,$f(x+y)=f(x)f(y)$. Suppose there exist $a,b$ such that $f(a)\neq 0, f'(b)>0$. Show that $f(x)$ is a monotonic function I tried to use the Cauchy equation…
math110
  • 93,304
6
votes
1 answer

If a function has a inverse that is well defined is it a bijection

If I have a function (binary relation), $f: X \to Y:x \mapsto y$ and I show that it is well defined and I show that its inverse is well defined. Then have I shown that $f$ is a bijection? (That it is one to one, and onto) By show that it is well…
6
votes
5 answers

I need to define a family (one parameter) of monotonic curves

I want to define a function family $f_a(x)$ with a parameter $a$ in $(0,1)$, where: For any $a$, $f_a(0) = Y_0$ and $f_a(X_0) = 0$ (see image) For $a = 0.5$, this function is a straight line from $(0,Y_0)$ to $(X_0, 0)$. For $a < 0.5$, up to zero…
6
votes
3 answers

Proof that a bijection has unique two-sided inverse

For a bijection $\alpha:A\rightarrow B$ define a bijection $\beta: B\rightarrow A$ such that $\alpha \beta $ is the identity function $I:A\rightarrow A$ and $\beta\alpha $ is the identity function $I:B\rightarrow B$. Prove that $\alpha\beta$ or…
kuch nahi
  • 6,789
6
votes
1 answer

Isn't codomain of a function ambiguous?

I understand what domain and image of a function are, and believe those terms to be well-defined. I have read that range is ambiguous, so I avoid it. However for any given function the image has infinitely many supersets. It seems rather arbitrary…
6
votes
1 answer

if $f(\frac{x+y}{2})=\frac{1}{2}[f(x)+f(y)], f(0)=0,f(1)=1$ then$f(\frac{1}{22})=?$

let function $f:[0,1]\to [0,1]$,and such $f(0)=0,f(1)=1$, and foy any $0\le x\le y\le 1$,then we have $$f\left(\dfrac{x+y}{2}\right)=\dfrac{1}{2}[f(x)+f(y)]$$ Question 1 Find the value $f(\dfrac{1}{22})$ Qusetion 2: Find the…
math110
  • 93,304