Boost logo

Boost :

From: Andy Little (andy_at_[hidden])
Date: 2006-06-08 07:44:05


"Martin Bonner" wrote
> ----Original Message----
> From: boost-bounces_at_[hidden]
> [mailto:boost-bounces_at_[hidden]] On Behalf Of Andy Little Sent:
> 08 June 2006 08:32 To: boost_at_[hidden]
> Subject: Re: [boost] [review] pqs
>
>>> "Deane Yang" wrote
>>> Carlo Wood wrote:
>>>> English: meter per second
>>>> Dutch: meter per seconde
>>>> French: mtres par seconde
>>>> German: meter pro sekunde
>>>> Spanish: metro por segundo
>>>>
>>>> I think that 'per' is as much english as 'divided by'.
>>>> People who know english won't be confused by it.
>>>>
>>>
>>> I also vote for "per".
>>
>> in this case, as typedefs for declaring a quantity of a particular
>> type , you
>> end up with
>>
>> velocity:: m_per_s
>> velocity:: mi_per_h
>> acceleration::m_per_s2;
>> reciprocal_time::per_s;
>> reciprocal_mass::per_kg;
>> mass_flow::kg_per_s;
>
> This is *MUCH* easier to read than _div_.
>>
>> It might even be possible to abbreviate it and keep the sense:
>>
>> velocity:: m_p_s
>> velocity:: mi_p_h
>> acceleration::m_p_s2;
>> reciprocal_time::p_s;
>> reciprocal_mass::p_kg;
>> mass_flow::kg_p_s;
>
> But this is not. It gets close to idiomatic forms like mph (but not all
> that close), and is really difficult to read for m/s.
>
>
> Incidentally, none of the above units has a natural "named" unit (with
> the possible exception of reciprocal_time::Hz), so this does actually
> matter.

FWIW pqs has both frequency and reciprocal time. reciprocal time was implemented
so that using an angle value_type would give units of radians per second for
example.

Anyway its clear I havent paid enough attention to the issue of these unit
member typedefs. All ideas welcome.

regards
Andy Little


Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk