Differentiation: Piecewise Differentiable Function

Find AA and BB for which f(x)f\left(x\right) is differentiable everywhere. Answers are in the form (A,B)\left(A,B\right)

f(x)={xex2+1, if x1Ax+B, if x<1f(x)=\begin{cases} xe^{x^2+1}, \text{ if } x\geq 1 \\ Ax+B, \text{ if } x < 1 \end{cases}
More Differentiation Laws Questions: