vectorialOperations: Basic Vectorial Operations

vectorialOperationsR Documentation

Basic Vectorial Operations

Description

Basic vectorial operations such as scalar product and vectorial product

Usage

dotProd(U, V)

vectNorm(U)

rotVect(U, n = 1)

vectProd(U, V)

Arguments

U

a numeric vector of length 3.

V

a numeric vector of length 3.

n

an integer.

Value

  • dotProd return a single element numeric vector.

  • vectNorm return a single element numeric vector.

  • rotVect return a numeric vector of length 3.

  • vectProd return a numeric vector of length 3.

See Also

matmult

Examples

Vx <- c(3,0,0)
vectNorm(Vx)
Vx <- Vx / vectNorm(Vx)
Vy <- c(0,1,0)
Vz <- vectProd(Vx, Vy)
print(Vz)


Rpdb documentation built on March 16, 2026, 5:07 p.m.