A two-dimensional bounce averaged Fokker-Planck code is used to study the fusion yield and the wave absorption by residual hydrogen ions in higher harmonic ICRF heating of D (120 keV) and He-3 (80 keV) beams in the JT-60U tokamak. Both for the fourth harmonic resonance of He-3 (omega = 4omega(cHe-3)(0)), which is accompanied by the third harmonic resonance of hydrogen (omega = 3omega(cH)) at the low field side, and for the third harmonic resonance of He-3 (omega = 4omega(cD)(0) = 3omega(He-3)(0) = 2omega(cH)(0)), a few per cent of hydrogen ions are found to absorb a large fraction of the ICRF power and to degrade the fusion output power. In the latter case, D beam acceleration due to the fourth harmonic resonance in the He-3(D) regime can enhance the fusion yield more effectively. A discussion is,given of the effect of D beam acceleration due to the fifth harmonic resonance (omega = 5omega(cD)) at the high field side in the case of omega = 4omega(cHe-3)(0) and Of the optimization of the fusion yield in the case of lower electron density and higher electron temperature.