A compound of formula: wherein one of the two ---- bonds is a single bond and the other is a double bond; X 1 is O and X 2 is CR 2; each of Y and Z, independently, is O, S, or NR b, in which R b is H, alkyl, alkenyl, alkynyl, aryl, heteroaryl, cycloalkyl, cycloalkenyl, heterocycloalkyl, heterocycloalkenyl, cyano, or NO 2; each of R 1 and R 2, independently, is H, alkyl, alkenyl, alkynyl, aryl, heteroaryl, cycloalkyl, cycloalkenyl, heterocycloalkyl, heterocycloalkenyl, halo, cyano, nitro, OR c, OC R c, C R c, C OR c, C NR c R d, NR c R d, NHC R c, NHC NR c R d, NHC R c, NHC OR c, SO 3 R c, or SO 2 NR c R d, in which each of R c and R d, independently, is H, alkyl, alkenyl, alkynyl, aryl, heteroaryl, cycloalkyl, cycloalkenyl, heterocycloalkyl, or heterocycloalkenyl; each of R 3 and R 4, independently, is H, halo, nitro, cyano, amino, hydroxy, alkoxy, aryloxy, alkyl, alkenyl, alkynyl, cycloalkyl, cycloalkenyl, heterocycloalkyl, aryl, or heteroaryl; A is arylene or heteroarylene; B is O, S or NR e, in which R e is H, alkyl, alkenyl, or alkynyl; C is O, S, alkylene, or NR f, in which R f is H, alkyl, alkenyl, or alkynyl; or B and C, together with the carbon atom to which they are bonded, are heterocycloalkyl or heterocycloalkenyl; D is H, alkyl, alkenyl, alkynyl, aryl, heteroaryl, cycloalkyl, cycloalkenyl, heterocycloalkyl, or heterocycloalkenyl; or C and D together are heterocycloalkyl, heterocycloalkenyl, aryl or heteroaryl; and n is 1, 2, 3, or 4 wherein each of alkyl, alkenyl, alkynyl, aryl, heteroaryl, cycloalkyl, cycloalkenyl, heterocycloalkyl, and heterocycloalkenyl is optionally substituted with C 2 -C 10 alkenyl, C 2 -C 10 alkynyl, C 3 -C 20 cycloalkyl, C 3 -C 20 cycloalkenyl, C 1 -C 20 heterocycloalkyl, C 1 -C 20 heterocycloalkenyl, C 1 -C 10 alkoxy, aryl, aryloxy, heteroaryl, heteroaryloxy, amino, C 1 -C 10 alkylamino, arylamino, hydroxy, halo, oxo (O=), thioxo (S=), thio, silyl, C 1 -C 10 alkylthio, arylthio, C 1 -C 10 alkylsulfonyl, arylsulfonyl, aminothioacyl, amidino, mercapto, amido, thioureido, thiocyanato, sulfonamido, guanidine, ureido, cyano, nitro, acyl, thioacyl, acyloxy, carbamido, carbamyl, carboxyl, carboxylic ester, acylamino (RC NR'-), or aminoacyl (NRR'C -), each of R and R', independently, being H, alkyl, alkenyl, alkynyl, cycloalkyl, cycloalkenyl, heterocycloalkyl, heterocycloalkenyl, aryl, or heteroaryl; each of aryl, heteroaryl, cycloalkyl, cycloalkenyl, heterocycloalkyl, and heterocycloalkenyl is optionally substituted with C 1 -C 10 alkyl; and Cycloalkyl, cycloalkenyl, heterocycloalkyl, heterocycloalkenyl, aryl, and heteroaryl are optionally fused with each other. one of the two ---- bonds is a single bond and the other is a double bond; X 1 is O and X 2 is CR 2; each of Y and Z, independently, is O, S, or NR b, in which R b is H, alkyl, alkenyl, alkynyl, aryl, heteroaryl, cycloalkyl, cycloalkenyl, heterocycloalkyl, heterocycloalkenyl, cyano, or NO 2; each of R 1 and R 2, independently, is H, alkyl, alkenyl, alkynyl, aryl, heteroaryl, cycloalkyl, cycloalkenyl, heterocycloalkyl, heterocycloalkenyl, halo, cyano, nitro, OR c, OC R c, C R c, C OR c, C NR c R d, NR c R d, NHC R c, NHC NR c R d, NHC R c, NHC OR c, SO 3 R c, or SO 2 NR c R d, in which each of R c and R d, independently, is H, alkyl, alkenyl, alkynyl, aryl, heteroaryl, cycloalkyl, cycloalkenyl, heterocycloalkyl, or heterocycloalkenyl; each of R 3 and R 4, independently, is H, halo, nitro, cyano, amino, hydroxy, alkoxy, aryloxy, alkyl, alkenyl, alkynyl, cycloalkyl, cycloalkenyl, heterocycloalkyl, aryl, or heteroaryl; A is arylene or heteroarylene; B is O, S or NR e, in which R e is H, alkyl, alkenyl, or alkynyl; C is O, S, alkylene, or NR f, in which R f is H, alkyl, alkenyl, or alkynyl; or B and C, together with the carbon atom to which they are bonded, are heterocycloalkyl or heterocycloalkenyl; D is H, alkyl, alkenyl, alkynyl, aryl, heteroaryl, cycloalkyl, cycloalkenyl, heterocycloalkyl, or heterocycloalkenyl; or C and D together are heterocycloalkyl, heterocycloalkenyl, aryl or heteroaryl; and n is 1, 2, 3, or 4 each of alkyl, alkenyl, alkynyl, aryl, heteroaryl, cycloalkyl, cycloalkenyl, heterocycloalkyl, and heterocycloalkenyl is optionally substituted with C 2 -C 10 alkenyl, C 2 -C 10 alkynyl, C 3 -C 20 cycloalkyl, C 3 -C 20 cycloalkenyl, C 1 -C 20 heterocycloalkyl, C 1 -C 20 heterocycloalkenyl, C 1 -C 10 alkoxy, aryl, aryloxy, heteroaryl, heteroaryloxy, amino, C 1 -C 10 alkylamino, arylamino, hydroxy, halo, oxo (O=), thioxo (S=), thio, silyl, C 1 -C 10 alkylthio, arylthio, C 1 -C 10 alkylsulfonyl, arylsulfonyl, aminothioacyl, amidino, mercapto, amido, thioureido, thiocyanato, sulfonamido, guanidine, ureido, cyano, nitro, acyl, thioacyl, acyloxy, carbamido, carbamyl, carboxyl, carboxylic ester, acylamino (RC NR'-), or aminoacyl (NRR'C -), each of R and R', independently, being H, alkyl, alkenyl, alkynyl, cycloalkyl, cycloalkenyl, heterocycloalkyl, heterocycloalkenyl, aryl, or heteroaryl; each of aryl, heteroaryl, cycloalkyl, cycloalkenyl, heterocycloalkyl, and heterocycloalkenyl is optionally substituted with C 1 -C 10 alkyl; and Cycloalkyl, cycloalkenyl, heterocycloalkyl, heterocycloalkenyl, aryl, and heteroaryl are optionally fused with each other.