Improved modeling of excitons in type-II semiconductor heterostructures by use of a three-dimensional variational function.