parse_Atomic_Weights_and_Isotopic_Compositions_for_All_Elements

PURPOSE ^

Parses NIST data on atomic weights

SYNOPSIS ^

function [atomicWeights]=parse_Atomic_Weights_and_Isotopic_Compositions_for_All_Elements

DESCRIPTION ^

 Parses NIST data on atomic weights

 The atomic weight    J. S. Coursey, D. J. Schwab, and R. A. Dragoset 
 NIST, Physics Laboratory, Office of Electronic Commerce in Scientific and 
 Engineering Data 
 The atomic weights are available for elements 1 through 112, 114, & 116 and
 isotopic compositions or abundances are given when appropriate. The atomic 
 weights data were published by T.B. Coplen1 in Atomic Weights of the Elements
 1999, (and include changes reported from the 2001 review in Chem. Int., 23, 179 (2001))
 and the isotopic compositions data were published by K.J.R. Rosman2 and P.D.P. Taylor3 
 in Isotopic Compositions of the Elements 1997. The relative atomic masses of the
 isotopes data were published by G. Audi4 and A. H. Wapstra5 in The 1995 Update To
 The Atomic Mass Evaluation.
 http://physics.nist.gov/PhysRefData/Compositions/

 Ronan Fleming 9 March 09

CROSS-REFERENCE INFORMATION ^

This function calls: This function is called by:

SOURCE CODE ^

0001 function [atomicWeights]=parse_Atomic_Weights_and_Isotopic_Compositions_for_All_Elements
0002 % Parses NIST data on atomic weights
0003 %
0004 % The atomic weight    J. S. Coursey, D. J. Schwab, and R. A. Dragoset
0005 % NIST, Physics Laboratory, Office of Electronic Commerce in Scientific and
0006 % Engineering Data
0007 % The atomic weights are available for elements 1 through 112, 114, & 116 and
0008 % isotopic compositions or abundances are given when appropriate. The atomic
0009 % weights data were published by T.B. Coplen1 in Atomic Weights of the Elements
0010 % 1999, (and include changes reported from the 2001 review in Chem. Int., 23, 179 (2001))
0011 % and the isotopic compositions data were published by K.J.R. Rosman2 and P.D.P. Taylor3
0012 % in Isotopic Compositions of the Elements 1997. The relative atomic masses of the
0013 % isotopes data were published by G. Audi4 and A. H. Wapstra5 in The 1995 Update To
0014 % The Atomic Mass Evaluation.
0015 % http://physics.nist.gov/PhysRefData/Compositions/
0016 %
0017 % Ronan Fleming 9 March 09
0018 
0019 fid=fopen('Atomic_Weights_and_Isotopic_Compositions_for_All_Elements.m','r');
0020 
0021 nElements=2816/8;
0022 p=1;
0023 ele=1;
0024 fieldNames={'AtomicNumber';
0025 'AtomicSymbol';
0026 'MassNumber';
0027 'RelativeAtomicMass';
0028 'IsotopicComposition';
0029 'StandardAtomicWeight';
0030 'Notes'};
0031 
0032 for x=1:2816
0033     line= fgetl(fid);
0034     if ~isempty(line)
0035         if p==2 || p==7
0036             tmp=textscan(line,'%s%s\n',2815,'Delimiter','=(','TreatAsEmpty',' ');
0037             if ~isempty(tmp{2})
0038                 atomicWeights.data(ele).(fieldNames{p})=tmp{2};
0039             end
0040             if p==2
0041                 tmp2=tmp{2};
0042                 if ~isempty(tmp2)
0043                     atomicWeights.AtomicSymbol{ele}=tmp2{1};
0044                 end
0045             end
0046         else
0047             tmp=textscan(line,'%s%f\n',2815,'Delimiter','=(','TreatAsEmpty',' ');
0048             atomicWeights.data(ele).(fieldNames{p})=tmp{2};
0049         end
0050         p=p+1;
0051     else
0052         ele=ele+1;
0053         p=1;
0054     end
0055 end
0056 
0057 fclose(fid);
0058

Generated on Thu 21-Jun-2012 15:39:23 by m2html © 2003