A beam of particles with spin 1/2 are coming out of a polarizer and moving along the x-axis, the spin of the particles points in the positive y direction. A uniform magnetic field is turned on and off over a short distance compared with the wavelength of the particle beam. The field is given by Bz(x)=-Bo if -a<x<0 and Bz(x)=0 otherwise. I have to write down an expression for the wave function corresponding to stationary states, of particles with spin either parallel or antiparallel to the z-axis. What I've come up with so far is (Ae^(ikx)+Be^(-ikx)) but I'm actually quite lost in this problem. Could someone please give me a hint how to solve this problem?