  The energy spectra and composition of ultra-high energy cosmic rays are
changing in a course of propagation in the expanding Universe filled with
background radiation. We developed a numerical code for solution of inverse
problem for cosmic-ray transport equations that allows the determination of
average source spectra of different nuclei from the cosmic ray spectra observed
at the Earth. Employing this approach, the injection spectra of protons and
Iron nuclei in extragalactic sources are found assuming that only these species
are accelerated at the source. The data from the Auger experiment and the
combined data from the Telescope Array + HiRes experiments are used to
illustrate the method.
