Skip to contents

Checks whether the given input is a ComplexLazyTensor encoding a single complex value. That is, if the input is a fixed parameter ComplexLazyTensor of dimension 1.

Usage

is.ComplexLazyParameter(x)

Arguments

x

A LazyTensor object that we want to know if it is a ComplexLazyParameter.

Value

A boolean, TRUE or FALSE.

Details

If x is a fixed parameter ComplexLazyTensor encoding a single complex value, is.ComplexLazyParameter(x) returns TRUE, else, returns FALSE.

Author

Chloe Serre-Combe, Amelie Vernay

Examples

if (FALSE) {
# basic example
scal <- 3.14
cplx <- 2 + 3i
v <- rep(3 + 7i, 10)
z <- matrix(2 + 1i^ (-6:5), nrow = 4)

# create LazyTensor and ComplexLazyTensor
scal_LT <- LazyTensor(scal)
cplx_LT <- LazyTensor(cplx)
v_LT <- LazyTensor(v)
z_i <- LazyTensor(z, index = 'i')

# call is.ComplexLazyParameter
is.ComplexLazyParameter(scal_LT) # returns FALSE
is.ComplexLazyParameter(cplx_LT) # returns TRUE
is.ComplexLazyParameter(v_LT) # returns FALSE
is.ComplexLazyParameter(x_i) # returns FALSE
}