BPU

A rational (usually integral) power of a single basis unit

Context

_images/ditaa-7e93663a62d3e6f5a75b008c04ff95ad0895c4eb.png

Introduction

#include <xo/unit/bpu.hpp>

A xo::qty::bpu (aka “basis power unit”) represents a rational (usually integer) power of a Basis Unit.

For example:

object mm3<<bpu>>
mm3 : native_dim = dim::distance
mm3 : scalefactor = 1/1000
mm3 : power = 3/1

representation for cubic millimeters

object vol<<bpu>>
vol : native_dim = dim::time
vol : scalefactor = 365*24*3600
vol : power = -1/2

representation for annual (365-day) volatility

bpu is intended as an implementation-level abstraction. Application code will normally interact with the more-general scaled_unit instead of bpu.

Class

template<typename Int>
class bpu

represent product of a compile-time scale-factor with a rational power of a native unit

Member Variables

Warning

doxygengroup: Cannot find group “bpu-instance-vars” in doxygen xml output for project “xodoxxml” from directory: /home/roland/proj/xo/xo-unit/.build-ccov/docs/dox/xml

Constructors

Warning

doxygengroup: Cannot find group “bpu-ctors” in doxygen xml output for project “xodoxxml” from directory: /home/roland/proj/xo/xo-unit/.build-ccov/docs/dox/xml

Access Methods

Warning

doxygengroup: Cannot find group “bpu-access-methods” in doxygen xml output for project “xodoxxml” from directory: /home/roland/proj/xo/xo-unit/.build-ccov/docs/dox/xml

Other Methods

Warning

doxygengroup: Cannot find group “bpu-methods” in doxygen xml output for project “xodoxxml” from directory: /home/roland/proj/xo/xo-unit/.build-ccov/docs/dox/xml

Comparison

Warning

doxygengroup: Cannot find group “bpu-comparison” in doxygen xml output for project “xodoxxml” from directory: /home/roland/proj/xo/xo-unit/.build-ccov/docs/dox/xml

Details

Warning

doxygengroup: Cannot find group “bpu-abbrev-helpers” in doxygen xml output for project “xodoxxml” from directory: /home/roland/proj/xo/xo-unit/.build-ccov/docs/dox/xml