An adaptive quadratic approximation for structural and topology optimization