Path: news.mathworks.com!not-for-mail
From: <HIDDEN>
Newsgroups: comp.soft-sys.matlab
Subject: Re: State Space Matrices
Date: Sat, 27 Dec 2008 18:59:02 +0000 (UTC)
Organization: The MathWorks, Inc.
Lines: 12
Message-ID: <gj5ttm$nq0$1@fred.mathworks.com>
References: <1943188.1230396037162.JavaMail.jakarta@nitrogen.mathforum.org>
Reply-To: <HIDDEN>
NNTP-Posting-Host: webapp-05-blr.mathworks.com
Content-Type: text/plain; charset="ISO-8859-1"
Content-Transfer-Encoding: 8bit
X-Trace: fred.mathworks.com 1230404342 24384 172.30.248.35 (27 Dec 2008 18:59:02 GMT)
X-Complaints-To: news@mathworks.com
NNTP-Posting-Date: Sat, 27 Dec 2008 18:59:02 +0000 (UTC)
X-Newsreader: MATLAB Central Newsreader 1651907
Xref: news.mathworks.com comp.soft-sys.matlab:508912


Mohit C <mchhabra27@gmail.com> wrote in message <1943188.1230396037162.JavaMail.jakarta@nitrogen.mathforum.org>...
> After creating a system "sys" using 'feedback' command, I'm trying to extract A_sys,B_sys,C_sys matrices for this new system.
> 
> I can view them by using ss(sys), but I'd like to use them for further math in my code. 
> 
> Is there a way to extract them out ?

There's a command called ssdata that you can use.

[A_sys,B_sys,C_sys,D_sys] = ssdata(sys)

That should work.