ECG P-Wave Smoothing and Denoising by Quadratic Variation Reduction