GNU Octave  4.2.1
A high-level interpreted language, primarily intended for numerical computations, mostly compatible with Matlab
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
Macros | Functions
xdiv.cc File Reference
#include <cassert>
#include "Array-util.h"
#include "CMatrix.h"
#include "dMatrix.h"
#include "CNDArray.h"
#include "dNDArray.h"
#include "fCMatrix.h"
#include "fMatrix.h"
#include "fCNDArray.h"
#include "fNDArray.h"
#include "oct-cmplx.h"
#include "dDiagMatrix.h"
#include "fDiagMatrix.h"
#include "CDiagMatrix.h"
#include "fCDiagMatrix.h"
#include "lo-array-errwarn.h"
#include "quit.h"
#include "error.h"
#include "xdiv.h"
Include dependency graph for xdiv.cc:

Go to the source code of this file.

Macros

#define INSTANTIATE_MX_DIV_CONFORM(T1, T2)   template bool mx_div_conform (const T1&, const T2&)
 
#define INSTANTIATE_MX_LEFTDIV_CONFORM(T1, T2)   template bool mx_leftdiv_conform (const T1&, const T2&, blas_trans_type)
 

Functions

template<typename MT , typename DMT >
MT dmdm_div_impl (const MT &a, const DMT &d)
 
template<typename MT , typename DMT >
MT dmdm_leftdiv_impl (const DMT &d, const MT &a)
 
template<typename MT , typename DMT >
MT dmm_leftdiv_impl (const DMT &d, const MT &a)
 
template<typename MT , typename DMT >
MT mdm_div_impl (const MT &a, const DMT &d)
 
template<typename T1 , typename T2 >
bool mx_div_conform (const T1 &a, const T2 &b)
 
template bool mx_div_conform (const Matrix &, const Matrix &)
 
template bool mx_div_conform (const Matrix &, const ComplexMatrix &)
 
template bool mx_div_conform (const ComplexMatrix &, const Matrix &)
 
template bool mx_div_conform (const ComplexMatrix &, const ComplexMatrix &)
 
template bool mx_div_conform (const FloatMatrix &, const FloatMatrix &)
 
template bool mx_div_conform (const FloatMatrix &, const FloatComplexMatrix &)
 
template bool mx_div_conform (const FloatComplexMatrix &, const FloatMatrix &)
 
template bool mx_div_conform (const FloatComplexMatrix &, const FloatComplexMatrix &)
 
template<typename T1 , typename T2 >
bool mx_leftdiv_conform (const T1 &a, const T2 &b, blas_trans_type blas_trans)
 
template bool mx_leftdiv_conform (const Matrix &, const Matrix &, blas_trans_type)
 
template bool mx_leftdiv_conform (const Matrix &, const ComplexMatrix &, blas_trans_type)
 
template bool mx_leftdiv_conform (const ComplexMatrix &, const Matrix &, blas_trans_type)
 
template bool mx_leftdiv_conform (const ComplexMatrix &, const ComplexMatrix &, blas_trans_type)
 
template bool mx_leftdiv_conform (const FloatMatrix &, const FloatMatrix &, blas_trans_type)
 
template bool mx_leftdiv_conform (const FloatMatrix &, const FloatComplexMatrix &, blas_trans_type)
 
template bool mx_leftdiv_conform (const FloatComplexMatrix &, const FloatMatrix &, blas_trans_type)
 
template bool mx_leftdiv_conform (const FloatComplexMatrix &, const FloatComplexMatrix &, blas_trans_type)
 
static bool result_ok (octave_idx_type info)
 
static void solve_singularity_warning (double rcond)
 
static void solve_singularity_warning (float rcond)
 
Matrix x_el_div (double a, const Matrix &b)
 
ComplexMatrix x_el_div (double a, const ComplexMatrix &b)
 
ComplexMatrix x_el_div (const Complex a, const Matrix &b)
 
ComplexMatrix x_el_div (const Complex a, const ComplexMatrix &b)
 
NDArray x_el_div (double a, const NDArray &b)
 
ComplexNDArray x_el_div (double a, const ComplexNDArray &b)
 
ComplexNDArray x_el_div (const Complex a, const NDArray &b)
 
