File: branches.auto

package info (click to toggle)
auto-07p 0.9.1%2Bdfsg-7
  • links: PTS, VCS
  • area: main
  • in suites: buster
  • size: 16,200 kB
  • sloc: fortran: 22,644; f90: 19,340; python: 19,045; ansic: 11,116; sh: 1,079; makefile: 618; perl: 339
file content (17 lines) | stat: -rw-r--r-- 542 bytes parent folder | download | duplicates (5)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
# get and run the ab demo
demo('ab')
auto('ab.auto')
# load data from b.ab, s.ab, and d.ab
ab = loadbd('ab')
# change the branch number to either 1 or 2 depending on IPS
for branch in ab:
    branch['BR'] = branch.c['IPS']
# delete the last branch
del ab[-1]
# subtract the first branch from all other branches with respect to PAR(1)
ab = subtract(ab, ab, 'PAR(1)')
# plot the branches, coloring by branch number
plot(ab, coloring_method='branch', color_list='black red')
wait()
# save data to b.abnew, s.abnew, and d.abnew
save(ab, 'abnew')