We derive a general equation for the depletion thickness delta next to a flat wall in a solution of nonadsorbing polymer, which is easily extended to spherical geometry. This equation has the simple form delta(-2) = delta(0)(-2) + xi(-2). Here, delta(0) is the value of delta in the limit of infinite dilution, which depends only on the chain length: delta(0) = 2R/rootpi, where R is the radius of gyration of the polymer. The parameter xi is a correlation length in solution, which depends on the polymer concentration phi(b) and the solvency chi, but not on the chain length. We use a mean-field form of xi = xi(chi,phi(b)) which provides a smooth crossover from good to 0 solvency conditions. We show that the depletion thickness is actually a generalized bulk solution correlation length which does depend on chain length. In all cases the profile for a flat wall is given by rho = phi/phi(b) = tanh(2)(z/delta). The extension to a sphere of radius a is also very simple: rho(s) = [z/a + tanh(z/delta)](2)/ [z/a + 1](2). These analytical results are compared to numerical self-consistent-field computations, whereby the segment-wall repulsion in the lattice model is chosen in accordance with the boundary condition P(0) = 0 in the continuum model. The agreement is nearly perfect for good solvents and large particles. For a Theta solvent our simple analytical model overestimates delta slightly; in this case the tanh(2) profile is not strictly valid, and we derive a corrected analytical form. For smaller particles, also a slight overestimation of the width of the depletion zone is found. However, in all cases the trends are predicted very well. Our simple equations allow, in principle, analytical expressions for the surface tension, for the distribution coefficient in size-exclusion chromatography, and for interaction potentials and phase diagrams of colloids with nonadsorbing polymer.