@@ -260,23 +260,23 @@ public static class NpM
260
260
/// <summary>
261
261
/// Resistance conversions from and to Newtons/metre/sec
262
262
/// </summary>
263
- public static class NpMpS
263
+ public static class NSpM
264
264
{
265
265
/// <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 ; }
267
267
/// <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 ; }
269
269
}
270
270
271
271
/// <summary>
272
272
/// Resistance conversions from and to Newtons/metre^2/sec^2
273
273
/// </summary>
274
- public static class NpMpS2
274
+ public static class NSSpMM
275
275
{
276
276
/// <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 ; }
278
278
/// <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 ; }
280
280
}
281
281
282
282
/// <summary>
@@ -591,8 +591,12 @@ public static class FormatStrings
591
591
public static string f = Catalog . GetString ( "°F" ) ;
592
592
public static string n = Catalog . GetString ( "N" ) ;
593
593
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)²" ) ;
594
596
public static string lbf = Catalog . GetString ( "lbf" ) ;
595
597
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²" ) ;
596
600
public static string deg = Catalog . GetString ( "°" ) ;
597
601
598
602
/// <summary>
@@ -804,6 +808,18 @@ public static string FormatLargeForce(float forceN, bool isMetric)
804
808
return String . Format ( CultureInfo . CurrentCulture , "{0:F1} {1}" , force * 1e-3f , unit ) ;
805
809
}
806
810
811
+ public static string FormatLinearResistance ( float resistanceNSpM , bool isMetric )
812
+ {
813
+ var resistance = isMetric ? resistanceNSpM : NSpM . ToLbfpMpH ( resistanceNSpM ) ;
814
+ return String . Format ( CultureInfo . CurrentCulture , isMetric ? "{0:F1} {1}" : "{0:F2} {2}" , resistance , nspm , lbfpmph ) ;
815
+ }
816
+
817
+ public static string FormatQuadraticResistance ( float resistanceNSSpMM , bool isMetric )
818
+ {
819
+ var resistance = isMetric ? resistanceNSSpMM : NSSpMM . ToLbfpMpH2 ( resistanceNSSpMM ) ;
820
+ return String . Format ( CultureInfo . CurrentCulture , isMetric ? "{0:F3} {1}" : "{0:F4} {2}" , resistance , nsspmm , lbfpmph2 ) ;
821
+ }
822
+
807
823
public static string FormatTemperature ( float temperatureC , bool isMetric , bool isDelta )
808
824
{
809
825
var temperature = isMetric ? temperatureC : isDelta ? C . ToDeltaF ( temperatureC ) : C . ToF ( temperatureC ) ;
0 commit comments