lkat_trace.py 345 Bytes
Newer Older
Daniel Brown's avatar
Daniel Brown committed
1
2
3
4
5
6
import pykat
								 
cmd = """
l l1 1 0 n1
s s1 1 n1 n2
m m1 0.99 0.01 0 n2 n3
7
s s2 999 n3 n4
Daniel Brown's avatar
Daniel Brown committed
8
9
10
11
m m2 0.99 0.01 0 n4 n5
pd circ n3

noxaxis
12
maxtem 0
Daniel Brown's avatar
Daniel Brown committed
13

Daniel Brown's avatar
Daniel Brown committed
14
attr m1 Rc 0
Daniel Brown's avatar
Daniel Brown committed
15
16
17
18
19
20
21
22
23
24
attr m2 Rc 1000 
cav c1 m1 n3 m2 n4
"""

kat = pykat.finesse.kat()

kat.parseCommands(cmd)

info = kat.lkat_trace()

25
print "n1 qx =", info["n1"].qx
Daniel Brown's avatar
Daniel Brown committed
26
27
28

print "Cavity info ", info["c1"]