Design and simulation of optical switches on nonlinear glass