Skip to content

Commit 3b74e19

Browse files
piotrstenkePiotr Stenke
and
Piotr Stenke
authored
Add radiation equivalent dose (#1352)
Added radiation equivalent dose and its two units - Sievert (SI-derived) and Roentgen equivalent man (or, simply, rem). Sievert comes with three prefixes - milli, micro, nano. This will support 99% of usecases, ranging from radiation caused by Earth itself (~6 to 83nSv/h, per this [article](https://www.epa.gov/radnet/about-exposure-and-dose-rates)), [eating bananas](https://en.wikipedia.org/wiki/Banana_equivalent_dose) (yep, that's a real unit), X-rays or tomography scans, as well as measuring health risk of radiation-induced cancer and radiation sickness. Roentgen equivalent man is mostly used in the US, and it can be easily converted to sieverts (1 sievert = 100 rems). It includes only one prefix - milli - as I did not find any sources with other prefixes being used. Wikipedia pages: https://en.wikipedia.org/wiki/Equivalent_dose https://en.wikipedia.org/wiki/Sievert https://en.wikipedia.org/wiki/Roentgen_equivalent_man https://en.wikipedia.org/wiki/Orders_of_magnitude_(radiation) --------- Co-authored-by: Piotr Stenke <[email protected]>
1 parent 85aec1b commit 3b74e19

18 files changed

+2561
-0
lines changed
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,48 @@
1+
{
2+
"Name": "RadiationEquivalentDose",
3+
"BaseUnit": "Sievert",
4+
"XmlDocSummary": "Equivalent dose is a dose quantity representing the stochastic health effects of low levels of ionizing radiation on the human body which represents the probability of radiation-induced cancer and genetic damage.",
5+
"XmlDocsRemarks": "https://en.wikipedia.org/wiki/Equivalent_dose",
6+
"BaseDimensions": {
7+
"L": 2,
8+
"T": -2
9+
},
10+
"Units": [
11+
{
12+
"SingularName": "Sievert",
13+
"PluralName": "Sieverts",
14+
"FromUnitToBaseFunc": "{x}",
15+
"FromBaseToUnitFunc": "{x}",
16+
"BaseUnits": {
17+
"L": "Meter",
18+
"T": "Second"
19+
},
20+
"Prefixes": [ "Nano", "Micro", "Milli" ],
21+
"XmlDocSummary": "The sievert is a unit in the International System of Units (SI) intended to represent the stochastic health risk of ionizing radiation, which is defined as the probability of causing radiation-induced cancer and genetic damage.",
22+
"XmlDocRemarks": "https://en.wikipedia.org/wiki/Sievert",
23+
"Localization": [
24+
{
25+
"Culture": "en-US",
26+
"Abbreviations": [ "Sv" ]
27+
},
28+
{
29+
"Culture": "ru-RU",
30+
"Abbreviations": [ "Зв" ]
31+
}
32+
]
33+
},
34+
{
35+
"SingularName": "RoentgenEquivalentMan",
36+
"PluralName": "RoentgensEquivalentMan",
37+
"FromUnitToBaseFunc": "{x} / 100",
38+
"FromBaseToUnitFunc": "{x} * 100",
39+
"Prefixes": [ "Milli" ],
40+
"Localization": [
41+
{
42+
"Culture": "en-US",
43+
"Abbreviations": [ "rem" ]
44+
}
45+
]
46+
}
47+
]
48+
}

Common/UnitEnumValues.g.json

+10
Original file line numberDiff line numberDiff line change
@@ -1845,5 +1845,15 @@
18451845
"Roentgen": 4,
18461846
"Microroentgen": 12,
18471847
"Milliroentgen": 13
1848+
},
1849+
"RadiationEquivalentDose": {
1850+
"Microsievert": 1,
1851+
"MilliroentgenEquivalentMan": 2,
1852+
"Millisievert": 7,
1853+
"Nanosievert": 5,
1854+
"RoentgenEquivalentMan": 4,
1855+
"Sievert": 9,
1856+
"Kilosievert": 3,
1857+
"Megasievert": 6
18481858
}
18491859
}

UnitsNet.NanoFramework/GeneratedCode/Quantities/RadiationEquivalentDose.g.cs

+224
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
<?xml version="1.0" encoding="utf-8"?>
2+
<Project ToolsVersion="15.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
3+
<PropertyGroup Label="Globals">
4+
<NanoFrameworkProjectSystemPath>$(MSBuildExtensionsPath)\nanoFramework\v1.0\</NanoFrameworkProjectSystemPath>
5+
</PropertyGroup>
6+
<Import Project="$(NanoFrameworkProjectSystemPath)NFProjectSystem.Default.props" Condition="Exists('$(NanoFrameworkProjectSystemPath)NFProjectSystem.Default.props')" />
7+
<PropertyGroup>
8+
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
9+
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
10+
<ProjectTypeGuids>{11A8DD76-328B-46DF-9F39-F559912D0360};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}</ProjectTypeGuids>
11+
<ProjectGuid>{dcdccf04-c930-b455-77a4-d9d4a7df8723}</ProjectGuid>
12+
<OutputType>Library</OutputType>
13+
<AppDesignerFolder>Properties</AppDesignerFolder>
14+
<FileAlignment>512</FileAlignment>
15+
<RootNamespace>UnitsNet</RootNamespace>
16+
<AssemblyName>UnitsNet.RadiationEquivalentDose</AssemblyName>
17+
<TargetFrameworkVersion>v1.0</TargetFrameworkVersion>
18+
<DocumentationFile>bin\$(Configuration)\$(AssemblyName).xml</DocumentationFile>
19+
</PropertyGroup>
20+
<Import Project="$(NanoFrameworkProjectSystemPath)NFProjectSystem.props" Condition="Exists('$(NanoFrameworkProjectSystemPath)NFProjectSystem.props')" />
21+
<ItemGroup>
22+
<Compile Include="..\Quantities\RadiationEquivalentDose.g.cs" />
23+
<Compile Include="..\Units\RadiationEquivalentDoseUnit.g.cs" />
24+
<Compile Include="..\Properties\AssemblyInfo.cs" />
25+
</ItemGroup>
26+
<ItemGroup>
27+
<Reference Include="mscorlib, Version=1.15.6.0, Culture=neutral, PublicKeyToken=c07d481e9758c731">
28+
<HintPath>..\packages\nanoFramework.CoreLibrary.1.15.5\lib\mscorlib.dll</HintPath>
29+
<Private>True</Private>
30+
<SpecificVersion>True</SpecificVersion>
31+
</Reference>
32+
</ItemGroup>
33+
<ItemGroup>
34+
<None Include="packages.config" />
35+
</ItemGroup>
36+
<Import Project="$(NanoFrameworkProjectSystemPath)NFProjectSystem.CSharp.targets" Condition="Exists('$(NanoFrameworkProjectSystemPath)NFProjectSystem.CSharp.targets')" />
37+
<ProjectExtensions>
38+
<ProjectCapabilities>
39+
<ProjectConfigurationsDeclaredAsItems />
40+
</ProjectCapabilities>
41+
</ProjectExtensions>
42+
</Project>
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
<?xml version="1.0" encoding="utf-8"?>
2+
<package xmlns="http://schemas.microsoft.com/packaging/2012/06/nuspec.xsd">
3+
<metadata>
4+
<id>UnitsNet.nanoFramework.RadiationEquivalentDose</id>
5+
<version>5.42.0</version>
6+
<title>Units.NET RadiationEquivalentDose - nanoFramework</title>
7+
<authors>Andreas Gullberg Larsen,nanoframework</authors>
8+
<owners>UnitsNet</owners>
9+
<license type="expression">MIT</license>
10+
<projectUrl>https://github.com/angularsen/UnitsNet</projectUrl>
11+
<requireLicenseAcceptance>false</requireLicenseAcceptance>
12+
<description>Adds RadiationEquivalentDose units for Units.NET on .NET nanoFramework. For .NET or .NET Core, use UnitsNet instead.</description>
13+
<iconUrl>https://raw.githubusercontent.com/angularsen/UnitsNet/ce85185429be345d77eb2ce09c99d59cc9ab8aed/Docs/Images/logo-32.png</iconUrl>
14+
<releaseNotes>
15+
</releaseNotes>
16+
<copyright>Copyright 2013 Andreas Gullberg Larsen ([email protected]).</copyright>
17+
<language>en-US</language>
18+
<tags>nanoframework radiationequivalentdose unit units quantity quantities measurement si metric imperial abbreviation abbreviations convert conversion parse immutable</tags>
19+
<dependencies>
20+
<dependency id="nanoFramework.CoreLibrary" version="1.15.5" />
21+
</dependencies>
22+
</metadata>
23+
<files>
24+
<file src="..\..\..\Artifacts\UnitsNet.NanoFramework\RadiationEquivalentDose\UnitsNet.*" target="lib" />
25+
</files>
26+
</package>
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
<?xml version="1.0" encoding="utf-8"?>
2+
<packages>
3+
<package id="nanoFramework.CoreLibrary" version="1.15.5" targetFramework="netnanoframework10" />
4+
</packages>

0 commit comments

Comments
 (0)