usr/kevin/code/develop/direct.c
void direct_driver(ffs_param_t * ffs) {

  int n;
  double runtime;
  sim_state_t * s_init;

  Ensemble current;
  Ensemble next;

  simulation_set_up(ffs);
  s_init = simulation_state_initialise(ffs); 

  direct_initial_ensemble(&current, &runtime, s_init, ffs);

  for (n = 1; n < ffs->nlambda; n++) {

    printf("Interface %3d start trials lambda %5.2f -> %5.2f\n", n,
	   ffs->interface[n].lambda, ffs->interface[n+1].lambda);
    
    next = direct_advance_ensemble(n, current, ffs);

    free_ensemble(current);
    current = convert_ensemble(next);
    free_ensemble(next);
    printf("Interface %3d weight %lf\n", n, ffs->interface[n].weight);
  }

  simulation_state_finalise(s_init);
  simulation_tear_down();

  output_data(runtime, ffs);

  return;
}
/*****************************************************************************
 *
 *  direct_driver
 *
 *  Driver section for direct algorithm.
 *
 *****************************************************************************/
direct_driver
Driver section for direct algorithm.
direct_driver Driver section for direct algorithm .
void direct_driver(ffs_param_t * ffs) {
  int n;
  double runtime;
  sim_state_t * s_init;
  Ensemble current;
  Ensemble next;
  simulation_set_up(ffs);
  s_init = simulation_state_initialise(ffs); 
  direct_initial_ensemble(&current, &runtime, s_init, ffs);
  for (n = 1; n < ffs->nlambda; n++) {
    printf("Interface %3d start trials lambda %5.2f -> %5.2f\n", n,
	   ffs->interface[n].lambda, ffs->interface[n+1].lambda);
    next = direct_advance_ensemble(n, current, ffs);
    free_ensemble(current);
    current = convert_ensemble(next);
    free_ensemble(next);
    printf("Interface %3d weight %lf\n", n, ffs->interface[n].weight);
  }
  simulation_state_finalise(s_init);
  simulation_tear_down();
  output_data(runtime, ffs);
  return;
}
void direct_driver ( ffs_param_t * ffs ) { int n ; double runtime ; sim_state_t * s_init ; Ensemble current ; Ensemble next ; simulation_set_up ( ffs ) ; s_init = simulation_state_initialise ( ffs ) ; direct_initial_ensemble ( & current , & runtime , s_init , ffs ) ; for ( n = 1 ; n < ffs -> nlambda ; n ++ ) { printf ( " \n " , n , ffs -> interface [ n ] . lambda , ffs -> interface [ n + 1 ] . lambda ) ; next = direct_advance_ensemble ( n , current , ffs ) ; free_ensemble ( current ) ; current = convert_ensemble ( next ) ; free_ensemble ( next ) ; printf ( " \n " , n , ffs -> interface [ n ] . weight ) ; } simulation_state_finalise ( s_init ) ; simulation_tear_down ( ) ; output_data ( runtime , ffs ) ; return ; }
direct_driver
  Driver section for direct algorithm.
direct_driver Driver section for direct algorithm .