Andrew,
The "u" prefix can be added to the UDUNITS-2 database by inserting the line
<symbol>u</symbol>
in the set of other "symbol" definitions for the value "1e-6" in the
database file "$(prefix)/share/udunits/udunits2-prefixes.xml".
At this time, however, I can't say whether or not doing so will have
unintended consequences. If you wish to try it, please do so and get
back to me.
I think a larger issue regarding the adoption of the UDUNITS-2 package
is the fact that it doesn't yet have a Fortran interface. I have not
investigated this matter much but, apparently, Fortran-95 has a
relatively easy mechanism for creating such an interface -- which,
hopefully, would mean that few resources would be needed to create one.
The question then becomes one of priority: given that the CF
convention adopts the UDUNITS-2 package, how necessary or important is a
Fortran interface? On the other hand, given that creating a Fortran
interface will consume resources (most especially time) how necessary is
adoption of the UDUNITS-2 package?
I encourage and await your input on the matter. Would you please CC me
directly as I don't (yet?) subscribe to the CF mailing-list.
Regards,
Steve Emmerson
UDUNITS Developer
On 3/4/2010 3:08 AM, Andrew Clegg wrote:
> Steve,
>> The UDUNITS-1 library had a bug in it. The bug was that "g" was
>> interpreted as meaning "gravity" (i.e., "standard_free_fall") rather
>> than "gram". This was corrected in version 1.12.10 of the UDUNITS-1
>> package, which was released on 2009-09-17.
>>
>> The UDUNITS-2 package did not have this bug from the outset.
> Thanks for this, however this is not the only incompatibility I have
> found. Another one is specifying microns. Udunits1 understands 'um',
> while Udunits2 recognises '?m'. I note that the CF conventions list in
> Table 3.1 that the abbreviation for micro is 'u', not '?'.
>
> It may well be that these are the only 2 incompatibilities - in which
> case, it might be wise to note these specifically in the conventions, ie
> to specify that "The value of the |units| attribute is a string that can
> be recognized by UNIDATA"s Udunits package (version 1.12.10 or higher)
> <http://cf-pcmdi.llnl.gov/documents/cf-conventions/1.4/cf-conventions.html#udunits>",
> and perhaps that '1e-6' should be used in place of u/? to ensure
> compatibility with both versions.
>
> Cheers,
> Andrew
>
> --------------------------------------------------------------------------------
>
> Plymouth Marine Laboratory
>
> Registered Office:
> Prospect Place The Hoe
> Plymouth PL1 3DH
>
> Website: www.pml.ac.uk
> Registered Charity No. 1091222
> PML is a company limited by guarantee
> registered in England & Wales
> company number 4178503
>
> PML is a member of the Plymouth Marine Sciences Partnership
> Website: www.pmsp.org.uk
> --------------------------------------------------------------------------------
>
> This e-mail, its content and any file attachments are confidential.
>
> If you have received this e-mail in error please do not copy, disclose
> it to any third party or use the contents or attachments in any way.
> Please notify the sender by replying to this e-mail or e-mail
> forinfo at pml.ac.uk and then delete the email without making any copies or
> using it in any other way.
>
> The content of this message may contain personal views which are not the
> views of Plymouth Marine Laboratory unless specifically stated.
>
> You are reminded that e-mail communications are not secure and may
> contain viruses. Plymouth Marine Laboratory accepts no liability for any
> loss or damage which may be caused by viruses.
> --------------------------------------------------------------------------------
>
Received on Thu Mar 04 2010 - 08:53:41 GMT