[Proj] Question on colon DMS format

Gerald I. Evenden geraldi.evenden at gmail.com
Sun May 17 09:47:17 EST 2009


On Saturday 16 May 2009 10:55:23 pm Hamish wrote:
	...
> GRASS still uses this format, the following are allowed:
>
> DDDh
>  (DDD.DDDDDDh is not allowed, as E has problems with
>   mistranslation into e.g. e+06; so +/- DDD.DDDDD must be
>   used there; could probably be coded around but currently isn't)

I do not understand the "h".

Problems with a NEWS suffix sign sounds like a library problem.  On a GNU 
library 11.3e is interpreted as a positive 11.3 and "e" is still in the 
uninterpreded input string.

A proper lexical analyser should sense existance of an e|E followed by a 
signed number.  The "D" of FORTRAN infamy is not recognized.  In any case 
proj_dms2rad and preceeding versions have not put a restriction on ddd.dddd.

> DDD:MMh
> DDD:MM.MMMMh  (recently added to deal with GPS output)
> DDD:MM:SSh
> DDD:MM:SS.SSSSSh
>
> GRASS enforces %02d for MM and SS input, but I don't think
> that's necessary and have considered removing it.

Don't use %2d as that will cause space for numbers under 10.  "%d" will work 
OK with proj_dms2rad.

	...
> and using a degree ascii char, but then that always goes nuts
> when the LANG setting changes.

Basic, old time, standard ASCII does *not* have a degree mark and that is why 
I have not used it.  The degree mark is an addition to some alphabets.

I would use it but I am not a student of all the alphabets available nor do I 
want to be and until a standard alphabet is mandated by the US Congress, The 
United Nations, or a local star cluster federation, I must stick to old 
standards although I would like to use a °.

If this august group of potential users can make an IRON-CLAD guarantee that 
latin-1, UTF-8, or whatever set is univerally available to a *all* potential 
users and usable in C format operations, I would add the degree mark to the 
system.

Thanks for the comments.

-- 
The whole religious complexion of the modern world is due
to the absence from Jerusalem of a lunatic asylum.
-- Havelock Ellis (1859-1939) British psychologist


More information about the Proj mailing list