00001
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026 #ifndef _ElectricCurrent_h
00027 #define _ElectricCurrent_h
00028
00029
00030 #include "Quantity/Variable.h"
00031 #include "Quantity/Constant.h"
00032 #include "Quantity/QuantityCluster.h"
00033
00034 namespace quantity {
00035 namespace electricCurrent {
00036
00038 class Class;
00039
00041 class Unit;
00042
00043
00044 class AmpereUnits;
00045 class GauUnit;
00046 class BiotUnit;
00047 class AtomicUnit;
00048
00050 typedef unit::Prefixable<Unit, AmpereUnits> Amperes;
00051
00053 typedef unit::Prefixed<Amperes> Ampere;
00054
00056 typedef unit::Prefixed<Amperes, unit::Milli> MilliAmpere;
00057
00059 typedef unit::Prefixed<Amperes, unit::Micro> MicroAmpere;
00060
00062 typedef unit::NonPrefixable<Unit, GauUnit> Gau;
00063
00065 typedef unit::NonPrefixable<Unit, BiotUnit> Biot;
00066
00068 typedef unit::NonPrefixable<Unit, AtomicUnit> Atomic;
00069
00071 typedef Loki::TL::Append<Amperes::Units,
00072 LOKI_TYPELIST_3(Gau, Biot, Atomic)>::Result Units;
00073
00074
00075
00076 typedef Quantity<Class> Quantity;
00077
00078 class DerivedElectricCurrent;
00079
00080 }
00081
00083
00085 template<typename ST>
00086 struct Standard<electricCurrent::Amperes, ST>
00087 {
00088 static const ST ratio;
00089 static const bool exact;
00090 };
00091
00093 template<typename ST> const ST Standard<electricCurrent::Amperes, ST>::ratio = 1.0;
00094
00096 template<typename ST> const bool Standard<electricCurrent::Amperes, ST>::exact = true;
00097
00099
00101 template<typename ST>
00102 struct Standard<electricCurrent::Gau, ST>
00103 {
00104 static const ST ratio;
00105 static const bool exact;
00106 };
00107
00109 template<typename ST> const ST Standard<electricCurrent::Gau, ST>::ratio = 3.33564e-10;
00110
00112 template<typename ST> const bool Standard<electricCurrent::Gau, ST>::exact = false;
00113
00115
00117 template<typename ST>
00118 struct Standard<electricCurrent::Biot, ST>
00119 {
00120 static const ST ratio;
00121 static const bool exact;
00122 };
00123
00125 template<typename ST> const ST Standard<electricCurrent::Biot, ST>::ratio = 10.0;
00126
00128 template<typename ST> const bool Standard<electricCurrent::Biot, ST>::exact = true;
00129
00131
00133 template<typename ST>
00134 struct Standard<electricCurrent::Atomic, ST>
00135 {
00136 static const ST ratio;
00137 static const bool exact;
00138 };
00139
00141 template<typename ST> const ST Standard<electricCurrent::Atomic, ST>::ratio = 6.62362e-3;
00142
00144 template<typename ST> const bool Standard<electricCurrent::Atomic, ST>::exact = false;
00145
00147 template<>
00148 struct QuantityTraits<electricCurrent::Class>
00149 {
00150 typedef
00151 dimension::Dimension<BSUtilities::Rational<0>,
00152 BSUtilities::Rational<0>, BSUtilities::Rational<0>,
00153 BSUtilities::Rational<1>, BSUtilities::Rational<0>,
00154 BSUtilities::Rational<0>, BSUtilities::Rational<0> > Dimension;
00155 typedef electricCurrent::Unit UnitType;
00156 typedef electricCurrent::Units UnitList;
00157 typedef electricCurrent::Ampere DefaultUnit;
00158
00159 typedef electricCurrent::DerivedElectricCurrent DefaultDerivedQuantityType;
00160
00161 static const std::string NameString;
00162 static const std::string SymbolString;
00163
00164 };
00165
00166
00167 template<>
00168 struct DerivedQuantityTraits<electricCurrent::Class, electricCurrent::DerivedElectricCurrent>
00169 {
00170 static const bool OverwriteName = false;
00171 static const bool OverwriteSymbol = false;
00172
00173 static const std::string NameString;
00174 static const std::string SymbolString;
00175
00176 };
00177
00179 typedef Variable<electricCurrent::Quantity> ElectricCurrent;
00180
00182 typedef Constant<electricCurrent::Quantity> ElectricCurrentConstant;
00183
00185 typedef QuantityVector<Variable, electricCurrent::Quantity>
00186 ElectricCurrentVector;
00187
00188 }
00189
00190 #endif