The application of a method of phase-amplitude functions for the calculation of reflectograms obtained during the reflection of neutrons and X-rays from planar nanostructures is considered. Several approximations and substitutions that can be useful for different problems are described. It is shown that this method can be used to calculate reflectivity curves with lower computational expenditures than in the case of other approaches. A comparison between model numerical results for different algorithms is given. The Levenberg-Marquardt algorithm is used to solve the inverse problem and reconstruct the scattering potential of a metal film using the experimental reflection intensity. Experimental results for two systems, namely, the Al 2 O 3 //Cr(200 Å) film and the Al 2 O 3 //Cr(100 Å)/[Gd(50 Å)/Cr(11 Å)] 6 /Cr(100 Å) metal superlattice are presented. The obtained scattering potentials make it possible to draw conclusions about the layered structures of the samples and determine their dependence on the growth conditions.