Menu

Diff of /Atom.cpp [r68] .. [r69]  Maximize  Restore

Switch to side-by-side view

--- a/Atom.cpp
+++ b/Atom.cpp
@@ -80,6 +80,12 @@
     res += AtFormFactor.a4*exp(-1*AtFormFactor.b4*X);
     res += AtFormFactor.c;
     return res;
+}
+CString Atom::getAtomType(int atnb)
+{
+    if(atnb<0) return "Q";
+    if(atnb>=m_nElementsNumber) return "Q";
+    return AtomProperties[atnb].Name;
 }
 CString Atom::getAtomType(CString str)
 {