scaled units are a great feature of boost.units, however it seems
complicated to (explicitly) create variables in such units. This is
the way I found to create a variable that stores a quantity like
GigaPascals:
using boost::units;
typedef make_scaled_unit
::type gpa_unit; gpa_unit GPa; quantity
p(1.*GPa); //or p(1.*si::giga*si::pascal);
the question is, is there a simpler way of doing this? for example,
just
quantity
::type unit; };
and use it like
quantity