diff --git a/CodeGen/Generators/UnitsNetGen/NumberExtensionsTestClassGenerator.cs b/CodeGen/Generators/UnitsNetGen/NumberExtensionsTestClassGenerator.cs
index d272d23ebc..b5cced30fd 100644
--- a/CodeGen/Generators/UnitsNetGen/NumberExtensionsTestClassGenerator.cs
+++ b/CodeGen/Generators/UnitsNetGen/NumberExtensionsTestClassGenerator.cs
@@ -38,8 +38,6 @@ public class NumberTo{_quantityName}ExtensionsTests
Writer.WL(2, $@"
[Fact]");
- Writer.WLIfText(2, GetObsoleteAttributeOrNull(unit.ObsoleteText));
-
Writer.WL(2, $@"public void NumberTo{unit.PluralName}Test() =>
Assert.Equal({_quantityName}.From{unit.PluralName}(2), 2.{unit.PluralName}());
");
@@ -49,10 +47,5 @@ public class NumberTo{_quantityName}ExtensionsTests
}");
return Writer.ToString();
}
-
- private static string? GetObsoleteAttributeOrNull(string? obsoleteText) =>
- string.IsNullOrWhiteSpace(obsoleteText) ?
- null :
- $"[Obsolete(\"{obsoleteText}\")]";
}
}
diff --git a/Common/UnitDefinitions/HeatTransferCoefficient.json b/Common/UnitDefinitions/HeatTransferCoefficient.json
index 4e6e82abd1..75db786ba7 100644
--- a/Common/UnitDefinitions/HeatTransferCoefficient.json
+++ b/Common/UnitDefinitions/HeatTransferCoefficient.json
@@ -35,12 +35,38 @@
{
"SingularName": "BtuPerSquareFootDegreeFahrenheit",
"PluralName": "BtusPerSquareFootDegreeFahrenheit",
+ "ObsoleteText": "The name of this definition incorrectly omitted time as divisor, please use BtuPerHourSquareFootDegreeFahrenheit instead",
"FromUnitToBaseFunc": "{x} * 5.6782633411134878",
"FromBaseToUnitFunc": "{x} / 5.6782633411134878",
"Localization": [
{
"Culture": "en-US",
- "Abbreviations": [ "Btu/ft²·hr·°F" ]
+ "Abbreviations": [ "Btu/ft²·°F" ]
+ }
+ ]
+ },
+ {
+ "SingularName": "BtuPerHourSquareFootDegreeFahrenheit",
+ "PluralName": "BtusPerHourSquareFootDegreeFahrenheit",
+ "FromUnitToBaseFunc": "{x} * 5.6782633411134878",
+ "FromBaseToUnitFunc": "{x} / 5.6782633411134878",
+ "Localization": [
+ {
+ "Culture": "en-US",
+ "Abbreviations": [ "Btu/h·ft²·°F", "Btu/ft²·h·°F", "Btu/hr·ft²·°F", "Btu/ft²·hr·°F" ]
+ }
+ ]
+ },
+ {
+ "SingularName": "CaloriePerHourSquareMeterDegreeCelsius",
+ "PluralName": "CaloriesPerHourSquareMeterDegreeCelsius",
+ "Prefixes": [ "Kilo" ],
+ "FromUnitToBaseFunc": "({x} * 4.1868) / 3600",
+ "FromBaseToUnitFunc": "({x} / 4.1868) * 3600",
+ "Localization": [
+ {
+ "Culture": "en-US",
+ "Abbreviations": [ "kcal/h·m²·°C", "kcal/m²·h·°C", "kcal/hr·m²·°C", "kcal/m²·hr·°C" ]
}
]
}
diff --git a/Common/UnitDefinitions/MolarFlow.json b/Common/UnitDefinitions/MolarFlow.json
new file mode 100644
index 0000000000..e9d90d51e4
--- /dev/null
+++ b/Common/UnitDefinitions/MolarFlow.json
@@ -0,0 +1,110 @@
+{
+ "Name": "MolarFlow",
+ "BaseUnit": "MolePerSecond",
+ "XmlDocSummary": "Molar flow is the ratio of the amount of substance change to the time during which the change occurred (value of amount of substance changes per unit time).",
+ "BaseDimensions": {
+ "N": 1,
+ "T": -1
+ },
+ "Units": [
+ {
+ "SingularName": "MolePerSecond",
+ "PluralName": "MolesPerSecond",
+ "BaseUnits": {
+ "N": "Mole",
+ "T": "Second"
+ },
+ "Prefixes": [ "Kilo" ],
+ "FromUnitToBaseFunc": "{x}",
+ "FromBaseToUnitFunc": "{x}",
+ "Localization": [
+ {
+ "Culture": "en-US",
+ "Abbreviations": [ "mol/s" ]
+ }
+ ]
+ },
+ {
+ "SingularName": "MolePerMinute",
+ "PluralName": "MolesPerMinute",
+ "BaseUnits": {
+ "N": "Mole",
+ "T": "Minute"
+ },
+ "Prefixes": [ "Kilo" ],
+ "FromUnitToBaseFunc": "{x} / 60",
+ "FromBaseToUnitFunc": "{x} * 60",
+ "Localization": [
+ {
+ "Culture": "en-US",
+ "Abbreviations": [ "mol/min" ]
+ }
+ ]
+ },
+ {
+ "SingularName": "MolePerHour",
+ "PluralName": "MolesPerHour",
+ "BaseUnits": {
+ "N": "Mole",
+ "T": "Hour"
+ },
+ "Prefixes": [ "Kilo" ],
+ "FromUnitToBaseFunc": "{x} / 3600",
+ "FromBaseToUnitFunc": "{x} * 3600",
+ "Localization": [
+ {
+ "Culture": "en-US",
+ "Abbreviations": [ "kmol/h" ]
+ }
+ ]
+ },
+ {
+ "SingularName": "PoundMolePerSecond",
+ "PluralName": "PoundMolesPerSecond",
+ "BaseUnits": {
+ "N": "PoundMole",
+ "T": "Second"
+ },
+ "FromUnitToBaseFunc": "{x} * 453.59237",
+ "FromBaseToUnitFunc": "{x} / 453.59237",
+ "Localization": [
+ {
+ "Culture": "en-US",
+ "Abbreviations": [ "lbmol/s" ]
+ }
+ ]
+ },
+ {
+ "SingularName": "PoundMolePerMinute",
+ "PluralName": "PoundMolesPerMinute",
+ "BaseUnits": {
+ "N": "PoundMole",
+ "T": "Minute"
+ },
+ "FromUnitToBaseFunc": "({x} * 453.59237) / 60",
+ "FromBaseToUnitFunc": "({x} / 453.59237) * 60",
+ "Localization": [
+ {
+ "Culture": "en-US",
+ "Abbreviations": [ "lbmol/min" ]
+ }
+ ]
+ },
+ {
+ "SingularName": "PoundMolePerHour",
+ "PluralName": "PoundMolesPerHour",
+ "BaseUnits": {
+ "N": "PoundMole",
+ "T": "Hour"
+ },
+ "FromUnitToBaseFunc": "({x} * 453.59237) / 3600",
+ "FromBaseToUnitFunc": "({x} / 453.59237) * 3600",
+ "Localization": [
+ {
+ "Culture": "en-US",
+ "Abbreviations": [ "lbmol/h" ]
+ }
+ ]
+ }
+ ]
+}
diff --git a/Common/UnitDefinitions/MolarMass.json b/Common/UnitDefinitions/MolarMass.json
index 49c31aae60..36401297c6 100644
--- a/Common/UnitDefinitions/MolarMass.json
+++ b/Common/UnitDefinitions/MolarMass.json
@@ -24,6 +24,18 @@
}
]
},
+ {
+ "SingularName": "KilogramPerKilomole",
+ "PluralName": "KilogramsPerKilomole",
+ "FromUnitToBaseFunc": "{x} / 1e3",
+ "FromBaseToUnitFunc": "{x} * 1e3",
+ "Localization": [
+ {
+ "Culture": "en-US",
+ "Abbreviations": [ "kg/kmol" ]
+ }
+ ]
+ },
{
"SingularName": "PoundPerMole",
"PluralName": "PoundsPerMole",
diff --git a/Common/UnitDefinitions/Molarity.json b/Common/UnitDefinitions/Molarity.json
index a35ca9c2b6..9dc937c082 100644
--- a/Common/UnitDefinitions/Molarity.json
+++ b/Common/UnitDefinitions/Molarity.json
@@ -17,7 +17,7 @@
},
"FromUnitToBaseFunc": "{x}",
"FromBaseToUnitFunc": "{x}",
- "Prefixes": [],
+ "Prefixes": [ "Kilo" ],
"Localization": [
{
"Culture": "en-US",
@@ -41,6 +41,22 @@
"Abbreviations": [ "mol/L", "M" ]
}
]
+ },
+ {
+ "SingularName": "PoundMolePerCubicFoot",
+ "PluralName": "PoundMolesPerCubicFoot",
+ "BaseUnits": {
+ "L": "Foot",
+ "N": "PoundMole"
+ },
+ "FromUnitToBaseFunc": "{x} / 6.2427960576144611956325455827221e-5",
+ "FromBaseToUnitFunc": "{x} * 6.2427960576144611956325455827221e-5",
+ "Localization": [
+ {
+ "Culture": "en-US",
+ "Abbreviations": [ "lbmol/ft³" ]
+ }
+ ]
}
]
}
diff --git a/Common/UnitEnumValues.g.json b/Common/UnitEnumValues.g.json
index d0a4cd5db3..d2cb2ed2d6 100644
--- a/Common/UnitEnumValues.g.json
+++ b/Common/UnitEnumValues.g.json
@@ -537,7 +537,10 @@
"HeatTransferCoefficient": {
"BtuPerSquareFootDegreeFahrenheit": 1,
"WattPerSquareMeterCelsius": 2,
- "WattPerSquareMeterKelvin": 3
+ "WattPerSquareMeterKelvin": 3,
+ "BtuPerHourSquareFootDegreeFahrenheit": 11,
+ "KilocaloriePerHourSquareMeterDegreeCelsius": 8,
+ "CaloriePerHourSquareMeterDegreeCelsius": 5
},
"Illuminance": {
"Kilolux": 1,
@@ -956,7 +959,10 @@
"NanomolePerLiter": 14,
"NanomolesPerLiter": 15,
"PicomolePerLiter": 16,
- "PicomolesPerLiter": 17
+ "PicomolesPerLiter": 17,
+ "KilomolePerCubicMeter": 25,
+ "KilopoundMolePerCubicFoot": 23,
+ "PoundMolePerCubicFoot": 18
},
"MolarMass": {
"CentigramPerMole": 1,
@@ -970,7 +976,9 @@
"MicrogramPerMole": 9,
"MilligramPerMole": 10,
"NanogramPerMole": 11,
- "PoundPerMole": 12
+ "PoundPerMole": 12,
+ "KiloGramPerKiloMole": 20,
+ "KilogramPerKilomole": 15
},
"Permeability": {
"HenryPerMeter": 1
@@ -1690,5 +1698,19 @@
"PoundFootPerSecond": 16,
"SlugFootPerSecond": 11,
"PoundForceSecond": 18
+ },
+ "MolarFlow": {
+ "KiloMolePerHour": 10,
+ "KiloMolePerMinute": 1,
+ "KiloMolePerSecond": 5,
+ "PoundMolePerHour": 6,
+ "PoundMolePerMinute": 7,
+ "PoundMolePerSecond": 4,
+ "KilomolePerHour": 2,
+ "KilomolePerMinute": 15,
+ "KilomolePerSecond": 12,
+ "MolePerHour": 8,
+ "MolePerMinute": 18,
+ "MolePerSecond": 3
}
}
diff --git a/UnitsNet.NanoFramework/GeneratedCode/MolarFlow/MolarFlow.nfproj b/UnitsNet.NanoFramework/GeneratedCode/MolarFlow/MolarFlow.nfproj
new file mode 100644
index 0000000000..cac2107cd5
--- /dev/null
+++ b/UnitsNet.NanoFramework/GeneratedCode/MolarFlow/MolarFlow.nfproj
@@ -0,0 +1,42 @@
+
+
+
+ $(MSBuildExtensionsPath)\nanoFramework\v1.0\
+
+
+
+ Debug
+ AnyCPU
+ {11A8DD76-328B-46DF-9F39-F559912D0360};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}
+ {49cc942b-d836-a48b-0429-25bf95247759}
+ Library
+ Properties
+ 512
+ UnitsNet
+ UnitsNet.MolarFlow
+ v1.0
+ bin\$(Configuration)\$(AssemblyName).xml
+
+
+
+
+
+
+
+
+
+ ..\packages\nanoFramework.CoreLibrary.1.14.2\lib\mscorlib.dll
+ True
+ True
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/UnitsNet.NanoFramework/GeneratedCode/MolarFlow/UnitsNet.NanoFramework.MolarFlow.nuspec b/UnitsNet.NanoFramework/GeneratedCode/MolarFlow/UnitsNet.NanoFramework.MolarFlow.nuspec
new file mode 100644
index 0000000000..8be55b4230
--- /dev/null
+++ b/UnitsNet.NanoFramework/GeneratedCode/MolarFlow/UnitsNet.NanoFramework.MolarFlow.nuspec
@@ -0,0 +1,26 @@
+
+
+
+ UnitsNet.nanoFramework.MolarFlow
+ 5.1.0
+ Units.NET MolarFlow - nanoFramework
+ Andreas Gullberg Larsen,nanoFramework project contributors
+ UnitsNet
+ MIT
+ https://github.com/angularsen/UnitsNet
+ false
+ Adds MolarFlow units for Units.NET on .NET nanoFramework. For .NET or .NET Core, use UnitsNet instead.
+ https://raw.githubusercontent.com/angularsen/UnitsNet/ce85185429be345d77eb2ce09c99d59cc9ab8aed/Docs/Images/logo-32.png
+
+
+ Copyright 2013 Andreas Gullberg Larsen (andreas.larsen84@gmail.com).
+ en-US
+ nanoframework molarflow unit units quantity quantities measurement si metric imperial abbreviation abbreviations convert conversion parse immutable
+
+
+
+
+
+
+
+
diff --git a/UnitsNet.NanoFramework/GeneratedCode/MolarFlow/packages.config b/UnitsNet.NanoFramework/GeneratedCode/MolarFlow/packages.config
new file mode 100644
index 0000000000..faccd72a98
--- /dev/null
+++ b/UnitsNet.NanoFramework/GeneratedCode/MolarFlow/packages.config
@@ -0,0 +1,4 @@
+
+
+
+
diff --git a/UnitsNet.NanoFramework/GeneratedCode/Quantities/HeatTransferCoefficient.g.cs b/UnitsNet.NanoFramework/GeneratedCode/Quantities/HeatTransferCoefficient.g.cs
index b658044414..5330ee5a83 100644
--- a/UnitsNet.NanoFramework/GeneratedCode/Quantities/HeatTransferCoefficient.g.cs
+++ b/UnitsNet.NanoFramework/GeneratedCode/Quantities/HeatTransferCoefficient.g.cs
@@ -79,11 +79,27 @@ public HeatTransferCoefficient(double value, HeatTransferCoefficientUnit unit)
public static HeatTransferCoefficient Zero { get; } = new HeatTransferCoefficient(0, BaseUnit);
#region Conversion Properties
+ ///
+ /// Gets a value of this quantity converted into
+ ///
+ public double BtusPerHourSquareFootDegreeFahrenheit => As(HeatTransferCoefficientUnit.BtuPerHourSquareFootDegreeFahrenheit);
+
///
/// Gets a value of this quantity converted into
///
+ [Obsolete("The name of this definition incorrectly omitted time as divisor, please use BtuPerHourSquareFootDegreeFahrenheit instead")]
public double BtusPerSquareFootDegreeFahrenheit => As(HeatTransferCoefficientUnit.BtuPerSquareFootDegreeFahrenheit);
+ ///
+ /// Gets a value of this quantity converted into
+ ///
+ public double CaloriesPerHourSquareMeterDegreeCelsius => As(HeatTransferCoefficientUnit.CaloriePerHourSquareMeterDegreeCelsius);
+
+ ///
+ /// Gets a value of this quantity converted into
+ ///
+ public double KilocaloriesPerHourSquareMeterDegreeCelsius => As(HeatTransferCoefficientUnit.KilocaloriePerHourSquareMeterDegreeCelsius);
+
///
/// Gets a value of this quantity converted into
///
@@ -98,12 +114,31 @@ public HeatTransferCoefficient(double value, HeatTransferCoefficientUnit unit)
#region Static Factory Methods
+ ///
+ /// Creates a from .
+ ///
+ /// If value is NaN or Infinity.
+ public static HeatTransferCoefficient FromBtusPerHourSquareFootDegreeFahrenheit(double btusperhoursquarefootdegreefahrenheit) => new HeatTransferCoefficient(btusperhoursquarefootdegreefahrenheit, HeatTransferCoefficientUnit.BtuPerHourSquareFootDegreeFahrenheit);
+
///
/// Creates a from .
///
/// If value is NaN or Infinity.
+ [Obsolete("The name of this definition incorrectly omitted time as divisor, please use BtuPerHourSquareFootDegreeFahrenheit instead")]
public static HeatTransferCoefficient FromBtusPerSquareFootDegreeFahrenheit(double btuspersquarefootdegreefahrenheit) => new HeatTransferCoefficient(btuspersquarefootdegreefahrenheit, HeatTransferCoefficientUnit.BtuPerSquareFootDegreeFahrenheit);
+ ///
+ /// Creates a from .
+ ///
+ /// If value is NaN or Infinity.
+ public static HeatTransferCoefficient FromCaloriesPerHourSquareMeterDegreeCelsius(double caloriesperhoursquaremeterdegreecelsius) => new HeatTransferCoefficient(caloriesperhoursquaremeterdegreecelsius, HeatTransferCoefficientUnit.CaloriePerHourSquareMeterDegreeCelsius);
+
+ ///
+ /// Creates a from .
+ ///
+ /// If value is NaN or Infinity.
+ public static HeatTransferCoefficient FromKilocaloriesPerHourSquareMeterDegreeCelsius(double kilocaloriesperhoursquaremeterdegreecelsius) => new HeatTransferCoefficient(kilocaloriesperhoursquaremeterdegreecelsius, HeatTransferCoefficientUnit.KilocaloriePerHourSquareMeterDegreeCelsius);
+
///
/// Creates a from .
///
@@ -156,7 +191,10 @@ private double GetValueInBaseUnit()
{
return Unit switch
{
+ HeatTransferCoefficientUnit.BtuPerHourSquareFootDegreeFahrenheit => _value * 5.6782633411134878,
HeatTransferCoefficientUnit.BtuPerSquareFootDegreeFahrenheit => _value * 5.6782633411134878,
+ HeatTransferCoefficientUnit.CaloriePerHourSquareMeterDegreeCelsius => (_value * 4.1868) / 3600,
+ HeatTransferCoefficientUnit.KilocaloriePerHourSquareMeterDegreeCelsius => ((_value * 4.1868) / 3600) * 1e3d,
HeatTransferCoefficientUnit.WattPerSquareMeterCelsius => _value,
HeatTransferCoefficientUnit.WattPerSquareMeterKelvin => _value,
_ => throw new NotImplementedException($"Can not convert {Unit} to base units.")
@@ -172,7 +210,10 @@ private double GetValueAs(HeatTransferCoefficientUnit unit)
return unit switch
{
+ HeatTransferCoefficientUnit.BtuPerHourSquareFootDegreeFahrenheit => baseUnitValue / 5.6782633411134878,
HeatTransferCoefficientUnit.BtuPerSquareFootDegreeFahrenheit => baseUnitValue / 5.6782633411134878,
+ HeatTransferCoefficientUnit.CaloriePerHourSquareMeterDegreeCelsius => (baseUnitValue / 4.1868) * 3600,
+ HeatTransferCoefficientUnit.KilocaloriePerHourSquareMeterDegreeCelsius => ((baseUnitValue / 4.1868) * 3600) / 1e3d,
HeatTransferCoefficientUnit.WattPerSquareMeterCelsius => baseUnitValue,
HeatTransferCoefficientUnit.WattPerSquareMeterKelvin => baseUnitValue,
_ => throw new NotImplementedException($"Can not convert {Unit} to {unit}.")
diff --git a/UnitsNet.NanoFramework/GeneratedCode/Quantities/MolarFlow.g.cs b/UnitsNet.NanoFramework/GeneratedCode/Quantities/MolarFlow.g.cs
new file mode 100644
index 0000000000..387d2fdb60
--- /dev/null
+++ b/UnitsNet.NanoFramework/GeneratedCode/Quantities/MolarFlow.g.cs
@@ -0,0 +1,263 @@
+//------------------------------------------------------------------------------
+//
+// This code was generated by \generate-code.bat.
+//
+// Changes to this file will be lost when the code is regenerated.
+// The build server regenerates the code before each build and a pre-build
+// step will regenerate the code on each local build.
+//
+// See https://github.com/angularsen/UnitsNet/wiki/Adding-a-New-Unit for how to add or edit units.
+//
+// Add CustomCode\Quantities\MyQuantity.extra.cs files to add code to generated quantities.
+// Add UnitDefinitions\MyQuantity.json and run generate-code.bat to generate new units or quantities.
+//
+//
+//------------------------------------------------------------------------------
+
+// Licensed under MIT No Attribution, see LICENSE file at the root.
+// Copyright 2013 Andreas Gullberg Larsen (andreas.larsen84@gmail.com). Maintained at https://github.com/angularsen/UnitsNet.
+
+using System;
+using UnitsNet.Units;
+
+namespace UnitsNet
+{
+ ///
+ ///
+ /// Molar flow is the ratio of the amount of substance change to the time during which the change occurred (value of amount of substance changes per unit time).
+ ///
+ public struct MolarFlow
+ {
+ ///
+ /// The numeric value this quantity was constructed with.
+ ///
+ private readonly double _value;
+
+ ///
+ /// The unit this quantity was constructed with.
+ ///
+ private readonly MolarFlowUnit _unit;
+
+ ///
+ /// The numeric value this quantity was constructed with.
+ ///
+ public double Value => _value;
+
+ ///
+ public MolarFlowUnit Unit => _unit;
+
+ ///
+ /// Creates the quantity with the given numeric value and unit.
+ ///
+ /// The numeric value to construct this quantity with.
+ /// The unit representation to construct this quantity with.
+ /// If value is NaN or Infinity.
+ public MolarFlow(double value, MolarFlowUnit unit)
+ {
+ _value = value;
+ _unit = unit;
+ }
+
+ ///
+ /// The base unit of Duration, which is Second. All conversions go via this value.
+ ///
+ public static MolarFlowUnit BaseUnit { get; } = MolarFlowUnit.MolePerSecond;
+
+ ///
+ /// Represents the largest possible value of Duration
+ ///
+ public static MolarFlow MaxValue { get; } = new MolarFlow(double.MaxValue, BaseUnit);
+
+ ///
+ /// Represents the smallest possible value of Duration
+ ///
+ public static MolarFlow MinValue { get; } = new MolarFlow(double.MinValue, BaseUnit);
+
+ ///
+ /// Gets an instance of this quantity with a value of 0 in the base unit Second.
+ ///
+ public static MolarFlow Zero { get; } = new MolarFlow(0, BaseUnit);
+ #region Conversion Properties
+
+ ///
+ /// Gets a value of this quantity converted into
+ ///
+ public double KilomolesPerHour => As(MolarFlowUnit.KilomolePerHour);
+
+ ///
+ /// Gets a value of this quantity converted into
+ ///
+ public double KilomolesPerMinute => As(MolarFlowUnit.KilomolePerMinute);
+
+ ///
+ /// Gets a value of this quantity converted into
+ ///
+ public double KilomolesPerSecond => As(MolarFlowUnit.KilomolePerSecond);
+
+ ///
+ /// Gets a value of this quantity converted into
+ ///
+ public double MolesPerHour => As(MolarFlowUnit.MolePerHour);
+
+ ///
+ /// Gets a value of this quantity converted into
+ ///
+ public double MolesPerMinute => As(MolarFlowUnit.MolePerMinute);
+
+ ///
+ /// Gets a value of this quantity converted into
+ ///
+ public double MolesPerSecond => As(MolarFlowUnit.MolePerSecond);
+
+ ///
+ /// Gets a value of this quantity converted into
+ ///
+ public double PoundMolesPerHour => As(MolarFlowUnit.PoundMolePerHour);
+
+ ///
+ /// Gets a value of this quantity converted into
+ ///
+ public double PoundMolesPerMinute => As(MolarFlowUnit.PoundMolePerMinute);
+
+ ///
+ /// Gets a value of this quantity converted into
+ ///
+ public double PoundMolesPerSecond => As(MolarFlowUnit.PoundMolePerSecond);
+
+ #endregion
+
+ #region Static Factory Methods
+
+ ///
+ /// Creates a from .
+ ///
+ /// If value is NaN or Infinity.
+ public static MolarFlow FromKilomolesPerHour(double kilomolesperhour) => new MolarFlow(kilomolesperhour, MolarFlowUnit.KilomolePerHour);
+
+ ///
+ /// Creates a from .
+ ///
+ /// If value is NaN or Infinity.
+ public static MolarFlow FromKilomolesPerMinute(double kilomolesperminute) => new MolarFlow(kilomolesperminute, MolarFlowUnit.KilomolePerMinute);
+
+ ///
+ /// Creates a from .
+ ///
+ /// If value is NaN or Infinity.
+ public static MolarFlow FromKilomolesPerSecond(double kilomolespersecond) => new MolarFlow(kilomolespersecond, MolarFlowUnit.KilomolePerSecond);
+
+ ///
+ /// Creates a from .
+ ///
+ /// If value is NaN or Infinity.
+ public static MolarFlow FromMolesPerHour(double molesperhour) => new MolarFlow(molesperhour, MolarFlowUnit.MolePerHour);
+
+ ///
+ /// Creates a from .
+ ///
+ /// If value is NaN or Infinity.
+ public static MolarFlow FromMolesPerMinute(double molesperminute) => new MolarFlow(molesperminute, MolarFlowUnit.MolePerMinute);
+
+ ///
+ /// Creates a from .
+ ///
+ /// If value is NaN or Infinity.
+ public static MolarFlow FromMolesPerSecond(double molespersecond) => new MolarFlow(molespersecond, MolarFlowUnit.MolePerSecond);
+
+ ///
+ /// Creates a from .
+ ///
+ /// If value is NaN or Infinity.
+ public static MolarFlow FromPoundMolesPerHour(double poundmolesperhour) => new MolarFlow(poundmolesperhour, MolarFlowUnit.PoundMolePerHour);
+
+ ///
+ /// Creates a from .
+ ///
+ /// If value is NaN or Infinity.
+ public static MolarFlow FromPoundMolesPerMinute(double poundmolesperminute) => new MolarFlow(poundmolesperminute, MolarFlowUnit.PoundMolePerMinute);
+
+ ///
+ /// Creates a from .
+ ///
+ /// If value is NaN or Infinity.
+ public static MolarFlow FromPoundMolesPerSecond(double poundmolespersecond) => new MolarFlow(poundmolespersecond, MolarFlowUnit.PoundMolePerSecond);
+
+ ///
+ /// Dynamically convert from value and unit enum to .
+ ///
+ /// Value to convert from.
+ /// Unit to convert from.
+ /// MolarFlow unit value.
+ public static MolarFlow From(double value, MolarFlowUnit fromUnit)
+ {
+ return new MolarFlow(value, fromUnit);
+ }
+
+ #endregion
+
+ #region Conversion Methods
+
+ ///
+ /// Convert to the unit representation .
+ ///
+ /// Value converted to the specified unit.
+ public double As(MolarFlowUnit unit) => GetValueAs(unit);
+
+ ///
+ /// Converts this Duration to another Duration with the unit representation .
+ ///
+ /// A Duration with the specified unit.
+ public MolarFlow ToUnit(MolarFlowUnit unit)
+ {
+ var convertedValue = GetValueAs(unit);
+ return new MolarFlow(convertedValue, unit);
+ }
+
+ ///
+ /// Converts the current value + unit to the base unit.
+ /// This is typically the first step in converting from one unit to another.
+ ///
+ /// The value in the base unit representation.
+ private double GetValueInBaseUnit()
+ {
+ return Unit switch
+ {
+ MolarFlowUnit.KilomolePerHour => (_value / 3600) * 1e3d,
+ MolarFlowUnit.KilomolePerMinute => (_value / 60) * 1e3d,
+ MolarFlowUnit.KilomolePerSecond => (_value) * 1e3d,
+ MolarFlowUnit.MolePerHour => _value / 3600,
+ MolarFlowUnit.MolePerMinute => _value / 60,
+ MolarFlowUnit.MolePerSecond => _value,
+ MolarFlowUnit.PoundMolePerHour => (_value * 453.59237) / 3600,
+ MolarFlowUnit.PoundMolePerMinute => (_value * 453.59237) / 60,
+ MolarFlowUnit.PoundMolePerSecond => _value * 453.59237,
+ _ => throw new NotImplementedException($"Can not convert {Unit} to base units.")
+ };
+ }
+
+ private double GetValueAs(MolarFlowUnit unit)
+ {
+ if (Unit == unit)
+ return _value;
+
+ var baseUnitValue = GetValueInBaseUnit();
+
+ return unit switch
+ {
+ MolarFlowUnit.KilomolePerHour => (baseUnitValue * 3600) / 1e3d,
+ MolarFlowUnit.KilomolePerMinute => (baseUnitValue * 60) / 1e3d,
+ MolarFlowUnit.KilomolePerSecond => (baseUnitValue) / 1e3d,
+ MolarFlowUnit.MolePerHour => baseUnitValue * 3600,
+ MolarFlowUnit.MolePerMinute => baseUnitValue * 60,
+ MolarFlowUnit.MolePerSecond => baseUnitValue,
+ MolarFlowUnit.PoundMolePerHour => (baseUnitValue / 453.59237) * 3600,
+ MolarFlowUnit.PoundMolePerMinute => (baseUnitValue / 453.59237) * 60,
+ MolarFlowUnit.PoundMolePerSecond => baseUnitValue / 453.59237,
+ _ => throw new NotImplementedException($"Can not convert {Unit} to {unit}.")
+ };
+ }
+
+ #endregion
+ }
+}
+
diff --git a/UnitsNet.NanoFramework/GeneratedCode/Quantities/MolarMass.g.cs b/UnitsNet.NanoFramework/GeneratedCode/Quantities/MolarMass.g.cs
index 8134422826..95cdd25de5 100644
--- a/UnitsNet.NanoFramework/GeneratedCode/Quantities/MolarMass.g.cs
+++ b/UnitsNet.NanoFramework/GeneratedCode/Quantities/MolarMass.g.cs
@@ -104,6 +104,11 @@ public MolarMass(double value, MolarMassUnit unit)
///
public double HectogramsPerMole => As(MolarMassUnit.HectogramPerMole);
+ ///
+ /// Gets a value of this quantity converted into
+ ///
+ public double KilogramsPerKilomole => As(MolarMassUnit.KilogramPerKilomole);
+
///
/// Gets a value of this quantity converted into
///
@@ -173,6 +178,12 @@ public MolarMass(double value, MolarMassUnit unit)
/// If value is NaN or Infinity.
public static MolarMass FromHectogramsPerMole(double hectogramspermole) => new MolarMass(hectogramspermole, MolarMassUnit.HectogramPerMole);
+ ///
+ /// Creates a from .
+ ///
+ /// If value is NaN or Infinity.
+ public static MolarMass FromKilogramsPerKilomole(double kilogramsperkilomole) => new MolarMass(kilogramsperkilomole, MolarMassUnit.KilogramPerKilomole);
+
///
/// Creates a from .
///
@@ -260,6 +271,7 @@ private double GetValueInBaseUnit()
MolarMassUnit.DecigramPerMole => (_value / 1e3) * 1e-1d,
MolarMassUnit.GramPerMole => _value / 1e3,
MolarMassUnit.HectogramPerMole => (_value / 1e3) * 1e2d,
+ MolarMassUnit.KilogramPerKilomole => _value / 1e3,
MolarMassUnit.KilogramPerMole => (_value / 1e3) * 1e3d,
MolarMassUnit.KilopoundPerMole => (_value * 0.45359237) * 1e3d,
MolarMassUnit.MegapoundPerMole => (_value * 0.45359237) * 1e6d,
@@ -285,6 +297,7 @@ private double GetValueAs(MolarMassUnit unit)
MolarMassUnit.DecigramPerMole => (baseUnitValue * 1e3) / 1e-1d,
MolarMassUnit.GramPerMole => baseUnitValue * 1e3,
MolarMassUnit.HectogramPerMole => (baseUnitValue * 1e3) / 1e2d,
+ MolarMassUnit.KilogramPerKilomole => baseUnitValue * 1e3,
MolarMassUnit.KilogramPerMole => (baseUnitValue * 1e3) / 1e3d,
MolarMassUnit.KilopoundPerMole => (baseUnitValue / 0.45359237) / 1e3d,
MolarMassUnit.MegapoundPerMole => (baseUnitValue / 0.45359237) / 1e6d,
diff --git a/UnitsNet.NanoFramework/GeneratedCode/Quantities/Molarity.g.cs b/UnitsNet.NanoFramework/GeneratedCode/Quantities/Molarity.g.cs
index d9263501fd..abf7d40884 100644
--- a/UnitsNet.NanoFramework/GeneratedCode/Quantities/Molarity.g.cs
+++ b/UnitsNet.NanoFramework/GeneratedCode/Quantities/Molarity.g.cs
@@ -97,6 +97,11 @@ public Molarity(double value, MolarityUnit unit)
///
public double FemtomolesPerLiter => As(MolarityUnit.FemtomolePerLiter);
+ ///
+ /// Gets a value of this quantity converted into
+ ///
+ public double KilomolesPerCubicMeter => As(MolarityUnit.KilomolePerCubicMeter);
+
///
/// Gets a value of this quantity converted into
///
@@ -127,6 +132,11 @@ public Molarity(double value, MolarityUnit unit)
///
public double PicomolesPerLiter => As(MolarityUnit.PicomolePerLiter);
+ ///
+ /// Gets a value of this quantity converted into
+ ///
+ public double PoundMolesPerCubicFoot => As(MolarityUnit.PoundMolePerCubicFoot);
+
#endregion
#region Static Factory Methods
@@ -149,6 +159,12 @@ public Molarity(double value, MolarityUnit unit)
/// If value is NaN or Infinity.
public static Molarity FromFemtomolesPerLiter(double femtomolesperliter) => new Molarity(femtomolesperliter, MolarityUnit.FemtomolePerLiter);
+ ///
+ /// Creates a from .
+ ///
+ /// If value is NaN or Infinity.
+ public static Molarity FromKilomolesPerCubicMeter(double kilomolespercubicmeter) => new Molarity(kilomolespercubicmeter, MolarityUnit.KilomolePerCubicMeter);
+
///
/// Creates a from .
///
@@ -185,6 +201,12 @@ public Molarity(double value, MolarityUnit unit)
/// If value is NaN or Infinity.
public static Molarity FromPicomolesPerLiter(double picomolesperliter) => new Molarity(picomolesperliter, MolarityUnit.PicomolePerLiter);
+ ///
+ /// Creates a from .
+ ///
+ /// If value is NaN or Infinity.
+ public static Molarity FromPoundMolesPerCubicFoot(double poundmolespercubicfoot) => new Molarity(poundmolespercubicfoot, MolarityUnit.PoundMolePerCubicFoot);
+
///
/// Dynamically convert from value and unit enum to .
///
@@ -228,12 +250,14 @@ private double GetValueInBaseUnit()
MolarityUnit.CentimolePerLiter => (_value / 1e-3) * 1e-2d,
MolarityUnit.DecimolePerLiter => (_value / 1e-3) * 1e-1d,
MolarityUnit.FemtomolePerLiter => (_value / 1e-3) * 1e-15d,
+ MolarityUnit.KilomolePerCubicMeter => (_value) * 1e3d,
MolarityUnit.MicromolePerLiter => (_value / 1e-3) * 1e-6d,
MolarityUnit.MillimolePerLiter => (_value / 1e-3) * 1e-3d,
MolarityUnit.MolePerCubicMeter => _value,
MolarityUnit.MolePerLiter => _value / 1e-3,
MolarityUnit.NanomolePerLiter => (_value / 1e-3) * 1e-9d,
MolarityUnit.PicomolePerLiter => (_value / 1e-3) * 1e-12d,
+ MolarityUnit.PoundMolePerCubicFoot => _value / 6.2427960576144611956325455827221e-5,
_ => throw new NotImplementedException($"Can not convert {Unit} to base units.")
};
}
@@ -250,12 +274,14 @@ private double GetValueAs(MolarityUnit unit)
MolarityUnit.CentimolePerLiter => (baseUnitValue * 1e-3) / 1e-2d,
MolarityUnit.DecimolePerLiter => (baseUnitValue * 1e-3) / 1e-1d,
MolarityUnit.FemtomolePerLiter => (baseUnitValue * 1e-3) / 1e-15d,
+ MolarityUnit.KilomolePerCubicMeter => (baseUnitValue) / 1e3d,
MolarityUnit.MicromolePerLiter => (baseUnitValue * 1e-3) / 1e-6d,
MolarityUnit.MillimolePerLiter => (baseUnitValue * 1e-3) / 1e-3d,
MolarityUnit.MolePerCubicMeter => baseUnitValue,
MolarityUnit.MolePerLiter => baseUnitValue * 1e-3,
MolarityUnit.NanomolePerLiter => (baseUnitValue * 1e-3) / 1e-9d,
MolarityUnit.PicomolePerLiter => (baseUnitValue * 1e-3) / 1e-12d,
+ MolarityUnit.PoundMolePerCubicFoot => baseUnitValue * 6.2427960576144611956325455827221e-5,
_ => throw new NotImplementedException($"Can not convert {Unit} to {unit}.")
};
}
diff --git a/UnitsNet.NanoFramework/GeneratedCode/Units/HeatTransferCoefficientUnit.g.cs b/UnitsNet.NanoFramework/GeneratedCode/Units/HeatTransferCoefficientUnit.g.cs
index e337b5095a..beaabc3f3b 100644
--- a/UnitsNet.NanoFramework/GeneratedCode/Units/HeatTransferCoefficientUnit.g.cs
+++ b/UnitsNet.NanoFramework/GeneratedCode/Units/HeatTransferCoefficientUnit.g.cs
@@ -25,7 +25,11 @@ namespace UnitsNet.Units
public enum HeatTransferCoefficientUnit
{
+ BtuPerHourSquareFootDegreeFahrenheit = 11,
+ [System.Obsolete("The name of this definition incorrectly omitted time as divisor, please use BtuPerHourSquareFootDegreeFahrenheit instead")]
BtuPerSquareFootDegreeFahrenheit = 1,
+ CaloriePerHourSquareMeterDegreeCelsius = 5,
+ KilocaloriePerHourSquareMeterDegreeCelsius = 8,
WattPerSquareMeterCelsius = 2,
WattPerSquareMeterKelvin = 3,
}
diff --git a/UnitsNet.NanoFramework/GeneratedCode/Units/MolarFlowUnit.g.cs b/UnitsNet.NanoFramework/GeneratedCode/Units/MolarFlowUnit.g.cs
new file mode 100644
index 0000000000..48bc201810
--- /dev/null
+++ b/UnitsNet.NanoFramework/GeneratedCode/Units/MolarFlowUnit.g.cs
@@ -0,0 +1,40 @@
+//------------------------------------------------------------------------------
+//
+// This code was generated by \generate-code.bat.
+//
+// Changes to this file will be lost when the code is regenerated.
+// The build server regenerates the code before each build and a pre-build
+// step will regenerate the code on each local build.
+//
+// See https://github.com/angularsen/UnitsNet/wiki/Adding-a-New-Unit for how to add or edit units.
+//
+// Add CustomCode\Quantities\MyQuantity.extra.cs files to add code to generated quantities.
+// Add UnitDefinitions\MyQuantity.json and run generate-code.bat to generate new units or quantities.
+//
+//
+//------------------------------------------------------------------------------
+
+// Licensed under MIT No Attribution, see LICENSE file at the root.
+// Copyright 2013 Andreas Gullberg Larsen (andreas.larsen84@gmail.com). Maintained at https://github.com/angularsen/UnitsNet.
+
+// ReSharper disable once CheckNamespace
+namespace UnitsNet.Units
+{
+ // Disable missing XML comment warnings for the generated unit enums.
+ #pragma warning disable 1591
+
+ public enum MolarFlowUnit
+ {
+ KilomolePerHour = 2,
+ KilomolePerMinute = 15,
+ KilomolePerSecond = 12,
+ MolePerHour = 8,
+ MolePerMinute = 18,
+ MolePerSecond = 3,
+ PoundMolePerHour = 6,
+ PoundMolePerMinute = 7,
+ PoundMolePerSecond = 4,
+ }
+
+ #pragma warning restore 1591
+}
diff --git a/UnitsNet.NanoFramework/GeneratedCode/Units/MolarMassUnit.g.cs b/UnitsNet.NanoFramework/GeneratedCode/Units/MolarMassUnit.g.cs
index 417075c855..4be43903ef 100644
--- a/UnitsNet.NanoFramework/GeneratedCode/Units/MolarMassUnit.g.cs
+++ b/UnitsNet.NanoFramework/GeneratedCode/Units/MolarMassUnit.g.cs
@@ -30,6 +30,7 @@ public enum MolarMassUnit
DecigramPerMole = 3,
GramPerMole = 4,
HectogramPerMole = 5,
+ KilogramPerKilomole = 15,
KilogramPerMole = 6,
KilopoundPerMole = 7,
MegapoundPerMole = 8,
diff --git a/UnitsNet.NanoFramework/GeneratedCode/Units/MolarityUnit.g.cs b/UnitsNet.NanoFramework/GeneratedCode/Units/MolarityUnit.g.cs
index 3119352a47..d9c7972422 100644
--- a/UnitsNet.NanoFramework/GeneratedCode/Units/MolarityUnit.g.cs
+++ b/UnitsNet.NanoFramework/GeneratedCode/Units/MolarityUnit.g.cs
@@ -28,12 +28,14 @@ public enum MolarityUnit
CentimolePerLiter = 1,
DecimolePerLiter = 3,
FemtomolePerLiter = 5,
+ KilomolePerCubicMeter = 25,
MicromolePerLiter = 6,
MillimolePerLiter = 8,
MolePerCubicMeter = 10,
MolePerLiter = 11,
NanomolePerLiter = 14,
PicomolePerLiter = 16,
+ PoundMolePerCubicFoot = 18,
}
#pragma warning restore 1591
diff --git a/UnitsNet.NanoFramework/GeneratedCode/UnitsNet.nanoFramework.sln b/UnitsNet.NanoFramework/GeneratedCode/UnitsNet.nanoFramework.sln
index c4180bc92b..e1eafd5bbc 100644
--- a/UnitsNet.NanoFramework/GeneratedCode/UnitsNet.nanoFramework.sln
+++ b/UnitsNet.NanoFramework/GeneratedCode/UnitsNet.nanoFramework.sln
@@ -142,6 +142,8 @@ Project("{d608a2b1-6ead-4383-a205-ad1ce69d9ef7}") = "MolarEnergy", "MolarEnergy\
EndProject
Project("{d608a2b1-6ead-4383-a205-ad1ce69d9ef7}") = "MolarEntropy", "MolarEntropy\MolarEntropy.nfproj", "{2053731b-90f5-5141-d15e-8d7be8c2662f}"
EndProject
+Project("{d608a2b1-6ead-4383-a205-ad1ce69d9ef7}") = "MolarFlow", "MolarFlow\MolarFlow.nfproj", "{49cc942b-d836-a48b-0429-25bf95247759}"
+EndProject
Project("{d608a2b1-6ead-4383-a205-ad1ce69d9ef7}") = "Molarity", "Molarity\Molarity.nfproj", "{0d21f127-8c25-9b3a-9612-ce2eea6e7ac1}"
EndProject
Project("{d608a2b1-6ead-4383-a205-ad1ce69d9ef7}") = "MolarMass", "MolarMass\MolarMass.nfproj", "{fe51bbda-2039-23fd-f29a-39c14adcb1f6}"
@@ -662,6 +664,12 @@ Global
{2053731b-90f5-5141-d15e-8d7be8c2662f}.Release|Any CPU.ActiveCfg = Release|Any CPU
{2053731b-90f5-5141-d15e-8d7be8c2662f}.Release|Any CPU.Build.0 = Release|Any CPU
{2053731b-90f5-5141-d15e-8d7be8c2662f}.Release|Any CPU.Deploy.0 = Release|Any CPU
+{49cc942b-d836-a48b-0429-25bf95247759}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+{49cc942b-d836-a48b-0429-25bf95247759}.Debug|Any CPU.Build.0 = Debug|Any CPU
+{49cc942b-d836-a48b-0429-25bf95247759}.Debug|Any CPU.Deploy.0 = Debug|Any CPU
+{49cc942b-d836-a48b-0429-25bf95247759}.Release|Any CPU.ActiveCfg = Release|Any CPU
+{49cc942b-d836-a48b-0429-25bf95247759}.Release|Any CPU.Build.0 = Release|Any CPU
+{49cc942b-d836-a48b-0429-25bf95247759}.Release|Any CPU.Deploy.0 = Release|Any CPU
{0d21f127-8c25-9b3a-9612-ce2eea6e7ac1}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{0d21f127-8c25-9b3a-9612-ce2eea6e7ac1}.Debug|Any CPU.Build.0 = Debug|Any CPU
{0d21f127-8c25-9b3a-9612-ce2eea6e7ac1}.Debug|Any CPU.Deploy.0 = Debug|Any CPU
diff --git a/UnitsNet.NumberExtensions.Tests/GeneratedCode/NumberToHeatTransferCoefficientExtensionsTest.g.cs b/UnitsNet.NumberExtensions.Tests/GeneratedCode/NumberToHeatTransferCoefficientExtensionsTest.g.cs
index c252afd20e..9f317e64d2 100644
--- a/UnitsNet.NumberExtensions.Tests/GeneratedCode/NumberToHeatTransferCoefficientExtensionsTest.g.cs
+++ b/UnitsNet.NumberExtensions.Tests/GeneratedCode/NumberToHeatTransferCoefficientExtensionsTest.g.cs
@@ -24,10 +24,22 @@ namespace UnitsNet.Tests
{
public class NumberToHeatTransferCoefficientExtensionsTests
{
+ [Fact]
+ public void NumberToBtusPerHourSquareFootDegreeFahrenheitTest() =>
+ Assert.Equal(HeatTransferCoefficient.FromBtusPerHourSquareFootDegreeFahrenheit(2), 2.BtusPerHourSquareFootDegreeFahrenheit());
+
[Fact]
public void NumberToBtusPerSquareFootDegreeFahrenheitTest() =>
Assert.Equal(HeatTransferCoefficient.FromBtusPerSquareFootDegreeFahrenheit(2), 2.BtusPerSquareFootDegreeFahrenheit());
+ [Fact]
+ public void NumberToCaloriesPerHourSquareMeterDegreeCelsiusTest() =>
+ Assert.Equal(HeatTransferCoefficient.FromCaloriesPerHourSquareMeterDegreeCelsius(2), 2.CaloriesPerHourSquareMeterDegreeCelsius());
+
+ [Fact]
+ public void NumberToKilocaloriesPerHourSquareMeterDegreeCelsiusTest() =>
+ Assert.Equal(HeatTransferCoefficient.FromKilocaloriesPerHourSquareMeterDegreeCelsius(2), 2.KilocaloriesPerHourSquareMeterDegreeCelsius());
+
[Fact]
public void NumberToWattsPerSquareMeterCelsiusTest() =>
Assert.Equal(HeatTransferCoefficient.FromWattsPerSquareMeterCelsius(2), 2.WattsPerSquareMeterCelsius());
diff --git a/UnitsNet.NumberExtensions.Tests/GeneratedCode/NumberToMolarFlowExtensionsTest.g.cs b/UnitsNet.NumberExtensions.Tests/GeneratedCode/NumberToMolarFlowExtensionsTest.g.cs
new file mode 100644
index 0000000000..3a4f360973
--- /dev/null
+++ b/UnitsNet.NumberExtensions.Tests/GeneratedCode/NumberToMolarFlowExtensionsTest.g.cs
@@ -0,0 +1,64 @@
+//------------------------------------------------------------------------------
+//
+// This code was generated by \generate-code.bat.
+//
+// Changes to this file will be lost when the code is regenerated.
+// The build server regenerates the code before each build and a pre-build
+// step will regenerate the code on each local build.
+//
+// See https://github.com/angularsen/UnitsNet/wiki/Adding-a-New-Unit for how to add or edit units.
+//
+// Add CustomCode\Quantities\MyQuantity.extra.cs files to add code to generated quantities.
+// Add UnitDefinitions\MyQuantity.json and run generate-code.bat to generate new units or quantities.
+//
+//
+//------------------------------------------------------------------------------
+
+// Licensed under MIT No Attribution, see LICENSE file at the root.
+// Copyright 2013 Andreas Gullberg Larsen (andreas.larsen84@gmail.com). Maintained at https://github.com/angularsen/UnitsNet.
+
+using UnitsNet.NumberExtensions.NumberToMolarFlow;
+using Xunit;
+
+namespace UnitsNet.Tests
+{
+ public class NumberToMolarFlowExtensionsTests
+ {
+ [Fact]
+ public void NumberToKilomolesPerHourTest() =>
+ Assert.Equal(MolarFlow.FromKilomolesPerHour(2), 2.KilomolesPerHour());
+
+ [Fact]
+ public void NumberToKilomolesPerMinuteTest() =>
+ Assert.Equal(MolarFlow.FromKilomolesPerMinute(2), 2.KilomolesPerMinute());
+
+ [Fact]
+ public void NumberToKilomolesPerSecondTest() =>
+ Assert.Equal(MolarFlow.FromKilomolesPerSecond(2), 2.KilomolesPerSecond());
+
+ [Fact]
+ public void NumberToMolesPerHourTest() =>
+ Assert.Equal(MolarFlow.FromMolesPerHour(2), 2.MolesPerHour());
+
+ [Fact]
+ public void NumberToMolesPerMinuteTest() =>
+ Assert.Equal(MolarFlow.FromMolesPerMinute(2), 2.MolesPerMinute());
+
+ [Fact]
+ public void NumberToMolesPerSecondTest() =>
+ Assert.Equal(MolarFlow.FromMolesPerSecond(2), 2.MolesPerSecond());
+
+ [Fact]
+ public void NumberToPoundMolesPerHourTest() =>
+ Assert.Equal(MolarFlow.FromPoundMolesPerHour(2), 2.PoundMolesPerHour());
+
+ [Fact]
+ public void NumberToPoundMolesPerMinuteTest() =>
+ Assert.Equal(MolarFlow.FromPoundMolesPerMinute(2), 2.PoundMolesPerMinute());
+
+ [Fact]
+ public void NumberToPoundMolesPerSecondTest() =>
+ Assert.Equal(MolarFlow.FromPoundMolesPerSecond(2), 2.PoundMolesPerSecond());
+
+ }
+}
diff --git a/UnitsNet.NumberExtensions.Tests/GeneratedCode/NumberToMolarMassExtensionsTest.g.cs b/UnitsNet.NumberExtensions.Tests/GeneratedCode/NumberToMolarMassExtensionsTest.g.cs
index 72161eee76..cc48f3cbf5 100644
--- a/UnitsNet.NumberExtensions.Tests/GeneratedCode/NumberToMolarMassExtensionsTest.g.cs
+++ b/UnitsNet.NumberExtensions.Tests/GeneratedCode/NumberToMolarMassExtensionsTest.g.cs
@@ -44,6 +44,10 @@ public void NumberToGramsPerMoleTest() =>
public void NumberToHectogramsPerMoleTest() =>
Assert.Equal(MolarMass.FromHectogramsPerMole(2), 2.HectogramsPerMole());
+ [Fact]
+ public void NumberToKilogramsPerKilomoleTest() =>
+ Assert.Equal(MolarMass.FromKilogramsPerKilomole(2), 2.KilogramsPerKilomole());
+
[Fact]
public void NumberToKilogramsPerMoleTest() =>
Assert.Equal(MolarMass.FromKilogramsPerMole(2), 2.KilogramsPerMole());
diff --git a/UnitsNet.NumberExtensions.Tests/GeneratedCode/NumberToMolarityExtensionsTest.g.cs b/UnitsNet.NumberExtensions.Tests/GeneratedCode/NumberToMolarityExtensionsTest.g.cs
index 688089b86b..4e870a80bf 100644
--- a/UnitsNet.NumberExtensions.Tests/GeneratedCode/NumberToMolarityExtensionsTest.g.cs
+++ b/UnitsNet.NumberExtensions.Tests/GeneratedCode/NumberToMolarityExtensionsTest.g.cs
@@ -36,6 +36,10 @@ public void NumberToDecimolesPerLiterTest() =>
public void NumberToFemtomolesPerLiterTest() =>
Assert.Equal(Molarity.FromFemtomolesPerLiter(2), 2.FemtomolesPerLiter());
+ [Fact]
+ public void NumberToKilomolesPerCubicMeterTest() =>
+ Assert.Equal(Molarity.FromKilomolesPerCubicMeter(2), 2.KilomolesPerCubicMeter());
+
[Fact]
public void NumberToMicromolesPerLiterTest() =>
Assert.Equal(Molarity.FromMicromolesPerLiter(2), 2.MicromolesPerLiter());
@@ -60,5 +64,9 @@ public void NumberToNanomolesPerLiterTest() =>
public void NumberToPicomolesPerLiterTest() =>
Assert.Equal(Molarity.FromPicomolesPerLiter(2), 2.PicomolesPerLiter());
+ [Fact]
+ public void NumberToPoundMolesPerCubicFootTest() =>
+ Assert.Equal(Molarity.FromPoundMolesPerCubicFoot(2), 2.PoundMolesPerCubicFoot());
+
}
}
diff --git a/UnitsNet.NumberExtensions/GeneratedCode/NumberToHeatTransferCoefficientExtensions.g.cs b/UnitsNet.NumberExtensions/GeneratedCode/NumberToHeatTransferCoefficientExtensions.g.cs
index d03e2febe0..81575bbcda 100644
--- a/UnitsNet.NumberExtensions/GeneratedCode/NumberToHeatTransferCoefficientExtensions.g.cs
+++ b/UnitsNet.NumberExtensions/GeneratedCode/NumberToHeatTransferCoefficientExtensions.g.cs
@@ -28,10 +28,23 @@ namespace UnitsNet.NumberExtensions.NumberToHeatTransferCoefficient
///
public static class NumberToHeatTransferCoefficientExtensions
{
+ ///
+ public static HeatTransferCoefficient BtusPerHourSquareFootDegreeFahrenheit(this T value) =>
+ HeatTransferCoefficient.FromBtusPerHourSquareFootDegreeFahrenheit(Convert.ToDouble(value));
+
///
+ [Obsolete("The name of this definition incorrectly omitted time as divisor, please use BtuPerHourSquareFootDegreeFahrenheit instead")]
public static HeatTransferCoefficient BtusPerSquareFootDegreeFahrenheit(this T value) =>
HeatTransferCoefficient.FromBtusPerSquareFootDegreeFahrenheit(Convert.ToDouble(value));
+ ///
+ public static HeatTransferCoefficient CaloriesPerHourSquareMeterDegreeCelsius(this T value) =>
+ HeatTransferCoefficient.FromCaloriesPerHourSquareMeterDegreeCelsius(Convert.ToDouble(value));
+
+ ///
+ public static HeatTransferCoefficient KilocaloriesPerHourSquareMeterDegreeCelsius(this T value) =>
+ HeatTransferCoefficient.FromKilocaloriesPerHourSquareMeterDegreeCelsius(Convert.ToDouble(value));
+
///
public static HeatTransferCoefficient WattsPerSquareMeterCelsius(this T value) =>
HeatTransferCoefficient.FromWattsPerSquareMeterCelsius(Convert.ToDouble(value));
diff --git a/UnitsNet.NumberExtensions/GeneratedCode/NumberToMolarFlowExtensions.g.cs b/UnitsNet.NumberExtensions/GeneratedCode/NumberToMolarFlowExtensions.g.cs
new file mode 100644
index 0000000000..1dcdca6bbc
--- /dev/null
+++ b/UnitsNet.NumberExtensions/GeneratedCode/NumberToMolarFlowExtensions.g.cs
@@ -0,0 +1,68 @@
+//------------------------------------------------------------------------------
+//
+// This code was generated by \generate-code.bat.
+//
+// Changes to this file will be lost when the code is regenerated.
+// The build server regenerates the code before each build and a pre-build
+// step will regenerate the code on each local build.
+//
+// See https://github.com/angularsen/UnitsNet/wiki/Adding-a-New-Unit for how to add or edit units.
+//
+// Add CustomCode\Quantities\MyQuantity.extra.cs files to add code to generated quantities.
+// Add UnitDefinitions\MyQuantity.json and run generate-code.bat to generate new units or quantities.
+//
+//
+//------------------------------------------------------------------------------
+
+// Licensed under MIT No Attribution, see LICENSE file at the root.
+// Copyright 2013 Andreas Gullberg Larsen (andreas.larsen84@gmail.com). Maintained at https://github.com/angularsen/UnitsNet.
+
+using System;
+
+#nullable enable
+
+namespace UnitsNet.NumberExtensions.NumberToMolarFlow
+{
+ ///
+ /// A number to MolarFlow Extensions
+ ///
+ public static class NumberToMolarFlowExtensions
+ {
+ ///
+ public static MolarFlow KilomolesPerHour(this T value) =>
+ MolarFlow.FromKilomolesPerHour(Convert.ToDouble(value));
+
+ ///
+ public static MolarFlow KilomolesPerMinute(this T value) =>
+ MolarFlow.FromKilomolesPerMinute(Convert.ToDouble(value));
+
+ ///
+ public static MolarFlow KilomolesPerSecond(this T value) =>
+ MolarFlow.FromKilomolesPerSecond(Convert.ToDouble(value));
+
+ ///
+ public static MolarFlow MolesPerHour(this T value) =>
+ MolarFlow.FromMolesPerHour(Convert.ToDouble(value));
+
+ ///
+ public static MolarFlow MolesPerMinute(this T value) =>
+ MolarFlow.FromMolesPerMinute(Convert.ToDouble(value));
+
+ ///
+ public static MolarFlow MolesPerSecond(this T value) =>
+ MolarFlow.FromMolesPerSecond(Convert.ToDouble(value));
+
+ ///
+ public static MolarFlow PoundMolesPerHour(this T value) =>
+ MolarFlow.FromPoundMolesPerHour(Convert.ToDouble(value));
+
+ ///
+ public static MolarFlow PoundMolesPerMinute(this T value) =>
+ MolarFlow.FromPoundMolesPerMinute(Convert.ToDouble(value));
+
+ ///
+ public static MolarFlow PoundMolesPerSecond(this T value) =>
+ MolarFlow.FromPoundMolesPerSecond(Convert.ToDouble(value));
+
+ }
+}
diff --git a/UnitsNet.NumberExtensions/GeneratedCode/NumberToMolarMassExtensions.g.cs b/UnitsNet.NumberExtensions/GeneratedCode/NumberToMolarMassExtensions.g.cs
index 35d86155a5..2c8fa6dd48 100644
--- a/UnitsNet.NumberExtensions/GeneratedCode/NumberToMolarMassExtensions.g.cs
+++ b/UnitsNet.NumberExtensions/GeneratedCode/NumberToMolarMassExtensions.g.cs
@@ -48,6 +48,10 @@ public static MolarMass GramsPerMole(this T value) =>
public static MolarMass HectogramsPerMole(this T value) =>
MolarMass.FromHectogramsPerMole(Convert.ToDouble(value));
+ ///
+ public static MolarMass KilogramsPerKilomole(this T value) =>
+ MolarMass.FromKilogramsPerKilomole(Convert.ToDouble(value));
+
///
public static MolarMass KilogramsPerMole(this T value) =>
MolarMass.FromKilogramsPerMole(Convert.ToDouble(value));
diff --git a/UnitsNet.NumberExtensions/GeneratedCode/NumberToMolarityExtensions.g.cs b/UnitsNet.NumberExtensions/GeneratedCode/NumberToMolarityExtensions.g.cs
index a4f5a24607..c7b472ee5d 100644
--- a/UnitsNet.NumberExtensions/GeneratedCode/NumberToMolarityExtensions.g.cs
+++ b/UnitsNet.NumberExtensions/GeneratedCode/NumberToMolarityExtensions.g.cs
@@ -40,6 +40,10 @@ public static Molarity DecimolesPerLiter(this T value) =>
public static Molarity FemtomolesPerLiter(this T value) =>
Molarity.FromFemtomolesPerLiter(Convert.ToDouble(value));
+ ///
+ public static Molarity KilomolesPerCubicMeter(this T value) =>
+ Molarity.FromKilomolesPerCubicMeter(Convert.ToDouble(value));
+
///
public static Molarity MicromolesPerLiter(this T value) =>
Molarity.FromMicromolesPerLiter(Convert.ToDouble(value));
@@ -64,5 +68,9 @@ public static Molarity NanomolesPerLiter(this T value) =>
public static Molarity PicomolesPerLiter(this T value) =>
Molarity.FromPicomolesPerLiter(Convert.ToDouble(value));
+ ///
+ public static Molarity PoundMolesPerCubicFoot(this T value) =>
+ Molarity.FromPoundMolesPerCubicFoot(Convert.ToDouble(value));
+
}
}
diff --git a/UnitsNet.Tests/CustomCode/HeatTransferCoefficientTests.cs b/UnitsNet.Tests/CustomCode/HeatTransferCoefficientTests.cs
index 4e07e9c612..ab1846a381 100644
--- a/UnitsNet.Tests/CustomCode/HeatTransferCoefficientTests.cs
+++ b/UnitsNet.Tests/CustomCode/HeatTransferCoefficientTests.cs
@@ -30,6 +30,9 @@ public class HeatTransferCoefficientTests : HeatTransferCoefficientTestsBase
protected override bool SupportsSIUnitSystem => false;
protected override double WattsPerSquareMeterCelsiusInOneWattPerSquareMeterKelvin => 1;
protected override double WattsPerSquareMeterKelvinInOneWattPerSquareMeterKelvin => 1;
+ protected override double BtusPerHourSquareFootDegreeFahrenheitInOneWattPerSquareMeterKelvin => 1.7611018368230584e-1;
+ protected override double KilocaloriesPerHourSquareMeterDegreeCelsiusInOneWattPerSquareMeterKelvin => 0.859845227859;
protected override double BtusPerSquareFootDegreeFahrenheitInOneWattPerSquareMeterKelvin => 1.7611018368230584e-1;
+ protected override double CaloriesPerHourSquareMeterDegreeCelsiusInOneWattPerSquareMeterKelvin => 859.845227859;
}
}
diff --git a/UnitsNet.Tests/CustomCode/MolarFlowTests.cs b/UnitsNet.Tests/CustomCode/MolarFlowTests.cs
new file mode 100644
index 0000000000..f11828b446
--- /dev/null
+++ b/UnitsNet.Tests/CustomCode/MolarFlowTests.cs
@@ -0,0 +1,78 @@
+//------------------------------------------------------------------------------
+//
+// This code was generated by \generate-code.bat.
+//
+// Changes to this file will be lost when the code is regenerated.
+// The build server regenerates the code before each build and a pre-build
+// step will regenerate the code on each local build.
+//
+// See https://github.com/angularsen/UnitsNet/wiki/Adding-a-New-Unit for how to add or edit units.
+//
+// Add CustomCode\Quantities\MyQuantity.extra.cs files to add code to generated quantities.
+// Add UnitDefinitions\MyQuantity.json and run generate-code.bat to generate new units or quantities.
+//
+//
+//------------------------------------------------------------------------------
+
+// Licensed under MIT No Attribution, see LICENSE file at the root.
+// Copyright 2013 Andreas Gullberg Larsen (andreas.larsen84@gmail.com). Maintained at https://github.com/angularsen/UnitsNet.
+
+using System;
+using UnitsNet.Units;
+using Xunit;
+
+namespace UnitsNet.Tests.CustomCode
+{
+ public class MolarFlowTests : MolarFlowTestsBase
+ {
+ // Override properties in base class here
+ protected override bool SupportsSIUnitSystem => true;
+
+ protected override double KilomolesPerHourInOneMolePerSecond => 3.6;
+
+ protected override double KilomolesPerMinuteInOneMolePerSecond => 0.06;
+
+ protected override double KilomolesPerSecondInOneMolePerSecond => 0.001;
+
+ protected override double PoundMolesPerHourInOneMolePerSecond => 7.93664143866;
+
+ protected override double PoundMolesPerMinuteInOneMolePerSecond => 0.132277357311;
+
+ protected override double PoundMolesPerSecondInOneMolePerSecond => 2.2046226218488e-3;
+
+ protected override double MolesPerHourInOneMolePerSecond => 3600;
+
+ protected override double MolesPerMinuteInOneMolePerSecond => 60;
+
+ protected override double MolesPerSecondInOneMolePerSecond => 1.0;
+
+ [Fact]
+ public void MolarFlowTimesTimeSpanEqualsAmountOfSubstance()
+ {
+ AmountOfSubstance amount = MolarFlow.FromKilomolesPerSecond(20) * TimeSpan.FromSeconds(2);
+ Assert.Equal(AmountOfSubstance.FromKilomoles(40), amount);
+ }
+
+ [Fact]
+ public void MolarFlowTimesDurationEqualsAmountOfSubstance()
+ {
+ AmountOfSubstance amount = MolarFlow.FromKilomolesPerSecond(20) * Duration.FromSeconds(2);
+ Assert.Equal(AmountOfSubstance.FromKilomoles(40), amount);
+ }
+
+ [Fact]
+ public void MolarFlowTimesMolarMassEqualsMassFlow()
+ {
+ MassFlow massFlow = MolarFlow.FromKilomolesPerSecond(2) * MolarMass.FromKilogramsPerKilomole(3);
+ Assert.Equal(MassFlow.FromKilogramsPerSecond(6), massFlow);
+ }
+
+ [Fact]
+ public void MolarFlowOverMolarityEqualsVolumeFlow()
+ {
+ VolumeFlow volumeFlow = MolarFlow.FromKilomolesPerSecond(6) / Molarity.FromKilomolesPerCubicMeter(3);
+ Assert.Equal(VolumeFlow.FromCubicMetersPerSecond(2), volumeFlow);
+ }
+
+ }
+}
diff --git a/UnitsNet.Tests/CustomCode/MolarMassTests.cs b/UnitsNet.Tests/CustomCode/MolarMassTests.cs
index d954425a7a..264350bee0 100644
--- a/UnitsNet.Tests/CustomCode/MolarMassTests.cs
+++ b/UnitsNet.Tests/CustomCode/MolarMassTests.cs
@@ -42,6 +42,6 @@ public class MolarMassTests : MolarMassTestsBase
protected override double NanogramsPerMoleTolerance => 1e-3;
protected override double NanogramsPerMoleInOneKilogramPerMole => 1e12;
protected override double PoundsPerMoleInOneKilogramPerMole => 2.2046226218487757;
-
+ protected override double KilogramsPerKilomoleInOneKilogramPerMole => 1e3;
}
}
diff --git a/UnitsNet.Tests/CustomCode/MolarityTests.cs b/UnitsNet.Tests/CustomCode/MolarityTests.cs
index 7ff13f12b3..9d409e10d1 100644
--- a/UnitsNet.Tests/CustomCode/MolarityTests.cs
+++ b/UnitsNet.Tests/CustomCode/MolarityTests.cs
@@ -41,6 +41,8 @@ public class MolarityTests : MolarityTestsBase
protected override double MicromolesPerLiterInOneMolePerCubicMeter => 1e3;
protected override double NanomolesPerLiterInOneMolePerCubicMeter => 1e6;
protected override double PicomolesPerLiterInOneMolePerCubicMeter => 1e9;
+ protected override double KilomolesPerCubicMeterInOneMolePerCubicMeter => 1e-3;
+ protected override double PoundMolesPerCubicFootInOneMolePerCubicMeter => 6.242796e-5;
#endregion
diff --git a/UnitsNet.Tests/GeneratedCode/IQuantityTests.g.cs b/UnitsNet.Tests/GeneratedCode/IQuantityTests.g.cs
index ab0ba68c6e..63d87ca150 100644
--- a/UnitsNet.Tests/GeneratedCode/IQuantityTests.g.cs
+++ b/UnitsNet.Tests/GeneratedCode/IQuantityTests.g.cs
@@ -104,7 +104,8 @@ void Assertion(int expectedValue, Enum expectedUnit, IQuantity quantity)
Assertion(3, MassMomentOfInertiaUnit.TonneSquareMilimeter, Quantity.From(3, MassMomentOfInertiaUnit.TonneSquareMilimeter));
Assertion(3, MolarEnergyUnit.MegajoulePerMole, Quantity.From(3, MolarEnergyUnit.MegajoulePerMole));
Assertion(3, MolarEntropyUnit.MegajoulePerMoleKelvin, Quantity.From(3, MolarEntropyUnit.MegajoulePerMoleKelvin));
- Assertion(3, MolarityUnit.PicomolePerLiter, Quantity.From(3, MolarityUnit.PicomolePerLiter));
+ Assertion(3, MolarFlowUnit.PoundMolePerSecond, Quantity.From(3, MolarFlowUnit.PoundMolePerSecond));
+ Assertion(3, MolarityUnit.PoundMolePerCubicFoot, Quantity.From(3, MolarityUnit.PoundMolePerCubicFoot));
Assertion(3, MolarMassUnit.PoundPerMole, Quantity.From(3, MolarMassUnit.PoundPerMole));
Assertion(3, PermeabilityUnit.HenryPerMeter, Quantity.From(3, PermeabilityUnit.HenryPerMeter));
Assertion(3, PermittivityUnit.FaradPerMeter, Quantity.From(3, PermittivityUnit.FaradPerMeter));
@@ -228,6 +229,7 @@ public void QuantityInfo_IsSameAsStaticInfoProperty()
Assertion(MassMomentOfInertia.Info, MassMomentOfInertia.Zero);
Assertion(MolarEnergy.Info, MolarEnergy.Zero);
Assertion(MolarEntropy.Info, MolarEntropy.Zero);
+ Assertion(MolarFlow.Info, MolarFlow.Zero);
Assertion(Molarity.Info, Molarity.Zero);
Assertion(MolarMass.Info, MolarMass.Zero);
Assertion(Permeability.Info, Permeability.Zero);
@@ -352,6 +354,7 @@ public void Dimensions_IsSameAsStaticBaseDimensions()
Assertion(MassMomentOfInertia.BaseDimensions, MassMomentOfInertia.Zero);
Assertion(MolarEnergy.BaseDimensions, MolarEnergy.Zero);
Assertion(MolarEntropy.BaseDimensions, MolarEntropy.Zero);
+ Assertion(MolarFlow.BaseDimensions, MolarFlow.Zero);
Assertion(Molarity.BaseDimensions, Molarity.Zero);
Assertion(MolarMass.BaseDimensions, MolarMass.Zero);
Assertion(Permeability.BaseDimensions, Permeability.Zero);
diff --git a/UnitsNet.Tests/GeneratedCode/TestsBase/HeatTransferCoefficientTestsBase.g.cs b/UnitsNet.Tests/GeneratedCode/TestsBase/HeatTransferCoefficientTestsBase.g.cs
index 18d97a32b2..565a16cc33 100644
--- a/UnitsNet.Tests/GeneratedCode/TestsBase/HeatTransferCoefficientTestsBase.g.cs
+++ b/UnitsNet.Tests/GeneratedCode/TestsBase/HeatTransferCoefficientTestsBase.g.cs
@@ -38,12 +38,18 @@ namespace UnitsNet.Tests
// ReSharper disable once PartialTypeWithSinglePart
public abstract partial class HeatTransferCoefficientTestsBase : QuantityTestsBase
{
+ protected abstract double BtusPerHourSquareFootDegreeFahrenheitInOneWattPerSquareMeterKelvin { get; }
protected abstract double BtusPerSquareFootDegreeFahrenheitInOneWattPerSquareMeterKelvin { get; }
+ protected abstract double CaloriesPerHourSquareMeterDegreeCelsiusInOneWattPerSquareMeterKelvin { get; }
+ protected abstract double KilocaloriesPerHourSquareMeterDegreeCelsiusInOneWattPerSquareMeterKelvin { get; }
protected abstract double WattsPerSquareMeterCelsiusInOneWattPerSquareMeterKelvin { get; }
protected abstract double WattsPerSquareMeterKelvinInOneWattPerSquareMeterKelvin { get; }
// ReSharper disable VirtualMemberNeverOverriden.Global
+ protected virtual double BtusPerHourSquareFootDegreeFahrenheitTolerance { get { return 1e-5; } }
protected virtual double BtusPerSquareFootDegreeFahrenheitTolerance { get { return 1e-5; } }
+ protected virtual double CaloriesPerHourSquareMeterDegreeCelsiusTolerance { get { return 1e-5; } }
+ protected virtual double KilocaloriesPerHourSquareMeterDegreeCelsiusTolerance { get { return 1e-5; } }
protected virtual double WattsPerSquareMeterCelsiusTolerance { get { return 1e-5; } }
protected virtual double WattsPerSquareMeterKelvinTolerance { get { return 1e-5; } }
// ReSharper restore VirtualMemberNeverOverriden.Global
@@ -52,7 +58,10 @@ public abstract partial class HeatTransferCoefficientTestsBase : QuantityTestsBa
{
return unit switch
{
+ HeatTransferCoefficientUnit.BtuPerHourSquareFootDegreeFahrenheit => (BtusPerHourSquareFootDegreeFahrenheitInOneWattPerSquareMeterKelvin, BtusPerHourSquareFootDegreeFahrenheitTolerance),
HeatTransferCoefficientUnit.BtuPerSquareFootDegreeFahrenheit => (BtusPerSquareFootDegreeFahrenheitInOneWattPerSquareMeterKelvin, BtusPerSquareFootDegreeFahrenheitTolerance),
+ HeatTransferCoefficientUnit.CaloriePerHourSquareMeterDegreeCelsius => (CaloriesPerHourSquareMeterDegreeCelsiusInOneWattPerSquareMeterKelvin, CaloriesPerHourSquareMeterDegreeCelsiusTolerance),
+ HeatTransferCoefficientUnit.KilocaloriePerHourSquareMeterDegreeCelsius => (KilocaloriesPerHourSquareMeterDegreeCelsiusInOneWattPerSquareMeterKelvin, KilocaloriesPerHourSquareMeterDegreeCelsiusTolerance),
HeatTransferCoefficientUnit.WattPerSquareMeterCelsius => (WattsPerSquareMeterCelsiusInOneWattPerSquareMeterKelvin, WattsPerSquareMeterCelsiusTolerance),
HeatTransferCoefficientUnit.WattPerSquareMeterKelvin => (WattsPerSquareMeterKelvinInOneWattPerSquareMeterKelvin, WattsPerSquareMeterKelvinTolerance),
_ => throw new NotSupportedException()
@@ -61,7 +70,10 @@ public abstract partial class HeatTransferCoefficientTestsBase : QuantityTestsBa
public static IEnumerable