To make an arrest, a private person if the offense is a felony, and a public officer in all cases, may break open any door or window of the house in which the person to be arrested is, or in which they have reasonable ground for believing him to be, after having demanded admittance and explained the purpose for which admittance is desired.