chsvlib
chsv helper source code

◆ operator*=() [2/2]

std::enable_if< is_rng<val_t>::value && std::is_convertible<elem_t, val_t>::value , typename Matrix<val_t, alloc_t, der_t, policy_t>::derived_type& >::type Chusov::Math::operator*= ( Matrix< val_t, alloc_t, der_t, policy_t > &  left,
elem_t &&  val 
)

Multiplies a matrix and a scalar and assigns the product to the matrix.

Template Parameters
val_tis a type of an element of the matrix.
alloc_tis a type of an allocator used by the left matrix.
der_tis a derived type of the first operand. See Matrix::derived_type.
policy_tis an execution policy of the matrix.
elem_tis a type of the scalar multiplied to the matrix.
Parameters
leftis an lvalue reference to the matrix to which the right operand is multiplied and to which the product is assigned.
valis a universal reference to the scalar to be multiplied to the matrix from the right.
Returns
Returns a reference to left cast to the
std::conditional< std::is_void< Derived_t >::value, Matrix< Val, Alloc, void, Policy >, Derived_t >::type derived_type
A type alias for a most-derived class inheriting and implementing the behaviour of the matrix,...
Definition: chsvmath.h:6380
after the multiplication has been performed.
Remarks
The operation is defined only when elements of the matrix appertain to an Rng, and values of the elem_t type are convertible to val1_t.