50% off: Unlimited data and AI learning.
State of Data and AI Literacy Report 2025

tensorA (version 0.36.2.1)

chol.tensor: Cholesky decomposition of a tensor

Description

A tensor can be seen as a linear mapping of a tensor to a tensor. This function computes its Cholesky decomposition.

Usage

chol.tensor(X,i,j,...,name="lambda")

Value

a tensor

Arguments

X

The tensor to be decomposed

i

The image dimensions of the linear mapping

j

The coimage dimensions of the linear mapping

name

The name of the eigenspace dimension. This is the dimension created by the decompositions, in which the eigenvectors are ei

...

for generic use only

Author

K. Gerald van den Boogaart

Details

A tensor can be seen as a linear mapping of a tensor to a tensor. Let denote Ri the space of real tensors with dimensions i1...id.

chol.tensor

Computes for a tensor ai1idj1jd representing a positive definit mapping form Rj to Ri with equal dimension structure in i and j its "Cholesky" decomposition Li1idλ such that ai1...idj1...jd=λLi1...idλLj1...jdλ

See Also

to.tensor, svd.tensor

Examples

Run this code


A <- to.tensor(rnorm(15),c(a=3,b=5))
AAt <- einstein.tensor(A,mark(A,i="a"))
ch <- chol.tensor(AAt,"a","a'",name="lambda")
#names(ch)[1]<-"lambda"
einstein.tensor(ch,mark(ch,i="a")) # AAt

A <- to.tensor(rnorm(30),c(a=3,b=5,c=2))
AAt <- einstein.tensor(A,mark(A,i="a"),by="c")
ch <- chol.tensor(AAt,"a","a'",name="lambda")
einstein.tensor(ch,mark(ch,i="a"),by="c") #AAt

	     

Run the code above in your browser using DataLab