Find a function so that the composition is continuous

Click For Summary
SUMMARY

The function defined as $$f(x)=\begin{cases}1+x^2 & \text{ for } x\leq 1, \\ ax-x^3 & \text{ for } 12\end{cases}$$ is continuous on $\mathbb{R}$ when $a=3$, $b=-2$, and $c=-\frac{1}{2}$. The continuity must be checked at points $x=1$ and $x=2$, leading to the conditions $a-1=2$ and $-2=4c=b$. Additionally, for the composition of functions $f \circ g$ or $g \circ f$ to be continuous, $g$ must not cross the discontinuities of $f$, specifically at $x=1$ and $x=2$.

PREREQUISITES
  • Understanding of piecewise functions
  • Knowledge of limits and continuity in real analysis
  • Familiarity with function composition
  • Basic algebraic manipulation of equations
NEXT STEPS
  • Study the properties of piecewise functions in calculus
  • Learn about the epsilon-delta definition of continuity
  • Explore the concept of function composition and its implications for continuity
  • Investigate examples of continuous and discontinuous functions
USEFUL FOR

Mathematicians, students studying real analysis, and anyone interested in understanding continuity in piecewise functions and function composition.

mathmari
Gold Member
MHB
Messages
4,984
Reaction score
7
Hey! :o

For which real constants $a,b,c$ is the following function $f$ continuous on $\mathbb{R}$ ?
$$f(x)=\begin{cases}1+x^2 & \text{ for } x\leq 1, \\ ax-x^3 & \text{ for } 1<x< 2 \\ b & \text{ for } x=2\\ cx^2 & \text{ for } x>2\end{cases}$$
For $a=1, b=-6, c=-\frac{3}{2}$ the function $f$ is discontinuous at $x_0=1$. Are there continuous functions $g:\mathbb{R}\rightarrow \mathbb{R}$, such that $f\circ g$ or $g\circ f$ is continuous on whole $\mathbb{R}$ ?

We have to check the continuity at the points $x=1$ and $x=2$.

We consider the point $x=1$:

We have that $\lim_{x\rightarrow 1^-}f(x)=\lim_{x\rightarrow 1^-}(1+x^2)=2$, $\lim_{x\rightarrow 1^+}f(x)=\lim_{x\rightarrow 1^+}(ax-x^3)=a-1$ and $f(1)=1+1^2=2$.

So that the function is continuous at $x=1$ it must hold $a-1=2\Rightarrow a=3$.

We consider the point $x=2$:

We have that $\lim_{x\rightarrow 2^-}f(x)\overset{ a=3 }{ = } \lim_{x\rightarrow 2^-}(3x-x^3)=6-8=-2$, $\lim_{x\rightarrow 2^+}f(x)=\lim_{x\rightarrow 2^+}(cx^2)=4c$ and $f(2)=b$.

So that the function is continuous at $x=2$ it must hold $-2=4c=b$. So we get $b=-2$ and $c=-\frac{1}{2}$.

Is everything correct?

For $a=1, b=-6, c=-\frac{3}{2}$ we get the function $$f(x)=\begin{cases}1+x^2 & \text{ for } x\leq 1, \\ x-x^3 & \text{ for } 1<x< 2 \\ -6 & \text{ for } x=2\\ -\frac{3}{2}x^2 & \text{ for } x>2\end{cases}$$

How can we find (or check if there exist) continuous functions $g$ such that $f\circ g$ or $g\circ f$ is continuous on whole $\mathbb{R}$ ?
 
Physics news on Phys.org
mathmari said:
Is everything correct?

Hey mathmari! (Smile)

Yep. (Nod)

mathmari said:
For $a=1, b=-6, c=-\frac{3}{2}$ we get the function $$f(x)=\begin{cases}1+x^2 & \text{ for } x\leq 1, \\ x-x^3 & \text{ for } 1<x< 2 \\ -6 & \text{ for } x=2\\ -\frac{3}{2}x^2 & \text{ for } x>2\end{cases}$$

