R/X.prod.R

Defines functions X.prod

Documented in X.prod

X.prod<-function(a,b)
{
####   return the cartesian Cross product between two vectors
  z=rep(0, length(a))

  z[1] <- (a[2] * b[3]) - (b[2] * a[3]) 
  z[2] <- (a[3] * b[1]) - (b[3] * a[1]) 
  z[3] <- (a[1] * b[2]) - (b[1] * a[2])
  return(z)

}

Try the GEOmap package in your browser

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

GEOmap documentation built on Sept. 1, 2023, 5:09 p.m.