Read a list of X,Y and an origin (Xo,Yo). Compute values that include the corresponding polar angle.
% xya_list.sh --help
Help Information for: xya_list.sh
Usage: xya_list.sh list.1 120.0 200.0
arg1 - file with X,Y list (usually in pixels)
arg2 - Xo (origin)
arg3 - Yo (origin)
I will show: /home/sco/sco/codes/bash/HELP_FILES/xya_list.sh.help
Enter any key to roceed with the view of help:
xya_list.sh:
Read a list of X,Y values and an origin (Xo,Yo)
and compute a list of Xt, Y, Radius, Angle.
Xt,Yt = the translated X,Y value
Radius = point radius relative to Xo,Yo
Angle = position angle in units of degrees
============================================================
A sample run:
% cat list.1
1374.410 713.801
1379.346 720.371
1429.173 805.244
1432.504 812.755
1435.704 820.323
1438.770 827.946
% xya_list.sh list.1 1000.503 999.844
373.91 -286.04 470.77 232.58
378.84 -279.47 470.77 233.58
428.67 -194.60 470.77 245.58
432.00 -187.09 470.77 246.58
435.20 -179.52 470.77 247.58
438.27 -171.90 470.77 248.58
% cat xya_list.explain
# Output from xya_list.sh:
Col01: translated X (Xin-Xo)
Col02: translated Y (Yin-Yo)
Col03: Radius
Col04: Angle in degrees