Design and simulation of a switch based on nonlinear directional coupler