ASPN ActiveState Programmer Network
ActiveState
/ Home / Perl / PHP / Python / Tcl / XSLT /
/ Safari / My ASPN /
Cookbooks | Documentation | Mailing Lists | Modules | News Feeds | Products | User Groups


Recent Messages
List Archives
About the List
List Leaders
Subscription Options

View Subscriptions
Help

View by Topic
ActiveState
.NET Framework
Open Source
Perl
PHP
Python
Tcl
Web Services
XML & XSLT

View by Category
Database
General
SOAP
System Administration
Tools
User Interfaces
Web Programming
XML Programming


MyASPN >> Mail Archive >> boost
boost
[boost] Re: Physical Quantities revisited
by Andy Little other posts by this author
Oct 24 2003 9:21AM messages near this date
RE: [boost] Re: Physical Quantities revisited | [boost] Re: Physical Quantities revisited
"Ross MacGregor" <ross__macgregor@[...].com>  wrote in message
news:bn9mfr$uec$1@[...]..

>  1) All units are represented as SI units by convention.
>  2) Each quantity has its own precision. Use longs, floats, double, or a
>  custom type.
>  3) Each quantity uses a predefined dimention.
>  4) Each type provides a transformation to the base dimention (units).
>  5) Provides automatic type conversion of same dimention types.
>  6) Provides loss of precision warnings.
> 

Of the list many things have been discussed higher up this thread and in the
dimensional analysis thread, so worth a look.

6) is to me the most important and problematic. There should be a means of
clear compile time error feedback to the user.
 Unfortunately as far as I know C++ templates do not (yet) provide a neat
mechanism for this.

note: I would  be interested if anyone could point me to current research,
thinking or policy in this area...?

>  Is such an entity possible?

See my demo for one approach:

http://www.servocomm.freeserve.co.uk/Cpp/physical_quantity/index.html

Please note that there are a lot of other examples about... some on boost...
also worth a look.

Andy Little
andy@[...].uk







_______________________________________________
Unsubscribe & other changes: http://lists.boost.org/mailman/listinfo.cgi/boost
Thread:
Andy Little
Andy Little
Andy Little
Andy Little
Andy Little
Andy Little
Andy Little
Jan Langer
Andy Little
Deane Yang
Paul A. Bristow
Phil Richards
Rene Jager
Deane Yang
Phil Richards
Andy Little
Deane Yang
Brock Peabody
Paul A. Bristow
Andy Little
Andy Little
Matthias Troyer
Paul A. Bristow
Ross MacGregor
Deane Yang
Paul A. Bristow
Deane Yang
Paul A. Bristow
Paul A. Bristow
David Abrahams
Jonathan de Halleux
Philip Miller
Deane Yang
Paul A. Bristow
Paul A. Bristow
David Abrahams

Privacy Policy | Email Opt-out | Feedback | Syndication
© ActiveState Software Inc. All rights reserved