How can we find (or check if there exist) continuous functions $g$ such that $f\circ g$ or $g\circ f$ is continuous on whole $\mathbb{R}$ ?

What do we get if we apply the definition of continuity to $g\circ f$ for some unknown function $g$? (Wondering)
 
I like Serena said:
What do we get if we apply the definition of continuity to $g\circ f$ for some unknown function $g$? (Wondering)

Let $a$ be an arbitrary point.

We want that $f(g(x))$ is continuous at each $a$, so $f$ is continuous at each $g(a)$.

We know that $g$ is a continuos function. So it will be continuous at each $a$.
That means that for all $\epsilon>0$ there is some $\delta>0$ such that $$|x-a|<\delta \Rightarrow|g(x)-g(a)|<\epsilon$$

Since $f$ is continuous at $g(a)$ we have that for all $\tilde{\epsilon} > 0$ there is some $\tilde{\delta}$ such that $$|g(x) - g(a)| < \tilde{\delta} \Rightarrow |f(g(x))-f(g(a))|<\tilde{\epsilon}$$

For $\epsilon=\tilde{\delta}$ we have the following:

For all $\epsilon > 0$ there is some $\delta > 0$ and a $\tilde{\delta}> 0$ such that $$|x-a| < \delta\Rightarrow |g(x)-g(a)|<\tilde{\delta}\Rightarrow |f(g(x)) - f(g(a))|<\epsilon$$
right? (Wondering)
 
mathmari said:
Let $a$ be an arbitrary point.

We want that $f(g(x))$ is continuous at each $a$, so $f$ is continuous at each $g(a)$.

We know that $g$ is a continuos function. So it will be continuous at each $a$.
That means that for all $\epsilon>0$ there is some $\delta>0$ such that $$|x-a|<\delta \Rightarrow|g(x)-g(a)|<\epsilon$$

Since $f$ is continuous at $g(a)$ we have that for all $\tilde{\epsilon} > 0$ there is some $\tilde{\delta}$ such that $$|g(x) - g(a)| < \tilde{\delta} \Rightarrow |f(g(x))-f(g(a))|<\tilde{\epsilon}$$

For $\epsilon=\tilde{\delta}$ we have the following:

For all $\epsilon > 0$ there is some $\delta > 0$ and a $\tilde{\delta}> 0$ such that $$|x-a| < \delta\Rightarrow |g(x)-g(a)|<\tilde{\delta}\Rightarrow |f(g(x)) - f(g(a))|<\epsilon$$
right? (Wondering)

Let's not jump to $\epsilon$-$\delta$ definitions of limits. (Worried)What we need for continuity of $g\circ f$ is that $\lim_{x\to x_0} g(f(x)) = g(f(x_0))$.
More specifically in our case that means that:
$$\lim_{x\to 1^+} g(f(x)) = \lim_{x\to 1^-} g(f(x)) = g(f(1))$$
What do we require from $g$ for that to be true? (Wondering)
 
I like Serena said:
What we need for continuity of $g\circ f$ is that $\lim_{x\to x_0} g(f(x)) = g(f(x_0))$.
More specifically in our case that means that:
$$\lim_{x\to 1^+} g(f(x)) = \lim_{x\to 1^-} g(f(x)) = g(f(1))$$
What do we require from $g$ for that to be true? (Wondering)

$g$ has to continuous at $f(1)=2$, right? (Wondering)
 
mathmari said:
$g$ has to continuous at $f(1)=2$, right? (Wondering)

Not quite, since f is not continuous at 1. (Thinking)
 
I like Serena said:
Not quite, since f is not continuous at 1. (Thinking)

Do we maybe take as $g$ a constant function? Then we would have that $g(x)=C$ and $g(f(x))=C$, which is continuous everywhere? (Wondering)
 
mathmari said:
Do we maybe take as $g$ a constant function? Then we would have that $g(x)=C$ and $g(f(x))=C$, which is continuous everywhere? (Wondering)

