-  3.39.23
Public Member Functions | List of all members
matfaust::proj::normlin Class Reference

Functor for the NORMLIN projector. More...

Public Member Functions

function normlin (shape, varargin)
 
- Public Member Functions inherited from matfaust::proj::proj_gen
function subsref (self, S)
 

Additional Inherited Members

- Protected Attributes inherited from matfaust::proj::proj_gen
Property constraint
 

Detailed Description

Functor for the NORMLIN projector.

A, the image matrix, is defined by \( \forall i \in \{1,\ldots,shape(1)\} \) the i-th row \( A_{i,*} \) is such that \( \| A_{i, *} \|_2 = s \).

Example

>> rng(42)
>> M = rand(5, 5)
M =
0.3745 0.1560 0.0206 0.1834 0.6119
0.9507 0.0581 0.9699 0.3042 0.1395
0.7320 0.8662 0.8324 0.5248 0.2921
0.5987 0.6011 0.2123 0.4319 0.3664
0.1560 0.7081 0.1818 0.2912 0.4561
>> p = normlin(size(M), .01);
>> pM = p(M);
>> norm(pM(1,:), 2) % doctest: +ELLIPSIS
ans =
1%>
>>

Constructor & Destructor Documentation

◆ normlin()

function matfaust::proj::normlin::normlin ( shape  ,
varargin   
)

Usage

    normlin(shape, s): returns a NORMLIN projector (functor), shape defines the size of the input matrix (e.g. [1, 10]), s defines the sparsity of the output matrix (the 2-norm of each row).

Parameters
shapevector of size 2, to define the size of the input matrix.
's',value(optional) the sparsity parameter, the 2-norm of the row (1 by default).
Return values
normlinprojector

The documentation for this class was generated from the following file:
matfaust::proj
This module provides matrix projectors.
Definition: +proj/@anticirc/anticirc.m:1
pyfaust.norm
def norm(F, ord='fro', **kwargs)
Returns Faust.norm(F, ord) or numpy.linalg.norm(F, ord) depending of F type.
Definition: __init__.py:3894
matfaust
The FAuST Matlab Wrapper
Definition: bsl.m:1
matfaust::proj::normlin::normlin
function normlin(shape, varargin)
matfaust::rand
function rand(M, N, varargin)
Generates a random Faust.
matfaust::proj::normlin
Functor for the NORMLIN projector.
Definition: normlin.m:62