ComplexNDArray x_el_div (const Complex a, const ComplexNDArray &b)
 
FloatMatrix x_el_div (float a, const FloatMatrix &b)
 
FloatComplexMatrix x_el_div (float a, const FloatComplexMatrix &b)
 
FloatComplexMatrix x_el_div (const FloatComplex a, const FloatMatrix &b)
 
FloatComplexMatrix x_el_div (const FloatComplex a, const FloatComplexMatrix &b)
 
FloatNDArray x_el_div (float a, const FloatNDArray &b)
 
FloatComplexNDArray x_el_div (float a, const FloatComplexNDArray &b)
 
FloatComplexNDArray x_el_div (const FloatComplex a, const FloatNDArray &b)
 
FloatComplexNDArray x_el_div (const FloatComplex a, const FloatComplexNDArray &b)
 
Matrix xdiv (const Matrix &a, const Matrix &b, MatrixType &typ)
 
ComplexMatrix xdiv (const Matrix &a, const ComplexMatrix &b, MatrixType &typ)
 
ComplexMatrix xdiv (const ComplexMatrix &a, const Matrix &b, MatrixType &typ)
 
ComplexMatrix xdiv (const ComplexMatrix &a, const ComplexMatrix &b, MatrixType &typ)
 
FloatMatrix xdiv (const FloatMatrix &a, const FloatMatrix &b, MatrixType &typ)
 
FloatComplexMatrix xdiv (const FloatMatrix &a, const FloatComplexMatrix &b, MatrixType &typ)
 
FloatComplexMatrix xdiv (const FloatComplexMatrix &a, const FloatMatrix &b, MatrixType &typ)
 
FloatComplexMatrix xdiv (const FloatComplexMatrix &a, const FloatComplexMatrix &b, MatrixType &typ)
 
Matrix xdiv (const Matrix &a, const DiagMatrix &b)
 
ComplexMatrix xdiv (const ComplexMatrix &a, const DiagMatrix &b)
 
ComplexMatrix xdiv (const ComplexMatrix &a, const ComplexDiagMatrix &b)
 
FloatMatrix xdiv (const FloatMatrix &a, const FloatDiagMatrix &b)
 
FloatComplexMatrix xdiv (const FloatComplexMatrix &a, const FloatDiagMatrix &b)
 
FloatComplexMatrix xdiv (const FloatComplexMatrix &a, const FloatComplexDiagMatrix &b)
 
DiagMatrix xdiv (const DiagMatrix &a, const DiagMatrix &b)
 
ComplexDiagMatrix xdiv (const ComplexDiagMatrix &a, const DiagMatrix &b)
 
ComplexDiagMatrix xdiv (const ComplexDiagMatrix &a, const ComplexDiagMatrix &b)
 
FloatDiagMatrix xdiv (const FloatDiagMatrix &a, const FloatDiagMatrix &b)
 
FloatComplexDiagMatrix xdiv (const FloatComplexDiagMatrix &a, const FloatDiagMatrix &b)
 
FloatComplexDiagMatrix xdiv (const FloatComplexDiagMatrix &a, const FloatComplexDiagMatrix &b)
 
Matrix xleftdiv (const Matrix &a, const Matrix &b, MatrixType &typ, blas_trans_type transt)
 
ComplexMatrix xleftdiv (const Matrix &a, const ComplexMatrix &b, MatrixType &typ, blas_trans_type transt)
 
ComplexMatrix xleftdiv (const ComplexMatrix &a, const Matrix &b, MatrixType &typ, blas_trans_type transt)
 
ComplexMatrix xleftdiv (const ComplexMatrix &a, const ComplexMatrix &b, MatrixType &typ, blas_trans_type transt)
 
FloatMatrix xleftdiv (const FloatMatrix &a, const FloatMatrix &b, MatrixType &typ, blas_trans_type transt)
 
FloatComplexMatrix xleftdiv (const FloatMatrix &a, const FloatComplexMatrix &b, MatrixType &typ, blas_trans_type transt)
 
FloatComplexMatrix xleftdiv (const FloatComplexMatrix &a, const FloatMatrix &b, MatrixType &typ, blas_trans_type transt)
 
