ma::maths::NormOp

Compute the Euclidean norm for each row. More...

Header
#include <openma/maths/unaryop.h>

Module

Public Functions#

NormOp(const XprBase< Xpr > &x)

Index
rows() const noexcept

auto
values() const noexcept-> decltype(OPENMA_MATHS_DECLVAL_NESTED(Xpr).values().square().rowwise().sum().sqrt())

auto
residuals() const noexcept-> decltype(OPENMA_MATHS_DECLVAL_NESTED(Xpr).residuals())

Detailed Description#

Member Function Documentation#

ma::maths::NormOp::NormOp ( const XprBase < Xpr > & x ) [inline]

Constructor

auto ma::maths::NormOp::residuals ( ) const noexcept [inline]

Returns the residuals associated with this operation. The residuals is generated based on the input one.

Index ma::maths::NormOp::rows ( ) const noexcept [inline]

Returns the number of rows that shall have the result of this operation. Internaly, this method relies on the number of rows of the given expresion.

auto ma::maths::NormOp::values ( ) const noexcept [inline]

Returns a template expression corresponding to the calculation of this operation.