Seol mar théacs é seo: Derivation of the bidomain equations for a beating heart with a general microstructure