FloatComplexMatrix xleftdiv (const FloatComplexMatrix &a, const FloatComplexMatrix &b, MatrixType &typ, blas_trans_type transt)
 
Matrix xleftdiv (const DiagMatrix &a, const Matrix &b)
 
ComplexMatrix xleftdiv (const DiagMatrix &a, const ComplexMatrix &b)
 
ComplexMatrix xleftdiv (const ComplexDiagMatrix &a, const ComplexMatrix &b)
 
FloatMatrix xleftdiv (const FloatDiagMatrix &a, const FloatMatrix &b)
 
FloatComplexMatrix xleftdiv (const FloatDiagMatrix &a, const FloatComplexMatrix &b)
 
FloatComplexMatrix xleftdiv (const FloatComplexDiagMatrix &a, const FloatComplexMatrix &b)
 
DiagMatrix xleftdiv (const DiagMatrix &a, const DiagMatrix &b)
 
ComplexDiagMatrix xleftdiv (const DiagMatrix &a, const ComplexDiagMatrix &b)
 
ComplexDiagMatrix xleftdiv (const ComplexDiagMatrix &a, const ComplexDiagMatrix &b)
 
FloatDiagMatrix xleftdiv (const FloatDiagMatrix &a, const FloatDiagMatrix &b)
 
FloatComplexDiagMatrix xleftdiv (const FloatDiagMatrix &a, const FloatComplexDiagMatrix &b)
 
FloatComplexDiagMatrix xleftdiv (const FloatComplexDiagMatrix &a, const FloatComplexDiagMatrix &b)
 

Macro Definition Documentation

#define INSTANTIATE_MX_DIV_CONFORM (   T1,
  T2 
)    template bool mx_div_conform (const T1&, const T2&)

Definition at line 110 of file xdiv.cc.

#define INSTANTIATE_MX_LEFTDIV_CONFORM (   T1,
  T2 
)    template bool mx_leftdiv_conform (const T1&, const T2&, blas_trans_type)

Definition at line 84 of file xdiv.cc.

Function Documentation

template<typename MT , typename DMT >
MT dmdm_div_impl ( const MT &  a,
const DMT &  d 
)

Definition at line 871 of file xdiv.cc.

References k, m, min(), mx_div_conform(), octave_map::rows(), and x.

Referenced by xdiv().

template<typename MT , typename DMT >
MT dmdm_leftdiv_impl ( const DMT &  d,
const MT &  a 
)

Definition at line 946 of file xdiv.cc.

References blas_no_trans, octave_map::cols(), k, m, min(), mx_leftdiv_conform(), and x.

Referenced by xleftdiv().

template<typename MT , typename DMT >
MT dmm_leftdiv_impl ( const DMT &  d,
const MT &  a 
)

Definition at line 791 of file xdiv.cc.

References blas_no_trans, octave_map::cols(), k, m, mx_leftdiv_conform(), and x.

Referenced by xleftdiv().

template<typename MT , typename DMT >
MT mdm_div_impl ( const MT &  a,
const DMT &  d 
)

Definition at line 708 of file xdiv.cc.

References m, mx_div_conform(), octave_map::rows(), and x.

Referenced by xdiv().

template<typename T1 , typename T2 >
bool mx_div_conform ( const T1 &  a,
const T2 &  b 
)

Definition at line 94 of file xdiv.cc.

References a_nc, a_nr, b_nc, b_nr, and octave::err_nonconformant().

Referenced by dmdm_div_impl(), mdm_div_impl(), and xdiv().

template bool mx_div_conform ( const Matrix ,
const Matrix  
)
template bool mx_div_conform ( const Matrix ,
const ComplexMatrix  
)
template bool mx_div_conform ( const ComplexMatrix ,
const Matrix  
)
template bool mx_div_conform ( const ComplexMatrix ,
const ComplexMatrix  
)
template bool mx_div_conform ( const FloatMatrix ,
const FloatMatrix  
)
template bool mx_div_conform ( const FloatMatrix ,
const FloatComplexMatrix  
)
template bool mx_div_conform ( const FloatComplexMatrix ,
const FloatMatrix  
)
template bool mx_div_conform ( const FloatComplexMatrix ,
const FloatComplexMatrix  
)
template<typename T1 , typename T2 >
bool mx_leftdiv_conform ( const T1 &  a,
const T2 &  b,
blas_trans_type  blas_trans 
)

