radiopurity / persephone

A material assay database
www.radiopurity.org
Apache License 2.0
12 stars 5 forks source link

Automatic conversion of element names in search #13

Open nepahwin opened 11 years ago

nepahwin commented 11 years ago

Default searches (on name and description) should include automatic contraction and expansion of element names. A search for 'Ge' or 'germanium' should become one for 'Ge AND germanium'. Also account for UK element names: 'aluminum' or 'aluminium' becomes 'aluminum AND aluminium'. Also sulphur/sulfur. Any others?

nepahwin commented 11 years ago

Obviously it should be case-insensitive and we should substitute with AND's as I described. We also want to check chemical elements are separate sentence units - e.g. " Ag " not just "Ag".

Symbol Name (US) Name (UK) Al Aluminum Aluminium Sb Antimony
Ar Argon
As Arsenic Ba Barium
Be Beryllium
Bi Bismuth B Boron
Br Bromine Cd Cadmium Cs Cesium Ceasium Ca Calcium C Carbon
Ce Cerium
Cl Chlorine
Cr Chromium
Co Cobalt
Cu Copper
Dy Dysprosium
Er Erbium
Eu Europium
F Fluorine
Gd Gadolinium
Ga Gallium Ge Germanium
Au Gold
Hf Hafnium He Helium
Ho Holmium H Hydrogen
In Indium
I Iodine
Ir Iridium Fe Iron
Kr Krypton La Lanthanum
Pb Lead
Li Lithium Lu Lutetium
Mg Magnesium
Mn Manganese
Hg Mercury Mo Molybdenum
Nd Neodymium
Ne Neon
Ni Nickel
Nb Niobium N Nitrogen
Os Osmium
O Oxygen
Pd Palladium
P Phosphorus
Pt Platinum
Pu Plutonium
K Potassium
Pr Praseodymium
Re Rhenium Rh Rhodium Rb Rubidium
Ru Ruthenium
Sm Samarium
Sc Scandium
Se Selenium
Si Silicon Ag Silver
Na Sodium
Sr Strontium
S Sulfur Sulpher Ta Tantalum
Te Tellurium
Tb Terbium Tl Thallium
Th Thorium Tm Thulium Sn Tin Ti Titanium
W Tungsten
U Uranium V Vanadium
Xe Xenon
Yb Ytterbium
Y Yttrium Zn Zinc
Zr Zirconium

nepahwin commented 11 years ago

We could also do these:

H2O <-> water SS <-> stainless steel

nepahwin commented 11 years ago

Perhaps these should be in a configuration document. e.g. in indexes/config.json