|
Molecular Dynamics
v0.4
Project for the Practical hosted by the Scientific Computing Chair
|
Implementation of the gravitational force. More...
#include <Gravity.h>


Public Member Functions | |
| std::array< double, 3 > | compute (Particle &target, Particle &source) override |
| Actual computation of the gravitational force occurring. More... | |
| std::array< double, 3 > | computeOptimized (Particle &target, Particle &source, std::array< double, 3 > &difference, double distance) override |
| We needed this to integrate our optimization in our code to prevent breaking the inheritance hierachy. Will be removed, when we integrated the optimization properly. More... | |
Public Member Functions inherited from Force | |
| virtual | ~Force ()=default |
Implementation of the gravitational force.
The gravitational force is one example of a force which might act between two particles in space.
Actual computation of the gravitational force occurring.
| target | Particle on which the gravitational force acts. |
| source | Particle which exerts the gravitational force on the target. |
Computation of the gravitational force which exerts the source on the target.
Implements Force.

|
overridevirtual |
We needed this to integrate our optimization in our code to prevent breaking the inheritance hierachy. Will be removed, when we integrated the optimization properly.
Implements Force.