Changeset e1fe7e for src/Potentials/Specifics/unittests
- Timestamp:
- Jun 27, 2014, 9:32:55 PM (11 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:
- 550f2a
- Parents:
- 16227a
- git-author:
- Frederik Heber <heber@…> (02/27/14 20:15:41)
- git-committer:
- Frederik Heber <heber@…> (06/27/14 21:32:55)
- Location:
- src/Potentials/Specifics/unittests
- Files:
-
- 8 edited
Legend:
- Unmodified
- Added
- Removed
-
src/Potentials/Specifics/unittests/ConstantPotentialUnitTest.cpp
r16227a re1fe7e 82 82 Helpers::isEqual( 83 83 offset, 84 constant( FunctionModel:: arguments_t() )[0]84 constant( FunctionModel::list_of_arguments_t() )[0] 85 85 ) 86 86 ); … … 97 97 0., 98 98 constant.derivative( 99 FunctionModel:: arguments_t()99 FunctionModel::list_of_arguments_t() 100 100 )[0] 101 101 ) … … 114 114 1., 115 115 constant.parameter_derivative( 116 FunctionModel:: arguments_t(),116 FunctionModel::list_of_arguments_t(), 117 117 0 118 118 )[0] -
src/Potentials/Specifics/unittests/FourBodyPotential_ImproperUnitTest.cpp
r16227a re1fe7e 121 121 for (size_t index = 0; index < input.size(); ++index) { 122 122 const FourBodyPotential_Improper::results_t result = 123 angle( input[index]);123 angle( FunctionModel::list_of_arguments_t(1, input[index]) ); 124 124 CPPUNIT_ASSERT( 125 125 Helpers::isEqual( … … 144 144 0., 145 145 angle.derivative( 146 input[5]146 FunctionModel::list_of_arguments_t(1, input[5]) 147 147 )[0], 148 148 10. … … 165 165 0., 166 166 angle.parameter_derivative( 167 input[5],167 FunctionModel::list_of_arguments_t(1, input[5]), 168 168 0 169 169 )[0], … … 175 175 0., 176 176 angle.parameter_derivative( 177 input[5],177 FunctionModel::list_of_arguments_t(1, input[5]), 178 178 1 179 179 )[0], -
src/Potentials/Specifics/unittests/FourBodyPotential_TorsionUnitTest.cpp
r16227a re1fe7e 121 121 for (size_t index = 0; index < input.size(); ++index) { 122 122 const FourBodyPotential_Torsion::results_t result = 123 angle( input[index]);123 angle( FunctionModel::list_of_arguments_t(1, input[index]) ); 124 124 CPPUNIT_ASSERT( 125 125 Helpers::isEqual( … … 144 144 0., 145 145 angle.derivative( 146 input[5]146 FunctionModel::list_of_arguments_t(1, input[5]) 147 147 )[0], 148 148 10. … … 165 165 0., 166 166 angle.parameter_derivative( 167 input[5],167 FunctionModel::list_of_arguments_t(1, input[5]), 168 168 0 169 169 )[0], … … 175 175 0., 176 176 angle.parameter_derivative( 177 input[5],177 FunctionModel::list_of_arguments_t(1, input[5]), 178 178 1 179 179 )[0], -
src/Potentials/Specifics/unittests/ManyBodyPotential_TersoffUnitTest.cpp
r16227a re1fe7e 299 299 arg.globalid = index; // this is needed for the triplefunction to the configuration 300 300 FunctionModel::arguments_t args(1,arg); 301 const ManyBodyPotential_Tersoff::results_t res = tersoff(args); 301 const ManyBodyPotential_Tersoff::results_t res = 302 tersoff( FunctionModel::list_of_arguments_t(1, args) ); 302 303 temp += res[0]; 303 304 } … … 336 337 // 0., 337 338 // tersoff.derivative( 338 // FunctionModel:: arguments_t(1,argument_t(1.))339 // FunctionModel::list_of_arguments_t(1, FunctionModel::arguments_t(1,argument_t(1.))) 339 340 // )[0] 340 341 // ) … … 361 362 // 0., 362 363 // tersoff.parameter_derivative( 363 // FunctionModel:: arguments_t(1,argument_t(1.)),364 // FunctionModel::list_of_arguments_t(1, FunctionModel::arguments_t(1,argument_t(1.))), 364 365 // 0 365 366 // )[0] … … 370 371 // 0., 371 372 // tersoff.parameter_derivative( 372 // FunctionModel:: arguments_t(1,argument_t(1.)),373 // FunctionModel::list_of_arguments_t(1, FunctionModel::arguments_t(1,argument_t(1.))), 373 374 // 1 374 375 // )[0] … … 379 380 // 1., 380 381 // tersoff.parameter_derivative( 381 // FunctionModel:: arguments_t(1,argument_t(1.)),382 // FunctionModel::list_of_arguments_t(1, FunctionModel::arguments_t(1,argument_t(1.))), 382 383 // 2 383 384 // )[0] -
src/Potentials/Specifics/unittests/PairPotential_HarmonicUnitTest.cpp
r16227a re1fe7e 102 102 Helpers::isEqual( 103 103 output[index], 104 harmonic( FunctionModel:: arguments_t(1,arg) )[0]104 harmonic( FunctionModel::list_of_arguments_t(1, FunctionModel::arguments_t(1,arg)) )[0] 105 105 ) 106 106 ); … … 122 122 0., 123 123 harmonic.derivative( 124 FunctionModel:: arguments_t(1,arg)124 FunctionModel::list_of_arguments_t(1, FunctionModel::arguments_t(1,arg)) 125 125 )[0] 126 126 ) … … 143 143 0., 144 144 harmonic.parameter_derivative( 145 FunctionModel:: arguments_t(1,arg),145 FunctionModel::list_of_arguments_t(1, FunctionModel::arguments_t(1,arg)), 146 146 0 147 147 )[0] … … 152 152 0., 153 153 harmonic.parameter_derivative( 154 FunctionModel:: arguments_t(1,arg),154 FunctionModel::list_of_arguments_t(1, FunctionModel::arguments_t(1,arg)), 155 155 1 156 156 )[0] -
src/Potentials/Specifics/unittests/PairPotential_LennardJonesUnitTest.cpp
r16227a re1fe7e 118 118 Helpers::isEqual( 119 119 output[index], 120 lj( FunctionModel:: arguments_t(1,arg) )[0],120 lj( FunctionModel::list_of_arguments_t(1, FunctionModel::arguments_t(1,arg)) )[0], 121 121 1.e-4/std::numeric_limits<double>::epsilon() // only compare four digits 122 122 ) … … 140 140 0., 141 141 lj.derivative( 142 FunctionModel:: arguments_t(1,arg)142 FunctionModel::list_of_arguments_t(1, FunctionModel::arguments_t(1,arg)) 143 143 )[0], 144 144 1.e+6 … … 162 162 -1., 163 163 lj.parameter_derivative( 164 FunctionModel:: arguments_t(1,arg),164 FunctionModel::list_of_arguments_t(1, FunctionModel::arguments_t(1,arg)), 165 165 0 166 166 )[0], … … 172 172 0., 173 173 lj.parameter_derivative( 174 FunctionModel:: arguments_t(1,arg),174 FunctionModel::list_of_arguments_t(1, FunctionModel::arguments_t(1,arg)), 175 175 1 176 176 )[0], -
src/Potentials/Specifics/unittests/PairPotential_MorseUnitTest.cpp
r16227a re1fe7e 120 120 Helpers::isEqual( 121 121 output[index], 122 Morse( FunctionModel:: arguments_t(1,arg) )[0],122 Morse( FunctionModel::list_of_arguments_t(1, FunctionModel::arguments_t(1,arg)) )[0], 123 123 1.e-4/std::numeric_limits<double>::epsilon() // only compare four digits 124 124 ) … … 141 141 0., 142 142 Morse.derivative( 143 FunctionModel:: arguments_t(1,arg)143 FunctionModel::list_of_arguments_t(1, FunctionModel::arguments_t(1,arg)) 144 144 )[0], 145 145 1.e+6 … … 163 163 0., 164 164 Morse.parameter_derivative( 165 FunctionModel:: arguments_t(1,arg),165 FunctionModel::list_of_arguments_t(1, FunctionModel::arguments_t(1,arg)), 166 166 0 167 167 )[0], … … 173 173 0., 174 174 Morse.parameter_derivative( 175 FunctionModel:: arguments_t(1,arg),175 FunctionModel::list_of_arguments_t(1, FunctionModel::arguments_t(1,arg)), 176 176 1 177 177 )[0], … … 183 183 0., 184 184 Morse.parameter_derivative( 185 FunctionModel:: arguments_t(1,arg),185 FunctionModel::list_of_arguments_t(1, FunctionModel::arguments_t(1,arg)), 186 186 2 187 187 )[0], -
src/Potentials/Specifics/unittests/ThreeBodyPotential_AngleUnitTest.cpp
r16227a re1fe7e 112 112 for (size_t index = 0; index < input.size(); ++index) { 113 113 const ThreeBodyPotential_Angle::results_t result = 114 angle( input[index]);114 angle( FunctionModel::list_of_arguments_t(1, input[index]) ); 115 115 CPPUNIT_ASSERT( 116 116 Helpers::isEqual( … … 135 135 0., 136 136 angle.derivative( 137 input[5]137 FunctionModel::list_of_arguments_t(1, input[5]) 138 138 )[0], 139 139 10. … … 156 156 0., 157 157 angle.parameter_derivative( 158 input[5],158 FunctionModel::list_of_arguments_t(1, input[5]), 159 159 0 160 160 )[0], … … 166 166 0., 167 167 angle.parameter_derivative( 168 input[5],168 FunctionModel::list_of_arguments_t(1, input[5]), 169 169 1 170 170 )[0],
Note:
See TracChangeset
for help on using the changeset viewer.