/* Some sizes */
#define N_STATE_DIMENSIONS 8
#define N_ACTION_DIMENSIONS 1

/* State vector indices */
#define S_X 0
#define S_Y 1
#define S_A0 2
#define S_HIPL 3
#define S_XD 4
#define S_YD 5
#define S_A0D 6
#define S_HIPLD 7

/* Action vector indices */
#define A_HIPL 0

/* Treat the contents of this definition as hidden */
typedef struct dynamics_struct
{
  double time;     // current time in simulation
  double timestep; // Timestep of simulation
  double state[N_STATE_DIMENSIONS];
  unsigned seed; /* random number generator seed for rand_r() */
} Dynamics;
  
/* The dynamics API */
int init_dynamics();
Dynamics *create_dynamics();
int set_state( Dynamics *d, double time, double *state );
int integrate_one_step( Dynamics *d, double *action, double *next_state );
int integrate_one_step_alt( Dynamics *d, double *state, double *action,
			    double *next_state );
double one_step_cost( Dynamics *d, double *state, double *action );

