It's a long time since this was posted. I don't know why you didn't ask me directly. There is an oversight in exercise 2. The main term on the RHS in question 2 should be $\gcd(a_1,a_2,a_3)^{-1}J(n)\frak S$. One has to use intervals of length $1/\gcd(a_1,a_2,a_3)$.