  We use quantum Monte Carlo simulations to obtain zero-temperature state
diagrams for strongly correlated lattice bosons in one and two dimensions under
the influence of a harmonic confining potential. Since harmonic traps generate
a coexistence of superfluid and Mott insulating domains, we use local
quantities such as the quantum fluctuations of the density and a local
compressibility to identify the phases present in the inhomogeneous density
profiles. We emphasize the use of the "characteristic density" to produce a
state diagram that is relevant to experimental optical lattice systems,
regardless of the number of bosons or trap curvature and of the validity of the
local-density approximation. We show that the critical value of U/t at which
Mott insulating domains appear in the trap depends on the filling in the
system, and it is in general greater than the value in the homogeneous system.
Recent experimental results by Spielman et al. [Phys. Rev. Lett. 100, 120402
(2008)] are analyzed in the context of our two-dimensional state diagram, and
shown to exhibit a value for the critical point in good agreement with
simulations. We also study the effects of finite, but low (T<t/2),
temperatures. We find that in two dimensions they have little influence on our
zero-temperature results, while their effect is more pronounced in one
dimension.
