R/gsvd.r

Defines functions gsvd

gsvd <- function(r,p,q) {
	ps<-mfunc(p,function(x) ginvx(sqrt(x)))
	qs<-mfunc(q,function(x) ginvx(sqrt(x)))
	sv<-svd(ps%*%r%*%qs)
	return(list(gd=sv$d,gu=ps%*%sv$u,gv=qs%*%sv$v))
}

Try the anacor package in your browser

Any scripts or data that you put into this service are public.

anacor documentation built on June 10, 2022, 5:09 p.m.