The Schrödinger equation for a particle moving in a square well potential with BenDaniel–Duke
boundary conditions is solved. Using algebraic approximations for trigonometric functions, the
transcendental equations of the bound states energy are transformed into tractable, algebraic
equations. For the ground state and the first excited state, they are cubic equations; we obtain
simple formulas for their physically interesting roots. The case of higher excited states is also
analysed. Our results have direct applications in the physics of type I and type II semiconductor
heterostructures.