Definition at line 67 of file xdiv.cc.

References a_nc, a_nr, b_nc, b_nr, blas_no_trans, and octave::err_nonconformant().

Referenced by dmdm_leftdiv_impl(), dmm_leftdiv_impl(), and xleftdiv().

template bool mx_leftdiv_conform ( const Matrix ,
const Matrix ,
blas_trans_type   
)
template bool mx_leftdiv_conform ( const Matrix ,
const ComplexMatrix ,
blas_trans_type   
)
template bool mx_leftdiv_conform ( const ComplexMatrix ,
const Matrix ,
blas_trans_type   
)
template bool mx_leftdiv_conform ( const ComplexMatrix ,
const ComplexMatrix ,
blas_trans_type   
)
template bool mx_leftdiv_conform ( const FloatMatrix ,
const FloatMatrix ,
blas_trans_type   
)
template bool mx_leftdiv_conform ( const FloatMatrix ,
const FloatComplexMatrix ,
blas_trans_type   
)
template bool mx_leftdiv_conform ( const FloatComplexMatrix ,
const FloatMatrix ,
blas_trans_type   
)
template bool mx_leftdiv_conform ( const FloatComplexMatrix ,
const FloatComplexMatrix ,
blas_trans_type   
)
static bool result_ok ( octave_idx_type  info)
inlinestatic

Definition at line 52 of file xdiv.cc.

static void solve_singularity_warning ( double  rcond)
static

Definition at line 60 of file xdiv.cc.

References octave::warn_singular_matrix().

Referenced by xdiv(), and xleftdiv().

static void solve_singularity_warning ( float  rcond)
static

Definition at line 404 of file xdiv.cc.

References octave::warn_singular_matrix().

Matrix x_el_div ( double  a,
const Matrix b 
)

Definition at line 205 of file xdiv.cc.

References b, Array< T >::columns(), result, and Array< T >::rows().

ComplexMatrix x_el_div ( double  a,
const ComplexMatrix b 
)

Definition at line 223 of file xdiv.cc.

References b, Array< T >::columns(), result, and Array< T >::rows().

ComplexMatrix x_el_div ( const Complex  a,
const Matrix b 
)

Definition at line 241 of file xdiv.cc.

References b, Array< T >::columns(), result, and Array< T >::rows().

ComplexMatrix x_el_div ( const Complex  a,
const ComplexMatrix b 
)

Definition at line 259 of file xdiv.cc.

References b, Array< T >::columns(), result, and Array< T >::rows().

NDArray x_el_div ( double  a,
const NDArray b 
)

Definition at line 286 of file xdiv.cc.

References b, Array< T >::dims(), Array< T >::numel(), and result.

ComplexNDArray x_el_div ( double  a,
const ComplexNDArray b 
)

Definition at line 300 of file xdiv.cc.

References b, Array< T >::dims(), Array< T >::numel(), and result.

ComplexNDArray x_el_div ( const Complex  a,
const NDArray b 
)

Definition at line 314 of file xdiv.cc.

References b, Array< T >::dims(), Array< T >::numel(), and result.

ComplexNDArray x_el_div ( const Complex  a,
const ComplexNDArray b 
)

Definition at line 328 of file xdiv.cc.

References b, Array< T >::dims(), Array< T >::numel(), and result.

FloatMatrix x_el_div ( float  a,
const FloatMatrix b 
)

Definition at line 506 of file xdiv.cc.

References b, Array< T >::columns(), result, and Array< T >::rows().

FloatComplexMatrix x_el_div ( float  a,
const FloatComplexMatrix b 
)

Definition at line 524 of file xdiv.cc.

References b, Array< T >::columns(), result, and Array< T >::rows().

FloatComplexMatrix x_el_div ( const FloatComplex  a,
const FloatMatrix b 
)

Definition at line 542 of file xdiv.cc.

References b, Array< T >::columns(), result, and Array< T >::rows().

FloatComplexMatrix x_el_div ( const FloatComplex  a,
const FloatComplexMatrix b 
)

