Understanding Sinusoidal Neural Networks

Tiago Novello · DOI

Abstract

Sinusoidal Representation Networks (SIRENs) have revolutionized the representation of neural fields, excelling in tasks where standard ReLU networks often fail. Despite their success, the selection of network parameters has largely remained empirical. This paper provides a rigorous mathematical framework that treats sinusoidal MLPs as sophisticated harmonic expansions. By deriving a closed-form expansion using Bessel functions, the research demystifies how these networks generate frequency dictionaries and provides a principled approach to determining network width and understanding spectral bias.

Introduction

Sinusoidal MLPs, most notably SIRENs, are widely used to encode high-resolution images, 3D shapes, and radiance fields. While empirically powerful, the "black box" nature of these networks makes choosing the right width or initialization difficult. This work bridges the gap between deep learning and classical Fourier analysis, proving that sinusoidal neural networks are essentially compact harmonic sums.

Problem Statement

The research addresses three primary gaps in the understanding of SIRENs:

  1. Parameter Selection: Establishing a non-empirical method for determining the network width required to represent a signal with $K$ frequencies.
  2. Frequency Generation: Explaining how the composition of sine functions results in a comprehensive frequency dictionary.
  3. Spectral Bias: Providing a formal explanation for why these networks prioritize lower frequencies during training.

Methodology: The Harmonic Expansion

The author employs an inductive mathematical proof to derive an expansion formula for a sinusoidal neuron. The central tool in this derivation is the Bessel function of the first kind ($J_k$).

A neuron defined as $h(x) = \sin(\sum a_i \sin(\omega_i x + \phi_i) + b)$ can be expanded into a sum where the resulting frequencies are integer linear combinations of the input frequencies ($\sum k_i \omega_i$). The amplitude of each generated frequency is determined by the product of Bessel functions of the weights in the hidden layer.

Figure 1: Bessel functions of the first kind ($J_n$), which are fundamental to calculating the amplitudes of the generated harmonic components.

By utilizing the properties of Bessel functions, the author provides upper bounds on these amplitudes, allowing for the truncation of the infinite series into a manageable approximation for analysis.

Key Insights

Frequency Dictation

A critical finding is that the frequencies a network can represent are entirely determined by the weights of the first layer. Subsequent hidden layers do not create new frequencies; they instead allow the network to fine-tune the amplitudes of the frequencies established by the initial layer.

Combinatorial Efficiency

A small number of input neurons can produce a massive number of "hidden" frequencies. For a network with width $n$ and a truncation bound $B$, the system can represent up to $\frac{(2B+1)^n - 1}{2}$ non-null frequencies, explaining the remarkable compactness of SIRENs.

Spectral Bias and Gibbs Phenomenon

The expansion shows that amplitudes for high-frequency components (where the integer vector $k$ is large) decrease rapidly. This provides a formal justification for the observed spectral bias toward low frequencies. Furthermore, the paper notes that periodic sinusoidal networks can approximate discontinuous signals with fewer Gibbs phenomenon artifacts than standard Fourier series.

Results

The paper validates these theories through controlled synthetic signals:

  • Width Formula: The author proposes a lower bound for the network width $n$ required to represent $K$ frequencies: $n \approx \frac{\ln(2K + 1)}{\ln(2B + 1)}$. Experiments showed a network of width 2 could effectively represent a signal with 12 distinct frequencies.
  • Compression: The network demonstrated significant compression power, representing a complex signal using only 13 coefficients compared to the 24 parameters required by the ground truth.
  • Periodicity: A theorem is proven stating that if input neurons are periodic, the entire network maintains that periodicity, formally linking SIRENs to Fourier Series.

Conclusion

This framework transforms the understanding of sinusoidal networks from empirical "black magic" to a principled branch of harmonic analysis. While currently focused on single-hidden-layer architectures, the work paves the way for advanced pruning techniques and more efficient initialization strategies for deep neural fields.

Summary updated

BibTeX
@misc{novello2022understanding,
  author = {Tiago Novello},
  title = {{Understanding Sinusoidal Neural Networks}},
  year = {2022},
  eprint = {2212.01833},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2212.01833},
}
Figure