Here is my full derivation to the book example you gave, hopefully it'll help you clear up what went wrong:
!enter image description here
You need to remember that after there is selection acting on the population, you no longer have a total of 1 after selection. Think of selection as "killing" individuals, which means the total is now 1 minus what has been "selected out". s _y is what is selected out, therefore the new total is 1-s_ y. Which means you now divide each of your frequencies by 1-s*y (see picture).
Please comment if you need more explaining.