diff options
author | Suraj Yerramilli | 2016-02-27 14:17:20 +0530 |
---|---|---|
committer | Suraj Yerramilli | 2016-02-27 14:17:20 +0530 |
commit | 66463bac817baf2197042032c766510d2e7b9a86 (patch) | |
tree | fcd4fece3dfb9425c917a05a3b0233fde27d088a | |
parent | a3c7d680ae251da45c4e7d7e9a4e209b35bfffd8 (diff) | |
download | SysID-R-code-66463bac817baf2197042032c766510d2e7b9a86.tar.gz SysID-R-code-66463bac817baf2197042032c766510d2e7b9a86.tar.bz2 SysID-R-code-66463bac817baf2197042032c766510d2e7b9a86.zip |
minor correction
-rw-r--r-- | R/poly.R | 29 |
1 files changed, 6 insertions, 23 deletions
@@ -63,15 +63,15 @@ checkUnity <- function(x){ print.idpoly <- function(mod,se=NULL,dig=3){ if(mod$type=="arx"){ - cat("Discrete-time ARX mod: A(z)y[k] = B(z)u[k] + e[k] \n\n") + cat("Discrete-time ARX model: A(z)y[k] = B(z)u[k] + e[k] \n\n") } else if(mod$type=="armax"){ - cat("Discrete-time ARMAX mod: A(z)y[k] = B(z)u[k] + C(z)e[k] \n\n") + cat("Discrete-time ARMAX model: A(z)y[k] = B(z)u[k] + C(z)e[k] \n\n") } else if(mod$type=="oe"){ - cat("Discrete-time OE mod: y[k] = B(z)/F(z) u[k] + e[k] \n\n") + cat("Discrete-time OE model: y[k] = B(z)/F(z) u[k] + e[k] \n\n") } else if(mod$type=="bj"){ - cat("Discrete-time BJ mod: y[k] = B(z)/F(z) u[k] + C(z)/D(z) e[k] \n\n") + cat("Discrete-time BJ model: y[k] = B(z)/F(z) u[k] + C(z)/D(z) e[k] \n\n") } else{ - cat("Discrete-time Polynomial mod: A(z) y[k] = B(z)/F(z) u[k] + C(z)/D(z) e[k] \n\n") + cat("Discrete-time Polynomial model: A(z) y[k] = B(z)/F(z) u[k] + C(z)/D(z) e[k] \n\n") } # Printing Standard error sequence @@ -173,22 +173,5 @@ print.idpoly <- function(mod,se=NULL,dig=3){ } params <- function(x){ - if(x$type=="arx"||x$type=="armax"){ - coefs <- c(x$A[-1],x$B) - na <- length(x$A) - 1; nk <- x$ioDelay; - nb <- length(x$B) - if(x$type=="armax"){ - coefs <- c(coefs,x$C[-1]) - nc <- length(x$C)-1 - } - } else if(x$type=="oe"||x$type=="bj"){ - coefs <- c(x$B) - if(x$type=="bj"){ - coefs <- c(coefs,x$C[-1],x$D[-1]) - } - coefs <- c(coefs,x$F1[-1]) - nf <- length(x$F1) - 1; nk <- x$ioDelay; - nb <- length(x$B) - } - coefs + c(x$A[-1],x$B,x$C[-1],x$D[-1],x$F1[-1]) }
\ No newline at end of file |