how to tell if its a function in a function for calculus in calculus you apply chain rule when you have function in a function. But i can't tell when it's true.
(x+1) -> one function
(x+1)^2 -> two functions
what defines, how come +1 didn't make it two function while square root did. 
 A: You can write $(x+1)^2$ as a composition of two functions: $f(x) = x+1$ and $g(x) = x^2$.
Edit: You don't have to all the time, $(x+1)^2 = x^2 + 2x +1$ does not require the chain rule. But there are situations where you should use it. For instance, $\sqrt{x^2+1}$.
A: As you can for x + 1: $f(x) = x +1$ and $g(x) = x$.
Techsin, you are talking about the chain rule in regards to derivatives right? Well you can use the chain rule on both of those expressions. For the first example it is more work to use the chain rule, but you can still do it. In the same spirit you do not need to use the chain rule to find the derivative of the second expression.
So use the chain rule when you think it is the easy way to solve your problem.
A: A composition of two functions
$$
x \mapsto x+1 = u, \quad\quad\quad u \mapsto u^2 = (x+1)^2.
$$
Any time the output of one function becomes the input to another, you have a composition of functions.  The chain rule is applicable when you know how to differentiate the functions that get composed.
