Main Content

PS Vector Norm

Compute Euclidean norm of vector or matrix physical signal

Since R2023b

  • PS Vector Norm block

Libraries:
Simscape / Foundation Library / Physical Signals / Nonlinear Operators

Description

The PS Vector Norm block computes the Euclidean norm of a vector or matrix input physical signal:

y=sqrt(dot(u,u))

where:

  • y is the physical signal at the output port O.

  • u is the physical signal at the input port I.

If the input signal is a matrix, then the block computes the column-wise vector norm.

Ports

Input

expand all

Input physical signal specified as a row or column vector or a matrix.

The port name is not visible in the block icon, but you can see this name in the underlying source file by clicking the Source code link in the Description tab of the block dialog box.

Output

expand all

Output physical signal. If the input signal is a vector, then the output signal is a scalar. If the input signal is a matrix, then the output signal is a vector or matrix representing the column-wise vector norm of the input matrix.

The port name is not visible in the block icon, but you can see this name in the underlying source file by clicking the Source code link in the Description tab of the block dialog box.

Extended Capabilities

C/C++ Code Generation
Generate C and C++ code using Simulink® Coder™.

Version History

Introduced in R2023b