397 using std::runtime_error::runtime_error;
A class representing a matrix, derived from Tensor.
Implements the mathematical concept of tensor, which is a magnitude of multiple order....
Exceptions concerning txeo::TensorOp.
A utility class for performing operations on tensors and vectors.
static const T & subtract_by(const T &left, txeo::Tensor< T > &right)
In-place element-wise subtraction of tensor from scalar.
static txeo::Tensor< T > & divide_by(txeo::Tensor< T > &left, const T &right)
In-place element-wise division of tensor by scalar.
static txeo::Tensor< T > & sum_by(txeo::Tensor< T > &left, const txeo::Tensor< T > &right)
Sums the left operand with the right operand (in-place)
static T dot(const txeo::Vector< T > &left, const txeo::Vector< T > &right)
Computes the dot product of two vectors.
static txeo::Tensor< T > sum(const txeo::Tensor< T > &left, const T &right)
Element-wise sum of tensor and scalar (out-of-place)
static txeo::Tensor< T > & hadamard_prod_by(txeo::Tensor< T > &left, const txeo::Tensor< T > &right)
Performs element-wise multiplication of the left operand by the right operand (in-place)
static txeo::Tensor< T > subtract(const txeo::Tensor< T > &left, const txeo::Tensor< T > &right)
Returns the subtraction of two tensors.
static txeo::Tensor< T > divide(const T &left, const txeo::Tensor< T > &right)
Element-wise division of scalar by tensor (out-of-place)
static txeo::Tensor< T > multiply(const txeo::Tensor< T > &left, const T &right)
Returns the multiplication of a tensor and a scalar.
static txeo::Tensor< T > hadamard_div(const txeo::Tensor< T > &left, const txeo::Tensor< T > &right)
Element-wise Hadamard division (out-of-place)
static txeo::Tensor< T > & subtract_by(txeo::Tensor< T > &left, const txeo::Tensor< T > &right)
Subtracts the left operand by the right operand (in-place)
TensorOp(TensorOp &&)=delete
static txeo::Tensor< T > & divide_by(const T &scalar, txeo::Tensor< T > &tensor)
In-place element-wise division of scalar by tensor elements.
static txeo::Tensor< T > hadamard_prod(const txeo::Tensor< T > &left, const txeo::Tensor< T > &right)
Returns the element-wise product (Hadamard Product) of two tensors.
static txeo::Tensor< T > subtract(const txeo::Tensor< T > &left, const T &right)
Element-wise subtraction of scalar from tensor (out-of-place)
static txeo::Matrix< T > product(const txeo::Matrix< T > &left, const txeo::Matrix< T > &right)
Computes the matrix product of two matrices.
TensorOp & operator=(const TensorOp &)=delete
static txeo::Tensor< T > & multiply_by(txeo::Tensor< T > &left, const T &right)
Multiplies the tensor by a scalar (in-place)
static txeo::Tensor< T > & sum_by(txeo::Tensor< T > &left, const T &right)
In-place element-wise addition of scalar to tensor.
static txeo::Tensor< T > divide(const txeo::Tensor< T > &left, const T &right)
Element-wise division of tensor by scalar (out-of-place)
TensorOp(const TensorOp &)=delete
static txeo::Tensor< T > & hadamard_div_by(txeo::Tensor< T > &left, const txeo::Tensor< T > &right)
In-place element-wise Hadamard division.
static txeo::Tensor< T > sum(const txeo::Tensor< T > &left, const txeo::Tensor< T > &right)
Returns the sum of two tensors.
static txeo::Tensor< T > subtract(const T &left, const txeo::Tensor< T > &right)
Element-wise subtraction of tensor from scalar (out-of-place)
static txeo::Tensor< T > & subtract_by(txeo::Tensor< T > &left, const T &right)
In-place element-wise subtraction of scalar from tensor.
TensorOp & operator=(TensorOp &&)=delete
A class representing a vector, derived from Tensor.