Changeset 04b6f9 for src/config.cpp
- Timestamp:
- Jan 27, 2010, 2:36:09 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, 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:
- 2ededc2
- Parents:
- 1ca488f (diff), 244a84 (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/config.cpp (modified) (9 diffs)
Legend:
- Unmodified
- Added
- Removed
-
src/config.cpp
r1ca488f r04b6f9 6 6 7 7 #include <stdio.h> 8 #include <cstring> 8 9 9 10 #include "atom.hpp" … … 27 28 char number1[8]; 28 29 char number2[8]; 29 c har *dummy1, *dummy2;30 const char *dummy1, *dummy2; 30 31 //Log() << Verbose(0) << s1 << " " << s2 << endl; 31 32 dummy1 = strchr(s1, '_')+sizeof(char)*5; // go just after "Ion_Type" … … 1789 1790 mol->SetNameFromFilename(ConfigFileName); 1790 1791 1791 if (!strcmp(config uration->configpath, configuration->GetDefaultPath())) {1792 if (!strcmp(configpath, GetDefaultPath())) { 1792 1793 eLog() << Verbose(2) << "config is found under different path then stated in config file::defaultpath!" << endl; 1793 1794 } … … 1800 1801 strcpy(filename,"main_pcp_linux"); 1801 1802 Log() << Verbose(0) << "Saving as pdb input "; 1802 if ( configuration->SavePDB(filename, molecules))1803 if (SavePDB(filename, molecules)) 1803 1804 Log() << Verbose(0) << "done." << endl; 1804 1805 else … … 1811 1812 strcpy(filename,"main_pcp_linux"); 1812 1813 Log() << Verbose(0) << "Saving as tremolo data input "; 1813 if ( configuration->SaveTREMOLO(filename, molecules))1814 if (SaveTREMOLO(filename, molecules)) 1814 1815 Log() << Verbose(0) << "done." << endl; 1815 1816 else … … 1836 1837 Log() << Verbose(0) << "Storing configuration ... " << endl; 1837 1838 // get correct valence orbitals 1838 mol->CalculateOrbitals(* configuration);1839 configuration->InitMaxMinStopStep = configuration->MaxMinStopStep = configuration->MaxPsiDouble;1839 mol->CalculateOrbitals(*this); 1840 InitMaxMinStopStep = MaxMinStopStep = MaxPsiDouble; 1840 1841 if (ConfigFileName != NULL) { // test the file name 1841 1842 strcpy(filename, ConfigFileName); 1842 1843 output.open(filename, ios::trunc); 1843 } else if (strlen(config uration->configname) != 0) {1844 strcpy(filename, config uration->configname);1845 output.open(config uration->configname, ios::trunc);1844 } else if (strlen(configname) != 0) { 1845 strcpy(filename, configname); 1846 output.open(configname, ios::trunc); 1846 1847 } else { 1847 1848 strcpy(filename, DEFAULTCONFIG); … … 1851 1852 output.clear(); 1852 1853 Log() << Verbose(0) << "Saving of config file "; 1853 if ( configuration->Save(filename, periode, mol))1854 if (Save(filename, periode, mol)) 1854 1855 Log() << Verbose(0) << "successful." << endl; 1855 1856 else … … 1888 1889 strcpy(filename,"main_pcp_linux"); 1889 1890 Log() << Verbose(0) << "Saving as mpqc input "; 1890 if ( configuration->SaveMPQC(filename, mol))1891 if (SaveMPQC(filename, mol)) 1891 1892 Log() << Verbose(0) << "done." << endl; 1892 1893 else 1893 1894 Log() << Verbose(0) << "failed." << endl; 1894 1895 1895 if (!strcmp(config uration->configpath, configuration->GetDefaultPath())) {1896 if (!strcmp(configpath, GetDefaultPath())) { 1896 1897 eLog() << Verbose(2) << "config is found under different path then stated in config file::defaultpath!" << endl; 1897 1898 } … … 2247 2248 } 2248 2249 line++; 2249 } while ( dummy1 != NULL && (dummy1[0] == '#') || (dummy1[0] == '\n'));2250 } while ((dummy1 != NULL) && ((dummy1[0] == '#') || (dummy1[0] == '\n'))); 2250 2251 dummy = dummy1; 2251 2252 } else { // simple int, strings or doubles start in the same line
Note:
See TracChangeset
for help on using the changeset viewer.
