  Using Nottale's theory of scale relativity, we derive a generalized
Schr\"odinger equation applying to dark matter halos. This equation involves a
logarithmic nonlinearity associated with an effective temperature and a source
of dissipation. Fundamentally, this wave equation arises from the
nondifferentiability of the trajectories of the dark matter particles whose
origin may be due to ordinary quantum mechanics, classical ergodic (or almost
ergodic) chaos, or to the fractal nature of spacetime at the cosmic scale. The
generalized Schr\"odinger equation involves a coefficient ${\cal D}$, possibly
different from $\hbar/2m$, whose value for dark matter halos is ${\cal
D}=1.02\times 10^{23}\, {\rm m^2/s}$. We suggest that the cold dark matter
crisis may be solved by the fractal (nondifferentiable) structure of spacetime
at the cosmic scale, or by the chaotic motion of the particles on a very long
timescale, instead of ordinary quantum mechanics. The equilibrium states of the
generalized Schr\"odinger equation correspond to configurations with a
core-halo structure. The quantumlike potential generates a solitonic core that
solves the cusp problem of the classical cold dark matter model. The
logarithmic nonlinearity accounts for the presence of an isothermal halo that
leads to flat rotation curves. The damping term ensures that the system relaxes
towards an equilibrium state. This property is guaranteed by an $H$-theorem
satisfied by a Boltzmann-like free energy functional. In our approach, the
temperature and the friction arise from a single formalism. They correspond to
the real and imaginary parts of the complex friction coefficient present in the
scale covariant equation of dynamics that is at the basis of Nottale's theory
of scale relativity.
