author | Puneeth Chaganti <punchagan@fossee.in> |
Fri, 27 May 2011 14:24:59 +0530 | |
changeset 0 | 0efde00f9229 |
permissions | -rw-r--r-- |
0 | 1 |
#!/usr/bin/python |
2 |
# 13.8 |
|
3 |
# Solves Example 3.1 of Ahlen and Sternad in Hunt's book |
|
4 |
||
5 |
import scipy as sp |
|
6 |
from lqg import lqg |
|
7 |
from cl import cl |
|
8 |
||
9 |
A, dA = sp.array([1, -0.9]), 1 |
|
10 |
B, dB = sp.array([0.1, 0.08]), 1 |
|
11 |
F, dF = 1, 0 |
|
12 |
C, dC = 1, 0 |
|
13 |
k = 2 |
|
14 |
V, dV = 1, 0 |
|
15 |
W, dW = sp.array([1, -1]), 1 |
|
16 |
rho = 0.1 |
|
17 |
||
18 |
R1,dR1,Sc,dSc = lqg_simple(A,dA,B,dB,C,dC,k,rho,V,dV,W,dW,F,dF) |
|
19 |
||
20 |
print "R1", R1 |
|
21 |
print "dR1", dR1 |
|
22 |
print "Sc", Sc |
|
23 |
print "dSc", dSc |