How to train a NN model to fit a quadratic function (y = x^2)?

Polinomial fit in part one.