Polynomial and trigonometric approximation