Effect of a magnetic field on the thermodynamics of dilute XY quantum chains