Function opensn::LpNorm

Function Documentation

double opensn::LpNorm(const std::vector<double> &x, const double &p)

Return the p-norm: \(\|\mathbf{x}\|_{p}=\left(\sum_{i=1}^{n}\left|x_{i}\right|^{p}\right)^{1/p}\).