All Downloads are FREE. Search and download functionalities are using the official Maven repository.

se.lth.immun.chem.Element Maven / Gradle / Ivy

Go to download

Library for general purpose in silico chemistry, mainly intended for mass spectrometry proteomics computations.

There is a newer version: 1.3.3
Show newest version
package se.lth.immun.chem;

public enum Element {
	H 	("H", 	1, 	1.007940, 	new double[]{1.00782503207, 2.0141017778, 3.0160492777}, new double[]{0.999885, 0.000115, 0.0}, new int[]{1, 2, 3}),
	H2 	("2H", 	1, 	2.0141017778, 	new double[]{2.0141017778}, new double[]{1.0}, new int[]{2}),
	He 	("He", 	2, 	4.002602, 	new double[]{3.0160293191, 4.00260325415}, new double[]{1.34e-06, 0.99999866}, new int[]{3, 4}),
	Li 	("Li", 	3, 	6.941000, 	new double[]{6.015122795, 7.01600455}, new double[]{0.0759, 0.9241}, new int[]{6, 7}),
	Be 	("Be", 	4, 	9.012182, 	new double[]{9.0121822}, new double[]{1.0}, new int[]{9}),
	B 	("B", 	5, 	10.811000, 	new double[]{10.012937, 11.0093054}, new double[]{0.199, 0.801}, new int[]{10, 11}),
	C 	("C", 	6, 	12.010700, 	new double[]{12.0, 13.0033548378, 14.003241989}, new double[]{0.9893, 0.0107, 0.0}, new int[]{12, 13, 14}),
	C13 ("13C", 6, 	13.0033548378, new double[]{13.0033548378}, new double[]{1.0}, new int[]{13}),
	N 	("N", 	7, 	14.006700, 	new double[]{14.0030740048, 15.0001088982}, new double[]{0.99636, 0.00364}, new int[]{14, 15}),
	N15 ("15N", 7, 	15.0001088982, new double[]{15.0001088982}, new double[]{1.0}, new int[]{15}),
	O 	("O", 	8, 	15.999400, 	new double[]{15.99491461956, 16.9991317, 17.999161}, new double[]{0.99757, 0.00038, 0.00205}, new int[]{16, 17, 18}),
	O18 ("18O", 8, 	17.999161, 	new double[]{17.999161}, new double[]{1.0}, new int[]{18}),
	F 	("F", 	9, 	18.998403, 	new double[]{18.99840322}, new double[]{1.0}, new int[]{19}),
	Ne 	("Ne", 	10, 20.179700, 	new double[]{19.9924401754, 20.99384668, 21.991385114}, new double[]{0.9048, 0.0027, 0.0925}, new int[]{20, 21, 22}),
	Na 	("Na", 	11, 22.989769, 	new double[]{22.9897692809}, new double[]{1.0}, new int[]{23}),
	Mg 	("Mg", 	12, 24.305000, 	new double[]{23.9850417, 24.98583692, 25.982592929}, new double[]{0.7899, 0.1, 0.1101}, new int[]{24, 25, 26}),
	Al 	("Al", 	13, 26.981539, 	new double[]{26.98153863}, new double[]{1.0}, new int[]{27}),
	Si 	("Si", 	14, 28.085500, 	new double[]{27.9769265325, 28.9764947, 29.97377017}, new double[]{0.92223, 0.04685, 0.03092}, new int[]{28, 29, 30}),
	P 	("P", 	15, 30.973762, 	new double[]{30.97376163}, new double[]{1.0}, new int[]{31}),
	S 	("S", 	16, 32.065000, 	new double[]{31.972071, 32.97145876, 33.9678669, 35.96708076}, new double[]{0.9499, 0.0075, 0.0425, 0.0001}, new int[]{32, 33, 34, 36}),
	Cl 	("Cl", 	17, 35.453000, 	new double[]{34.96885268, 36.96590259}, new double[]{0.7576, 0.2424}, new int[]{35, 37}),
	Ar 	("Ar", 	18, 39.948000, 	new double[]{35.96754510, 37.9627324, 39.9623831225}, new double[]{0.003365, 0.000632, 0.996003}, new int[]{36, 38, 40}),
	K 	("K", 	19, 39.098300, 	new double[]{38.96370668, 39.96399848, 40.96182576}, new double[]{0.932581, 0.000117, 0.067302}, new int[]{39, 40, 41}),
	Ca 	("Ca", 	20, 40.078000, 	new double[]{39.96259098, 41.95861801, 42.9587666, 43.9554818, 45.9536926, 47.952534}, new double[]{0.96941, 0.00647, 0.00135, 0.02086, 4e-05, 0.00187}, new int[]{40, 42, 43, 44, 46, 48}),
	Sc 	("Sc", 	21, 44.955912, 	new double[]{44.9559119}, new double[]{1.0}, new int[]{45}),
	Ti 	("Ti", 	22, 47.867000, 	new double[]{45.9526316, 46.9517631, 47.9479463, 48.94787, 49.9447912}, new double[]{0.0825, 0.0744, 0.7372, 0.0541, 0.0518}, new int[]{46, 47, 48, 49, 50}),
	V 	("V", 	23, 50.941500, 	new double[]{49.9471585, 50.9439595}, new double[]{0.0025, 0.9975}, new int[]{50, 51}),
	Cr 	("Cr", 	24, 51.996100, 	new double[]{49.9460442, 51.9405075, 52.9406494, 53.9388804}, new double[]{0.04345, 0.83789, 0.09501, 0.02365}, new int[]{50, 52, 53, 54}),
	Mn 	("Mn", 	25, 54.938045, 	new double[]{54.9380451}, new double[]{1.0}, new int[]{55}),
	Fe 	("Fe", 	26, 55.845000, 	new double[]{53.9396105, 55.9349375, 56.935394, 57.9332756}, new double[]{0.05845, 0.91754, 0.02119, 0.00282}, new int[]{54, 56, 57, 58}),
	Co 	("Co", 	27, 58.933195, 	new double[]{58.933195}, new double[]{1.0}, new int[]{59}),
	Ni 	("Ni", 	28, 58.693400, 	new double[]{57.9353429, 59.9307864, 60.931056, 61.9283451, 63.927966}, new double[]{0.680769, 0.262231, 0.011399, 0.036345, 0.009256}, new int[]{58, 60, 61, 62, 64}),
	Cu 	("Cu", 	29, 63.546000, 	new double[]{62.9295975, 64.9277895}, new double[]{0.6915, 0.3085}, new int[]{63, 65}),
	Zn 	("Zn", 	30, 65.380000, 	new double[]{63.9291422, 65.9260334, 66.9271273, 67.9248442, 69.9253193}, new double[]{0.48268, 0.27975, 0.04102, 0.19024, 0.00631}, new int[]{64, 66, 67, 68, 70}),
	Ga 	("Ga", 	31, 69.723000, 	new double[]{68.9255736, 70.9247013}, new double[]{0.60108, 0.39892}, new int[]{69, 71}),
	Ge 	("Ge", 	32, 72.640000, 	new double[]{69.9242474, 71.9220758, 72.9234589, 73.9211778, 75.9214026}, new double[]{0.2038, 0.2731, 0.0776, 0.3672, 0.0783}, new int[]{70, 72, 73, 74, 76}),
	As 	("As", 	33, 74.921600, 	new double[]{74.9215965}, new double[]{1.0}, new int[]{75}),
	Se 	("Se", 	34, 78.960000, 	new double[]{73.9224764, 75.9192136, 76.919914, 77.9173091, 79.9165213, 81.9166994}, new double[]{0.0089, 0.0937, 0.0763, 0.2377, 0.4961, 0.0873}, new int[]{74, 76, 77, 78, 80, 82}),
	Br 	("Br", 	35, 79.904000, 	new double[]{78.9183371, 80.9162906}, new double[]{0.5069, 0.4931}, new int[]{79, 81}),
	Kr 	("Kr", 	36, 83.798000, 	new double[]{77.9203648, 79.916379, 81.9134836, 82.914136, 83.911507, 85.91061073}, new double[]{0.00355, 0.02286, 0.11593, 0.115, 0.56987, 0.17279}, new int[]{78, 80, 82, 83, 84, 86}),
	Rb 	("Rb", 	37, 85.467800, 	new double[]{84.911789738, 86.909180527}, new double[]{0.7217, 0.2783}, new int[]{85, 87}),
	Sr 	("Sr", 	38, 87.620000, 	new double[]{83.913425, 85.9092602, 86.9088771, 87.9056121}, new double[]{0.0056, 0.0986, 0.07, 0.8258}, new int[]{84, 86, 87, 88}),
	Y 	("Y", 	39, 88.905850, 	new double[]{88.9058483}, new double[]{1.0}, new int[]{89}),
	Zr 	("Zr", 	40, 91.224000, 	new double[]{89.9047044, 90.9056458, 91.9050408, 93.9063152, 95.9082734}, new double[]{0.5145, 0.1122, 0.1715, 0.1738, 0.028}, new int[]{90, 91, 92, 94, 96}),
	Nb 	("Nb", 	41, 92.906380, 	new double[]{92.9063781}, new double[]{1.0}, new int[]{93}),
	Mo 	("Mo", 	42, 95.960000, 	new double[]{91.906811, 93.9050883, 94.9058421, 95.9046795, 96.9060215, 97.9054082, 99.907477}, new double[]{0.1477, 0.0923, 0.159, 0.1668, 0.0956, 0.2419, 0.0967}, new int[]{92, 94, 95, 96, 97, 98, 100}),
	Tc 	("Tc", 	43, 98.000000, 	new double[]{96.906365, 97.907216, 98.9062547}, new double[]{0.0, 0.0, 0.0}, new int[]{97, 98, 99}),
	Ru 	("Ru", 	44, 101.070000, new double[]{95.907598, 97.905287, 98.9059393, 99.9042195, 100.9055821, 101.9043493, 103.905433}, new double[]{0.0554, 0.0187, 0.1276, 0.126, 0.1706, 0.3155, 0.1862}, new int[]{96, 98, 99, 100, 101, 102, 104}),
	Rh 	("Rh", 	45, 102.905500, new double[]{102.905504}, new double[]{1.0}, new int[]{103}),
	Pd 	("Pd", 	46, 106.420000, new double[]{101.905609, 103.904036, 104.905085, 105.903486, 107.903892, 109.905153}, new double[]{0.0102, 0.1114, 0.2233, 0.2733, 0.2646, 0.1172}, new int[]{102, 104, 105, 106, 108, 110}),
	Ag 	("Ag", 	47, 107.868200, new double[]{106.905097, 108.904752}, new double[]{0.51839, 0.48161}, new int[]{107, 109}),
	Cd 	("Cd", 	48, 112.411000, new double[]{105.906459, 107.904184, 109.9030021, 110.9041781, 111.9027578, 112.9044017, 113.9033585, 115.904756}, new double[]{0.0125, 0.0089, 0.1249, 0.128, 0.2413, 0.1222, 0.2873, 0.0749}, new int[]{106, 108, 110, 111, 112, 113, 114, 116}),
	In 	("In", 	49, 114.818000, new double[]{112.904058, 114.903878}, new double[]{0.0429, 0.9571}, new int[]{113, 115}),
	Sn 	("Sn", 	50, 118.710000, new double[]{111.904818, 113.902779, 114.903342, 115.901741, 116.902952, 117.901603, 118.903308, 119.9021947, 121.903439, 123.9052739}, new double[]{0.0097, 0.0066, 0.0034, 0.1454, 0.0768, 0.2422, 0.0859, 0.3258, 0.0463, 0.0579}, new int[]{112, 114, 115, 116, 117, 118, 119, 120, 122, 124}),
	Sb 	("Sb", 	51, 121.760000, new double[]{120.9038157, 122.904214}, new double[]{0.5721, 0.4279}, new int[]{121, 123}),
	Te 	("Te", 	52, 127.600000, new double[]{119.90402, 121.9030439, 122.90427, 123.9028179, 124.9044307, 125.9033117, 127.9044631, 129.9062244}, new double[]{0.0009, 0.0255, 0.0089, 0.0474, 0.0707, 0.1884, 0.3174, 0.3408}, new int[]{120, 122, 123, 124, 125, 126, 128, 130}),
	I 	("I", 	53, 126.904470, new double[]{126.904473}, new double[]{1.0}, new int[]{127}),
	Xe 	("Xe", 	54, 131.293000, new double[]{123.905893, 125.904274, 127.9035313, 128.9047794, 129.903508, 130.9050824, 131.9041535, 133.9053945, 135.907219}, new double[]{0.000952, 0.00089, 0.019102, 0.264006, 0.04071, 0.212324, 0.269086, 0.104357, 0.088573}, new int[]{124, 126, 128, 129, 130, 131, 132, 134, 136}),
	Cs 	("Cs", 	55, 132.905452, new double[]{132.905451933}, new double[]{1.0}, new int[]{133}),
	Ba 	("Ba", 	56, 137.327000, new double[]{129.9063208, 131.9050613, 133.9045084, 134.9056886, 135.9045759, 136.9058274, 137.9052472}, new double[]{0.00106, 0.00101, 0.02417, 0.06592, 0.07854, 0.11232, 0.71698}, new int[]{130, 132, 134, 135, 136, 137, 138}),
	La 	("La", 	57, 138.905470, new double[]{137.907112, 138.9063533}, new double[]{0.0009, 0.9991}, new int[]{138, 139}),
	Ce 	("Ce", 	58, 140.116000, new double[]{135.907172, 137.905991, 139.9054387, 141.909244}, new double[]{0.00185, 0.00251, 0.8845, 0.11114}, new int[]{136, 138, 140, 142}),
	Pr 	("Pr", 	59, 140.907650, new double[]{140.9076528}, new double[]{1.0}, new int[]{141}),
	Nd 	("Nd", 	60, 144.242000, new double[]{141.9077233, 142.9098143, 143.9100873, 144.9125736, 145.9131169, 147.916893, 149.920891}, new double[]{0.272, 0.122, 0.238, 0.083, 0.172, 0.057, 0.056}, new int[]{142, 143, 144, 145, 146, 148, 150}),
	Pm 	("Pm", 	61, 145.000000, new double[]{144.912749, 146.9151385}, new double[]{0.0, 0.0}, new int[]{145, 147}),
	Sm 	("Sm", 	62, 150.360000, new double[]{143.911999, 146.9148979, 147.9148227, 148.9171847, 149.9172755, 151.9197324, 153.9222093}, new double[]{0.0307, 0.1499, 0.1124, 0.1382, 0.0738, 0.2675, 0.2275}, new int[]{144, 147, 148, 149, 150, 152, 154}),
	Eu 	("Eu", 	63, 151.964000, new double[]{150.9198502, 152.9212303}, new double[]{0.4781, 0.5219}, new int[]{151, 153}),
	Gd 	("Gd", 	64, 157.250000, new double[]{151.919791, 153.9208656, 154.922622, 155.9221227, 156.9239601, 157.9241039, 159.9270541}, new double[]{0.002, 0.0218, 0.148, 0.2047, 0.1565, 0.2484, 0.2186}, new int[]{152, 154, 155, 156, 157, 158, 160}),
	Tb 	("Tb", 	65, 158.925350, new double[]{158.9253468}, new double[]{1.0}, new int[]{159}),
	Dy 	("Dy", 	66, 162.500000, new double[]{155.924283, 157.924409, 159.9251975, 160.9269334, 161.9267984, 162.9287312, 163.9291748}, new double[]{0.00056, 0.00095, 0.02329, 0.18889, 0.25475, 0.24896, 0.2826}, new int[]{156, 158, 160, 161, 162, 163, 164}),
	Ho 	("Ho", 	67, 164.930320, new double[]{164.9303221}, new double[]{1.0}, new int[]{165}),
	Er 	("Er", 	68, 167.259000, new double[]{161.928778, 163.9292, 165.9302931, 166.9320482, 167.9323702, 169.9354643}, new double[]{0.00139, 0.01601, 0.33503, 0.22869, 0.26978, 0.1491}, new int[]{162, 164, 166, 167, 168, 170}),
	Tm 	("Tm", 	69, 168.934210, new double[]{168.9342133}, new double[]{1.0}, new int[]{169}),
	Yb 	("Yb", 	70, 173.054000, new double[]{167.933897, 169.9347618, 170.9363258, 171.9363815, 172.9382108, 173.9388621, 175.9425717}, new double[]{0.0013, 0.0304, 0.1428, 0.2183, 0.1613, 0.3183, 0.1276}, new int[]{168, 170, 171, 172, 173, 174, 176}),
	Lu 	("Lu", 	71, 174.966800, new double[]{174.9407718, 175.9426863}, new double[]{0.9741, 0.0259}, new int[]{175, 176}),
	Hf 	("H", 	72, 178.490000, new double[]{173.940046, 175.9414086, 176.9432207, 177.9436988, 178.9458161, 179.94655}, new double[]{0.0016, 0.0526, 0.186, 0.2728, 0.1362, 0.3508}, new int[]{174, 176, 177, 178, 179, 180}),
	Ta 	("Ta", 	73, 180.947880, new double[]{179.9474648, 180.9479958}, new double[]{0.00012, 0.99988}, new int[]{180, 181}),
	W 	("W", 	74, 183.840000, new double[]{179.946704, 181.9482042, 182.950223, 183.9509312, 185.9543641}, new double[]{0.0012, 0.265, 0.1431, 0.3064, 0.2843}, new int[]{180, 182, 183, 184, 186}),
	Re 	("Re", 	75, 186.207000, new double[]{184.952955, 186.9557531}, new double[]{0.374, 0.626}, new int[]{185, 187}),
	Os 	("Os", 	76, 190.230000, new double[]{183.9524891, 185.9538382, 186.9557505, 187.9558382, 188.9581475, 189.958447, 191.9614807}, new double[]{0.0002, 0.0159, 0.0196, 0.1324, 0.1615, 0.2626, 0.4078}, new int[]{184, 186, 187, 188, 189, 190, 192}),
	Ir 	("Ir", 	77, 192.217000, new double[]{190.960594, 192.9629264}, new double[]{0.373, 0.627}, new int[]{191, 193}),
	Pt 	("Pt", 	78, 195.084000, new double[]{189.959932, 191.961038, 193.9626803, 194.9647911, 195.9649515, 197.967893}, new double[]{0.00014, 0.00782, 0.32967, 0.33832, 0.25242, 0.07163}, new int[]{190, 192, 194, 195, 196, 198}),
	Au 	("Au", 	79, 196.966569, new double[]{196.9665687}, new double[]{1.0}, new int[]{197}),
	Hg 	("Hg", 	80, 200.590000, new double[]{195.965833, 197.966769, 198.9682799, 199.968326, 200.9703023, 201.970643, 203.9734939}, new double[]{0.0015, 0.0997, 0.1687, 0.231, 0.1318, 0.2986, 0.0687}, new int[]{196, 198, 199, 200, 201, 202, 204}),
	Tl 	("Tl", 	81, 204.383300, new double[]{202.9723442, 204.9744275}, new double[]{0.2952, 0.7048}, new int[]{203, 205}),
	Pb 	("Pb", 	82, 207.200000, new double[]{203.9730436, 205.9744653, 206.9758969, 207.9766521}, new double[]{0.014, 0.241, 0.221, 0.524}, new int[]{204, 206, 207, 208}),
	Bi 	("Bi", 	83, 208.980400, new double[]{208.9803987}, new double[]{1.0}, new int[]{209}),
	Po 	("Po", 	84, 209.000000, new double[]{208.9824304, 209.9828737}, new double[]{0.0, 0.0}, new int[]{209, 210}),
	At 	("At", 	85, 210.000000, new double[]{209.987148, 210.9874963}, new double[]{0.0, 0.0}, new int[]{210, 211}),
	Rn 	("Rn", 	86, 222.000000, new double[]{210.990601, 220.011394, 222.0175777}, new double[]{0.0, 0.0, 0.0}, new int[]{211, 220, 222}),
	Fr 	("Fr", 	87, 223.000000, new double[]{223.0197359}, new double[]{0.0}, new int[]{223}),
	Ra 	("Ra", 	88, 226.000000, new double[]{223.0185022, 224.0202118, 226.0254098, 228.0310703}, new double[]{0.0, 0.0, 0.0, 0.0}, new int[]{223, 224, 226, 228}),
	Ac 	("Ac", 	89, 227.000000, new double[]{227.0277521}, new double[]{0.0}, new int[]{227}),
	Th 	("Th", 	90, 232.038060, new double[]{230.0331338, 232.0380553}, new double[]{0.0, 1.0}, new int[]{230, 232}),
	Pa 	("Pa", 	91, 231.035880, new double[]{231.035884}, new double[]{1.0}, new int[]{231}),
	U 	("U", 	92, 238.028910, new double[]{233.0396352, 234.0409521, 235.0439299, 236.045568, 238.0507882}, new double[]{0.0, 5.4e-05, 0.007204, 0.0, 0.992742}, new int[]{233, 234, 235, 236, 238}),
	Np 	("Np", 	93, 237.000000, new double[]{236.04657, 237.0481734}, new double[]{0.0, 0.0}, new int[]{236, 237}),
	Pu 	("Pu", 	94, 244.000000, new double[]{238.0495599, 239.0521634, 240.0538135, 241.0568515, 242.0587426, 244.064204}, new double[]{0.0, 0.0, 0.0, 0.0, 0.0, 0.0}, new int[]{238, 239, 240, 241, 242, 244}),
	Am 	("Am", 	95, 243.000000, new double[]{241.0568291, 243.0613811}, new double[]{0.0, 0.0}, new int[]{241, 243}),
	Cm 	("Cm", 	96, 247.000000, new double[]{243.0613891, 244.0627526, 245.0654912, 246.0672237, 247.070354, 248.072349}, new double[]{0.0, 0.0, 0.0, 0.0, 0.0, 0.0}, new int[]{243, 244, 245, 246, 247, 248}),
	Bk 	("Bk", 	97, 247.000000, new double[]{247.070307, 249.0749867}, new double[]{0.0, 0.0}, new int[]{247, 249}),
	Cf 	("Cf", 	98, 251.000000, new double[]{249.0748535, 250.0764061, 251.079587, 252.081626}, new double[]{0.0, 0.0, 0.0, 0.0}, new int[]{249, 250, 251, 252}),
	Es 	("Es", 	99, 252.000000, new double[]{252.08298}, new double[]{0.0}, new int[]{252}),
	Fm 	("Fm", 	100, 257.000000, new double[]{257.095105}, new double[]{0.0}, new int[]{257}),
	Md 	("Md", 	101, 258.000000, new double[]{258.098431, 260.10365}, new double[]{0.0, 0.0}, new int[]{258, 260}),
	No 	("No", 	102, 259.000000, new double[]{259.10103}, new double[]{0.0}, new int[]{259}),
	Lr 	("Lr", 	103, 262.000000, new double[]{262.10963}, new double[]{0.0}, new int[]{262}),
	R 	("R", 	104, 265.000000, new double[]{265.1167}, new double[]{0.0}, new int[]{265}),
	Db 	("Db", 	105, 268.000000, new double[]{268.12545}, new double[]{0.0}, new int[]{268}),
	Sg 	("Sg", 	106, 271.000000, new double[]{271.13347}, new double[]{0.0}, new int[]{271}),
	Bh 	("Bh", 	107, 272.000000, new double[]{272.13803}, new double[]{0.0}, new int[]{272}),
	Hs 	("Hs", 	108, 270.000000, new double[]{270.13465}, new double[]{0.0}, new int[]{270}),
	Mt 	("Mt", 	109, 276.000000, new double[]{276.15116}, new double[]{0.0}, new int[]{276}),
	Ds 	("Ds", 	110, 281.000000, new double[]{281.16206}, new double[]{0.0}, new int[]{281}),
	Rg 	("Rg", 	111, 280.000000, new double[]{280.16447}, new double[]{0.0}, new int[]{280}),
	Cn 	("Cn", 	112, 285.000000, new double[]{285.17411}, new double[]{0.0}, new int[]{285}),
	Uut ("Uut", 113, 284.000000, new double[]{284.17808}, new double[]{0.0}, new int[]{284}),
	Uuq ("Uuq", 114, 289.000000, new double[]{289.18728}, new double[]{0.0}, new int[]{289}),
	Uup ("Uup", 115, 288.000000, new double[]{288.19249}, new double[]{0.0}, new int[]{288}),
	Uuh ("Uuh", 116, 293.000000, new double[]{0.0}, new double[]{0.0}, new int[]{293}),
	Uus ("Uus", 117, 292.000000, new double[]{292.20755}, new double[]{0.0}, new int[]{292}),
	Uuo ("Uuo", 118, 294.000000, new double[]{0.0}, new double[]{0.0}, new int[]{294});

