abcdchk {control}R Documentation

State-space matrices check.

Description

abcdchk verifies the dimensions of A,B,C,D matrices in its arguments, to ascertain that they are correctly defined.

Usage

abcdchk(a, b, c, d)

Arguments

a

An n x n matrix

b

An n x m matrix

c

An p x n matrix

d

An p x m matrix

Details

This is a utility function that is always invoked by other functions to ascertain the dimensions of the arguments a,b,c,d and returns a message if there is an ill-defined entry.

Value

Returns an empty string if matrix dimensions are consistent. Otherwise it returns the associated error message

Examples

A <- rbind(c(0,1), c(-10000,-4))
B <- rbind(0,1)
C <- rbind(c(1,0), c(0,1))
D <- rbind(0,0)
message <-  abcdchk(A,B,C,D)


[Package control version 0.2.5 Index]