mdcore  0.1.5
Defines | Functions | Variables
/home/pedro/work/mdcore/src/runner_dopair.c File Reference
#include "../config.h"
#include <stdlib.h>
#include <stdio.h>
#include <pthread.h>
#include <math.h>
#include <float.h>
#include <string.h>
#include <limits.h>
#include <sched.h>
#include "cycle.h"
#include "errs.h"
#include "fptype.h"
#include "lock.h"
#include "part.h"
#include "cell.h"
#include "fifo.h"
#include "space.h"
#include "potential.h"
#include "potential_eval.h"
#include "engine.h"
#include "runner.h"

Defines

#define error(id)   ( runner_err = errs_register( id , runner_err_msg[-(id)] , __LINE__ , __FUNCTION__ , __FILE__ ) )

Functions

 __attribute__ ((flatten))
 Compute the pairwise interactions for the given pair using the sorted interactions algorithm.

Variables

char * runner_err_msg []
unsigned int runner_rcount

Define Documentation

#define error (   id)    ( runner_err = errs_register( id , runner_err_msg[-(id)] , __LINE__ , __FUNCTION__ , __FILE__ ) )

Function Documentation

__attribute__ ( (flatten)  )

Compute the pairwise interactions for the given pair using the sorted interactions algorithm.

Fill in the Verlet list entries for the given cell pair.

Fill in the pairwise Verlet list entries for the given cell pair if needed and compute the interactions.

Compute the pairwise interactions for the given pair.

Parameters:
rThe runner computing the pair.
cell_iThe first cell.
cell_jThe second cell.
pshiftA pointer to an array of three floating point values containing the vector separating the centers of cell_i and cell_j.
Returns:
runner_err_ok or <0 on error (see runner_err)

Sorts the particles from cell_i and cell_j along the normalized axis pshift and tries to interact only those particles that are within the cutoff distance along that axis.

It is assumed that cell_i != cell_j.

See also:
runner_dopair.
Parameters:
rThe runner computing the pair.
cell_iThe first cell.
cell_jThe second cell.
shiftA pointer to an array of three floating point values containing the vector separating the centers of cell_i and cell_j.
Returns:
runner_err_ok or <0 on error (see runner_err)

Computes the interactions between all the particles in cell_i and all the paritcles in cell_j. cell_i and cell_j may be the same cell.

See also:
#runner_sortedpair.
Parameters:
rThe runner computing the pair.
cell_iThe first cell.
cell_jThe second cell.
pshiftA pointer to an array of three floating point values containing the vector separating the centers of cell_i and cell_j.
Returns:
runner_err_ok or <0 on error (see runner_err)

This routine differs from runner_dopair_verlet in that instead of storing a Verlet table, the sorted particle ids are stored. This requires only (size_i + size_j) entries as opposed to size_i*size_j for the Verlet table, yet may be less efficient since particles within the skin along the cell-pair axis are inspected, as opposed to particles simply within the skin of each other.

Parameters:
rThe runner computing the pair.
cell_iThe first cell.
cell_jThe second cell.
pshiftA pointer to an array of three floating point values containing the vector separating the centers of cell_i and cell_j.
Returns:
runner_err_ok or <0 on error (see runner_err)

Variable Documentation

char* runner_err_msg[]
unsigned int runner_rcount
 All Data Structures Files Functions Variables Typedefs Enumerator Defines