Consider the following equations:
$$R=\frac{dU}{dx} +5U\tag{1}$$ $$U=f(x) \tag{2}$$
Which of the following statements is the correct way of calculating the total derivative of R?
$$R=R(U(x),x) \rightarrow \frac{dR}{dx}=\frac{\partial R}{\partial U}\frac{d U}{d x}+\frac{\partial R}{\partial x}\tag{a}$$
$$R=R(U(x)) \rightarrow \frac{dR}{dx}=\frac{d R}{d U}\frac{d U}{d x}\tag{b}$$
And is there a way to calculate $\frac{\partial R}{\partial U}$ or $\frac{d R}{d U}$ implicitly without substituting equation 2 into equation 1?