Change dynamic array to static boost/stl array in AInteraction

Registered by Łukasz Łaniewski-Wołłk

Change the AInteraction class to a template with the argument of number of particles, and change the dynamic std::vector to boost::array or std::array in C++11.

This will:
1. speed up the code
2. get rid of "evil hack"-s in Parallel Interaction Storage

Blueprint information

Status:
Started
Approver:
None
Priority:
Undefined
Drafter:
Łukasz Łaniewski-Wołłk
Direction:
Needs approval
Assignee:
Łukasz Łaniewski-Wołłk
Definition:
New
Series goal:
None
Implementation:
Beta Available
Milestone target:
None
Started by
Łukasz Łaniewski-Wołłk

Sprints

Whiteboard

I agree that using a std::vector for AInteraction::m_id doesn't make much sense, at least at the moment.
The historical context why this is a std::vector is that, at the time when the code was originally written, we wanted to keep the option open to implement interactions involving more than 2 particles, including interactions between a _variable_ number of particles. Given that I can't foresee the implementation of such interactions in the foreseeable future (and doing so would probably require major changes to ParallelInteractionStorage anyway) it probably is a good idea to implement the suggested change.

Of the options suggested I would prefer std::array over boost::array. Q: given that the number of elements would be static, small and fixed by the template parameter, would there be any advantage in using std::tuple instead of std::array ?

Steffen

(?)

Work Items

This blueprint contains Public information 
Everyone can see this information.