Takes in state-space model and discretizes it

c2d(A, B, Ts)

Arguments

A

State matrix

B

Input matrix

Ts

Timestep

Value

A discreted state-space model

Examples

A <- matrix(c(0.51,0.22,0.47,0.78),nrow = 2, byrow = T) B <- matrix(c(0.61,0.83,0.25,0.39),nrow = 2, byrow = T) csys <- d2c(A,B,600) c2d(csys$A,csys$B,600)
#> $A #> [,1] [,2] #> [1,] 0.51 0.22 #> [2,] 0.47 0.78 #> #> $B #> [,1] [,2] #> [1,] 0.61 0.83 #> [2,] 0.25 0.39 #>
c2d(csys$A,csys$B,1200)
#> $A #> [,1] [,2] #> [1,] 0.3635 0.2838 #> [2,] 0.6063 0.7118 #> #> $B #> [,1] [,2] #> [1,] 0.9761 1.3391 #> [2,] 0.7317 1.0843 #>