# Science:Math Exam Resources/Courses/MATH110/December 2015/Question 03 (a)/Solution 1

Recall that exponential functions and polynomials are continuous on the whole real line,. Therefore, it is enough to consider the continuity of function ${\displaystyle f}$ at ${\displaystyle x=0}$ and ${\displaystyle x=1}$.

Using

${\displaystyle \lim _{x\to 0-}f(x)=\lim _{x\to 0-}e^{x}=e^{0}=1=f(0)}$ and

${\displaystyle \lim _{x\to 0+}f(x)=\lim _{x\to 0+}ax+b=b}$,

to have the continuity at ${\displaystyle x=0}$, we need ${\displaystyle b=1}$.

On the other hand, we have

${\displaystyle \lim _{x\to 1-}f(x)=\lim _{x\to 1-}ax+b=a+b=a+1}$ and

${\displaystyle \lim _{x\to 1+}f(x)=\lim _{x\to 1+}-x^{2}+x=-(1^{2})+1=0=f(1)}$.

This implies that ${\displaystyle f}$ is continuous at ${\displaystyle x=1}$ when ${\displaystyle a+1=0}$. i.e., ${\displaystyle a=-1}$.

To sum, the answers are ${\displaystyle \color {blue}a=-1,b=1}$.