Preparation of diarylethene copolymers and their photoinduced refractive index change