- Timestamp:
- Aug 19, 2009, 12:22:08 PM (15 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:
- ef9df36
- Parents:
- 54a746
- Location:
- src
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
src/boundary.cpp
r54a746 r658efb 308 308 309 309 //*out << "Checking sign in quadrant : " << ProjectedVector.Projection(&AngleReferenceNormalVector) << "." << endl; 310 if (ProjectedVector. Projection(&AngleReferenceNormalVector) > 0) {310 if (ProjectedVector.ScalarProduct(&AngleReferenceNormalVector) > 0) { 311 311 angle = 2. * M_PI - angle; 312 312 } … … 804 804 G = sqrt(((a + b + c) * (a + b + c) - 2 * (a * a + b * b + c * c)) / 16.); // area of tesselated triangle 805 805 x.MakeNormalVector(runner->second->endpoints[0]->node->node, runner->second->endpoints[1]->node->node, runner->second->endpoints[2]->node->node); 806 x.Scale(runner->second->endpoints[1]->node->node-> Projection(&x));806 x.Scale(runner->second->endpoints[1]->node->node->ScalarProduct(&x)); 807 807 h = x.Norm(); // distance of CoG to triangle 808 808 PyramidVolume = (1. / 3.) * G * h; // this formula holds for _all_ pyramids (independent of n-edge base or (not) centered peak) -
src/builder.cpp
r54a746 r658efb 188 188 // remove the projection onto the rotation plane of the second angle 189 189 n.CopyVector(&y); 190 n.Scale(first->x. Projection(&y));190 n.Scale(first->x.ScalarProduct(&y)); 191 191 cout << "N1: ", 192 192 n.Output((ofstream *)&cout); … … 197 197 cout << endl; 198 198 n.CopyVector(&z); 199 n.Scale(first->x. Projection(&z));199 n.Scale(first->x.ScalarProduct(&z)); 200 200 cout << "N2: ", 201 201 n.Output((ofstream *)&cout); -
src/tesselation.cpp
r54a746 r658efb 349 349 350 350 // make it always point inward (any offset vector onto plane projected onto normal vector suffices) 351 if (NormalVector. Projection(&OtherVector) > 0)351 if (NormalVector.ScalarProduct(&OtherVector) > 0.) 352 352 NormalVector.Scale(-1.); 353 353 }; … … 737 737 TrialVector.CopyVector(checker->second->node->node); 738 738 TrialVector.SubtractVector(A->second->node->node); 739 distance = TrialVector. Projection(&PlaneVector);739 distance = TrialVector.ScalarProduct(&PlaneVector); 740 740 if (fabs(distance) < 1e-4) // we need to have a small epsilon around 0 which is still ok 741 741 continue; … … 897 897 TempVector.SubtractVector(baseline->second->endpoints[0]->node->node); // TempVector is vector on triangle plane pointing from one baseline egde towards center! 898 898 //*out << Verbose(2) << "Projection of propagation onto temp: " << PropagationVector.Projection(&TempVector) << "." << endl; 899 if (PropagationVector. Projection(&TempVector) > 0) // make sure normal propagation vector points outward from baseline899 if (PropagationVector.ScalarProduct(&TempVector) > 0) // make sure normal propagation vector points outward from baseline 900 900 PropagationVector.Scale(-1.); 901 901 *out << Verbose(4) << "PropagationVector of base triangle is " << PropagationVector << endl; … … 957 957 TempVector.SubtractVector(Center); 958 958 // make it always point outward 959 if (VirtualNormalVector. Projection(&TempVector) < 0)959 if (VirtualNormalVector.ScalarProduct(&TempVector) < 0) 960 960 VirtualNormalVector.Scale(-1.); 961 961 // calculate angle … … 1530 1530 AddTesselationLine(TPS[0], TPS[1], 0); 1531 1531 } 1532 cout << Verbose(2) << "Projection is " << BTS->NormalVector. Projection(&Oben) << "." << endl;1532 cout << Verbose(2) << "Projection is " << BTS->NormalVector.ScalarProduct(&Oben) << "." << endl; 1533 1533 } 1534 1534 if (BTS != NULL) // we have created one starting triangle -
src/tesselationhelpers.cpp
r54a746 r658efb 359 359 HeightA.SubtractVector(&par.x1); 360 360 361 t1 = HeightA. Projection(&SideA)/SideA.ScalarProduct(&SideA);361 t1 = HeightA.ScalarProduct(&SideA)/SideA.ScalarProduct(&SideA); 362 362 363 363 SideB.CopyVector(&par.x4); … … 366 366 HeightB.SubtractVector(&par.x3); 367 367 368 t2 = HeightB. Projection(&SideB)/SideB.ScalarProduct(&SideB);368 t2 = HeightB.ScalarProduct(&SideB)/SideB.ScalarProduct(&SideB); 369 369 370 370 cout << Verbose(2) << "Intersection " << intersection << " is at "
Note:
See TracChangeset
for help on using the changeset viewer.