Changeset d52819 for src/Potentials/Specifics
- Timestamp:
- Feb 27, 2013, 12:39:03 PM (12 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, 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:
- 775dd1a
- Parents:
- 7b019a
- git-author:
- Frederik Heber <heber@…> (11/30/12 16:35:37)
- git-committer:
- Frederik Heber <heber@…> (02/27/13 12:39:03)
- Location:
- src/Potentials/Specifics
- Files:
-
- 11 edited
Legend:
- Unmodified
- Added
- Removed
-
src/Potentials/Specifics/ManyBodyPotential_Tersoff.cpp
r7b019a rd52819 49 49 50 50 #include "FunctionApproximation/Extractors.hpp" 51 #include "FunctionApproximation/TrainingData.hpp" 51 52 #include "Potentials/helpers.hpp" 52 53 #include "Potentials/ParticleTypeCheckers.hpp" … … 697 698 } 698 699 700 void 701 ManyBodyPotential_Tersoff::setParametersToRandomInitialValues( 702 const TrainingData &data) 703 { 704 // params[ManyBodyPotential_Tersoff::R] = 1./AtomicLengthToAngstroem; 705 // params[ManyBodyPotential_Tersoff::S] = 2./AtomicLengthToAngstroem; 706 params[ManyBodyPotential_Tersoff::A] = 1e+4*rand()/(double)RAND_MAX;//1.393600e+03; 707 params[ManyBodyPotential_Tersoff::B] = 1e+4*rand()/(double)RAND_MAX;//3.467000e+02; 708 params[ManyBodyPotential_Tersoff::lambda] = 1e+1*rand()/(double)RAND_MAX;//3.487900e+00; 709 params[ManyBodyPotential_Tersoff::mu] = 1e+1*rand()/(double)RAND_MAX;//2.211900e+00; 710 // params[ManyBodyPotential_Tersoff::lambda3] = 0.; 711 // params[ManyBodyPotential_Tersoff::alpha] = 0.; 712 params[ManyBodyPotential_Tersoff::beta] = 1e-1*rand()/(double)RAND_MAX;//1.572400e-07; 713 // params[ManyBodyPotential_Tersoff::chi] = 1.; 714 // params[ManyBodyPotential_Tersoff::omega] = 1.; 715 params[ManyBodyPotential_Tersoff::n] = 1e+1*rand()/(double)RAND_MAX;//7.275100e-01; 716 params[ManyBodyPotential_Tersoff::c] = 1e+1*rand()/(double)RAND_MAX;//3.804900e+04; 717 params[ManyBodyPotential_Tersoff::d] = 1e+1*rand()/(double)RAND_MAX;//4.384000e+00; 718 params[ManyBodyPotential_Tersoff::h] = 1e+1*rand()/(double)RAND_MAX;//-5.705800e-01; 719 params[ManyBodyPotential_Tersoff::offset] = //0.*rand()/(double)RAND_MAX;//-5.705800e-01; 720 data.getTrainingOutputAverage()[0]; 721 } 722 -
src/Potentials/Specifics/ManyBodyPotential_Tersoff.hpp
r7b019a rd52819 21 21 #include "Potentials/SerializablePotential.hpp" 22 22 #include "FunctionApproximation/FunctionModel.hpp" 23 24 class TrainingData; 23 25 24 26 /** This class is the implementation of the Tersoff potential function. … … 318 320 } 319 321 322 /** Sets the parameter randomly within the sensible range of each parameter. 323 * 324 * \param data container with training data for guesstimating range 325 */ 326 void setParametersToRandomInitialValues(const TrainingData &data); 327 320 328 /** Getter for the number of parameters of this model function. 321 329 * -
src/Potentials/Specifics/PairPotential_Angle.cpp
r7b019a rd52819 46 46 47 47 #include "FunctionApproximation/Extractors.hpp" 48 #include "FunctionApproximation/TrainingData.hpp" 48 49 #include "Potentials/helpers.hpp" 49 50 #include "Potentials/ParticleTypeCheckers.hpp" … … 219 220 } 220 221 222 void 223 PairPotential_Angle::setParametersToRandomInitialValues( 224 const TrainingData &data) 225 { 226 params[PairPotential_Angle::energy_offset] = 227 data.getTrainingOutputAverage()[0];// -1.; 228 params[PairPotential_Angle::spring_constant] = 1e+0*rand()/(double)RAND_MAX;// 0.2; 229 params[PairPotential_Angle::equilibrium_distance] = -0.3;//2e+0*rand()/(double)RAND_MAX - 1.;// 1.; 230 } 231 -
src/Potentials/Specifics/PairPotential_Angle.hpp
r7b019a rd52819 22 22 #include "Potentials/SerializablePotential.hpp" 23 23 #include "FunctionApproximation/FunctionModel.hpp" 24 25 class TrainingData; 24 26 25 27 /** This is the implementation of a harmonic angle potential. … … 64 66 return params; 65 67 } 68 69 /** Sets the parameter randomly within the sensible range of each parameter. 70 * 71 * \param data container with training data for guesstimating range 72 */ 73 void setParametersToRandomInitialValues(const TrainingData &data); 66 74 67 75 /** Getter for the number of parameters of this model function. -
src/Potentials/Specifics/PairPotential_Harmonic.cpp
r7b019a rd52819 46 46 47 47 #include "FunctionApproximation/Extractors.hpp" 48 #include "FunctionApproximation/TrainingData.hpp" 48 49 #include "Potentials/helpers.hpp" 49 50 #include "Potentials/ParticleTypeCheckers.hpp" … … 195 196 } 196 197 198 void 199 PairPotential_Harmonic::setParametersToRandomInitialValues( 200 const TrainingData &data) 201 { 202 params[PairPotential_Harmonic::energy_offset] = 203 data.getTrainingOutputAverage()[0];// -1.; 204 params[PairPotential_Harmonic::equilibrium_distance] = 3e+0*rand()/(double)RAND_MAX + .5;// 1.; 205 params[PairPotential_Harmonic::spring_constant] = 1e+0*rand()/(double)RAND_MAX;// 0.2; 206 } 207 -
src/Potentials/Specifics/PairPotential_Harmonic.hpp
r7b019a rd52819 22 22 #include "Potentials/SerializablePotential.hpp" 23 23 #include "FunctionApproximation/FunctionModel.hpp" 24 25 class TrainingData; 24 26 25 27 /** This is the implementation of a harmonic pair potential. … … 64 66 return params; 65 67 } 68 69 /** Sets the parameter randomly within the sensible range of each parameter. 70 * 71 * \param data container with training data for guesstimating range 72 */ 73 void setParametersToRandomInitialValues(const TrainingData &data); 66 74 67 75 /** Getter for the number of parameters of this model function. -
src/Potentials/Specifics/PairPotential_Morse.cpp
r7b019a rd52819 47 47 48 48 #include "FunctionApproximation/Extractors.hpp" 49 #include "FunctionApproximation/TrainingData.hpp" 49 50 #include "Potentials/helpers.hpp" 50 51 #include "Potentials/ParticleTypeCheckers.hpp" … … 224 225 } 225 226 227 void 228 PairPotential_Morse::setParametersToRandomInitialValues( 229 const TrainingData &data) 230 { 231 params[PairPotential_Morse::dissociation_energy] = 1e+0*rand()/(double)RAND_MAX;// 0.5; 232 params[PairPotential_Morse::energy_offset] = 233 data.getTrainingOutputAverage()[0];// -1.; 234 params[PairPotential_Morse::spring_constant] = 1e+0*rand()/(double)RAND_MAX;// 1.; 235 params[PairPotential_Morse::equilibrium_distance] = 3e+0*rand()/(double)RAND_MAX;//2.9; 236 } 237 -
src/Potentials/Specifics/PairPotential_Morse.hpp
r7b019a rd52819 22 22 #include "Potentials/SerializablePotential.hpp" 23 23 #include "FunctionApproximation/FunctionModel.hpp" 24 25 class TrainingData; 24 26 25 27 /** This is the implementation of a harmonic pair potential. … … 65 67 return params; 66 68 } 69 70 /** Sets the parameter randomly within the sensible range of each parameter. 71 * 72 * \param data container with training data for guesstimating range 73 */ 74 void setParametersToRandomInitialValues(const TrainingData &data); 67 75 68 76 /** Getter for the number of parameters of this model function. -
src/Potentials/Specifics/SaturationPotential.cpp
r7b019a rd52819 48 48 49 49 #include "FunctionApproximation/Extractors.hpp" 50 #include "FunctionApproximation/TrainingData.hpp" 50 51 #include "Potentials/helpers.hpp" 51 52 #include "Potentials/ParticleTypeCheckers.hpp" … … 369 370 return returnfunction; 370 371 } 372 373 void 374 SaturationPotential::setParametersToRandomInitialValues( 375 const TrainingData &data) 376 { 377 energy_offset = data.getTrainingOutputAverage()[0]; 378 morse.setParametersToRandomInitialValues(data); 379 angle.setParametersToRandomInitialValues(data); 380 } -
src/Potentials/Specifics/SaturationPotential.hpp
r7b019a rd52819 24 24 #include "Potentials/Specifics/PairPotential_Morse.hpp" 25 25 #include "FunctionApproximation/FunctionModel.hpp" 26 27 class TrainingData; 26 28 27 29 /** This is a combination of Morse and Angle potentials for saturated elements. … … 77 79 parameters_t getParameters() const; 78 80 81 /** Sets the parameter randomly within the sensible range of each parameter. 82 * 83 * \param data container with training data for guesstimating range 84 */ 85 void setParametersToRandomInitialValues(const TrainingData &data); 86 79 87 /** Getter for the number of parameters of this model function. 80 88 * -
src/Potentials/Specifics/unittests/Makefile.am
r7b019a rd52819 27 27 ../libMolecuilderPotentials.la \ 28 28 ../libMolecuilderFragmentationSetValues.la \ 29 ../libMolecuilderFragmentation.la \ 29 30 ../libMolecuilderFunctionApproximation.la \ 30 31 $(top_builddir)/LinearAlgebra/src/LinearAlgebra/libLinearAlgebra.la \
Note:
See TracChangeset
for help on using the changeset viewer.