|
From: <de...@us...> - 2003-06-10 23:42:43
|
Update of /cvsroot/csp/APPLICATIONS/SimData/Include/SimData
In directory sc8-pr-cvs1:/tmp/cvs-serv7866
Modified Files:
Math.h Conversions.h
Log Message:
no message
Index: Math.h
===================================================================
RCS file: /cvsroot/csp/APPLICATIONS/SimData/Include/SimData/Math.h,v
retrieving revision 1.5
retrieving revision 1.6
diff -C2 -d -r1.5 -r1.6
*** Math.h 10 Jun 2003 22:31:00 -0000 1.5
--- Math.h 10 Jun 2003 23:42:39 -0000 1.6
***************
*** 52,78 ****
- double const FtInM = 0.3048;
- double const MInFt = 3.2808;
-
- inline double FeetToMeters(double feet) {
- return FtInM * feet;
- }
-
- inline double MetersToFeet(double meters) {
- return MInFt * meters;
- }
-
- double const PdsToN = 4.44822;
-
- double const NToPds = 0.22481;
-
- inline double PoundsToNewtons(double pds) {
- return PdsToN * pds;
- }
-
- inline double NewtonsToPounds(double newtonw) {
- return NToPds * newtonw;
- }
-
NAMESPACE_END // namespace simdata
--- 52,55 ----
Index: Conversions.h
===================================================================
RCS file: /cvsroot/csp/APPLICATIONS/SimData/Include/SimData/Conversions.h,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -d -r1.2 -r1.3
*** Conversions.h 12 Apr 2003 08:56:37 -0000 1.2
--- Conversions.h 10 Jun 2003 23:42:40 -0000 1.3
***************
*** 123,126 ****
--- 123,139 ----
SIMDATA_CVT(mmhg_pa)
+ /**
+ * pounds to newtons
+ */
+ template <typename T>
+ T lb_n(T x) { return x * 4.44822; }
+ SIMDATA_CVT(lb_n)
+
+ /**
+ * newtons to pounds
+ */
+ template <typename T>
+ T n_lb(T x) { return x * 0.22481; }
+ SIMDATA_CVT(n_lb)
} // namespace convert
|