from rsf.proj import * planes = [0.7,-1,0.1] spikes = [20,80,30] titles = ['linear','cubic'] for nw in (2,4): lines = [] for p in range(3): splan = 'splan%d-%d' % (nw,p) Flow([splan,'lag'+splan],None, ''' splineplane p=%g eps=0.0001 nw=%d lag=${TARGETS[1]} ''' % (planes[p],nw)) plane = 'plane%d-%d' % (nw,p) Flow(plane,splan, ''' spike n1=90 n2=90 k1=%d k2=1 d1=1 d2=1 label1= label2= | helicon div=1 filt=$SOURCE ''' % spikes[p],stdin=0) lines.append(plane) three = 'three%d' % nw Flow(three,lines, 'add ${SOURCES[1:3]} | postfilter2 nw=%d | window n2=75' % nw) Plot(three, ''' grey wantaxis=n wheretitle=b titlesz=9 crowd=.88 title="Spline waves B-%d (%s)" ''' % (nw-1,titles[nw//2-1])) Result('sthree','three2 three4','SideBySideAniso') End() |