  The future of precision cosmology could benefit from cross-correlations
between intensity maps of unresolved neutral hydrogen (HI) and more
conventional optical galaxy surveys. A major challenge that needs to be
overcome is removing the 21cm foreground emission that contaminates the
cosmological HI signal. Using N-body simulations we simulate HI intensity maps
and optical catalogues which share the same underlying cosmology. Adding
simulated foreground contamination and using state-of-the-art reconstruction
techniques we investigate the impacts that 21cm foregrounds and other
systematics have on these cross-correlations. We find that the impact a FASTICA
21cm foreground clean has on the cross-correlations with spectroscopic optical
surveys with well-constrained redshifts is minimal. However, problems arise
when photometric surveys are considered: we find that a redshift uncertainty
{\sigma}_z {\geq} 0.04 causes significant degradation in the cross power
spectrum signal. We diagnose the main root of these problems, which relates to
arbitrary amplitude changes along the line-of-sight in the intensity maps
caused by the foreground clean and suggest solutions which should be applicable
to real data. These solutions involve a reconstruction of the line-of-sight
temperature means using the available overlapping optical data along with an
artificial extension to the HI data through redshift to address edge effects.
We then put these solutions through a further test in a mock experiment that
uses a clustering-based redshift estimation technique to constrain the
photometric redshifts of the optical sample. We find that with our suggested
reconstruction, cross-correlations can be utilized to make an accurate
prediction of the optical redshift distribution.
