# Goertzel algorithm magnitude

I'm reading a Goertzel algorithm paper and an embedded article. I have several questions:

1. I don't understand why the the magnitude is calculated as follows:

$$\text{Magnitude} = y^2[n-2] + y^2[n-1] - a * y[n-2]y[n-1]$$ where $a$ is some coefficient. Can someone elaborate on why this is the expression?

1. Minimum block size If I have a sampling rate of 4000 Hz and target frequency of 50 Hz, what is the minimum block size?

2. If block size more that magnitude will more accurate right?

-
What are you not understanding? The first link shows a step-by-step derivation of the equation you're asking about. –  Jason R Sep 28 '12 at 14:39
How the step from Output and Input become to magnitude? –  mem mo Sep 28 '12 at 16:14
Great article here: asp.eurasipjournals.com/content/2012/1/56 –  P i Mar 15 '14 at 19:29