  The aim of this paper is to investigate the spatial structure of the
impulsive phase hard X-ray emission from solar flares. This work is motivated
by the YOHKOH and the forthcoming HESSI observations. Summarizing past results,
it is shown that the transport effects can account for the observations by
inhomogeneous loops where there is a strong field convergence and/or density
enhancement at the top of the flaring loop. Scattering by plasma turbulence at
the acceleration site or pancake type pitch angle distribution of the
accelerated electrons can also give rise to enhanced emission at the loop tops.
These could be a natural consequence of acceleration by plasma waves. This
paper considers a general case of stochastic scattering and acceleration that
leads to an isotropic pitch angle distribution and an enhanced emission from
the loop tops or the acceleration site.
  Following the formalism developed in earlier papers the strength and the
spectrum of the radiation expected from the acceleration site and the foot
points are evaluated and their dependence on the parameters describing the
acceleration process and the flare plasma are determined. The theoretical ratio
of these two intensities and relative values of their spectral indices are
compared with the YOHKOH observations, demonstrating that the above mentioned
parameters can be constrained with such observations. It is shown that future
high spatial and spectral resolution observations, for example those expected
from HESSI, can begin to distinguish between different models and constrain
their parameters.
