[#mp_units-quantity-01]
= xref:mp_units.adoc[mp&lowbar;units]::quantity
:relfileprefix: ../
:mrdocs:

A quantity

== Synopsis

Declared in `&lt;mp&hyphen;units&sol;framework&sol;quantity&period;h&gt;`

[source,cpp,subs="verbatim,replacements,macros,-callouts"]
----
template&lt;
    xref:mp_units/Reference.adoc[Reference] auto R,
    xref:mp_units/RepresentationOf.adoc[RepresentationOf&lt;get&lowbar;quantity&lowbar;spec(R)&gt;] Rep&gt;
class quantity;
----

== Types

[cols=1]
|===
| Name
| xref:mp_units/quantity-01/rep.adoc[`rep`] 
|===

== Member Functions

[cols=2]
|===
| Name
| Description
| xref:mp_units/quantity-01/2constructor-06a.adoc[`quantity`]         [.small]#[constructor]#
| Constructors
| xref:mp_units/quantity-01/2destructor.adoc[`&#126;quantity`] [.small]#[destructor]#
| Destructor
| xref:mp_units/quantity-01/operator_assign-0ed.adoc[`operator&equals;`] 
| Assignment operators
| xref:mp_units/quantity-01/force_in-02.adoc[`force&lowbar;in`] 
| 
| xref:mp_units/quantity-01/force_numerical_value_in.adoc[`force&lowbar;numerical&lowbar;value&lowbar;in`] 
| 
| xref:mp_units/quantity-01/in-08.adoc[`in`] 
| 
| xref:mp_units/quantity-01/numerical_value_in.adoc[`numerical&lowbar;value&lowbar;in`] 
| 
| xref:mp_units/quantity-01/numerical_value_ref_in-0d.adoc[`numerical&lowbar;value&lowbar;ref&lowbar;in`] 
| 
| xref:mp_units/quantity-01/operator_mod_eq.adoc[`operator%&equals;`] 
| Modulus assignment operator
| xref:mp_units/quantity-01/operator_star_eq-01.adoc[`operator&ast;&equals;`] 
| Multiplication assignment operators
| xref:mp_units/quantity-01/operator_plus.adoc[`operator&plus;`] 
| 
| xref:mp_units/quantity-01/operator_inc-0e.adoc[`operator&plus;&plus;`] 
| Increment operators
| xref:mp_units/quantity-01/operator_plus_eq.adoc[`operator&plus;&equals;`] 
| Addition assignment operator
| xref:mp_units/quantity-01/operator_minus.adoc[`operator&hyphen;`] 
| 
| xref:mp_units/quantity-01/operator_dec-07.adoc[`operator&hyphen;&hyphen;`] 
| Decrement operators
| xref:mp_units/quantity-01/operator_minus_eq.adoc[`operator&hyphen;&equals;`] 
| Subtraction assignment operator
| xref:mp_units/quantity-01/operator_slash_eq-04.adoc[`operator&sol;&equals;`] 
| Division assignment operators
| xref:mp_units/quantity-01/2conversion-0a.adoc[`operator `] 
| Conversion operators
|===

== Static Member Functions

[cols=1]
|===
| Name
| xref:mp_units/quantity-01/max.adoc[`max`] 
| xref:mp_units/quantity-01/min.adoc[`min`] 
| xref:mp_units/quantity-01/zero.adoc[`zero`] 
|===

== Data Members

[cols=2]
|===
| Name
| Description
| xref:mp_units/quantity-01/numerical_value_is_an_implementation_detail_.adoc[`numerical&lowbar;value&lowbar;is&lowbar;an&lowbar;implementation&lowbar;detail&lowbar;`] 
| needs to be public for a structural type
|===

== Static Data Members

[cols=1]
|===
| Name
| xref:mp_units/quantity-01/dimension.adoc[`dimension`] 
| xref:mp_units/quantity-01/quantity_spec.adoc[`quantity&lowbar;spec`] 
| xref:mp_units/quantity-01/reference.adoc[`reference`] 
| xref:mp_units/quantity-01/unit.adoc[`unit`] 
|===

== Friends

[cols=2]
|===
| Name
| Description
| `xref:mp_units/operator_3way-01.adoc[mp&lowbar;units::operator&lt;&equals;&gt;]`
| Three&hyphen;way comparison operator
| `xref:mp_units/operator_3way-07.adoc[mp&lowbar;units::operator&lt;&equals;&gt;]`
| Three&hyphen;way comparison operator
| `xref:mp_units/operator_eq-010.adoc[mp&lowbar;units::operator&equals;&equals;]`
| Equality operator
| `xref:mp_units/operator_eq-09.adoc[mp&lowbar;units::operator&equals;&equals;]`
| Equality operator
| `xref:mp_units/operator_slash-0ad.adoc[mp&lowbar;units::operator&sol;]`
| 
| `xref:mp_units/operator_slash-09.adoc[mp&lowbar;units::operator&sol;]`
| 
| `xref:mp_units/operator_slash-05.adoc[mp&lowbar;units::operator&sol;]`
| 
| `xref:mp_units/operator_star-03.adoc[mp&lowbar;units::operator&ast;]`
| 
| `xref:mp_units/operator_star-002.adoc[mp&lowbar;units::operator&ast;]`
| 
| `xref:mp_units/operator_star-08dc.adoc[mp&lowbar;units::operator&ast;]`
| 
| `xref:mp_units/operator_mod-0d.adoc[mp&lowbar;units::operator%]`
| 
| `xref:mp_units/operator_mod-09.adoc[mp&lowbar;units::operator%]`
| 
| `xref:mp_units/operator_mod-05.adoc[mp&lowbar;units::operator%]`
| 
| `xref:mp_units/operator_minus-079.adoc[mp&lowbar;units::operator&hyphen;]`
| 
| `xref:mp_units/operator_minus-0a.adoc[mp&lowbar;units::operator&hyphen;]`
| 
| `xref:mp_units/operator_minus-03.adoc[mp&lowbar;units::operator&hyphen;]`
| 
| `xref:mp_units/operator_plus-0b.adoc[mp&lowbar;units::operator&plus;]`
| 
| `xref:mp_units/operator_plus-0f.adoc[mp&lowbar;units::operator&plus;]`
| 
| `xref:mp_units/operator_plus-06d.adoc[mp&lowbar;units::operator&plus;]`
| 
|===

== Non-Member Functions

[cols=2]
|===
| Name
| Description
| xref:mp_units/abs.adoc[`abs`]
| Computes the absolute value of a quantity
| xref:mp_units/cbrt-0d.adoc[`cbrt`]
| Computes the cubic root of a quantity
| xref:mp_units/ceil.adoc[`ceil`]
| Computes the smallest quantity with integer representation and unit type To with its number not less than q
| xref:mp_units/epsilon.adoc[`epsilon`]
| Returns the epsilon of the quantity
| xref:mp_units/exp.adoc[`exp`]
| Computes Euler&apos;s raised to the given power
| xref:mp_units/floor.adoc[`floor`]
| Computes the largest quantity with integer representation and unit type To with its number not greater than q
| xref:mp_units/fma-09.adoc[`fma`]
| Computes the fma of 3 quantities
| xref:mp_units/fma-0a.adoc[`fma`]
| Computes the fma of 2 quantities and a quantity point
| xref:mp_units/fmod.adoc[`fmod`]
| Computes the floating&hyphen;point remainder of the division operation x &sol; y&period;
| xref:mp_units/hypot-08.adoc[`hypot`]
| Computes the square root of the sum of the squares of x, y, and z, without undue overflow or underflow at intermediate stages of the computation
| xref:mp_units/hypot-0e.adoc[`hypot`]
| Computes the square root of the sum of the squares of x and y, without undue overflow or underflow at intermediate stages of the computation
| xref:mp_units/inverse-09.adoc[`inverse`]
| Computes the inverse of a quantity in a provided unit
| xref:mp_units/isfinite-0d.adoc[`isfinite`]
| Determines if a quantity is finite&period;
| xref:mp_units/isinf-0f.adoc[`isinf`]
| Determines if a quantity is infinite&period;
| xref:mp_units/isnan-00.adoc[`isnan`]
| Determines if a quantity is a nan&period;
| xref:mp_units/operator_star-07.adoc[`operator&ast;`]
| Multiplication operator
| xref:mp_units/pow-05.adoc[`pow`]
| Computes the value of a quantity raised to the `Num&sol;Den` power
| xref:mp_units/remainder.adoc[`remainder`]
| Computes the IEEE remainder of the floating point division operation x &sol; y&period;
| xref:mp_units/round.adoc[`round`]
| Computes the nearest quantity with integer representation and unit type `To` to `q`
| xref:mp_units/sqrt-0b.adoc[`sqrt`]
| Computes the square root of a quantity
| xref:mp_units/value_cast-0e.adoc[`value&lowbar;cast`]
| Explicit cast of a quantity&apos;s representation type
|===

== Description

Property of a phenomenon, body, or substance, where the property has a magnitude that can be expressed by means of a number and a reference&period;

== Template Parameters

[cols=2]
|===
| Name
| Description
| *R*
| a reference of the quantity providing all information about quantity properties
| *Rep*
| a type to be used to represent values of a quantity
|===


[.small]#Created with https://www.mrdocs.com[MrDocs]#
