-/**
- * Structure to represent a barrier for multiple threads
- * @param mutex - Mutex around the counter
- * @param busy - Counter of threads within the barrier
- * @param threads_done_cv - Condition to wake up threads waiting on barrier once all working threads have left it
- */
-typedef struct
-{
- pthread_mutex_t mutex;
- unsigned threads_busy; // Counter of threads which are busy
- pthread_cond_t threads_done_cv;
-} Barrier;
-
-/**
- * Structure to represent a pair of Systems; passed to Force_Thread
- * @param A - System to calculate forces for
- * @param B - System causing forces on System A
- */
-typedef struct
-{
- System * A;
- System * B;
-} System_ForcePair;
-
-void Barrier_Init(Barrier * b);
-void Barrier_Enter(Barrier * b);
-void Barrier_Leave(Barrier * b);
-void Barrier_Wait(Barrier * b);