|
|
@@ -1,16 +1,16 @@
|
|
|
<?xml version="1.0" encoding="UTF-8"?>
|
|
|
<!-- Reviewed: no -->
|
|
|
<sect1 id="zend.measure.types">
|
|
|
-
|
|
|
<title>Types of measurements</title>
|
|
|
|
|
|
<para>
|
|
|
- All supported measurement types are listed below, each with an example of the standard usage for such
|
|
|
- measurements.
|
|
|
+ All supported measurement types are listed below, each with an example of the standard usage
|
|
|
+ for such measurements.
|
|
|
</para>
|
|
|
|
|
|
<table id="zend.measure.types.table-1">
|
|
|
<title>List of measurement types</title>
|
|
|
+
|
|
|
<tgroup cols="4">
|
|
|
<thead>
|
|
|
<row>
|
|
|
@@ -20,288 +20,365 @@
|
|
|
<entry>Description</entry>
|
|
|
</row>
|
|
|
</thead>
|
|
|
+
|
|
|
<tbody>
|
|
|
<row>
|
|
|
<entry>Acceleration</entry>
|
|
|
<entry>Zend_Measure_Acceleration</entry>
|
|
|
- <entry>Meter per square second | <code>m/s²</code>
|
|
|
+ <entry>Meter per square second | <code>m/s²</code></entry>
|
|
|
+
|
|
|
+ <entry>
|
|
|
+ <classname>Zend_Measure_Acceleration</classname> covers the
|
|
|
+ physical factor of acceleration.
|
|
|
</entry>
|
|
|
- <entry><classname>Zend_Measure_Acceleration</classname> covers the
|
|
|
- physical factor of acceleration.
|
|
|
- </entry>
|
|
|
</row>
|
|
|
+
|
|
|
<row>
|
|
|
<entry>Angle</entry>
|
|
|
<entry>Zend_Measure_Angle</entry>
|
|
|
- <entry>Radiant | <code>rad</code>
|
|
|
+ <entry>Radiant | <code>rad</code></entry>
|
|
|
+
|
|
|
+ <entry>
|
|
|
+ <classname>Zend_Measure_Angle</classname> covers angular dimensions.
|
|
|
</entry>
|
|
|
- <entry><classname>Zend_Measure_Angle</classname> covers angular dimensions.</entry>
|
|
|
</row>
|
|
|
+
|
|
|
<row>
|
|
|
<entry>Area</entry>
|
|
|
<entry>Zend_Measure_Area</entry>
|
|
|
- <entry>Square meter | <code>m²</code>
|
|
|
- </entry>
|
|
|
+ <entry>Square meter | <code>m²</code></entry>
|
|
|
<entry><classname>Zend_Measure_Area</classname> covers square measures.</entry>
|
|
|
</row>
|
|
|
+
|
|
|
<row>
|
|
|
<entry>Binary</entry>
|
|
|
<entry>Zend_Measure_Binary</entry>
|
|
|
- <entry>Byte | <code>b</code>
|
|
|
+ <entry>Byte | <code>b</code></entry>
|
|
|
+
|
|
|
+ <entry>
|
|
|
+ <classname>Zend_Measure_Binary</classname> covers binary conversions.
|
|
|
</entry>
|
|
|
- <entry><classname>Zend_Measure_Binary</classname> covers binary conversions.</entry>
|
|
|
</row>
|
|
|
+
|
|
|
<row>
|
|
|
<entry>Capacitance</entry>
|
|
|
<entry>Zend_Measure_Capacitance</entry>
|
|
|
- <entry>Farad | <code>F</code>
|
|
|
+ <entry>Farad | <code>F</code></entry>
|
|
|
+
|
|
|
+ <entry>
|
|
|
+ <classname>Zend_Measure_Capacitance</classname> covers physical factor of
|
|
|
+ capacitance.
|
|
|
</entry>
|
|
|
- <entry><classname>Zend_Measure_Capacitance</classname> covers physical factor of capacitance.
|
|
|
- </entry>
|
|
|
</row>
|
|
|
+
|
|
|
<row>
|
|
|
<entry>Cooking volumes</entry>
|
|
|
<entry>Zend_Measure_Cooking_Volume</entry>
|
|
|
- <entry>Cubic meter | <code>m³</code>
|
|
|
+ <entry>Cubic meter | <code>m³</code></entry>
|
|
|
+
|
|
|
+ <entry>
|
|
|
+ <classname>Zend_Measure_Cooking_Volume</classname> covers volumes
|
|
|
+ which are used for cooking or written in cookbooks.
|
|
|
</entry>
|
|
|
- <entry><classname>Zend_Measure_Cooking_Volume</classname> covers volumes
|
|
|
- which are used for cooking or written in cookbooks.
|
|
|
- </entry>
|
|
|
</row>
|
|
|
+
|
|
|
<row>
|
|
|
<entry>Cooking weights</entry>
|
|
|
<entry>Zend_Measure_Cooking_Weight</entry>
|
|
|
- <entry>Gram | <code>g</code>
|
|
|
+ <entry>Gram | <code>g</code></entry>
|
|
|
+
|
|
|
+ <entry>
|
|
|
+ <classname>Zend_Measure_Cooking_Weight</classname> covers the weights
|
|
|
+ which are used for cooking or written in cookbooks.
|
|
|
</entry>
|
|
|
- <entry><classname>Zend_Measure_Cooking_Weight</classname> covers the weights
|
|
|
- which are used for cooking or written in cookbooks.
|
|
|
- </entry>
|
|
|
</row>
|
|
|
+
|
|
|
<row>
|
|
|
<entry>Current</entry>
|
|
|
<entry>Zend_Measure_Current</entry>
|
|
|
- <entry>Ampere | <code>A</code>
|
|
|
+ <entry>Ampere | <code>A</code></entry>
|
|
|
+
|
|
|
+ <entry>
|
|
|
+ <classname>Zend_Measure_Current</classname> covers the physical factor of
|
|
|
+ current.
|
|
|
</entry>
|
|
|
- <entry><classname>Zend_Measure_Current</classname> covers the physical factor of current.
|
|
|
- </entry>
|
|
|
</row>
|
|
|
+
|
|
|
<row>
|
|
|
<entry>Density</entry>
|
|
|
<entry>Zend_Measure_Density</entry>
|
|
|
- <entry>Kilogram per cubic meter | <code>kg/m³</code>
|
|
|
+ <entry>Kilogram per cubic meter | <code>kg/m³</code></entry>
|
|
|
+
|
|
|
+ <entry>
|
|
|
+ <classname>Zend_Measure_Density</classname> covers the physical factor of
|
|
|
+ density.
|
|
|
</entry>
|
|
|
- <entry><classname>Zend_Measure_Density</classname> covers the physical factor of density.
|
|
|
- </entry>
|
|
|
</row>
|
|
|
+
|
|
|
<row>
|
|
|
<entry>Energy</entry>
|
|
|
<entry>Zend_Measure_Energy</entry>
|
|
|
- <entry>Joule | <code>J</code>
|
|
|
+ <entry>Joule | <code>J</code></entry>
|
|
|
+
|
|
|
+ <entry>
|
|
|
+ <classname>Zend_Measure_Energy</classname> covers the physical factor of
|
|
|
+ energy.
|
|
|
</entry>
|
|
|
- <entry><classname>Zend_Measure_Energy</classname> covers the physical factor of energy.
|
|
|
- </entry>
|
|
|
</row>
|
|
|
+
|
|
|
<row>
|
|
|
<entry>Force</entry>
|
|
|
<entry>Zend_Measure_Force</entry>
|
|
|
- <entry>Newton | <code>N</code>
|
|
|
+ <entry>Newton | <code>N</code></entry>
|
|
|
+
|
|
|
+ <entry>
|
|
|
+ <classname>Zend_Measure_Force</classname> covers the physical factor of
|
|
|
+ force.
|
|
|
</entry>
|
|
|
- <entry><classname>Zend_Measure_Force</classname> covers the physical factor of force.
|
|
|
- </entry>
|
|
|
</row>
|
|
|
+
|
|
|
<row>
|
|
|
<entry>Flow (mass)</entry>
|
|
|
<entry>Zend_Measure_Flow_Mass</entry>
|
|
|
- <entry>Kilogram per second | <code>kg/s</code>
|
|
|
+ <entry>Kilogram per second | <code>kg/s</code></entry>
|
|
|
+
|
|
|
+ <entry>
|
|
|
+ <classname>Zend_Measure_Flow_Mass</classname> covers the physical factor of
|
|
|
+ flow rate. The weight of the flowing mass is used as reference point within
|
|
|
+ this class.
|
|
|
</entry>
|
|
|
- <entry><classname>Zend_Measure_Flow_Mass</classname> covers the physical factor of flow rate.
|
|
|
- The weight of the flowing mass is used as reference point within this class.
|
|
|
- </entry>
|
|
|
</row>
|
|
|
+
|
|
|
<row>
|
|
|
<entry>Flow (mole)</entry>
|
|
|
<entry>Zend_Measure_Flow_Mole</entry>
|
|
|
- <entry>Mole per second | <code>mol/s</code>
|
|
|
+ <entry>Mole per second | <code>mol/s</code></entry>
|
|
|
+
|
|
|
+ <entry>
|
|
|
+ <classname>Zend_Measure_Flow_Mole</classname> covers the physical factor of
|
|
|
+ flow rate. The density of the flowing mass is used as reference point within
|
|
|
+ this class.
|
|
|
</entry>
|
|
|
- <entry><classname>Zend_Measure_Flow_Mole</classname> covers the physical factor of flow rate.
|
|
|
- The density of the flowing mass is used as reference point within this class.
|
|
|
- </entry>
|
|
|
</row>
|
|
|
+
|
|
|
<row>
|
|
|
<entry>Flow (volume)</entry>
|
|
|
<entry>Zend_Measure_Flow_Volume</entry>
|
|
|
- <entry>Cubic meter per second | <code>m³/s</code>
|
|
|
+ <entry>Cubic meter per second | <code>m³/s</code></entry>
|
|
|
+
|
|
|
+ <entry>
|
|
|
+ <classname>Zend_Measure_Flow_Volume</classname> covers the physical factor
|
|
|
+ of flow rate. The volume of the flowing mass is used as reference point
|
|
|
+ within this class.
|
|
|
</entry>
|
|
|
- <entry><classname>Zend_Measure_Flow_Volume</classname> covers the physical factor of flow rate.
|
|
|
- The volume of the flowing mass is used as reference point within this class.
|
|
|
- </entry>
|
|
|
</row>
|
|
|
+
|
|
|
<row>
|
|
|
<entry>Frequency</entry>
|
|
|
<entry>Zend_Measure_Frequency</entry>
|
|
|
- <entry>Hertz | <code>Hz</code>
|
|
|
+ <entry>Hertz | <code>Hz</code></entry>
|
|
|
+
|
|
|
+ <entry>
|
|
|
+ <classname>Zend_Measure_Frequency</classname> covers the physical factor of
|
|
|
+ frequency.
|
|
|
</entry>
|
|
|
- <entry><classname>Zend_Measure_Frequency</classname> covers the physical factor of frequency.
|
|
|
- </entry>
|
|
|
</row>
|
|
|
+
|
|
|
<row>
|
|
|
<entry>Illumination</entry>
|
|
|
<entry>Zend_Measure_Illumination</entry>
|
|
|
- <entry>Lux | <code>lx</code>
|
|
|
+ <entry>Lux | <code>lx</code></entry>
|
|
|
+
|
|
|
+ <entry>
|
|
|
+ <classname>Zend_Measure_Illumination</classname> covers the physical factor
|
|
|
+ of light density.
|
|
|
</entry>
|
|
|
- <entry><classname>Zend_Measure_Illumination</classname> covers the physical factor of light density.
|
|
|
- </entry>
|
|
|
</row>
|
|
|
+
|
|
|
<row>
|
|
|
<entry>Length</entry>
|
|
|
<entry>Zend_Measure_Length</entry>
|
|
|
- <entry>Meter | <code>m</code>
|
|
|
+ <entry>Meter | <code>m</code></entry>
|
|
|
+
|
|
|
+ <entry>
|
|
|
+ <classname>Zend_Measure_Length</classname> covers the physical factor of
|
|
|
+ length.
|
|
|
</entry>
|
|
|
- <entry><classname>Zend_Measure_Length</classname> covers the physical factor of length.
|
|
|
- </entry>
|
|
|
</row>
|
|
|
+
|
|
|
<row>
|
|
|
<entry>Lightness</entry>
|
|
|
<entry>Zend_Measure_Lightness</entry>
|
|
|
- <entry>Candela per square meter | <code>cd/m²</code>
|
|
|
+ <entry>Candela per square meter | <code>cd/m²</code></entry>
|
|
|
+
|
|
|
+ <entry>
|
|
|
+ <classname>Zend_Measure_Ligntness</classname> covers the physical factor of
|
|
|
+ light energy.
|
|
|
</entry>
|
|
|
- <entry><classname>Zend_Measure_Ligntness</classname> covers the physical factor of light energy.
|
|
|
- </entry>
|
|
|
</row>
|
|
|
+
|
|
|
<row>
|
|
|
<entry>Number</entry>
|
|
|
<entry>Zend_Measure_Number</entry>
|
|
|
- <entry>Decimal | <code>(10)</code>
|
|
|
+ <entry>Decimal | <code>(10)</code></entry>
|
|
|
+
|
|
|
+ <entry>
|
|
|
+ <classname>Zend_Measure_Number</classname> converts between number formats.
|
|
|
</entry>
|
|
|
- <entry><classname>Zend_Measure_Number</classname> converts between number formats.
|
|
|
- </entry>
|
|
|
</row>
|
|
|
+
|
|
|
<row>
|
|
|
<entry>Power</entry>
|
|
|
<entry>Zend_Measure_Power</entry>
|
|
|
- <entry>Watt | <code>W</code>
|
|
|
+ <entry>Watt | <code>W</code></entry>
|
|
|
+
|
|
|
+ <entry>
|
|
|
+ <classname>Zend_Measure_Power</classname> covers the physical factor of
|
|
|
+ power.
|
|
|
</entry>
|
|
|
- <entry><classname>Zend_Measure_Power</classname> covers the physical factor of power.
|
|
|
- </entry>
|
|
|
</row>
|
|
|
+
|
|
|
<row>
|
|
|
<entry>Pressure</entry>
|
|
|
<entry>Zend_Measure_Pressure</entry>
|
|
|
- <entry>Newton per square meter | <code>N/m²</code>
|
|
|
+ <entry>Newton per square meter | <code>N/m²</code></entry>
|
|
|
+
|
|
|
+ <entry>
|
|
|
+ <classname>Zend_Measure_Pressure</classname> covers the physical factor of
|
|
|
+ pressure.
|
|
|
</entry>
|
|
|
- <entry><classname>Zend_Measure_Pressure</classname> covers the physical factor of pressure.
|
|
|
- </entry>
|
|
|
</row>
|
|
|
+
|
|
|
<row>
|
|
|
<entry>Speed</entry>
|
|
|
<entry>Zend_Measure_Speed</entry>
|
|
|
- <entry>Meter per second | <code>m/s</code>
|
|
|
+ <entry>Meter per second | <code>m/s</code></entry>
|
|
|
+
|
|
|
+ <entry>
|
|
|
+ <classname>Zend_Measure_Speed</classname> covers the physical factor of
|
|
|
+ speed.
|
|
|
</entry>
|
|
|
- <entry><classname>Zend_Measure_Speed</classname> covers the physical factor of speed.
|
|
|
- </entry>
|
|
|
</row>
|
|
|
+
|
|
|
<row>
|
|
|
<entry>Temperature</entry>
|
|
|
<entry>Zend_Measure_Temperature</entry>
|
|
|
- <entry>Kelvin | <code>K</code>
|
|
|
+ <entry>Kelvin | <code>K</code></entry>
|
|
|
+
|
|
|
+ <entry>
|
|
|
+ <classname>Zend_Measure_Temperature</classname> covers the physical factor
|
|
|
+ of temperature.
|
|
|
</entry>
|
|
|
- <entry><classname>Zend_Measure_Temperature</classname> covers the physical factor of temperature.
|
|
|
- </entry>
|
|
|
</row>
|
|
|
+
|
|
|
<row>
|
|
|
<entry>Time</entry>
|
|
|
<entry>Zend_Measure_Time</entry>
|
|
|
- <entry>Second | <code>s</code>
|
|
|
+ <entry>Second | <code>s</code></entry>
|
|
|
+
|
|
|
+ <entry>
|
|
|
+ <classname>Zend_Measure_Time</classname> covers the physical factor of time.
|
|
|
</entry>
|
|
|
- <entry><classname>Zend_Measure_Time</classname> covers the physical factor of time.
|
|
|
- </entry>
|
|
|
</row>
|
|
|
+
|
|
|
<row>
|
|
|
<entry>Torque</entry>
|
|
|
<entry>Zend_Measure_Torque</entry>
|
|
|
- <entry>Newton meter | <code>Nm</code>
|
|
|
+ <entry>Newton meter | <code>Nm</code></entry>
|
|
|
+
|
|
|
+ <entry>
|
|
|
+ <classname>Zend_Measure_Torque</classname> covers the physical factor of
|
|
|
+ torque.
|
|
|
</entry>
|
|
|
- <entry><classname>Zend_Measure_Torque</classname> covers the physical factor of torque.
|
|
|
- </entry>
|
|
|
</row>
|
|
|
+
|
|
|
<row>
|
|
|
<entry>Viscosity (dynamic)</entry>
|
|
|
<entry>Zend_Measure_Viscosity_Dynamic</entry>
|
|
|
- <entry>Kilogram per meter second | <code>kg/ms</code>
|
|
|
+ <entry>Kilogram per meter second | <code>kg/ms</code></entry>
|
|
|
+
|
|
|
+ <entry>
|
|
|
+ <classname>Zend_Measure_Viscosity_Dynamic</classname> covers the physical
|
|
|
+ factor of viscosity. The weight of the fluid is used as reference point
|
|
|
+ within this class.
|
|
|
</entry>
|
|
|
- <entry><classname>Zend_Measure_Viscosity_Dynamic</classname> covers the physical factor of viscosity.
|
|
|
- The weight of the fluid is used as reference point within this class.
|
|
|
- </entry>
|
|
|
</row>
|
|
|
+
|
|
|
<row>
|
|
|
<entry>Viscosity (kinematic)</entry>
|
|
|
<entry>Zend_Measure_Viscosity_Kinematic</entry>
|
|
|
- <entry>Square meter per second | <code>m²/s</code>
|
|
|
+ <entry>Square meter per second | <code>m²/s</code></entry>
|
|
|
+
|
|
|
+ <entry>
|
|
|
+ <classname>Zend_Measure_Viscosity_Kinematic</classname> covers the physical
|
|
|
+ factor of viscosity. The distance of the flown fluid is used as reference
|
|
|
+ point within this class.
|
|
|
</entry>
|
|
|
- <entry><classname>Zend_Measure_Viscosity_Kinematic</classname> covers the physical factor of viscosity.
|
|
|
- The distance of the flown fluid is used as reference point within this class.
|
|
|
- </entry>
|
|
|
</row>
|
|
|
+
|
|
|
<row>
|
|
|
<entry>Volume</entry>
|
|
|
<entry>Zend_Measure_Volume</entry>
|
|
|
- <entry>Cubic meter | <code>m³</code>
|
|
|
+ <entry>Cubic meter | <code>m³</code></entry>
|
|
|
+
|
|
|
+ <entry>
|
|
|
+ <classname>Zend_Measure_Volume</classname> covers the physical factor of
|
|
|
+ volume (content).
|
|
|
</entry>
|
|
|
- <entry><classname>Zend_Measure_Volume</classname> covers the physical factor of volume (content).
|
|
|
- </entry>
|
|
|
</row>
|
|
|
+
|
|
|
<row>
|
|
|
<entry>Weight</entry>
|
|
|
<entry>Zend_Measure_Weight</entry>
|
|
|
- <entry>Kilogram | <code>kg</code>
|
|
|
+ <entry>Kilogram | <code>kg</code></entry>
|
|
|
+
|
|
|
+ <entry>
|
|
|
+ <classname>Zend_Measure_Weight</classname> covers the physical factor of
|
|
|
+ weight.
|
|
|
</entry>
|
|
|
- <entry><classname>Zend_Measure_Weight</classname> covers the physical factor of weight.
|
|
|
- </entry>
|
|
|
</row>
|
|
|
</tbody>
|
|
|
</tgroup>
|
|
|
</table>
|
|
|
|
|
|
<sect2 id="zend.measure.types.binary">
|
|
|
-
|
|
|
<title>Hints for Zend_Measure_Binary</title>
|
|
|
|
|
|
<para>
|
|
|
- Some popular binary conventions, include terms like kilo-, mega-, giga, etc. in normal language use imply
|
|
|
- base 10, such as 1000 or 10³. However, in the binary format for computers these terms have to be seen for a
|
|
|
- conversion factor of 1024 instead of 1000. To preclude confusions a few years ago the notation BI was
|
|
|
- introduced. Instead of kilobyte, kibibyte for kilo-binary-byte should be used.
|
|
|
+ Some popular binary conventions, include terms like kilo-, mega-, giga, etc. in normal
|
|
|
+ language use imply base 10, such as 1000 or 10³. However, in the binary format for
|
|
|
+ computers these terms have to be seen for a conversion factor of 1024 instead of 1000.
|
|
|
+ To preclude confusions a few years ago the notation BI was introduced. Instead of
|
|
|
+ kilobyte, kibibyte for kilo-binary-byte should be used.
|
|
|
</para>
|
|
|
|
|
|
<para>
|
|
|
- In the class BINARY both notations can be found, such as <code>KILOBYTE = 1024 - binary conputer conversion
|
|
|
- KIBIBYTE = 1024 - new notation KILO_BINARY_BYTE = 1024 - new</code>, or the notation, long format
|
|
|
- <code>KILOBYTE_SI = 1000 - SI notation for kilo (1000)</code>. DVDs for example are marked with the
|
|
|
- SI-notation, but almost all harddisks are marked in computer binary notation.
|
|
|
+ In the class BINARY both notations can be found, such as <code>KILOBYTE = 1024 - binary
|
|
|
+ conputer conversion KIBIBYTE = 1024 - new notation KILO_BINARY_BYTE = 1024 - new</code>,
|
|
|
+ or the notation, long format
|
|
|
+ <code>KILOBYTE_SI = 1000 - SI notation for kilo (1000)</code>. DVDs for example are
|
|
|
+ marked with the SI-notation, but almost all harddisks are marked in computer binary notation.
|
|
|
</para>
|
|
|
-
|
|
|
</sect2>
|
|
|
|
|
|
<sect2 id="zend.measure.types.decimal">
|
|
|
-
|
|
|
<title>Hints for Zend_Measure_Number</title>
|
|
|
|
|
|
<para>
|
|
|
- The best known number format is the decimal system. Additionally this class supports the octal system, the
|
|
|
- hexadecimal system, the binary system, the roman number system and some other less popular systems. Note
|
|
|
- that only the decimal part of numbers is handled. Any fractional part will be stripped.
|
|
|
+ The best known number format is the decimal system. Additionally this class supports the
|
|
|
+ octal system, the hexadecimal system, the binary system, the roman number system and
|
|
|
+ some other less popular systems. Note that only the decimal part of numbers is handled.
|
|
|
+ Any fractional part will be stripped.
|
|
|
</para>
|
|
|
-
|
|
|
</sect2>
|
|
|
|
|
|
<sect2 id="zend.measure.types.roman">
|
|
|
-
|
|
|
<title>Roman numbers</title>
|
|
|
|
|
|
<para>
|
|
|
- For the roman number system digits greater 4000 are supported. In reality these digits are shown with a
|
|
|
- crossbeam on top of the digit. As the crossbeam can not be shown within the computer, an underline has to be
|
|
|
- used instead of it.
|
|
|
+ For the roman number system digits greater 4000 are supported. In reality these digits
|
|
|
+ are shown with a crossbeam on top of the digit. As the crossbeam can not be shown within
|
|
|
+ the computer, an underline has to be used instead of it.
|
|
|
</para>
|
|
|
|
|
|
<programlisting language="php"><![CDATA[
|
|
|
@@ -312,9 +389,7 @@ $unit = new Zend_Measure_Number($great,Zend_Measure_Number::ROMAN, $locale);
|
|
|
// convert to the decimal system
|
|
|
echo $unit->convertTo(Zend_Measure_Number::DECIMAL);
|
|
|
]]></programlisting>
|
|
|
-
|
|
|
</sect2>
|
|
|
-
|
|
|
</sect1>
|
|
|
<!--
|
|
|
vim:se ts=4 sw=4 et:
|