	public final String	symbol;
	public final int 		atomicNumber;
	public final double	standardAtomicWeight;
	public final double[]	isotopeRelativeAtomicMasses;
	public final double[]	isotopeOccurence;
	public final int[]	isotopeMassNumbers;
	public final double 	monoisotopicWeight;
	public final IsotopeDistribution isotopeDistribution;
	
	Element(
			String symbol, 
			int atomicNumber,
			double standardAtomicWeight,
			double[] isotopeRelativeAtomicMasses,
			double[] isotopeOccurence, 
			int[] isotopeMassNumbers
	) {
		this.symbol = symbol;
		this.atomicNumber = atomicNumber;
		this.standardAtomicWeight = standardAtomicWeight;
		this.isotopeRelativeAtomicMasses = isotopeRelativeAtomicMasses;
		this.isotopeOccurence = isotopeOccurence;
		this.isotopeMassNumbers = isotopeMassNumbers;
		
		double mostrequentOccurence = isotopeOccurence[0];
		double mostrequentMass = isotopeRelativeAtomicMasses[0];
		for (int i = 1; i < isotopeMassNumbers.length; i++)
			if (isotopeOccurence[i] > mostrequentOccurence) {
				mostrequentOccurence = isotopeOccurence[i];
				mostrequentMass = isotopeRelativeAtomicMasses[i];
			}
		monoisotopicWeight = mostrequentMass;
		
		int low = (int)Math.round(isotopeRelativeAtomicMasses[0]);
		int high = (int)Math.round(isotopeRelativeAtomicMasses[isotopeRelativeAtomicMasses.length - 1]);
		isotopeDistribution = new IsotopeDistribution();
		isotopeDistribution.m0 = low;
		isotopeDistribution.dm = high - low + 1;
		isotopeDistribution.intensities = new double[isotopeDistribution.dm];
		for (int i = 0; i < isotopeOccurence.length; i++)
			isotopeDistribution.intensities[(int)Math.round(isotopeRelativeAtomicMasses[i]) - low] = isotopeOccurence[i];
	}
	
	public static Element fromString(String str) {
		Element[] es = Element.values();
		for (Element e : es)
			if (e.symbol.equals(str))
				return e;
		return null;
	}
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy