Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

New Units - Molecular Mass (Dalton) #1397

Open
rogerfydp opened this issue Jun 18, 2024 · 2 comments
Open

New Units - Molecular Mass (Dalton) #1397

rogerfydp opened this issue Jun 18, 2024 · 2 comments

Comments

@rogerfydp
Copy link

rogerfydp commented Jun 18, 2024

Is your feature request related to a problem? Please describe.
Within existing quantity Mass there is no units often used for "Molecular mass"

Describe the solution you'd like
Molecular mass (m) is the mass of a given molecule. The unit dalton (Da) is often used.

Will be nice to extend the quantity mass (if it's the proper one) to include Dalton (unit) such as,

  • Daltons (Da) - Used for individual molecules or small biomolecules.
  • Kilodaltons (kDa) - Used for larger molecules, such as proteins.
  • Megadaltons (MDa) - Used for very large molecular complexes, such as viruses and large protein assemblies.
  • Gigadaltons (GDa) - Used for extremely large molecular structures.

Describe alternatives you've considered
None. Using other mass units for 'molecular mass' is not common.

@angularsen
Copy link
Owner

Hi, sure this sounds reasonable to add.
Would you be interested in attempting a pull request? I'm happy to assist.

Detailed steps here:
https://github.com/angularsen/UnitsNet/wiki/Adding-a-New-Unit

@rogerfydp
Copy link
Author

Hi, thanks for accepting it!

I can do a pull request, no problem.

I was adding the quantity mass.json in the following way,

{
  "SingularName": "Dalton",
  "PluralName": "Daltons",
  "BaseUnits": {
    "M": "Dalton"
  },
  "FromUnitToBaseFunc": "{x} * 1.66053906660e-27",
  "FromBaseToUnitFunc": "{x} / 1.66053906660e-27",
  "Prefixes": ["Kilo", "Mega", "Giga"],
  "Localization": [
    {
      "Culture": "en-US",
      "Abbreviations": ["Da"]
    }
  ],
  "XmlDocSummary": "A Dalton, also known as the unified atomic mass unit, is a unit of mass commonly used to express the mass of atoms and molecules. It is defined as one twelfth of the mass of an unbound neutral atom of carbon-12 in its nuclear and electronic ground state.",
  "XmlDocRemarks": "https://en.wikipedia.org/wiki/Dalton_(unit)"
}

Taking initially the value from Wikipedia. But when double checking with other sources I see variations, here some examples.

Source Value
Wikipedia 1.66053906892(52)×10−27 kg
CODATA (2018) (page 50) 1.66053906660(50)x10−27
UCLA 1.660538921x10−27 kg
chemeurope.com 1.660538782(83)×10−27 kg

On the other hand, on Wikipedia's article, in the references we can find

Therefor I would like your opinion on the value to take, to comply with your project. Do you have any other reference or source?

Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants