<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def get_source_dnde(self, name):
 """Return differential flux distribution of a source. For sources with FileFunction spectral type this returns the internal differential flux array. Returns ------- loge : `~numpy.ndarray` Array of energies at which the differential flux is evaluated (log10(E/MeV)). dnde : `~numpy.ndarray` Array of differential flux values (cm^{-2} s^{-1} MeV^{-1}) evaluated at energies in ``loge``. """

        name = self.roi.get_source_by_name(name).name

        if self.roi[name]['SpectrumType'] != 'FileFunction':

            src = self.components[0].like.logLike.getSource(str(name))
            spectrum = src.spectrum()
            file_function = pyLike.FileFunction_cast(spectrum)
            loge = file_function.log_energy()
            logdnde = file_function.log_dnde()

            loge = np.log10(np.exp(loge))
            dnde = np.exp(logdnde)

            return loge, dnde

        else:
            ebinsz = (self.log_energies[-1] -
                      self.log_energies[0]) / self.enumbins
            loge = utils.extend_array(self.log_energies, ebinsz, 0.5, 6.5)

            dnde = np.array([self.like[name].spectrum()(pyLike.dArg(10 ** egy))
                             for egy in loge])

            return loge, dnde