Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions Common/UnitDefinitions/AreaDensity.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,10 @@
{
"SingularName": "KilogramPerSquareMeter",
"PluralName": "KilogramsPerSquareMeter",
"BaseUnits": {
"L": "Meter",
"M": "Kilogram"
},
"FromUnitToBaseFunc": "x",
"FromBaseToUnitFunc": "x",
"Localization": [
Expand Down
18 changes: 18 additions & 0 deletions Common/UnitDefinitions/AreaMomentOfInertia.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,9 @@
{
"SingularName": "MeterToTheFourth",
"PluralName": "MetersToTheFourth",
"BaseUnits": {
"L": "Meter"
},
"FromUnitToBaseFunc": "x",
"FromBaseToUnitFunc": "x",
"Localization": [
Expand All @@ -21,6 +24,9 @@
{
"SingularName": "DecimeterToTheFourth",
"PluralName": "DecimetersToTheFourth",
"BaseUnits": {
"L": "Decimeter"
},
"FromUnitToBaseFunc": "x/1e4",
"FromBaseToUnitFunc": "x*1e4",
"Localization": [
Expand All @@ -33,6 +39,9 @@
{
"SingularName": "CentimeterToTheFourth",
"PluralName": "CentimetersToTheFourth",
"BaseUnits": {
"L": "Centimeter"
},
"FromUnitToBaseFunc": "x/1e8",
"FromBaseToUnitFunc": "x*1e8",
"Localization": [
Expand All @@ -45,6 +54,9 @@
{
"SingularName": "MillimeterToTheFourth",
"PluralName": "MillimetersToTheFourth",
"BaseUnits": {
"L": "Millimeter"
},
"FromUnitToBaseFunc": "x/1e12",
"FromBaseToUnitFunc": "x*1e12",
"Localization": [
Expand All @@ -57,6 +69,9 @@
{
"SingularName": "FootToTheFourth",
"PluralName": "FeetToTheFourth",
"BaseUnits": {
"L": "Foot"
},
"FromUnitToBaseFunc": "x*Math.Pow(0.3048, 4)",
"FromBaseToUnitFunc": "x/Math.Pow(0.3048, 4)",
"Localization": [
Expand All @@ -69,6 +84,9 @@
{
"SingularName": "InchToTheFourth",
"PluralName": "InchesToTheFourth",
"BaseUnits": {
"L": "Inch"
},
"FromUnitToBaseFunc": "x*Math.Pow(2.54e-2, 4)",
"FromBaseToUnitFunc": "x/Math.Pow(2.54e-2, 4)",
"Localization": [
Expand Down
6 changes: 6 additions & 0 deletions Common/UnitDefinitions/Capacitance.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,12 @@
{
"SingularName": "Farad",
"PluralName": "Farads",
"BaseUnits": {
"L": "Meter",
"M": "Kilogram",
"T": "Second",
"I": "Ampere"
},
"FromUnitToBaseFunc": "x",
"FromBaseToUnitFunc": "x",
"Prefixes": [ "Pico", "Nano", "Micro", "Milli", "Kilo", "Mega" ],
Expand Down
9 changes: 9 additions & 0 deletions Common/UnitDefinitions/CoefficientOfThermalExpansion.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,9 @@
{
"SingularName": "InverseKelvin",
"PluralName": "InverseKelvin",
"BaseUnits": {
"Θ": "Kelvin"
},
"FromUnitToBaseFunc": "x",
"FromBaseToUnitFunc": "x",
"Localization": [
Expand All @@ -21,6 +24,9 @@
{
"SingularName": "InverseDegreeCelsius",
"PluralName": "InverseDegreeCelsius",
"BaseUnits": {
"Θ": "DegreeCelsius"
},
"FromUnitToBaseFunc": "x",
"FromBaseToUnitFunc": "x",
"Localization": [
Expand All @@ -33,6 +39,9 @@
{
"SingularName": "InverseDegreeFahrenheit",
"PluralName": "InverseDegreeFahrenheit",
"BaseUnits": {
"Θ": "DegreeFahrenheit"
},
"FromUnitToBaseFunc": "x*5/9",
"FromBaseToUnitFunc": "x*9/5",
"Localization": [
Expand Down
36 changes: 36 additions & 0 deletions Common/UnitDefinitions/Density.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,10 @@
{
"SingularName": "GramPerCubicMillimeter",
"PluralName": "GramsPerCubicMillimeter",
"BaseUnits": {
"L": "Millimeter",
"M": "Gram"
},
"FromUnitToBaseFunc": "x/1e-6",
"FromBaseToUnitFunc": "x*1e-6",
"Prefixes": [ "Kilo" ],
Expand All @@ -24,6 +28,10 @@
{
"SingularName": "GramPerCubicCentimeter",
"PluralName": "GramsPerCubicCentimeter",
"BaseUnits": {
"L": "Centimeter",
"M": "Gram"
},
"FromUnitToBaseFunc": "x/1e-3",
"FromBaseToUnitFunc": "x*1e-3",
"Prefixes": [ "Kilo" ],
Expand All @@ -37,6 +45,10 @@
{
"SingularName": "GramPerCubicMeter",
"PluralName": "GramsPerCubicMeter",
"BaseUnits": {
"L": "Meter",
"M": "Gram"
},
"FromUnitToBaseFunc": "x/1e3",
"FromBaseToUnitFunc": "x*1e3",
"Prefixes": [ "Kilo", "Milli", "Micro" ],
Expand All @@ -54,6 +66,10 @@
{
"SingularName": "PoundPerCubicInch",
"PluralName": "PoundsPerCubicInch",
"BaseUnits": {
"L": "Inch",
"M": "Pound"
},
"FromUnitToBaseFunc": "x/3.6127298147753e-5",
"FromBaseToUnitFunc": "x*3.6127298147753e-5",
"Prefixes": [ "Kilo" ],
Expand All @@ -68,6 +84,10 @@
{
"SingularName": "PoundPerCubicFoot",
"PluralName": "PoundsPerCubicFoot",
"BaseUnits": {
"L": "Foot",
"M": "Pound"
},
"FromUnitToBaseFunc": "x/0.062427961",
"FromBaseToUnitFunc": "x*0.062427961",
"Prefixes": [ "Kilo" ],
Expand All @@ -82,6 +102,10 @@
{
"SingularName": "TonnePerCubicMillimeter",
"PluralName": "TonnesPerCubicMillimeter",
"BaseUnits": {
"L": "Millimeter",
"M": "Tonne"
},
"FromUnitToBaseFunc": "x/1e-12",
"FromBaseToUnitFunc": "x*1e-12",
"Localization": [
Expand All @@ -94,6 +118,10 @@
{
"SingularName": "TonnePerCubicCentimeter",
"PluralName": "TonnesPerCubicCentimeter",
"BaseUnits": {
"L": "Centimeter",
"M": "Tonne"
},
"FromUnitToBaseFunc": "x/1e-9",
"FromBaseToUnitFunc": "x*1e-9",
"Localization": [
Expand All @@ -106,6 +134,10 @@
{
"SingularName": "TonnePerCubicMeter",
"PluralName": "TonnesPerCubicMeter",
"BaseUnits": {
"L": "Meter",
"M": "Tonne"
},
"FromUnitToBaseFunc": "x/0.001",
"FromBaseToUnitFunc": "x*0.001",
"Localization": [
Expand All @@ -118,6 +150,10 @@
{
"SingularName": "SlugPerCubicFoot",
"PluralName": "SlugsPerCubicFoot",
"BaseUnits": {
"L": "Foot",
"M": "Slug"
},
"FromUnitToBaseFunc": "x*515.378818",
"FromBaseToUnitFunc": "x*0.00194032033",
"Localization": [
Expand Down
17 changes: 16 additions & 1 deletion Common/UnitDefinitions/Force.json
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{
{
"Name": "Force",
"BaseUnit": "Newton",
"XmlDoc": "In physics, a force is any influence that causes an object to undergo a certain change, either concerning its movement, direction, or geometrical construction. In other words, a force can cause an object with mass to change its velocity (which includes to begin moving from a state of rest), i.e., to accelerate, or a flexible object to deform, or both. Force can also be described by intuitive concepts such as a push or a pull. A force has both magnitude and direction, making it a vector quantity. It is measured in the SI unit of newtons and represented by the symbol F.",
Expand All @@ -11,6 +11,11 @@
{
"SingularName": "Dyn",
"PluralName": "Dyne",
"BaseUnits": {
"L": "Centimeter",
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Where do you look up these facts? I have no prior reference. Do you google each you are unsure about or do you have a goto-source? I found this one on wiki.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Here's one for dyne:

The dyne is defined as "the force required to accelerate a mass of one gram at a rate of one centimetre per second per second"

Or try this:

Unit system:
centimeter-gram-second (cgs)

Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks

"M": "Gram",
"T": "Second"
},
"FromUnitToBaseFunc": "x/1e5",
"FromBaseToUnitFunc": "x*1e5",
"Localization": [
Expand Down Expand Up @@ -59,6 +64,11 @@
{
"SingularName": "Newton",
"PluralName": "Newtons",
"BaseUnits": {
"L": "Meter",
"M": "Kilogram",
"T": "Second"
},
"FromUnitToBaseFunc": "x",
"FromBaseToUnitFunc": "x",
"Prefixes": [ "Micro", "Milli", "Deca", "Kilo", "Mega" ],
Expand Down Expand Up @@ -93,6 +103,11 @@
{
"SingularName": "Poundal",
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I see there is a notion of foot-pound-second system and centimeter-gram-second system (CGS / Gauss).
I'll create a PR to discuss adding those.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Indeed there is. CGS, FPS, MKS

"PluralName": "Poundals",
"BaseUnits": {
"L": "Foot",
"M": "Pound",
"T": "Second"
},
"FromUnitToBaseFunc": "x*0.13825502798973041652092282466083",
"FromBaseToUnitFunc": "x/0.13825502798973041652092282466083",
"Localization": [
Expand Down

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

18 changes: 9 additions & 9 deletions UnitsNet/GeneratedCode/Quantities/Density.NetFramework.g.cs

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 3 additions & 3 deletions UnitsNet/GeneratedCode/Quantities/Force.NetFramework.g.cs

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.