dy/dx means differentiate y with respect to x
dy/du means differentiate y with respect to u
du/dx means differentiate u with respect to x
y = u2 dy/du = 2u
u = ax + 1 du/dx = a
Since dy/du = 2u and u = ax + 1 we must have dy/du = 2(ax + 1) by simply replacing u on the right hand side by ax + 1.
So dy/du*du/dx = 2(ax + 1)*a → 2a(ax + 1) or 2a2x + 2a
Notice that dy/dx = dy/du*du/dx (this is known as the chain rule) so dy/dx = 2a2x + 2a.
(See http://www.mathcentre.ac.uk/resources/uploaded/mc-ty-chain-2009-1.pdf for more information on the chain rule.)
Hope this helps!