|
Boost Users : |
Subject: Re: [Boost-users] [units] Creating specific unit quantities
From: Matthias Schabel (boost_at_[hidden])
Date: 2011-03-03 14:38:01
> On Thu, Mar 3, 2011 at 12:02 PM, Matthias Schabel <boost_at_[hidden]> wrote:
> I don't really understand what you're trying to accomplish.
>
> I'm trying to add two quantities together. One quantity was created using the si system and the other was created directly.
>
>
> I thought what this meant was a quantity value was being creating with the si::length dimension. The unit of measurement for si::length is the meter and therefore the value 2.0 is being stored as 2.0 meters. I thought this was confirmed when the display of the quantity value showed "2 m". If this isn't what is occurring could you shed some light on this?
quantity<si::length> is shorthand for quantity<si::length,double>. si::length is type representing a length in the SI system, so it encapsulates both the dimensionality of length and the specific measure of length.
Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net