78 std::vector<cytnx::UniTensor>
Svd(
const cytnx::UniTensor &Tin,
const bool &is_U=
true,
const bool &is_vT=
true);
80 std::vector<cytnx::UniTensor>
Hosvd(
const cytnx::UniTensor &Tin,
const std::vector<cytnx_uint64> &mode,
const bool &is_core=
true,
const bool &is_Ls=
false,
const std::vector<cytnx_int64> &trucate_dim=std::vector<cytnx_int64>());
261 std::vector<Tensor>
Svd(
const Tensor &Tin,
const bool &is_U=
true,
const bool &is_vT=
true);
271 std::vector<Tensor>
Hosvd(
const Tensor &Tin,
const std::vector<cytnx_uint64> &mode,
const bool &is_core=
true,
const bool &is_Ls=
false,
const std::vector<cytnx_int64> &trucate_dim=std::vector<cytnx_int64>());
286 std::vector<Tensor>
Qr(
const Tensor &Tin,
const bool &is_tau=
false);
301 std::vector<Tensor>
Qdr(
const Tensor &Tin,
const bool &is_tau=
false);
313 std::vector<Tensor>
Eigh(
const Tensor &Tin,
const bool &is_V=
true,
const bool &row_v=
false);
325 std::vector<Tensor>
Eig(
const Tensor &Tin,
const bool &is_V=
true,
const bool &row_v=
false);
578 Tensor Tensordot(
const Tensor &Tl,
const Tensor &Tr,
const std::vector<cytnx_uint64> &idxl,
const std::vector<cytnx_uint64> &idxr,
const bool &cacheL=
false,
const bool &cacheR=
false);
792 std::vector<Tensor>
Lanczos_Gnd(
LinOp *Hop,
const double &CvgCrit=1.0e-14,
const bool &is_V=
true,
const Tensor &Tin=
Tensor(),
const bool &verbose=
false,
const unsigned int &Maxiter=100000);
an tensor (multi-dimensional array)
Definition Tensor.hpp:289
An Enhanced tensor specifically designed for physical Tensor network simulation.
Definition UniTensor.hpp:1072
cytnx::UniTensor Trace(const cytnx::UniTensor &Tin, const cytnx_int64 &a, const cytnx_int64 &b, const bool &by_label=false)
std::vector< cytnx::UniTensor > Qr(const cytnx::UniTensor &Tin, const bool &is_tau=false)
std::vector< cytnx::UniTensor > Svd_truncate(const cytnx::UniTensor &Tin, const cytnx_uint64 &keepdim, const bool &is_U=true, const bool &is_vT=true)
Tensor Dot(const Tensor &Tl, const Tensor &Tr)
dot product of two arrays.
Tensor Tensordot(const Tensor &Tl, const Tensor &Tr, const std::vector< cytnx_uint64 > &idxl, const std::vector< cytnx_uint64 > &idxr, const bool &cacheL=false, const bool &cacheR=false)
perform tensor dot by sum out the indices assigned of two Tensors.
std::vector< Tensor > Eig(const Tensor &Tin, const bool &is_V=true, const bool &row_v=false)
eigen-value decomposition for generic square matrix
Tensor Sum(const Tensor &Tn)
get the sum of all the elements.
Tensor Min(const Tensor &Tn)
get the minimum element.
void Abs_(Tensor &Tin)
inplace perform elementwiase absolute value.
void Pow_(UniTensor &Tin, const double &p)
inplace perform power on all the elements in UniTensor.
Tensor Abs(const Tensor &Tin)
Elementwise absolute value.
Tensor Outer(const Tensor &Tl, const Tensor &Tr)
perform outer produces of two rank-1 Tensor.
Tensor Conj(const Tensor &Tin)
Conjugate all the element in Tensor.
Tensor Matmul(const Tensor &TL, const Tensor &TR)
perform matrix multiplication on two tensors.
cytnx::UniTensor Mod(const cytnx::UniTensor &Lt, const cytnx::UniTensor &Rt)
element-wise modulo
Tensor Expf(const Tensor &Tin)
Exponential all the element in Tensor.
Tensor Diag(const Tensor &Tin)
return a diagonal tensor with diagonal elements provided as Tin.
std::vector< Tensor > Lstsq(const Tensor &A, const Tensor &b, const float &rcond=-1)
Return the least-squares solution to a linear matrix equation.
void Expf_(Tensor &Tin)
inplace perform Exponential on all the element in Tensor.
Tensor Det(const Tensor &Tl)
calculate the determinant of a tensor.
std::vector< Tensor > Eigh(const Tensor &Tin, const bool &is_V=true, const bool &row_v=false)
eigen-value decomposition for Hermitian matrix
cytnx::UniTensor ExpM(const cytnx::UniTensor &Tin, const double &a=1, const double &b=0)
Tensor Inv(const Tensor &Tin, const double &clip)
Element-wise inverse with clip.
cytnx::UniTensor Mul(const cytnx::UniTensor &Lt, const cytnx::UniTensor &Rt)
element-wise subtract
Tensor Max(const Tensor &Tn)
get the maximum element.
cytnx::UniTensor Sub(const cytnx::UniTensor &Lt, const cytnx::UniTensor &Rt)
element-wise subtract
Tensor Norm(const Tensor &Tl)
calculate the norm of a tensor.
std::vector< cytnx::UniTensor > Hosvd(const cytnx::UniTensor &Tin, const std::vector< cytnx_uint64 > &mode, const bool &is_core=true, const bool &is_Ls=false, const std::vector< cytnx_int64 > &trucate_dim=std::vector< cytnx_int64 >())
void Inv_(Tensor &Tin, const double &clip)
inplace perform Element-wise inverse with clip.
Tensor Vectordot(const Tensor &Tl, const Tensor &Tr, const bool &is_conj=false)
perform inner product of vectors
void Exp_(Tensor &Tin)
inplace perform Exponential on all the element in Tensor.
Tensor Exp(const Tensor &Tin)
Exponential all the element in Tensor.
Tensor Kron(const Tensor &Tl, const Tensor &Tr, const bool &Tl_pad_left=false, const bool &Tr_pad_left=false)
perform kronecker produces of two Tensor.
std::vector< Tensor > Lanczos_ER(LinOp *Hop, const cytnx_uint64 &k=1, const bool &is_V=true, const cytnx_uint64 &maxiter=10000, const double &CvgCrit=1.0e-14, const bool &is_row=false, const Tensor &Tin=Tensor(), const cytnx_uint32 &max_krydim=4, const bool &verbose=false)
perform Lanczos for hermitian/symmetric matrices or linear function.
std::vector< cytnx::UniTensor > Qdr(const cytnx::UniTensor &Tin, const bool &is_tau=false)
void InvM_(Tensor &Tin)
inplace perform Matrix inverse.
cytnx::UniTensor Add(const cytnx::UniTensor &Lt, const cytnx::UniTensor &Rt)
element-wise add
Tensor Tensordot_dg(const Tensor &Tl, const Tensor &Tr, const std::vector< cytnx_uint64 > &idxl, const std::vector< cytnx_uint64 > &idxr, const bool &diag_L)
perform tensor dot by sum out the indices assigned of two Tensors, with either one of them to be a ra...
std::vector< Tensor > Tridiag(const Tensor &Diag, const Tensor &Sub_diag, const bool &is_V=true, const bool &is_row=false)
perform diagonalization of symmetric tri-diagnoal matrix.
std::vector< cytnx::UniTensor > Svd(const cytnx::UniTensor &Tin, const bool &is_U=true, const bool &is_vT=true)
void Conj_(Tensor &Tin)
inplace perform Conjugate on all the element in Tensor.
std::vector< Tensor > Lanczos_Gnd(LinOp *Hop, const double &CvgCrit=1.0e-14, const bool &is_V=true, const Tensor &Tin=Tensor(), const bool &verbose=false, const unsigned int &Maxiter=100000)
perform Lanczos for hermitian/symmetric matrices or linear function to get ground state and lowest ei...
Tensor Cpr(const Tensor &Lt, const Tensor &Rt)
element-wise compare
UniTensor Pow(const UniTensor &Tin, const double &p)
take power p on all the elements in UniTensor.
Tensor Matmul_dg(const Tensor &Tl, const Tensor &Tr)
perform matrix multiplication on two Tensors with one rank-1 and the other rank-2 where the rank-1 re...
Tensor InvM(const Tensor &Tin)
Matrix inverse.
cytnx::UniTensor ExpH(const cytnx::UniTensor &Tin, const double &a=1, const double &b=0)
cytnx::UniTensor Div(const cytnx::UniTensor &Lt, const cytnx::UniTensor &Rt)
element-wise divide
Definition Accessor.hpp:12
cytnx::UniTensor operator*(const cytnx::UniTensor &Lt, const cytnx::UniTensor &Rt)
double cytnx_double
Definition Type.hpp:20
uint32_t cytnx_uint32
Definition Type.hpp:23
cytnx::UniTensor operator-(const cytnx::UniTensor &Lt, const cytnx::UniTensor &Rt)
Tensor operator==(const Tensor &Lt, const Tensor &Rt)
uint64_t cytnx_uint64
Definition Type.hpp:22
int64_t cytnx_int64
Definition Type.hpp:25
cytnx::UniTensor operator%(const cytnx::UniTensor &Lt, const cytnx::UniTensor &Rt)
cytnx::UniTensor operator+(const cytnx::UniTensor &Lt, const cytnx::UniTensor &Rt)
cytnx::UniTensor operator/(const cytnx::UniTensor &Lt, const cytnx::UniTensor &Rt)