But $f$ is not continuous is it?
So if $g$ is a constant function, $g\circ f$ won't be continuous either would it?

Suppose we substitute the relevant parts of $f$ into the limit expression... (Thinking)
 
I like Serena said:
Suppose we substitute the relevant parts of $f$ into the limit expression... (Thinking)

Do you mean the following?

$$\lim_{x\to 1^+} g(f(x)) =\lim_{x\to 1^+} g(x-x^3) \\ \lim_{x\to 1^-} g(f(x)) = \lim_{x\to 1^-} g(1+x^2) $$

So, it must hold that $$\lim_{x\to 1^+} g(x-x^3)= \lim_{x\to 1^-} g(1+x^2)$$ right? (Wondering)
 
Last edited by a moderator:
  • #10
Indeed. And since g is continuous, we can evaluate those limits, can't we? (Wondering)
 
  • #11
I like Serena said:
Indeed. And since g is continuous, we can evaluate those limits, can't we? (Wondering)

Ah yes. So, we get $$\lim_{x\to 1^+} g(x-x^3)= \lim_{x\to 1^-} g(1+x^2)\Rightarrow g\left (\lim_{x\to 1^+}(x-x^3)\right )= g\left (\lim_{x\to 1^-} (1+x^2)\right )\Rightarrow g(0 )= g(2)$$ right?

Such a function is for example $g(x)=x\cdot (x-2)$, isn't it?

(Wondering)
 
  • #12
mathmari said:
Ah yes. So, we get $$\lim_{x\to 1^+} g(x-x^3)= \lim_{x\to 1^-} g(1+x^2)\Rightarrow g\left (\lim_{x\to 1^+}(x-x^3)\right )= g\left (\lim_{x\to 1^-} (1+x^2)\right )\Rightarrow g(0 )= g(2)$$ right?

Such a function is for example $g(x)=x\cdot (x-2)$, isn't it?

Yep.

And I'm just realizing that I was wrong before. If $g$ is a constant function, $g\circ f$ will also be a constant function and therefore continuous. (Blush)
 
  • #13
I like Serena said:
Yep.

And I'm just realizing that I was wrong before. If $g$ is a constant function, $g\circ f$ will also be a constant function and therefore continuous. (Blush)

Ah ok!

If $g$ is a constant, $g(x)=C$. then we have that $g(f(x))=C$ and a constant function is everywhere continuous, right?

Is it possible that $f\circ g$ is continuous for some function $g$ ?

Can we take here also a constanst function? When $g(x)=C$ then we have that $f\circ g(x)=f(g(x))=f(C)$, which is also constant, right?

(Wondering)
 
  • #14
Yep.
 
  • #15
But can $C$ be also $1$ ?

Then we would have $f\circ g(x)=f(g(x))=f(1)=2$, or isn't $f(1)=2$ ? (Wondering)
 
  • #16
Sure. That's all correct. (Nod)
 
  • #17
mathmari said:
Do you mean the following?

$$\lim_{x\to 1^+} g(f(x)) =\lim_{x\to 1^+} g(x-x^3) \\ \lim_{x\to 1^-} g(f(x)) = \lim_{x\to 1^-} g(1+x^2) $$

So, it must hold that $$\lim_{x\to 1^+} g(x-x^3)= \lim_{x\to 1^-} g(1+x^2)$$ right? (Wondering)

mathmari said:
Ah yes. So, we get $$\lim_{x\to 1^+} g(x-x^3)= \lim_{x\to 1^-} g(1+x^2)\Rightarrow g\left (\lim_{x\to 1^+}(x-x^3)\right )= g\left (\lim_{x\to 1^-} (1+x^2)\right )\Rightarrow g(0 )= g(2)$$ right?

Such a function is for example $g(x)=x\cdot (x-2)$, isn't it?

(Wondering)

Could we do that also for $f\circ g$ ?

