[x41,x42,x43,x44,x45,x46,x47] ; x41=1 first image number ; x42=25 last image number ; x43=50 mask radius ; x44=16 first ring ; x45=30 last ring ; x46=4 number of maxima to test in OR 2 ; x47=1 number of iterations per image. fr ?Images to be aligned?<3> fr ?Output images?<4> fi ?Reference image?<5> x71=x1/2+1 ; x71 - image center fr ?Document file with alignment parameters?<7> CP <5> _8 FT _8 _9 x55=0 do lb1 i=x41,x42 x87=x0 cp <3>x87 _5 x61=0 x62=0 x63=0 cp _5 _4 do lb7 k=1,x47 ma _4 _1 x43,x55 G A x71,x71 (3.5) OR 2M,x92 _1 _8 x44,x45 (0) F x46 peaks001 x91=-1.0E10 do lb2 j=1,x92 x88=x0 ud ic,x88,x32 peaks001 rt sq _1 _2 x32 (0,0) ma _2 _3 x43,x55 G A x71,x71 (3.5) cc _3 _9 _7 pk c x21,x22,x23,x24,x25,x26 _7 (3,0) (3.,3.) n (2.) (10) if(x23.gt.x91) then x91=x23 x51=x32 x52=-x25 x53=-x26 endif lb2 ud ice peaks001 de peaks001 sa p,x61,x62,x63,x51,x52,x53,x64,x65,x66 x61=x64 x62=x65 x63=x66 rt sq _5 _4 x61 x62,x63 lb7 cp _4 <4>x87 sd x87,x61,x62,x63,x91 <7> lb1 sd e <7> re