Skip to contents

det calculates the determinant of a FastTransform object. determinant returns separately the modulus of the determinant, optionally (by default) on the logarithm scale, and the sign of the determinant. If the input transform (x) is not square, the function will fail with an error.

Usage

# S3 method for FastTransform
determinant(x, logarithm = TRUE, ...)

Arguments

x

Object of FastTransform type with dim_in == dim_out.

logarithm

Logical. if TRUE (default) return the logarithm of the modulus of the determinant.

...

Extra parameters (ignored).

Value

For det, the determinant of x. For determinant, the same output format as determinant.matrix().

See also

Examples

det(fort(16)) # either 1 or -1
#> [1] 1
determinant(fort(16))
#> $modulus
#> [1] -3.330669e-16
#> attr(,"logarithm")
#> [1] TRUE
#> 
#> $sign
#> [1] 1
#> 
#> attr(,"class")
#> [1] "det"