derivative of function I have a simple problem from calculus topics. Suppose we have
$$x=at^2,\qquad y=2at$$
and want to find $\dfrac{d^2y}{dx^2}$. There is given sample  http://www.mathopolis.com/questions/a.php?id=137&ansno=957
I think that the answer is zero  but here it is equal  D  why?
 A: You are not taking the derivative of $y$ with respect to $t$, you are taking the derivative of $y$ with respect to $x$.
Now, by the Chain Rule we have that
$$\frac{dy}{dt} = \frac{dy}{dx}\frac{dx}{dt},$$
or, equivalently (solving for $\frac{dy}{dx}$), 
$$\frac{dy}{dx} = \frac{\quad\frac{dy}{dt}\quad}{\frac{dx}{dt}}.$$
Therefore, since $\frac{dy}{dt} = \frac{d}{dt}(2at) = 2a$, and $\frac{dx}{dt} = \frac{d}{dt}(at^2) = 2at$, then
$$\frac{dy}{dx} = \frac{2a}{2at} = t^{-1}.$$
Now you can repeat: from the Chain Rule we have
$$\frac{d}{dt}\left(\frac{dy}{dx}\right) = \Biggl(\frac{d}{dx}\left(\frac{dy}{dx}\right)\Biggr)\frac{dx}{dt} = \frac{d^2y}{dx^2}\frac{dx}{dt}.$$
Solving for $\frac{d^2y}{dx^2}$, we get
$$\frac{d^2y}{dx^2} = \frac{\quad\frac{d}{dt}\left(\frac{dy}{dx}\right)\quad}{\frac{dx}{dt}};$$
since $\frac{d}{dt}\left(\frac{dy}{dx}\right) = \frac{d}{dt}(t^{-1}) = -t^{-2}$, we have:
$$\frac{d^2y}{dx^2} = \frac{-t^{-2}}{2at} = -\frac{1}{2at^3},$$
which is answer D in the given link.
A: Observe that $y^2 = 4ax$
Then $2y\frac{dy}{dx} = 4a$
So $\frac{dy}{dx} = \frac{2a}{y}$ [A]
Then $\frac{\mathrm d^2 y}{\mathrm dx^2} = \frac{-2a}{y^2} \frac{dy}{dx} =$ (using [A]) $-\frac{4a^2}{y^3} = -\frac{4a^2}{8a^3t^3} = -\frac{1}{2at^3}$
A: A slightly different approach not using the chain rule explicitly:
From $x=at^2$ you have $$t=a^{-1/2}x^{1/2}$$ so with $y=2at$ you have $$y =2 a^{1/2}x^{1/2}$$ so taking the derivative with respect to $x$ $$\frac{\mathrm dy}{\mathrm dx}=a^{1/2}x^{-1/2}$$ and doing it again and reusing $x=at^2$  $$\frac{\mathrm d^2 y}{\mathrm dx^2}=-\frac{1}{2} a^{1/2}x^{-3/2}=-\frac{1}{2a t^3}.  $$  
A: Here, you use the fact that
$$\frac{\mathrm dy}{\mathrm dx}=\frac{\frac{\mathrm dy}{\mathrm dt}}{\frac{\mathrm dx}{\mathrm dt}}$$
Since you're doing second derivatives, you need a further differentiation:
$$\frac{\mathrm d^2 y}{\mathrm dx^2}=\left(\frac{\mathrm dx}{\mathrm dt}\right)^{-1}\frac{\mathrm d}{\mathrm dt}\frac{\frac{\mathrm dy}{\mathrm dt}}{\frac{\mathrm dx}{\mathrm dt}}$$
and this is the formula you should be using (replace $x$ and $y$ with the appropriate expressions).
A: I'm not sure what else to add to the explanation provided in your link. I think the key to understanding this question is the statement
$$\frac{dy}{dx}=\frac{\quad\tfrac{dy}{dt}\quad}{\tfrac{dx}{dt}},$$
which follows from the chain rule:
$$\frac{dy}{dt}=\frac{dy}{dx}\cdot\frac{dx}{dt}.$$
Do you understand why this is true?
A: In general, if one has the parametric equations
$$
x=f(t),\quad y=g(t)\tag{1}
$$
one can$\dagger$ write $\frac{dy}{dx}$  in terms of $t$ by
$$
\frac{dy}{dx}=\frac{g'(t)}{f'(t)}\tag{2}=:h(t)\;.
$$
Now, to write $\frac{d^2y}{dx^2}$ in terms of $t$, one simply observes that $\frac{d^2y}{dx^2}=\frac{d}{dx}(\frac{dy}{dx})$ and replaces (1) by
$$
x=f(t),\quad \frac{dy}{dx}=h(t)\tag{3}
$$
to get
$$
\frac{d}{dx}\left(\frac{dy}{dx}\right)=\frac{h'(t)}{f'(t)}\tag{4}
$$
The calculation is of course essentially the same as in Arturo's answer.
Sometimes, people use Newton's notation for derivatives in (2) and write
$$
\frac{dy}{dx}=\frac{\dot{y}}{\dot{x}}\quad
\frac{d^2y}{dx^2} = \frac{d}{dt}\left(\frac{\dot{y}}{\dot{x}}\right)\frac{1}{\dot{x}} = \frac{\dot{x} \ddot{y}-\dot{y} \ddot{x}}{\dot{x}^{3}}
$$
This is related to the notion of curvature.

$\dagger$ Assume that $f$ and $g$ are both smooth.

So if $f(t)=at^2$ and $g(t)=2at$, combining (2) and (4) together, one has
$$
h(t) = \frac{2a}{2at}
=\frac1t,\quad \frac{h'(t)}{f'(t)}
=-\frac{1}{t^2}\cdot\frac{1}{2at}=-\frac{1}{2at^3}\;.
$$
