Skip to main content

norm_lp_1d

Function norm_lp_1d 

Source
pub fn norm_lp_1d(
    data: &[f64],
    n: usize,
    m: usize,
    argvals: &[f64],
    p: f64,
) -> Vec<f64>
Expand description

Compute Lp norm for each sample.

§Arguments

  • data - Column-major matrix (n x m)
  • n - Number of samples
  • m - Number of evaluation points
  • argvals - Evaluation points for integration
  • p - Order of the norm (e.g., 2.0 for L2)

§Returns

Vector of Lp norms for each sample