What happens when the source of the waves moves toward you, a stationary observer? Again, you encounter more waves per unit time than you did before so the frequency is shifted up. This time, though, the shift occurs because the wavelength has been lowered by the movement of the source.
When nothing moves the wavelength is equal to vT, where T is the period, or v/f, because T = 1/f. When the source moves at speed vs, the wavelength is different by the distance traveled by the source in one period:
Change in wavelength = vsT = vs/f
The effective wavelength is λ / = v/f -/+ vs/f = [v -/+ vs]/f
Use the first sign (-) when the source moves toward the observer, and the second sign (+) when it moves away.
The detected frequency is:
f/ = v/λ / = f v/[v -/+ vs ]