Definition at line 560 of file xdiv.cc.

References b, Array< T >::columns(), result, and Array< T >::rows().

FloatNDArray x_el_div ( float  a,
const FloatNDArray b 
)

Definition at line 587 of file xdiv.cc.

References b, Array< T >::dims(), Array< T >::numel(), and result.

FloatComplexNDArray x_el_div ( float  a,
const FloatComplexNDArray b 
)

Definition at line 601 of file xdiv.cc.

References b, Array< T >::dims(), Array< T >::numel(), and result.

FloatComplexNDArray x_el_div ( const FloatComplex  a,
const FloatNDArray b 
)

Definition at line 615 of file xdiv.cc.

References b, Array< T >::dims(), Array< T >::numel(), and result.

FloatComplexNDArray x_el_div ( const FloatComplex  a,
const FloatComplexNDArray b 
)

Definition at line 629 of file xdiv.cc.

References b, Array< T >::dims(), Array< T >::numel(), and result.

Matrix xdiv ( const Matrix a,
const Matrix b,
MatrixType typ 
)
ComplexMatrix xdiv ( const Matrix a,
const ComplexMatrix b,
MatrixType typ 
)
ComplexMatrix xdiv ( const ComplexMatrix a,
const Matrix b,
MatrixType typ 
)
ComplexMatrix xdiv ( const ComplexMatrix a,
const ComplexMatrix b,
MatrixType typ 
)
FloatMatrix xdiv ( const FloatMatrix a,
const FloatMatrix b,
MatrixType typ 
)
FloatComplexMatrix xdiv ( const FloatMatrix a,
const FloatComplexMatrix b,
MatrixType typ 
)
FloatComplexMatrix xdiv ( const FloatComplexMatrix a,
const FloatMatrix b,
MatrixType typ 
)
FloatComplexMatrix xdiv ( const FloatComplexMatrix a,
const FloatComplexMatrix b,
MatrixType typ 
)
Matrix xdiv ( const Matrix a,
const DiagMatrix b 
)

Definition at line 752 of file xdiv.cc.

References mdm_div_impl().

ComplexMatrix xdiv ( const ComplexMatrix a,
const DiagMatrix b 
)

Definition at line 757 of file xdiv.cc.

References mdm_div_impl().

ComplexMatrix xdiv ( const ComplexMatrix a,
const ComplexDiagMatrix b 
)

Definition at line 762 of file xdiv.cc.

References mdm_div_impl().

FloatMatrix xdiv ( const FloatMatrix a,
const FloatDiagMatrix b 
)

Definition at line 776 of file xdiv.cc.

References mdm_div_impl().

FloatComplexMatrix xdiv ( const FloatComplexMatrix a,
const FloatDiagMatrix b 
)

Definition at line 781 of file xdiv.cc.

References mdm_div_impl().

FloatComplexMatrix xdiv ( const FloatComplexMatrix a,
const FloatComplexDiagMatrix b 
)

Definition at line 786 of file xdiv.cc.

References mdm_div_impl().

DiagMatrix xdiv ( const DiagMatrix a,
const DiagMatrix b 
)

Definition at line 907 of file xdiv.cc.

References dmdm_div_impl().

ComplexDiagMatrix xdiv ( const ComplexDiagMatrix a,
const DiagMatrix b 
)

Definition at line 912 of file xdiv.cc.

References dmdm_div_impl().

ComplexDiagMatrix xdiv ( const ComplexDiagMatrix a,
const ComplexDiagMatrix b 
)

Definition at line 917 of file xdiv.cc.

References dmdm_div_impl().

FloatDiagMatrix xdiv ( const FloatDiagMatrix a,
const FloatDiagMatrix b 
)

Definition at line 931 of file xdiv.cc.

References dmdm_div_impl().

FloatComplexDiagMatrix xdiv ( const FloatComplexDiagMatrix a,
const FloatDiagMatrix b 
)

Definition at line 936 of file xdiv.cc.

References dmdm_div_impl().

Definition at line 941 of file xdiv.cc.

References dmdm_div_impl().

Matrix xleftdiv ( const Matrix a,
const Matrix b,
MatrixType typ,
blas_trans_type  transt 
)

