@@ -260,23 +260,23 @@ public static class NpM
260260 /// <summary>
261261 /// Resistance conversions from and to Newtons/metre/sec
262262 /// </summary>
263- public static class NpMpS
263+ public static class NSpM
264264 {
265265 /// <summary>Convert from pounds per mph to newtons per meter per second</summary>
266- public static float FromLbpMpH ( float lbfPerMpH ) { return lbfPerMpH * 9.9503884f ; }
266+ public static float FromLbfpMpH ( float lbfPerMpH ) { return lbfPerMpH * 9.9503884f ; }
267267 /// <summary>Convert from newtons per meter per second to pounds per mph</summary>
268- public static float ToLbpMpH ( float nPerMpS ) { return nPerMpS / 9.9503884f ; }
268+ public static float ToLbfpMpH ( float nPerMpS ) { return nPerMpS / 9.9503884f ; }
269269 }
270270
271271 /// <summary>
272272 /// Resistance conversions from and to Newtons/metre^2/sec^2
273273 /// </summary>
274- public static class NpMpS2
274+ public static class NSSpMM
275275 {
276276 /// <summary>Convert from pounds per mph^2 to newtons per mps^2</summary>
277- public static float FromLbpMpH2 ( float lbfPerMpH2 ) { return lbfPerMpH2 * 22.2583849f ; }
277+ public static float FromLbfpMpH2 ( float lbfPerMpH2 ) { return lbfPerMpH2 * 22.2583849f ; }
278278 /// <summary>Convert from newtons per mps^2 to pounds per mph^2</summary>
279- public static float ToLbpMpH2 ( float nPerMpS2 ) { return nPerMpS2 / 22.2583849f ; }
279+ public static float ToLbfpMpH2 ( float nPerMpS2 ) { return nPerMpS2 / 22.2583849f ; }
280280 }
281281
282282 /// <summary>
@@ -591,8 +591,12 @@ public static class FormatStrings
591591 public static string f = Catalog . GetString ( "°F" ) ;
592592 public static string n = Catalog . GetString ( "N" ) ;
593593 public static string kN = Catalog . GetString ( "kN" ) ;
594+ public static string nspm = Catalog . GetString ( "N/m/s" ) ;
595+ public static string nsspmm = Catalog . GetString ( "N/(m/s)²" ) ;
594596 public static string lbf = Catalog . GetString ( "lbf" ) ;
595597 public static string klbf = Catalog . GetString ( "klbf" ) ;
598+ public static string lbfpmph = Catalog . GetString ( "lbf/mph" ) ;
599+ public static string lbfpmph2 = Catalog . GetString ( "lbf/mph²" ) ;
596600 public static string deg = Catalog . GetString ( "°" ) ;
597601
598602 /// <summary>
@@ -797,6 +801,18 @@ public static string FormatForce(float forceN, bool isMetric)
797801 return String . Format ( CultureInfo . CurrentCulture , kilo ? "{0:F1} {1}" : "{0:F0} {1}" , force , unit ) ;
798802 }
799803
804+ public static string FormatLinearResistance ( float resistanceNSpM , bool isMetric )
805+ {
806+ var resistance = isMetric ? resistanceNSpM : NSpM . ToLbfpMpH ( resistanceNSpM ) ;
807+ return String . Format ( CultureInfo . CurrentCulture , isMetric ? "{0:F1} {1}" : "{0:F2} {2}" , resistance , nspm , lbfpmph ) ;
808+ }
809+
810+ public static string FormatQuadraticResistance ( float resistanceNSSpMM , bool isMetric )
811+ {
812+ var resistance = isMetric ? resistanceNSSpMM : NSSpMM . ToLbfpMpH2 ( resistanceNSSpMM ) ;
813+ return String . Format ( CultureInfo . CurrentCulture , isMetric ? "{0:F3} {1}" : "{0:F4} {2}" , resistance , nsspmm , lbfpmph2 ) ;
814+ }
815+
800816 public static string FormatTemperature ( float temperatureC , bool isMetric , bool isDelta )
801817 {
802818 var temperature = isMetric ? temperatureC : isDelta ? C . ToDeltaF ( temperatureC ) : C . ToF ( temperatureC ) ;
0 commit comments