Optical defect mode with tunable Q factor in a one-dimensional anisotropic photonic crystal