$g'(x)=x^3$ and tangent line to g(x) is given as $x+y=1$. Find the function $g(x)$.
My attempt: $g'(x)=x^3\rightarrow g(x)=x^4/4+K$
The tangent line will touch $g(x)$ at $y=-x$
Therefore, $x^4/4+K=-x$. However, this will give K as a function of x and not a number. Am I on the right track? Or did I miss something. Any help is much appreciated.
Assume $g(x)$ is tangent to $x+y=1$ in $(x_0,y_0)$ therefore$$g'(x_0)=-1\to x_0^3=-1\to x_0=-1 ,y_0=1-x_0=2$$therefore the point $(x_0,y_0)=(-1,2)$ is a point of $g(x)$ and by substitution we obtain:$$g(x)=\dfrac{x^4+7}{4}$$here is a sketch