ger: Genral Vector Outer Product

Description Usage Arguments Value Author(s) Examples

Description

Calculates: ans = alpha * A.B**T + C where alpha is a scalar and A, B, are vectors and C is a matrix.

Usage

1
ger(alpha = NULL, A, B, C = NULL)

Arguments

alpha

a reference object of class 'number' with rank 0

A

a reference object of class 'number' with rank 1

B

a reference object of class 'number' with rank 1

C

a reference number of class 'number' with rank 2

Value

Returns a reference object of class 'number'

Author(s)

Filippo Monari

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
modello.init(10, 10, 10, 10)
alpha = number(1, scalar=TRUE)
A = number(rnorm(3))
B = number(rnorm(3))
C = number(matrix(rnorm(9), 3, 3))
ans1 = ger(alpha, A, B, C)
ans2 = ger(NULL, A, B, C)
ans3 = ger(NULL, A, B, NULL)
print(ans1)
print(ans1$v)
print(ans2)
print(ans2$v)
print(ans3)
print(ans3$v)
modello.close()

modello documentation built on Feb. 2, 2021, 9:06 a.m.

Related to ger in modello...