  Supernova remnants are likely to be the accelerators of the galactic cosmic
rays. Assuming the correctness of this hypothesis, we develop a method to
extract the parent cosmic ray spectrum from the VHE gamma ray flux emitted by
supernova remnants (and other gamma transparent sources). Namely, we calculate
semi-analytically the (inverse) operator which relates an arbitrary gamma ray
flux to the parent cosmic ray spectrum, without relying on any theoretical
assumption about the shape of the cosmic ray and/or photon spectrum. We
illustrate the use of this technique by applying it to the young SNR RX
J1713.7-3946 which has been observed by H.E.S.S. experiment during the last
three years. Specific implementations of the method permit to use as an input
either the parameterized VHE gamma ray flux or directly the raw data. The
possibility to detect features in the cosmic rays spectrum and the error in the
determination of the parent cosmic ray spectrum are also discussed.
