Changeset 5f612ee for src/periodentafel.cpp
- Timestamp:
- Apr 27, 2010, 2:25:42 PM (16 years ago)
- Branches:
- Action_Thermostats, Add_AtomRandomPerturbation, Add_FitFragmentPartialChargesAction, Add_RotateAroundBondAction, Add_SelectAtomByNameAction, Added_ParseSaveFragmentResults, AddingActions_SaveParseParticleParameters, Adding_Graph_to_ChangeBondActions, Adding_MD_integration_tests, Adding_ParticleName_to_Atom, Adding_StructOpt_integration_tests, AtomFragments, Automaking_mpqc_open, AutomationFragmentation_failures, Candidate_v1.5.4, Candidate_v1.6.0, Candidate_v1.6.1, Candidate_v1.7.0, Candidate_v1.7.1, ChangeBugEmailaddress, ChangingTestPorts, ChemicalSpaceEvaluator, CombiningParticlePotentialParsing, Combining_Subpackages, Debian_Package_split, Debian_package_split_molecuildergui_only, Disabling_MemDebug, Docu_Python_wait, EmpiricalPotential_contain_HomologyGraph, EmpiricalPotential_contain_HomologyGraph_documentation, Enable_parallel_make_install, Enhance_userguide, Enhanced_StructuralOptimization, Enhanced_StructuralOptimization_continued, Example_ManyWaysToTranslateAtom, Exclude_Hydrogens_annealWithBondGraph, FitPartialCharges_GlobalError, Fix_BoundInBox_CenterInBox_MoleculeActions, Fix_ChargeSampling_PBC, Fix_ChronosMutex, Fix_FitPartialCharges, Fix_FitPotential_needs_atomicnumbers, Fix_ForceAnnealing, Fix_IndependentFragmentGrids, Fix_ParseParticles, Fix_ParseParticles_split_forward_backward_Actions, Fix_PopActions, Fix_QtFragmentList_sorted_selection, Fix_Restrictedkeyset_FragmentMolecule, Fix_StatusMsg, Fix_StepWorldTime_single_argument, Fix_Verbose_Codepatterns, Fix_fitting_potentials, Fixes, ForceAnnealing_goodresults, ForceAnnealing_oldresults, ForceAnnealing_tocheck, ForceAnnealing_with_BondGraph, ForceAnnealing_with_BondGraph_continued, ForceAnnealing_with_BondGraph_continued_betteresults, ForceAnnealing_with_BondGraph_contraction-expansion, FragmentAction_writes_AtomFragments, FragmentMolecule_checks_bonddegrees, GeometryObjects, Gui_Fixes, Gui_displays_atomic_force_velocity, ImplicitCharges, IndependentFragmentGrids, IndependentFragmentGrids_IndividualZeroInstances, IndependentFragmentGrids_IntegrationTest, IndependentFragmentGrids_Sole_NN_Calculation, JobMarket_RobustOnKillsSegFaults, JobMarket_StableWorkerPool, JobMarket_unresolvable_hostname_fix, MoreRobust_FragmentAutomation, ODR_violation_mpqc_open, PartialCharges_OrthogonalSummation, PdbParser_setsAtomName, PythonUI_with_named_parameters, QtGui_reactivate_TimeChanged_changes, Recreated_GuiChecks, Rewrite_FitPartialCharges, RotateToPrincipalAxisSystem_UndoRedo, SaturateAtoms_findBestMatching, SaturateAtoms_singleDegree, StoppableMakroAction, Subpackage_CodePatterns, Subpackage_JobMarket, Subpackage_LinearAlgebra, Subpackage_levmar, Subpackage_mpqc_open, Subpackage_vmg, Switchable_LogView, ThirdParty_MPQC_rebuilt_buildsystem, TrajectoryDependenant_MaxOrder, TremoloParser_IncreasedPrecision, TremoloParser_MultipleTimesteps, TremoloParser_setsAtomName, Ubuntu_1604_changes, stable
- Children:
- 632bc3
- Parents:
- 13d5a9 (diff), c695c9 (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the(diff)links above to see all the changes relative to each parent. - File:
-
- 1 edited
-
src/periodentafel.cpp (modified) (7 diffs)
Legend:
- Unmodified
- Added
- Removed
-
src/periodentafel.cpp
r13d5a9 r5f612ee 47 47 pointer->sort = &pointer->Z; 48 48 if (pointer->getNumber() < 1 && pointer->getNumber() >= MAX_ELEMENTS) 49 Log() << Verbose(0) << "Invalid Z number!\n";49 DoeLog(0) && (eLog() << Verbose(0) << "Invalid Z number!\n"); 50 50 pair<iterator,bool> res = elements.insert(pair<atomicNumber_t,element*>(Z,pointer)); 51 51 return res.first; … … 108 108 int Z; 109 109 do { 110 Log() << Verbose(0) << "Atomic number Z: ";110 DoLog(0) && (Log() << Verbose(0) << "Atomic number Z: "); 111 111 cin >> Z; 112 112 walker = this->FindElement(Z); // give type … … 122 122 const element *res = NULL; 123 123 atomicNumber_t Z = 0; 124 Log() << Verbose(0) << "Atomic number: " << Z << endl;124 DoLog(0) && (Log() << Verbose(0) << "Atomic number: " << Z << endl); 125 125 cin >> Z; 126 126 res = FindElement(Z); … … 128 128 // TODO: make this using the constructor 129 129 element *tmp; 130 Log() << Verbose(0) << "Element not found in database, please enter." << endl;130 DoLog(0) && (Log() << Verbose(0) << "Element not found in database, please enter." << endl); 131 131 tmp = new element; 132 132 tmp->Z = Z; 133 Log() << Verbose(0) << "Mass: " << endl;133 DoLog(0) && (Log() << Verbose(0) << "Mass: " << endl); 134 134 cin >> tmp->mass; 135 Log() << Verbose(0) << "Name [max 64 chars]: " << endl;135 DoLog(0) && (Log() << Verbose(0) << "Name [max 64 chars]: " << endl); 136 136 cin >> tmp->name; 137 Log() << Verbose(0) << "Short form [max 3 chars]: " << endl;137 DoLog(0) && (Log() << Verbose(0) << "Short form [max 3 chars]: " << endl); 138 138 cin >> tmp->symbol; 139 139 AddElement(tmp); … … 219 219 infile.getline(header1, MAXSTRINGSIZE); 220 220 infile.getline(header2, MAXSTRINGSIZE); // skip first two header lines 221 Log() << Verbose(0) << "Parsed elements:";221 DoLog(0) && (Log() << Verbose(0) << "Parsed elements:"); 222 222 while (!infile.eof()) { 223 223 element *neues = new element; … … 241 241 //infile >> ws; 242 242 infile >> ws; 243 Log() << Verbose(0) << " " << neues->symbol;243 DoLog(0) && (Log() << Verbose(0) << " " << neues->symbol); 244 244 //neues->Output((ofstream *)&cout); 245 245 if ((neues->Z > 0) && (neues->Z < MAX_ELEMENTS)) 246 246 parsedElems[neues->getNumber()] = neues; 247 247 else { 248 Log() << Verbose(0) << "Could not parse element: ";248 DoLog(0) && (Log() << Verbose(0) << "Could not parse element: "); 249 249 neues->Output((ofstream *)&cout); 250 250 delete(neues); 251 251 } 252 252 } 253 Log() << Verbose(0) << endl;253 DoLog(0) && (Log() << Verbose(0) << endl); 254 254 infile.close(); 255 255 infile.clear(); … … 345 345 } 346 346 else{ 347 eLog() << Verbose(2) << "Something went wrong while parsing the other databases!" << endl;347 DoeLog(2) && (eLog()<< Verbose(2) << "Something went wrong while parsing the other databases!" << endl); 348 348 map<atomicNumber_t,element*>::iterator iter; 349 349 for(iter=parsedElems.begin();iter!=parsedElems.end();++iter){
Note:
See TracChangeset
for help on using the changeset viewer.
