Menu

Tree [734eea] master /
 History

HTTPS access


File Date Author Commit
 Makefile 2013-03-04 Jeremy Heyl Jeremy Heyl [b63d96] new quad_kd and triangle_kd
 README 2013-03-04 Jeremy Heyl Jeremy Heyl [734eea] added new quieter mode
 calctrans.c 2013-03-02 Jeremy Heyl Jeremy Heyl [f0e462] Added new calctrans and match_kd
 calctransform.c 2013-03-04 Jeremy Heyl Jeremy Heyl [b63d96] new quad_kd and triangle_kd
 calctransform.h 2013-03-04 Jeremy Heyl Jeremy Heyl [b63d96] new quad_kd and triangle_kd
 kdtree.c 2013-02-07 Jeremy Heyl Jeremy Heyl [56657b] Initial commit
 kdtree.h 2013-02-07 Jeremy Heyl Jeremy Heyl [56657b] Initial commit
 loadfile.c 2013-02-07 Jeremy Heyl Jeremy Heyl [56657b] Initial commit
 loadfile.h 2013-02-07 Jeremy Heyl Jeremy Heyl [56657b] Initial commit
 match_kd.c 2013-03-02 Jeremy Heyl Jeremy Heyl [f0e462] Added new calctrans and match_kd
 quad_kd.c 2013-03-04 Jeremy Heyl Jeremy Heyl [734eea] added new quieter mode
 triangle_kd.c 2013-03-04 Jeremy Heyl Jeremy Heyl [734eea] added new quieter mode

Read Me

The kd-match suite uses k-d trees to efficiently match stars (or points) 
in two lists and combine the lists.

The four programs are 

1) triangle_kd looks for similar triangles in the first and second 
   catalogues.  Because there are many, many triangles, it is useful to
   use triangle_kd on a subset of each catalogue where you expect the same 
   objects to appear in both.  Triangle_kd will provide a list of pairs of 
   similar triangles and highlight all of the pairs that have similar 
   transformation matrices and calculate the matrix for these groups of 
   pairs.   This matrix can be used as input for matchopt_kd below to match
   the entire catalogue.

2) quad_kd looks for matching quadrilaterals in the first and second
   catalogues.  Because there are many, many quadrilaterals, it is
   useful to use quad_kd on a subset of each catalogue where you
   expect the same objects to appear in both.  Furthermore because
   there are many more quadrilaterals than triangles, it is best to
   start with triangle_kd and only use quad_kd if you expect shearing
   between the two coordinate systems.  Quad_kd will provide a list of
   pairs of matching quadrilaterals and highlight all of the pairs
   that have similar transformation matrices and calculate the matrix
   for these groups of pairs.  This matrix can be used as input for
   matchopt_kd below to match the entire catalogue.

3) match_kd uses the transformation found by triange_kd or quad_kd to find 
   the nearest match to a star in one catalogue from the other catalogue and
   combine the two catalogues.   It can also list all the stars in the second 
   catalogue within a given search radius.

4) calctrans determines the best fitting transformation between the two sets
   of coordinates.  It does not fit asterisms, but rather it assumes that the
   objects in the first list corresponds to those in the second list.


******************************************************************************
triangle_kd

Format:

   triangle_kd file1 file2 [options]

   where the options can appear anywhere in any order:

   -d distance_cutoff  how small of a distance to call a match - default 1e-05
   -t transform_cutoff how small of a distance to call a match - default 0.001
   -p translate_factor factor to scale the x-translation       - default 1000
   -m max_matches      number of matching transforms to quit   - default 20
   -x1 column          column to read x-coordinate from file 1 - default 1
   -y1 column          column to read y-coordinate from file 1 - default 2
   -x2 column          column to read x-coordinate from file 2 - default 1
   -y2 column          column to read y-coordinate from file 2 - default 2
   -fs  FS             field separator - default space/TAB
   -fs1 FS             field separator for file 1
   -fs2 FS             field separator for file 2
   -ns                 Do not swap lists, even if the first is larger
   -v                  be more verbose (more -v more verbose)
   -q                  be less verbose (more -q less verbose)
   -                   read from standard input

   Only the first two files listed will be read.  The final listed parameter
   stands.

   triangle_kd will try to match triangles in the two catalogues.  It is useful
   when one expects there to be rotation, translation and scaling between the
   two catalogues but no shearing.  If you do expect shearing, use quad_kd.

******************************************************************************
quad_kd

Format:

   quad_kd file1 file2 [options]

   where the options can appear anywhere in any order:

   -d distance_cutoff  how small of a distance to call a match - default 0.003
   -t transform_cutoff how small of a distance to call a match - default 0.001
   -p translate_factor factor to scale the x-translation       - default 1000
   -m max_matches      number of matching transforms to quit   - default 20
   -x1 column          column to read x-coordinate from file 1 - default 1
   -y1 column          column to read y-coordinate from file 1 - default 2
   -x2 column          column to read x-coordinate from file 2 - default 1
   -y2 column          column to read y-coordinate from file 2 - default 2
   -fs  FS             field separator - default space/TAB
   -fs1 FS             field separator for file 1
   -fs2 FS             field separator for file 2
   -ns                 Do not swap lists, even if the first is larger
   -v                  be more verbose (more -v more verbose)
   -q                  be less verbose (more -q less verbose)
   -                   read from standard input

   Only the first two files listed will be read.  The final listed parameter
   stands.

   quad_kd will try to match quadrilaterals in the two catalogues.  It is useful
   when one expects there to be shearing as well as rotation, translation and
   scaling between the two catalogues.  If you don't expect shearing, use
   triangle_kd.

******************************************************************************
matchopt_kd

Format:

   matchopt_kd file1 file2 [options]

Find the closest star in catalogue 2 for each star in catalogue 1.
Print the line from catalogue 1 - distance - the line in catalogue 2.
The options can appear anywhere in any order:

   -x1 column    column to read x-coordinate from file 1 - default 1
   -y1 column    column to read y-coordinate from file 1 - default 2
   -x2 column    column to read x-coordinate from file 2 - default 1
   -y2 column    column to read y-coordinate from file 2 - default 2
   -t  params    six parameter transformation from 1 to 2 (from triangle_kd)
   -fs  FS       field separator - default space/TAB
   -fs1 FS       field separator for file 1
   -fs2 FS       field separator for file 2
   -             read from standard input

   Only the first two files listed will be read.  The final listed parameter
   stands.

******************************************************************************
calctrans

Format:

   calctrans file1 file2 [options]

   where the options can appear anywhere in any order:

   -x1 column          column to read x-coordinate from file 1 - default 1
   -y1 column          column to read y-coordinate from file 1 - default 2
   -x2 column          column to read x-coordinate from file 2 - default 1
   -y2 column          column to read y-coordinate from file 2 - default 2
   -x  x-coord         x-coord to transform
   -y  y-coord         x-coord to transform
   -fs  FS             field separator - default space/TAB
   -fs1 FS             field separator for file 1
   -fs2 FS             field separator for file 2
   -v                  be verbose (more -v more verbose)
   -                   read from standard input

   Only the first two files listed will be read.  The final listed parameter
   stands.

   calctrans determines the best fitting transformation between the two sets
   of coordinates.  It does not fit asterisms, but rather it assumes that the
   objects in the first list corresponds to those in the second list.
Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.