$$\lim_{x\to 1^+} f(g(x)) =\lim_{x\to 1^+} (g(x)-g^3(x))=g(1)-g^3(1) \\ \lim_{x\to 1^-} g(f(x)) = \lim_{x\to 1^-} (1+g^2(x))=1+g^2(1)$$

So we have to find a function $g$ such that $g(1)-g^3(1)=1+g^2(1)$.

Which function could that be? (Wondering)
 
  • #18
mathmari said:
Could we do that also for $f\circ g$ ?

$$\lim_{x\to 1^+} f(g(x)) =\lim_{x\to 1^+} (g(x)-g^3(x))=g(1)-g^3(1) \\ \lim_{x\to 1^-} g(f(x)) = \lim_{x\to 1^-} (1+g^2(x))=1+g^2(1)$$

So we have to find a function $g$ such that $g(1)-g^3(1)=1+g^2(1)$.

Which function could that be? (Wondering)

I'm afraid that for $f\circ g$ it's a little more complicated.
In this case it's not $x$ that has to approach $1^+$, but $g(x)$. (Worried)

Suppose that there is some $x_0$ such that $g(x_0)=1$ and $g$ is increasing in $x_0$.

Then
$$\lim_{{x\to x_0}^+} f(g(x)) = \lim_{y\to 1^+} f(y) =\lim_{y\to 1^+} (y-y^3)=0 \\
\lim_{{x\to x_0}^-} f(g(x)) = \lim_{y\to 1^-} f(y) =\lim_{y\to 1^-} (1+y^2)=2
$$
That meanst that $f\circ g$ would not be continuous in $x_0$ then.

So $g$ can't have a function value of $1$ where $g$ is monotone as well.
However, $g$ might still have a function value of $1$ if it is a (global) extreme. (Thinking)
 
  • #19
I like Serena said:
I'm afraid that for $f\circ g$ it's a little more complicated.
In this case it's not $x$ that has to approach $1^+$, but $g(x)$. (Worried)

Suppose that there is some $x_0$ such that $g(x_0)=1$ and $g$ is increasing in $x_0$.

Then
$$\lim_{{x\to x_0}^+} f(g(x)) = \lim_{y\to 1^+} f(y) =\lim_{y\to 1^+} (y-y^3)=0 \\
\lim_{{x\to x_0}^-} f(g(x)) = \lim_{y\to 1^-} f(y) =\lim_{y\to 1^+} (1+y^2)=2
$$
That meanst that $f\circ g$ would not be continuous in $x_0$ then.
So, is $f\circ g$ continuous only when $g$ is a constant function? (Wondering)
 
  • #20
mathmari said:
So, is $f\circ g$ continuous only when $g$ is a constant function?

$f$ has jump discontinuities in $1$ and $2$.
That means that $g$ cannot 'cross' those values.
But for instance $g(x)= 3 + x^2$ will work.
And $g(x)= 2 + x^2$ will also work since $\lim_{x\to 2^+} f(x) = f(2)$. (Thinking)
 
  • #21
I like Serena said:
$f$ has jump discontinuities in $1$ and $2$.
That means that $g$ cannot 'cross' those values.
But for instance $g(x)= 3 + x^2$ will work.
And $g(x)= 2 + x^2$ will also work since $\lim_{x\to 2^+} f(x) = f(2)$. (Thinking)

Ah I see! Thank you so much! (Yes)
 

Similar threads

  • · Replies 8 ·
Replies
8
Views
2K
  • · Replies 4 ·
Replies
4
Views
3K
  • · Replies 5 ·
Replies
5
Views
1K
  • · Replies 21 ·
Replies
21
Views
3K
  • · Replies 38 ·
2
Replies
38
Views
5K
  • · Replies 23 ·
Replies
23
Views
3K
  • · Replies 1 ·
Replies
1
Views
2K
  • · Replies 0 ·
Replies
0
Views
2K
  • · Replies 2 ·
Replies
2
Views
2K
Replies
4
Views
2K