next up previous contents
Next: Function: integrate_function() Up: GRASP Routines: Waveforms from Previous: Function: read_modes()   Contents

Function: read_real_data_file()

0 int read_real_data_file(const char *filename, float **x, float **y, int *number_of_points, int ReadX)
Read in a simple data file consisting of just two columns of data.
filename: Input. The file to read.
x: Input/Output. If ReadX is true ($\neq 0$) the array x[0..*number_of_points-1] will contain the first column of data. If **x == NULL allocate the memory. If number_of_points is nonzero allocate space for number_of_points points.
y: Input/Output. The array y[0..*number_of_points-1] will contain the second column of data. If **y == NULL allocate the memory. If number_of_points is nonzero allocate space for number_of_points points.
ReadX: Input. If false (=0) don't read the x-values.
Return value: Output. Errors.
Author: Serge Droz, droz@physics.uoguelph.ca
Comments: You must set the environment variable GRASP_PARAMETERS to the name of the GRASP parameter directory.



Bruce Allen 2000-11-19