Definition at line 352 of file xdiv.cc.

References mx_leftdiv_conform(), Matrix::solve(), and solve_singularity_warning().

ComplexMatrix xleftdiv ( const Matrix a,
const ComplexMatrix b,
MatrixType typ,
blas_trans_type  transt 
)

Definition at line 365 of file xdiv.cc.

References mx_leftdiv_conform(), Matrix::solve(), and solve_singularity_warning().

ComplexMatrix xleftdiv ( const ComplexMatrix a,
const Matrix b,
MatrixType typ,
blas_trans_type  transt 
)
ComplexMatrix xleftdiv ( const ComplexMatrix a,
const ComplexMatrix b,
MatrixType typ,
blas_trans_type  transt 
)
FloatMatrix xleftdiv ( const FloatMatrix a,
const FloatMatrix b,
MatrixType typ,
blas_trans_type  transt 
)

Definition at line 653 of file xdiv.cc.

References mx_leftdiv_conform(), FloatMatrix::solve(), and solve_singularity_warning().

FloatComplexMatrix xleftdiv ( const FloatMatrix a,
const FloatComplexMatrix b,
MatrixType typ,
blas_trans_type  transt 
)

Definition at line 666 of file xdiv.cc.

References mx_leftdiv_conform(), FloatMatrix::solve(), and solve_singularity_warning().

FloatComplexMatrix xleftdiv ( const FloatComplexMatrix a,
const FloatMatrix b,
MatrixType typ,
blas_trans_type  transt 
)
FloatComplexMatrix xleftdiv ( const FloatComplexMatrix a,
const FloatComplexMatrix b,
MatrixType typ,
blas_trans_type  transt 
)
Matrix xleftdiv ( const DiagMatrix a,
const Matrix b 
)

Definition at line 830 of file xdiv.cc.

References dmm_leftdiv_impl().

ComplexMatrix xleftdiv ( const DiagMatrix a,
const ComplexMatrix b 
)

Definition at line 835 of file xdiv.cc.

References dmm_leftdiv_impl().

ComplexMatrix xleftdiv ( const ComplexDiagMatrix a,
const ComplexMatrix b 
)

Definition at line 840 of file xdiv.cc.

References dmm_leftdiv_impl().

FloatMatrix xleftdiv ( const FloatDiagMatrix a,
const FloatMatrix b 
)

Definition at line 854 of file xdiv.cc.

References dmm_leftdiv_impl().

FloatComplexMatrix xleftdiv ( const FloatDiagMatrix a,
const FloatComplexMatrix b 
)

Definition at line 859 of file xdiv.cc.

References dmm_leftdiv_impl().

FloatComplexMatrix xleftdiv ( const FloatComplexDiagMatrix a,
const FloatComplexMatrix b 
)

Definition at line 864 of file xdiv.cc.

References dmm_leftdiv_impl().

DiagMatrix xleftdiv ( const DiagMatrix a,
const DiagMatrix b 
)

Definition at line 982 of file xdiv.cc.

References dmdm_leftdiv_impl().

ComplexDiagMatrix xleftdiv ( const DiagMatrix a,
const ComplexDiagMatrix b 
)

Definition at line 987 of file xdiv.cc.

References dmdm_leftdiv_impl().

ComplexDiagMatrix xleftdiv ( const ComplexDiagMatrix a,
const ComplexDiagMatrix b 
)

Definition at line 992 of file xdiv.cc.

References dmdm_leftdiv_impl().

FloatDiagMatrix xleftdiv ( const FloatDiagMatrix a,
const FloatDiagMatrix b 
)

Definition at line 1006 of file xdiv.cc.

References dmdm_leftdiv_impl().

FloatComplexDiagMatrix xleftdiv ( const FloatDiagMatrix a,
const FloatComplexDiagMatrix b 
)

Definition at line 1011 of file xdiv.cc.

References dmdm_leftdiv_impl().

FloatComplexDiagMatrix xleftdiv ( const FloatComplexDiagMatrix a,
const FloatComplexDiagMatrix b 
)

Definition at line 1016 of file xdiv.cc.

References dmdm_leftdiv_impl().