[brlcad-tracker] [ brlcad-Feature Requests-3152646 ] Coordinates Conversion by Bearing and Distance
Open Source Solid Modeling CAD
Brought to you by:
brlcad
From: SourceForge.net <no...@so...> - 2011-01-08 00:21:43
|
Feature Requests item #3152646, was opened at 2011-01-06 17:09 Message generated for change (Comment added) made by thardman You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=640805&aid=3152646&group_id=105292 Please note that this message will contain a full copy of the comment thread, including the initial issue submission, for this request, not just the latest update. Category: Geometry Conversion Group: Minor Effort Status: Open Resolution: None Priority: 3 Private: No Submitted By: thardman (thardman) Assigned to: Nobody/Anonymous (nobody) Summary: Coordinates Conversion by Bearing and Distance Initial Comment: It would be useful to have a way to provide start coordinates and the specify bearing and distance and thus to generate end coordinates. This should provide options for "Great Circle" point-to-point on spherical surfaces, and should allow for various formats input and output such as "digital degrees", "degree:minute:second.sss", "degree:minute.mmm, etc. Ideally this would be a commandline application that can read a table of input data and output a processed table. ---------------------------------------------------------------------- >Comment By: thardman (thardman) Date: 2011-01-07 19:21 Message: Another Useful Option would be the ability to specify ordering of x,y or y,x for either or both input and output. This also should be something that can be either specified on the commandline or read from the environment variable set. For example beardist -i0 -o0 [data] would accept input and would output ordered as latitude longitude. beardist -i1 -o0 [data] would accept input as longitude latitude and output as latitude longitude. ---------------------------------------------------------------------- Comment By: thardman (thardman) Date: 2011-01-07 10:50 Message: Perhaps a usage could be like this: beardist -lat lat -lng lng -b bearing -d dist [-ell ellipsoid -ug units-geometry -ud degree-units -ci CSV-input -co CSV-output -si space-separated-input -so space-separated-output -a append-output-to-copy-of-input] (Anything in brackets is "special purpose" and could be specified ideally both on command line or in environmental variables.) Alternatively, the ellipsoid spec (WGS84, NAD27, whatever) could be an environmental variable, as could the units of geometry (inches, feet, yards, perches, miles, nm, mm, cm, m, km etc) and degree format (decimal degrees, D:M:S.s, D:MM.mm etc). If all of that was set in env vars, behavior assuming -lat -lng -b and -d could exist, so that something like beardist 39.0000 -77.0000 180 1450 would be assumed to mean a start point at 39.0000 N, 77.0000 W, bearing due south, 1450 feet. With env vars set and default behavior, beardist < IN-TABLE > OUT-TABLE should be able to plow through a table of lat,long,bearing,distance and write out to a table of end-points. It might or might not make the most sense for it to default to accepting input as CSV (comma separated values) for easy interaction with database and spreadsheet import/export. "PHP friendly" for LAMP use might be a subsidiary goal. It might make sense for the default to be the -a option, which takes in a 4-column spec of x,y,bearing,distance and outputs 6 columns, x,y,bearing,distance,x2,y2. Perhaps a sub-option to -a to insert a different separator between the 4 original columns and the result columns might be useful, so that 'cut -f 2 -d "_"' could run nicely from 'bash'. See also the man page for "cs2cs" under OSGEO's "proj" project. It's open-source and they probably don't mind sharing. http://trac.osgeo.org/proj/wiki/man_cs2cs and http://trac.osgeo.org/proj/ Cheers, I hope I'm not being too wildly optimistic here. ;) ---------------------------------------------------------------------- Comment By: Sean Morrison (brlcad) Date: 2011-01-07 01:12 Message: So what would the exact usage of this tool ideally look like? Can you provide a mock input/output "screenshot" showing a few sample command line uses? For the tool to be more generally useful, it'd ideally have some option(s) for specifying geoid/ellipsoid dimensions instead of assuming a perfect sphere. The usage should take that into account as well. The calculators at http://williams.best.vwh.net/gccalc.htm look promising and the javascript probably wouldn't be too hard to convert, but how those convert to some sort of command-line tool could be tricky. If you can sort those details out, it would greatly simplify the implementation. ---------------------------------------------------------------------- Comment By: Tom Browder (tbrowder2) Date: 2011-01-06 19:48 Message: In case this is approved, I have received permission from Mr. Ed Williams to use data and code from his aviation formulary site (http://williams.best.vwh.net/avform.htm), with suitable attribution: On Thu, Jan 6, 2011 at 17:39, Ed Williams <ed...@ed...> wrote: > At 02:26 PM 1/6/2011, you wrote: >> >> Mr. Williams, would you permit the use of your aviation formulary >> information to be incorporated into Perl or other code for use on the >> BRL-CAD web site (<http://brlcad.org>? >> >> Thanks for your consideration. >> >> Regards, >> >> -Tom >> >> Thomas M. Browder, Jr. >> Niceville, Florida >> USA > > Absolutely. Just give credit as necessary. WILCO Regards, -Tom ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=640805&aid=3152646&group_id=105292 |