forward_sgwt: Compute Forward Spectral Graph Wavelet Transform

View source: R/forward_sgwt.R

forward_sgwtR Documentation

Compute Forward Spectral Graph Wavelet Transform


forward_sgwt computes the forward Spectral Graph Wavelet Transform (SGWT) for a given graph signal f.


  b = 2,
  filter_func = zetav,
  filter_params = list()



Numeric vector representing the graph signal to analyze.


Numeric vector of eigenvalues of the Laplacian matrix.


Matrix of eigenvectors of the Laplacian matrix.


Numeric scalar that control the number of scales in the SGWT. It must be greater than 1.


Function used to compute the filter values. By default, it uses the zetav function but other frame filters can be pass.


List of additional parameters required by filter_func. Default is an empty list.


The transform is constructed based on the frame defined by the tight_frame function, without the need for its explicit calculation. Other filters can be passed as parameters. The SGWT provides a multi-scale analysis of graph signals.

Given a graph signal f of length N, forward_sgwt computes the wavelet coefficients using SGWT.

The eigenvalues and eigenvectors of the graph Laplacian, are denoted as \Lambda and U respectively. The parameter b controls the number of scales, and \lambda_{\text{max}} is the largest eigenvalue.

For each scale j = 0, 1, \ldots, J, where

J = \left\lfloor \frac{\log(\lambda_{\text{max}})}{\log(b)} \right\rfloor + 2

the wavelet coefficients are computed as:

\mathbf{w}_j = U \left( g_j \odot (U^T f) \right)


g_j(\lambda) = \sqrt{\psi_j(\lambda)}

and \odot denotes element-wise multiplication.

The final result is a concatenated vector of these coefficients for all scales.


wc A concatenated vector of wavelet coefficients.


forward_sgwt can be adapted for other filters by passing a different filter function to the filter_func parameter.

The computation of k_{\text{max}} using \lambda_{\text{max}} and b applies primarily to the default zetav filter. It can be overridden by providing it in the filter_params list for other filters.


Göbel, F., Blanchard, G., von Luxburg, U. (2018). Construction of tight frames on graphs and application to denoising. In Handbook of Big Data Analytics (pp. 503-522). Springer, Cham.

Hammond, D. K., Vandergheynst, P., & Gribonval, R. (2011). Wavelets on graphs via spectral graph theory. Applied and Computational Harmonic Analysis, 30(2), 129-150.

de Loynes, B., Navarro, F., Olivier, B. (2021). Data-driven thresholding in denoising with Spectral Graph Wavelet Transform. Journal of Computational and Applied Mathematics, Vol. 389.

See Also

inverse_sgwt, tight_frame


## Not run: 
# Extract the adjacency matrix from the grid1 and compute the Laplacian
L <- laplacian_mat(grid1$sA)

# Compute the spectral decomposition of L
decomp <- eigensort(L)

# Create a sample graph signal
f <- rnorm(nrow(L))

# Compute the forward Spectral Graph Wavelet Transform
wc <- forward_sgwt(f, decomp$evalues, decomp$evectors)

## End(Not run)

gasper documentation built on Oct. 27, 2023, 1:07 a.m.