JWS C Library
C language utility library
vector_io.h File Reference

Declarations for I/O operations on a vector. More...

#include <jwsc/config.h>
#include <stdlib.h>
#include <stdio.h>
#include <inttypes.h>
#include "jwsc/base/error.h"
#include "jwsc/math/complex.h"
#include "jwsc/vector/vector.h"
Include dependency graph for vector_io.h:

Go to the source code of this file.

Functions

read_vector

Reads a vector from a file.

Errorread_vector_u32 (Vector_u32 **v_out, const char *fname)
 Reads a 32-bit unsigned integer vector.
Errorread_vector_i32 (Vector_i32 **v_out, const char *fname)
 Reads a 32-bit signed integer vector.
Errorread_vector_i64 (Vector_i64 **v_out, const char *fname)
 Reads a 64-bit signed integer vector.
Errorread_vector_f (Vector_f **v_out, const char *fname)
 Reads a single precision floating point vector.
Errorread_vector_d (Vector_d **v_out, const char *fname)
 Reads a double precision floating point vector.
Errorread_vector_cf (Vector_cf **v_out, const char *fname)
 Reads a single precision complex floating point vector.
Errorread_vector_cd (Vector_cd **v_out, const char *fname)
 Reads a double precision complex floating point vector.
read_vector_fp

Reads a vector from an opened file.

Errorread_vector_fp_u32 (Vector_u32 **v_out, FILE *fp)
 Reads a 32-bit unsigned integer vector.
Errorread_vector_fp_i32 (Vector_i32 **v_out, FILE *fp)
 Reads a 32-bit signed integer vector.
Errorread_vector_fp_i64 (Vector_i64 **v_out, FILE *fp)
 Reads a 64-bit signed integer vector.
Errorread_vector_fp_f (Vector_f **v_out, FILE *fp)
 Reads a single precision floating point vector.
Errorread_vector_fp_d (Vector_d **v_out, FILE *fp)
 Reads a double precision floating point vector.
Errorread_vector_fp_cf (Vector_cf **v_out, FILE *fp)
 Reads a single precision complex floating point vector.
Errorread_vector_fp_cd (Vector_cd **v_out, FILE *fp)
 Reads a double precision complex floating point vector.
write_vector

Writes a vector to a file.

Errorwrite_vector_u32 (const Vector_u32 *v, const char *fname)
 Writes a 32-bit unsigned integer vector.
Errorwrite_vector_i32 (const Vector_i32 *v, const char *fname)
 Writes a 32-bit signed integer vector.
Errorwrite_vector_i64 (const Vector_i64 *v, const char *fname)
 Writes a 64-bit signed integer vector.
Errorwrite_vector_f (const Vector_f *v, const char *fname)
 Writes a single precision floating point vector.
Errorwrite_vector_d (const Vector_d *v, const char *fname)
 Writes a double precision floating point vector.
Errorwrite_vector_cf (const Vector_cf *v, const char *fname)
 Writes a single precision complex floating point vector.
Errorwrite_vector_cd (const Vector_cd *v, const char *fname)
 Writes a double precision complex floating point vector.
write_formatted_vector

Writes a formatted vector to a file.

Errorwrite_formatted_vector_u32 (const Vector_u32 *v, const char *fmt, const char *fname)
 Writes a formatted 32-bit unsigned integer vector.
Errorwrite_formatted_vector_i32 (const Vector_i32 *v, const char *fmt, const char *fname)
 Writes a formatted 32-bit signed integer vector.
Errorwrite_formatted_vector_i64 (const Vector_i64 *v, const char *fmt, const char *fname)
 Writes a formatted 64-bit signed integer vector.
Errorwrite_formatted_vector_f (const Vector_f *v, const char *fmt, const char *fname)
 Writes a formatted single precision floating point vector.
Errorwrite_formatted_vector_d (const Vector_d *v, const char *fmt, const char *fname)
 Writes a formatted double precision floating point vector.
Errorwrite_formatted_vector_cf (const Vector_cf *v, const char *fmt, const char *fname)
 Writes a formatted single precision complex floating point vector.
Errorwrite_formatted_vector_cd (const Vector_cd *v, const char *fmt, const char *fname)
 Writes a formatted double precision complex floating point vector.
write_vector_fp

Writes a vector to an opened file.

Errorwrite_vector_fp_u32 (const Vector_u32 *v, FILE *fp)
 Writes a 32-bit unsigned integer vector.
Errorwrite_vector_fp_i32 (const Vector_i32 *v, FILE *fp)
 Writes a 32-bit signed integer vector.
Errorwrite_vector_fp_i64 (const Vector_i64 *v, FILE *fp)
 Writes a 64-bit signed integer vector.
Errorwrite_vector_fp_f (const Vector_f *v, FILE *fp)
 Writes a single precision floating point vector.
Errorwrite_vector_fp_d (const Vector_d *v, FILE *fp)
 Writes a double precision floating point vector.
Errorwrite_vector_fp_cf (const Vector_cf *v, FILE *fp)
 Writes a single precision complex floating point vector.
Errorwrite_vector_fp_cd (const Vector_cd *v, FILE *fp)
 Writes a double precision complex floating point vector.
write_formatted_vector_fp

Writes a vector to an opened file.

Errorwrite_formatted_vector_fp_u32 (const Vector_u32 *v, const char *fmt, FILE *fp)
 Writes a formatted 32-bit unsigned integer vector.
Errorwrite_formatted_vector_fp_i32 (const Vector_i32 *v, const char *fmt, FILE *fp)
 Writes a formatted 32-bit signed integer vector.
Errorwrite_formatted_vector_fp_i64 (const Vector_i64 *v, const char *fmt, FILE *fp)
 Writes a formatted 64-bit signed integer vector.
Errorwrite_formatted_vector_fp_f (const Vector_f *v, const char *fmt, FILE *fp)
 Writes a formatted single precision floating point vector.
Errorwrite_formatted_vector_fp_d (const Vector_d *v, const char *fmt, FILE *fp)
 Writes a formatted double precision floating point vector.
Errorwrite_formatted_vector_fp_cf (const Vector_cf *v, const char *fmt, FILE *fp)
 Writes a formatted single precision complex floating point vector.
Errorwrite_formatted_vector_fp_cd (const Vector_cd *v, const char *fmt, FILE *fp)
 Writes a formatted double precision complex floating point vector.
read_vector_with_header

Reads a vector with a header from a file.

Errorread_vector_with_header_u32 (Vector_u32 **v_out, const char *fname)
 Reads a 32-bit unsigned integer vector.
Errorread_vector_with_header_i32 (Vector_i32 **v_out, const char *fname)
 Reads a 32-bit signed integer vector.
Errorread_vector_with_header_i64 (Vector_i64 **v_out, const char *fname)
 Reads a 64-bit signed integer vector.
Errorread_vector_with_header_f (Vector_f **v_out, const char *fname)
 Reads a single precision floating point vector.
Errorread_vector_with_header_d (Vector_d **v_out, const char *fname)
 Reads a double precision floating point vector.
Errorread_vector_with_header_cf (Vector_cf **v_out, const char *fname)
 Reads a single precision complex floating point vector.
Errorread_vector_with_header_cd (Vector_cd **v_out, const char *fname)
 Reads a double precision complex floating point vector.
read_vector_with_header_fp

Reads a vector with a header from an opened file.

Errorread_vector_with_header_fp_u32 (Vector_u32 **v_out, FILE *fp)
 Reads a 32-bit unsigned integer vector.
Errorread_vector_with_header_fp_i32 (Vector_i32 **v_out, FILE *fp)
 Reads a 32-bit signed integer vector.
Errorread_vector_with_header_fp_i64 (Vector_i64 **v_out, FILE *fp)
 Reads a 64-bit signed integer vector.
Errorread_vector_with_header_fp_f (Vector_f **v_out, FILE *fp)
 Reads a single precision floating point vector.
Errorread_vector_with_header_fp_d (Vector_d **v_out, FILE *fp)
 Reads a double precision floating point vector.
Errorread_vector_with_header_fp_cf (Vector_cf **v_out, FILE *fp)
 Reads a single precision complex floating point vector.
Errorread_vector_with_header_fp_cd (Vector_cd **v_out, FILE *fp)
 Reads a double precision complex floating point vector.
write_vector_with_header

Writes a vector with a header to a file.

Errorwrite_vector_with_header_u32 (const Vector_u32 *v, const char *fname)
 Writes a 32-bit unsigned integer vector.
Errorwrite_vector_with_header_i32 (const Vector_i32 *v, const char *fname)
 Writes a 32-bit signed integer vector.
Errorwrite_vector_with_header_i64 (const Vector_i64 *v, const char *fname)
 Writes a 64-bit signed integer vector.
Errorwrite_vector_with_header_f (const Vector_f *v, const char *fname)
 Writes a single precision floating point vector.
Errorwrite_vector_with_header_d (const Vector_d *v, const char *fname)
 Writes a double precision floating point vector.
Errorwrite_vector_with_header_cf (const Vector_cf *v, const char *fname)
 Writes a single precision complex floating point vector.
Errorwrite_vector_with_header_cd (const Vector_cd *v, const char *fname)
 Writes a double precision complex floating point vector.
write_formatted_vector_with_header

Writes a formatted vector with a header to a file.

Errorwrite_formatted_vector_with_header_u32 (const Vector_u32 *v, const char *fmt, const char *fname)
 Writes a formatted 32-bit unsigned integer vector.
Errorwrite_formatted_vector_with_header_i32 (const Vector_i32 *v, const char *fmt, const char *fname)
 Writes a formatted 32-bit signed integer vector.
Errorwrite_formatted_vector_with_header_i64 (const Vector_i64 *v, const char *fmt, const char *fname)
 Writes a formatted 64-bit signed integer vector.
Errorwrite_formatted_vector_with_header_f (const Vector_f *v, const char *fmt, const char *fname)
 Writes a formatted single precision floating point vector.
Errorwrite_formatted_vector_with_header_d (const Vector_d *v, const char *fmt, const char *fname)
 Writes a formatted double precision floating point vector.
Errorwrite_formatted_vector_with_header_cf (const Vector_cf *v, const char *fmt, const char *fname)
 Writes a formatted single precision complex floating point vector.
Errorwrite_formatted_vector_with_header_cd (const Vector_cd *v, const char *fmt, const char *fname)
 Writes a formatted double precision complex floating point vector.
write_vector_with_header_fp

Writes a vector with a header to an opened file.

Errorwrite_vector_with_header_fp_u32 (const Vector_u32 *v, FILE *fp)
 Writes a 32-bit unsigned integer vector.
Errorwrite_vector_with_header_fp_i32 (const Vector_i32 *v, FILE *fp)
 Writes a 32-bit signed integer vector.
Errorwrite_vector_with_header_fp_i64 (const Vector_i64 *v, FILE *fp)
 Writes a 64-bit signed integer vector.
Errorwrite_vector_with_header_fp_f (const Vector_f *v, FILE *fp)
 Writes a single precision floating point vector.
Errorwrite_vector_with_header_fp_d (const Vector_d *v, FILE *fp)
 Writes a double precision floating point vector.
Errorwrite_vector_with_header_fp_cf (const Vector_cf *v, FILE *fp)
 Writes a single precision complex floating point vector.
Errorwrite_vector_with_header_fp_cd (const Vector_cd *v, FILE *fp)
 Writes a double precision complex floating point vector.
write_formatted_vector_with_header_fp

Writes a formatted vector with a header to an opened file.

Errorwrite_formatted_vector_with_header_fp_u32 (const Vector_u32 *v, const char *fmt, FILE *fp)
 Writes a formatted 32-bit unsigned integer vector.
Errorwrite_formatted_vector_with_header_fp_i32 (const Vector_i32 *v, const char *fmt, FILE *fp)
 Writes a formatted 32-bit signed integer vector.
Errorwrite_formatted_vector_with_header_fp_i64 (const Vector_i64 *v, const char *fmt, FILE *fp)
 Writes a formatted 64-bit signed integer vector.
Errorwrite_formatted_vector_with_header_fp_f (const Vector_f *v, const char *fmt, FILE *fp)
 Writes a formatted single precision floating point vector.
Errorwrite_formatted_vector_with_header_fp_d (const Vector_d *v, const char *fmt, FILE *fp)
 Writes a formatted double precision floating point vector.
Errorwrite_formatted_vector_with_header_fp_cf (const Vector_cf *v, const char *fmt, FILE *fp)
 Writes a formatted single precision complex floating point vector.
Errorwrite_formatted_vector_with_header_fp_cd (const Vector_cd *v, const char *fmt, FILE *fp)
 Writes a formatted double precision complex floating point vector.

Detailed Description

Declarations for I/O operations on a vector.

Author:
Joseph Schlecht
License:
Creative Commons BY-NC-SA 3.0

Definition in file vector_io.h.


Function Documentation

Error* read_vector_u32 ( Vector_u32 **  v_out,
const char *  fname 
)

Reads a 32-bit unsigned integer vector.

Format of the vector in the file is expected to be one line containing all the elements. Blank lines and lines beginning with '#' are skipped. For example,

 # Comment.
 1 2 3 4 5 6 7 8 9
Parameters:
v_outResult parameter. If *v_out is NULL, a vector is allocated; otherwise its space is re-used.
fnameName of the file to read the vector from.
Returns:
On success, NULL is returned; otherwise an Error is returned and *v_out is freed and set to NULL.
  • ERROR_IO Either there was a problem reading the file, or the vector in the file is not formatted properly.

Definition at line 179 of file vector_io.c.

Error* read_vector_i32 ( Vector_i32 **  v_out,
const char *  fname 
)

Reads a 32-bit signed integer vector.

Format of the vector in the file is expected to be one line containing all the elements. Blank lines and lines beginning with '#' are skipped. For example,

 # Comment.
 1 2 3 4 5 6 7 8 9
Parameters:
v_outResult parameter. If *v_out is NULL, a vector is allocated; otherwise its space is re-used.
fnameName of the file to read the vector from.
Returns:
On success, NULL is returned; otherwise an Error is returned and *v_out is freed and set to NULL.
  • ERROR_IO Either there was a problem reading the file, or the vector in the file is not formatted properly.

Definition at line 225 of file vector_io.c.

Error* read_vector_i64 ( Vector_i64 **  v_out,
const char *  fname 
)

Reads a 64-bit signed integer vector.

Format of the vector in the file is expected to be one line containing all the elements. Blank lines and lines beginning with '#' are skipped. For example,

 # Comment.
 1 2 3 4 5 6 7 8 9
Parameters:
v_outResult parameter. If *v_out is NULL, a vector is allocated; otherwise its space is re-used.
fnameName of the file to read the vector from.
Returns:
On success, NULL is returned; otherwise an Error is returned and *v_out is freed and set to NULL.
  • ERROR_IO Either there was a problem reading the file, or the vector in the file is not formatted properly.

Definition at line 271 of file vector_io.c.

Error* read_vector_f ( Vector_f **  v_out,
const char *  fname 
)

Reads a single precision floating point vector.

Format of the vector in the file is expected to be one line containing all the elements. Blank lines and lines beginning with '#' are skipped. For example,

 # Comment.
 1 2 3 4 5 6 7 8 9
Parameters:
v_outResult parameter. If *v_out is NULL, a vector is allocated; otherwise its space is re-used.
fnameName of the file to read the vector from.
Returns:
On success, NULL is returned; otherwise an Error is returned and *v_out is freed and set to NULL.
  • ERROR_IO Either there was a problem reading the file, or the vector in the file is not formatted properly.

Definition at line 317 of file vector_io.c.

Error* read_vector_d ( Vector_d **  v_out,
const char *  fname 
)

Reads a double precision floating point vector.

Format of the vector in the file is expected to be one line containing all the elements. Blank lines and lines beginning with '#' are skipped. For example,

 # Comment.
 1 2 3 4 5 6 7 8 9
Parameters:
v_outResult parameter. If *v_out is NULL, a vector is allocated; otherwise its space is re-used.
fnameName of the file to read the vector from.
Returns:
On success, NULL is returned; otherwise an Error is returned and *v_out is freed and set to NULL.
  • ERROR_IO Either there was a problem reading the file, or the vector in the file is not formatted properly.

Definition at line 363 of file vector_io.c.

Error* read_vector_cf ( Vector_cf **  v_out,
const char *  fname 
)

Reads a single precision complex floating point vector.

Format of the vector in the file is expected to be one line containing all the elements. Blank lines and lines beginning with '#' are skipped. For example,

 # Comment.
 1 2 3 4 5 6 7 8 9
Parameters:
v_outResult parameter. If *v_out is NULL, a vector is allocated; otherwise its space is re-used.
fnameName of the file to read the vector from.
Returns:
On success, NULL is returned; otherwise an Error is returned and *v_out is freed and set to NULL.
  • ERROR_IO Either there was a problem reading the file, or the vector in the file is not formatted properly.

Definition at line 409 of file vector_io.c.

Error* read_vector_cd ( Vector_cd **  v_out,
const char *  fname 
)

Reads a double precision complex floating point vector.

Format of the vector in the file is expected to be one line containing all the elements. Blank lines and lines beginning with '#' are skipped. For example,

 # Comment.
 1 2 3 4 5 6 7 8 9
Parameters:
v_outResult parameter. If *v_out is NULL, a vector is allocated; otherwise its space is re-used.
fnameName of the file to read the vector from.
Returns:
On success, NULL is returned; otherwise an Error is returned and *v_out is freed and set to NULL.
  • ERROR_IO Either there was a problem reading the file, or the vector in the file is not formatted properly.

Definition at line 455 of file vector_io.c.

Error* read_vector_fp_u32 ( Vector_u32 **  v_out,
FILE *  fp 
)

Reads a 32-bit unsigned integer vector.

Format of the vector in the file is expected to be one line containing all the elements. Blank lines and lines beginning with '#' are skipped. For example,

 # Comment.
 1 2 3 4 5 6 7 8 9
Parameters:
v_outResult parameter. If *v_out is NULL, a vector is allocated; otherwise its space is re-used.
fpFile to read the vector from.
Returns:
On success, NULL is returned; otherwise an Error is returned and *v_out is freed and set to NULL.
  • ERROR_IO Either there was a problem reading the file, or the vector in the file is not formatted properly.

Definition at line 513 of file vector_io.c.

Error* read_vector_fp_i32 ( Vector_i32 **  v_out,
FILE *  fp 
)

Reads a 32-bit signed integer vector.

Format of the vector in the file is expected to be one line containing all the elements. Blank lines and lines beginning with '#' are skipped. For example,

 # Comment.
 1 2 3 4 5 6 7 8 9
Parameters:
v_outResult parameter. If *v_out is NULL, a vector is allocated; otherwise its space is re-used.
fpFile to read the vector from.
Returns:
On success, NULL is returned; otherwise an Error is returned and *v_out is freed and set to NULL.
  • ERROR_IO Either there was a problem reading the file, or the vector in the file is not formatted properly.

Definition at line 604 of file vector_io.c.

Error* read_vector_fp_i64 ( Vector_i64 **  v_out,
FILE *  fp 
)

Reads a 64-bit signed integer vector.

Format of the vector in the file is expected to be one line containing all the elements. Blank lines and lines beginning with '#' are skipped. For example,

 # Comment.
 1 2 3 4 5 6 7 8 9
Parameters:
v_outResult parameter. If *v_out is NULL, a vector is allocated; otherwise its space is re-used.
fpFile to read the vector from.
Returns:
On success, NULL is returned; otherwise an Error is returned and *v_out is freed and set to NULL.
  • ERROR_IO Either there was a problem reading the file, or the vector in the file is not formatted properly.

Definition at line 695 of file vector_io.c.

Error* read_vector_fp_f ( Vector_f **  v_out,
FILE *  fp 
)

Reads a single precision floating point vector.

Format of the vector in the file is expected to be one line containing all the elements. Blank lines and lines beginning with '#' are skipped. For example,

 # Comment.
 1 2 3 4 5 6 7 8 9
Parameters:
v_outResult parameter. If *v_out is NULL, a vector is allocated; otherwise its space is re-used.
fpFile to read the vector from.
Returns:
On success, NULL is returned; otherwise an Error is returned and *v_out is freed and set to NULL.
  • ERROR_IO Either there was a problem reading the file, or the vector in the file is not formatted properly.

Definition at line 786 of file vector_io.c.

Error* read_vector_fp_d ( Vector_d **  v_out,
FILE *  fp 
)

Reads a double precision floating point vector.

Format of the vector in the file is expected to be one line containing all the elements. Blank lines and lines beginning with '#' are skipped. For example,

 # Comment.
 1 2 3 4 5 6 7 8 9
Parameters:
v_outResult parameter. If *v_out is NULL, a vector is allocated; otherwise its space is re-used.
fpFile to read the vector from.
Returns:
On success, NULL is returned; otherwise an Error is returned and *v_out is freed and set to NULL.
  • ERROR_IO Either there was a problem reading the file, or the vector in the file is not formatted properly.

Definition at line 877 of file vector_io.c.

Error* read_vector_fp_cf ( Vector_cf **  v_out,
FILE *  fp 
)

Reads a single precision complex floating point vector.

Format of the vector in the file is expected to be one line containing all the elements. Blank lines and lines beginning with '#' are skipped. For example,

 # Comment.
 1 2 3 4 5 6 7 8 9
Parameters:
v_outResult parameter. If *v_out is NULL, a vector is allocated; otherwise its space is re-used.
fpFile to read the vector from.
Returns:
On success, NULL is returned; otherwise an Error is returned and *v_out is freed and set to NULL.
  • ERROR_IO Either there was a problem reading the file, or the vector in the file is not formatted properly.

Definition at line 968 of file vector_io.c.

Error* read_vector_fp_cd ( Vector_cd **  v_out,
FILE *  fp 
)

Reads a double precision complex floating point vector.

Format of the vector in the file is expected to be one line containing all the elements. Blank lines and lines beginning with '#' are skipped. For example,

 # Comment.
 1 2 3 4 5 6 7 8 9
Parameters:
v_outResult parameter. If *v_out is NULL, a vector is allocated; otherwise its space is re-used.
fpFile to read the vector from.
Returns:
On success, NULL is returned; otherwise an Error is returned and *v_out is freed and set to NULL.
  • ERROR_IO Either there was a problem reading the file, or the vector in the file is not formatted properly.

Definition at line 1060 of file vector_io.c.

Error* write_vector_u32 ( const Vector_u32 v,
const char *  fname 
)

Writes a 32-bit unsigned integer vector.

Format of the vector written is one line containing all the elements. For example,

 1 2 3 4 5 6 7 8 9
Parameters:
vVector to write.
fnameName of the file to write the vector to.
Returns:
On success, NULL is returned; otherwise an Error is returned.
  • ERROR_IO There was a problem writing to the file.

Definition at line 1159 of file vector_io.c.

Error* write_vector_i32 ( const Vector_i32 v,
const char *  fname 
)

Writes a 32-bit signed integer vector.

Format of the vector written is one line containing all the elements. For example,

 1 2 3 4 5 6 7 8 9
Parameters:
vVector to write.
fnameName of the file to write the vector to.
Returns:
On success, NULL is returned; otherwise an Error is returned.
  • ERROR_IO There was a problem writing to the file.

Definition at line 1198 of file vector_io.c.

Error* write_vector_i64 ( const Vector_i64 v,
const char *  fname 
)

Writes a 64-bit signed integer vector.

Format of the vector written is one line containing all the elements. For example,

 1 2 3 4 5 6 7 8 9
Parameters:
vVector to write.
fnameName of the file to write the vector to.
Returns:
On success, NULL is returned; otherwise an Error is returned.
  • ERROR_IO There was a problem writing to the file.

Definition at line 1237 of file vector_io.c.

Error* write_vector_f ( const Vector_f v,
const char *  fname 
)

Writes a single precision floating point vector.

Format of the vector written is one line containing all the elements. For example,

 1 2 3 4 5 6 7 8 9
Parameters:
vVector to write.
fnameName of the file to write the vector to.
Returns:
On success, NULL is returned; otherwise an Error is returned.
  • ERROR_IO There was a problem writing to the file.

Definition at line 1276 of file vector_io.c.

Error* write_vector_d ( const Vector_d v,
const char *  fname 
)

Writes a double precision floating point vector.

Format of the vector written is one line containing all the elements. For example,

 1 2 3 4 5 6 7 8 9
Parameters:
vVector to write.
fnameName of the file to write the vector to.
Returns:
On success, NULL is returned; otherwise an Error is returned.
  • ERROR_IO There was a problem writing to the file.

Definition at line 1315 of file vector_io.c.

Error* write_vector_cf ( const Vector_cf v,
const char *  fname 
)

Writes a single precision complex floating point vector.

Format of the vector written is one line containing all the elements. For example,

 1 2 3 4 5 6
Parameters:
vVector to write.
fnameName of the file to write the vector to.
Returns:
On success, NULL is returned; otherwise an Error is returned.
  • ERROR_IO There was a problem writing to the file.

Definition at line 1354 of file vector_io.c.

Error* write_vector_cd ( const Vector_cd v,
const char *  fname 
)

Writes a double precision complex floating point vector.

Format of the vector written is one line containing all the elements. For example,

 1 2 3 4 5 6
Parameters:
vVector to write.
fnameName of the file to write the vector to.
Returns:
On success, NULL is returned; otherwise an Error is returned.
  • ERROR_IO There was a problem writing to the file.

Definition at line 1393 of file vector_io.c.

Error* write_formatted_vector_u32 ( const Vector_u32 v,
const char *  fmt,
const char *  fname 
)

Writes a formatted 32-bit unsigned integer vector.

Format of the vector written is one line containing all the elements. For example,

 1 2 3 4 5 6 7 8 9
Parameters:
vVector to write.
fmtPrintf style format for each element of the vector.
fnameName of the file to write the vector to.
Returns:
On success, NULL is returned; otherwise an Error is returned.
  • ERROR_IO There was a problem writing to the file.

Definition at line 1446 of file vector_io.c.

Error* write_formatted_vector_i32 ( const Vector_i32 v,
const char *  fmt,
const char *  fname 
)

Writes a formatted 32-bit signed integer vector.

Format of the vector written is one line containing all the elements. For example,

 1 2 3 4 5 6 7 8 9
Parameters:
vVector to write.
fmtPrintf style format for each element of the vector.
fnameName of the file to write the vector to.
Returns:
On success, NULL is returned; otherwise an Error is returned.
  • ERROR_IO There was a problem writing to the file.

Definition at line 1491 of file vector_io.c.

Error* write_formatted_vector_i64 ( const Vector_i64 v,
const char *  fmt,
const char *  fname 
)

Writes a formatted 64-bit signed integer vector.

Format of the vector written is one line containing all the elements. For example,

 1 2 3 4 5 6 7 8 9
Parameters:
vVector to write.
fmtPrintf style format for each element of the vector.
fnameName of the file to write the vector to.
Returns:
On success, NULL is returned; otherwise an Error is returned.
  • ERROR_IO There was a problem writing to the file.

Definition at line 1536 of file vector_io.c.

Error* write_formatted_vector_f ( const Vector_f v,
const char *  fmt,
const char *  fname 
)

Writes a formatted single precision floating point vector.

Format of the vector written is one line containing all the elements. For example,

 1 2 3 4 5 6 7 8 9
Parameters:
vVector to write.
fmtPrintf style format for each element of the vector.
fnameName of the file to write the vector to.
Returns:
On success, NULL is returned; otherwise an Error is returned.
  • ERROR_IO There was a problem writing to the file.

Definition at line 1581 of file vector_io.c.

Error* write_formatted_vector_d ( const Vector_d v,
const char *  fmt,
const char *  fname 
)

Writes a formatted double precision floating point vector.

Format of the vector written is one line containing all the elements. For example,

 1 2 3 4 5 6 7 8 9
Parameters:
vVector to write.
fmtPrintf style format for each element of the vector.
fnameName of the file to write the vector to.
Returns:
On success, NULL is returned; otherwise an Error is returned.
  • ERROR_IO There was a problem writing to the file.

Definition at line 1626 of file vector_io.c.

Error* write_formatted_vector_cf ( const Vector_cf v,
const char *  fmt,
const char *  fname 
)

Writes a formatted single precision complex floating point vector.

Format of the vector written is one line containing all the elements. For example,

 1 2 3 4 5 6
Parameters:
vVector to write.
fmtPrintf style format for each element of the vector.
fnameName of the file to write the vector to.
Returns:
On success, NULL is returned; otherwise an Error is returned.
  • ERROR_IO There was a problem writing to the file.

Definition at line 1671 of file vector_io.c.

Error* write_formatted_vector_cd ( const Vector_cd v,
const char *  fmt,
const char *  fname 
)

Writes a formatted double precision complex floating point vector.

Format of the vector written is one line containing all the elements. For example,

 1 2 3 4 5 6
Parameters:
vVector to write.
fmtPrintf style format for each element of the vector.
fnameName of the file to write the vector to.
Returns:
On success, NULL is returned; otherwise an Error is returned.
  • ERROR_IO There was a problem writing to the file.

Definition at line 1716 of file vector_io.c.

Error* write_vector_fp_u32 ( const Vector_u32 v,
FILE *  fp 
)

Writes a 32-bit unsigned integer vector.

Format of the vector written is one line containing all the elements. For example,

 1 2 3 4 5 6 7 8 9
Parameters:
vVector to write.
fpFile to write the vector to.
Returns:
On success, NULL is returned; otherwise an Error is returned.
  • ERROR_IO There was a problem writing to the file.

Definition at line 1771 of file vector_io.c.

Error* write_vector_fp_i32 ( const Vector_i32 v,
FILE *  fp 
)

Writes a 32-bit signed integer vector.

Format of the vector written is one line containing all the elements. For example,

 1 2 3 4 5 6 7 8 9
Parameters:
vVector to write.
fpFile to write the vector to.
Returns:
On success, NULL is returned; otherwise an Error is returned.
  • ERROR_IO There was a problem writing to the file.

Definition at line 1791 of file vector_io.c.

Error* write_vector_fp_i64 ( const Vector_i64 v,
FILE *  fp 
)

Writes a 64-bit signed integer vector.

Format of the vector written is one line containing all the elements. For example,

 1 2 3 4 5 6 7 8 9
Parameters:
vVector to write.
fpFile to write the vector to.
Returns:
On success, NULL is returned; otherwise an Error is returned.
  • ERROR_IO There was a problem writing to the file.

Definition at line 1811 of file vector_io.c.

Error* write_vector_fp_f ( const Vector_f v,
FILE *  fp 
)

Writes a single precision floating point vector.

Format of the vector written is one line containing all the elements. For example,

 1 2 3 4 5 6 7 8 9
Parameters:
vVector to write.
fpFile to write the vector to.
Returns:
On success, NULL is returned; otherwise an Error is returned.
  • ERROR_IO There was a problem writing to the file.

Definition at line 1835 of file vector_io.c.

Error* write_vector_fp_d ( const Vector_d v,
FILE *  fp 
)

Writes a double precision floating point vector.

Format of the vector written is one line containing all the elements. For example,

 1 2 3 4 5 6 7 8 9
Parameters:
vVector to write.
fpFile to write the vector to.
Returns:
On success, NULL is returned; otherwise an Error is returned.
  • ERROR_IO There was a problem writing to the file.

Definition at line 1855 of file vector_io.c.

Error* write_vector_fp_cf ( const Vector_cf v,
FILE *  fp 
)

Writes a single precision complex floating point vector.

Format of the vector written is one line containing all the elements. For example,

 1 2 3 4 5 6
Parameters:
vVector to write.
fpFile to write the vector to.
Returns:
On success, NULL is returned; otherwise an Error is returned.
  • ERROR_IO There was a problem writing to the file.

Definition at line 1875 of file vector_io.c.

Error* write_vector_fp_cd ( const Vector_cd v,
FILE *  fp 
)

Writes a double precision complex floating point vector.

Format of the vector written is one line containing all the elements. For example,

 1 2 3 4 5 6
Parameters:
vVector to write.
fpFile to write the vector to.
Returns:
On success, NULL is returned; otherwise an Error is returned.
  • ERROR_IO There was a problem writing to the file.

Definition at line 1895 of file vector_io.c.

Error* write_formatted_vector_fp_u32 ( const Vector_u32 v,
const char *  fmt,
FILE *  fp 
)

Writes a formatted 32-bit unsigned integer vector.

Format of the vector written is one line containing all the elements. For example,

 1 2 3 4 5 6 7 8 9
Parameters:
vVector to write.
fmtPrintf style format for each element of the vector.
fpFile to write the vector to.
Returns:
On success, NULL is returned; otherwise an Error is returned.
  • ERROR_IO There was a problem writing to the file.

Definition at line 1929 of file vector_io.c.

Error* write_formatted_vector_fp_i32 ( const Vector_i32 v,
const char *  fmt,
FILE *  fp 
)

Writes a formatted 32-bit signed integer vector.

Format of the vector written is one line containing all the elements. For example,

 1 2 3 4 5 6 7 8 9
Parameters:
vVector to write.
fmtPrintf style format for each element of the vector.
fpFile to write the vector to.
Returns:
On success, NULL is returned; otherwise an Error is returned.
  • ERROR_IO There was a problem writing to the file.

Definition at line 1965 of file vector_io.c.

Error* write_formatted_vector_fp_i64 ( const Vector_i64 v,
const char *  fmt,
FILE *  fp 
)

Writes a formatted 64-bit signed integer vector.

Format of the vector written is one line containing all the elements. For example,

 1 2 3 4 5 6 7 8 9
Parameters:
vVector to write.
fmtPrintf style format for each element of the vector.
fpFile to write the vector to.
Returns:
On success, NULL is returned; otherwise an Error is returned.
  • ERROR_IO There was a problem writing to the file.

Definition at line 2001 of file vector_io.c.

Error* write_formatted_vector_fp_f ( const Vector_f v,
const char *  fmt,
FILE *  fp 
)

Writes a formatted single precision floating point vector.

Format of the vector written is one line containing all the elements. For example,

 1 2 3 4 5 6 7 8 9
Parameters:
vVector to write.
fmtPrintf style format for each element of the vector.
fpFile to write the vector to.
Returns:
On success, NULL is returned; otherwise an Error is returned.
  • ERROR_IO There was a problem writing to the file.

Definition at line 2037 of file vector_io.c.

Error* write_formatted_vector_fp_d ( const Vector_d v,
const char *  fmt,
FILE *  fp 
)

Writes a formatted double precision floating point vector.

Format of the vector written is one line containing all the elements. For example,

 1 2 3 4 5 6 7 8 9
Parameters:
vVector to write.
fmtPrintf style format for each element of the vector.
fpFile to write the vector to.
Returns:
On success, NULL is returned; otherwise an Error is returned.
  • ERROR_IO There was a problem writing to the file.

Definition at line 2073 of file vector_io.c.

Error* write_formatted_vector_fp_cf ( const Vector_cf v,
const char *  fmt,
FILE *  fp 
)

Writes a formatted single precision complex floating point vector.

Format of the vector written is one line containing all the elements. For example,

 1 2 3 4 5 6
Parameters:
vVector to write.
fmtPrintf style format for each element of the vector.
fpFile to write the vector to.
Returns:
On success, NULL is returned; otherwise an Error is returned.
  • ERROR_IO There was a problem writing to the file.

Definition at line 2109 of file vector_io.c.

Error* write_formatted_vector_fp_cd ( const Vector_cd v,
const char *  fmt,
FILE *  fp 
)

Writes a formatted double precision complex floating point vector.

Format of the vector written is one line containing all the elements. For example,

 1 2 3 4 5 6
Parameters:
vVector to write.
fmtPrintf style format for each element of the vector.
fpFile to write the vector to.
Returns:
On success, NULL is returned; otherwise an Error is returned.
  • ERROR_IO There was a problem writing to the file.

Definition at line 2145 of file vector_io.c.

Error* read_vector_with_header_u32 ( Vector_u32 **  v_out,
const char *  fname 
)

Reads a 32-bit unsigned integer vector.

Format of the vector in the file is expected to be a line containing the number of elements followed by a line containing all the elements. Blank lines and lines beginning with '#' are skipped. For example,

 # Comment
 num_elts=9
 1 2 3 4 5 6 7 8 9
Parameters:
v_outResult parameter. If *v_out is NULL, a vector is allocated; otherwise its space is re-used.
fnameName of the file to read the vector from.
Returns:
On success, NULL is returned; otherwise an Error is returned and *v_out is freed and set to NULL.
  • ERROR_IO Either there was a problem reading the file, or the vector in the file is not formatted properly.

Definition at line 2197 of file vector_io.c.

Error* read_vector_with_header_i32 ( Vector_i32 **  v_out,
const char *  fname 
)

Reads a 32-bit signed integer vector.

Format of the vector in the file is expected to be a line containing the number of elements followed by a line containing all the elements. Blank lines and lines beginning with '#' are skipped. For example,

 # Comment
 num_elts=9
 1 2 3 4 5 6 7 8 9
Parameters:
v_outResult parameter. If *v_out is NULL, a vector is allocated; otherwise its space is re-used.
fnameName of the file to read the vector from.
Returns:
On success, NULL is returned; otherwise an Error is returned and *v_out is freed and set to NULL.
  • ERROR_IO Either there was a problem reading the file, or the vector in the file is not formatted properly.

Definition at line 2244 of file vector_io.c.

Error* read_vector_with_header_i64 ( Vector_i64 **  v_out,
const char *  fname 
)

Reads a 64-bit signed integer vector.

Format of the vector in the file is expected to be a line containing the number of elements followed by a line containing all the elements. Blank lines and lines beginning with '#' are skipped. For example,

 # Comment
 num_elts=9
 1 2 3 4 5 6 7 8 9
Parameters:
v_outResult parameter. If *v_out is NULL, a vector is allocated; otherwise its space is re-used.
fnameName of the file to read the vector from.
Returns:
On success, NULL is returned; otherwise an Error is returned and *v_out is freed and set to NULL.
  • ERROR_IO Either there was a problem reading the file, or the vector in the file is not formatted properly.

Definition at line 2291 of file vector_io.c.

Error* read_vector_with_header_f ( Vector_f **  v_out,
const char *  fname 
)

Reads a single precision floating point vector.

Format of the vector in the file is expected to be a line containing the number of elements followed by a line containing all the elements. Blank lines and lines beginning with '#' are skipped. For example,

 # Comment
 num_elts=9
 1 2 3 4 5 6 7 8 9
Parameters:
v_outResult parameter. If *v_out is NULL, a vector is allocated; otherwise its space is re-used.
fnameName of the file to read the vector from.
Returns:
On success, NULL is returned; otherwise an Error is returned and *v_out is freed and set to NULL.
  • ERROR_IO Either there was a problem reading the file, or the vector in the file is not formatted properly.

Definition at line 2338 of file vector_io.c.

Error* read_vector_with_header_d ( Vector_d **  v_out,
const char *  fname 
)

Reads a double precision floating point vector.

Format of the vector in the file is expected to be a line containing the number of elements followed by a line containing all the elements. Blank lines and lines beginning with '#' are skipped. For example,

 # Comment
 num_elts=9
 1 2 3 4 5 6 7 8 9
Parameters:
v_outResult parameter. If *v_out is NULL, a vector is allocated; otherwise its space is re-used.
fnameName of the file to read the vector from.
Returns:
On success, NULL is returned; otherwise an Error is returned and *v_out is freed and set to NULL.
  • ERROR_IO Either there was a problem reading the file, or the vector in the file is not formatted properly.

Definition at line 2385 of file vector_io.c.

Error* read_vector_with_header_cf ( Vector_cf **  v_out,
const char *  fname 
)

Reads a single precision complex floating point vector.

Format of the vector in the file is expected to be a line containing the number of elements followed by a line containing all the elements. Blank lines and lines beginning with '#' are skipped. For example,

 # Comment
 num_elts=3
 1 2 3 4 5 6
Parameters:
v_outResult parameter. If *v_out is NULL, a vector is allocated; otherwise its space is re-used.
fnameName of the file to read the vector from.
Returns:
On success, NULL is returned; otherwise an Error is returned and *v_out is freed and set to NULL.
  • ERROR_IO Either there was a problem reading the file, or the vector in the file is not formatted properly.

Definition at line 2432 of file vector_io.c.

Error* read_vector_with_header_cd ( Vector_cd **  v_out,
const char *  fname 
)

Reads a double precision complex floating point vector.

Format of the vector in the file is expected to be a line containing the number of elements followed by a line containing all the elements. Blank lines and lines beginning with '#' are skipped. For example,

 # Comment
 num_elts=3
 1 2 3 4 5 6
Parameters:
v_outResult parameter. If *v_out is NULL, a vector is allocated; otherwise its space is re-used.
fnameName of the file to read the vector from.
Returns:
On success, NULL is returned; otherwise an Error is returned and *v_out is freed and set to NULL.
  • ERROR_IO Either there was a problem reading the file, or the vector in the file is not formatted properly.

Definition at line 2479 of file vector_io.c.

Error* read_vector_with_header_fp_u32 ( Vector_u32 **  v_out,
FILE *  fp 
)

Reads a 32-bit unsigned integer vector.

Format of the vector in the file is expected to be a line containing the number of elements followed by a line containing all the elements. Blank lines and lines beginning with '#' are skipped. For example,

 # Comment
 num_elts=9
 1 2 3 4 5 6 7 8 9
Parameters:
v_outResult parameter. If *v_out is NULL, a vector is allocated; otherwise its space is re-used.
fpFile to read the vector from.
Returns:
On success, NULL is returned; otherwise an Error is returned and *v_out is freed and set to NULL.
  • ERROR_IO Either there was a problem reading the file, or the vector in the file is not formatted properly.

Definition at line 2538 of file vector_io.c.

Error* read_vector_with_header_fp_i32 ( Vector_i32 **  v_out,
FILE *  fp 
)

Reads a 32-bit signed integer vector.

Format of the vector in the file is expected to be a line containing the number of elements followed by a line containing all the elements. Blank lines and lines beginning with '#' are skipped. For example,

 # Comment
 num_elts=9
 1 2 3 4 5 6 7 8 9
Parameters:
v_outResult parameter. If *v_out is NULL, a vector is allocated; otherwise its space is re-used.
fpFile to read the vector from.
Returns:
On success, NULL is returned; otherwise an Error is returned and *v_out is freed and set to NULL.
  • ERROR_IO Either there was a problem reading the file, or the vector in the file is not formatted properly.

Definition at line 2591 of file vector_io.c.

Error* read_vector_with_header_fp_i64 ( Vector_i64 **  v_out,
FILE *  fp 
)

Reads a 64-bit signed integer vector.

Format of the vector in the file is expected to be a line containing the number of elements followed by a line containing all the elements. Blank lines and lines beginning with '#' are skipped. For example,

 # Comment
 num_elts=9
 1 2 3 4 5 6 7 8 9
Parameters:
v_outResult parameter. If *v_out is NULL, a vector is allocated; otherwise its space is re-used.
fpFile to read the vector from.
Returns:
On success, NULL is returned; otherwise an Error is returned and *v_out is freed and set to NULL.
  • ERROR_IO Either there was a problem reading the file, or the vector in the file is not formatted properly.

Definition at line 2644 of file vector_io.c.

Error* read_vector_with_header_fp_f ( Vector_f **  v_out,
FILE *  fp 
)

Reads a single precision floating point vector.

Format of the vector in the file is expected to be a line containing the number of elements followed by a line containing all the elements. Blank lines and lines beginning with '#' are skipped. For example,

 # Comment
 num_elts=9
 1 2 3 4 5 6 7 8 9
Parameters:
v_outResult parameter. If *v_out is NULL, a vector is allocated; otherwise its space is re-used.
fpFile to read the vector from.
Returns:
On success, NULL is returned; otherwise an Error is returned and *v_out is freed and set to NULL.
  • ERROR_IO Either there was a problem reading the file, or the vector in the file is not formatted properly.

Definition at line 2697 of file vector_io.c.

Error* read_vector_with_header_fp_d ( Vector_d **  v_out,
FILE *  fp 
)

Reads a double precision floating point vector.

Format of the vector in the file is expected to be a line containing the number of elements followed by a line containing all the elements. Blank lines and lines beginning with '#' are skipped. For example,

 # Comment
 num_elts=9
 1 2 3 4 5 6 7 8 9
Parameters:
v_outResult parameter. If *v_out is NULL, a vector is allocated; otherwise its space is re-used.
fpFile to read the vector from.
Returns:
On success, NULL is returned; otherwise an Error is returned and *v_out is freed and set to NULL.
  • ERROR_IO Either there was a problem reading the file, or the vector in the file is not formatted properly.

Definition at line 2750 of file vector_io.c.

Error* read_vector_with_header_fp_cf ( Vector_cf **  v_out,
FILE *  fp 
)

Reads a single precision complex floating point vector.

Format of the vector in the file is expected to be a line containing the number of elements followed by a line containing all the elements. Blank lines and lines beginning with '#' are skipped. For example,

 # Comment
 num_elts=3
 1 2 3 4 5 6
Parameters:
v_outResult parameter. If *v_out is NULL, a vector is allocated; otherwise its space is re-used.
fpFile to read the vector from.
Returns:
On success, NULL is returned; otherwise an Error is returned and *v_out is freed and set to NULL.
  • ERROR_IO Either there was a problem reading the file, or the vector in the file is not formatted properly.

Definition at line 2803 of file vector_io.c.

Error* read_vector_with_header_fp_cd ( Vector_cd **  v_out,
FILE *  fp 
)

Reads a double precision complex floating point vector.

Format of the vector in the file is expected to be a line containing the number of elements followed by a line containing all the elements. Blank lines and lines beginning with '#' are skipped. For example,

 # Comment
 num_elts=3
 1 2 3 4 5 6
Parameters:
v_outResult parameter. If *v_out is NULL, a vector is allocated; otherwise its space is re-used.
fpFile to read the vector from.
Returns:
On success, NULL is returned; otherwise an Error is returned and *v_out is freed and set to NULL.
  • ERROR_IO Either there was a problem reading the file, or the vector in the file is not formatted properly.

Definition at line 2856 of file vector_io.c.

Error* write_vector_with_header_u32 ( const Vector_u32 v,
const char *  fname 
)

Writes a 32-bit unsigned integer vector.

Format of the vector written is a line containing the number of elements followed by a line containing all the elements. For example,

 # Comment.
 num_elts=9
 1 2 3 4 5 6 7 8 9
Parameters:
vVector to write.
fnameName of the file to read the vector from.
Returns:
On success, NULL is returned; otherwise an Error is returned.
  • ERROR_IO There was a problem writing to the file.

Definition at line 2917 of file vector_io.c.

Error* write_vector_with_header_i32 ( const Vector_i32 v,
const char *  fname 
)

Writes a 32-bit signed integer vector.

Format of the vector written is a line containing the number of elements followed by a line containing all the elements. For example,

 # Comment.
 num_elts=9
 1 2 3 4 5 6 7 8 9
Parameters:
vVector to write.
fnameName of the file to read the vector from.
Returns:
On success, NULL is returned; otherwise an Error is returned.
  • ERROR_IO There was a problem writing to the file.

Definition at line 2953 of file vector_io.c.

Error* write_vector_with_header_i64 ( const Vector_i64 v,
const char *  fname 
)

Writes a 64-bit signed integer vector.

Format of the vector written is a line containing the number of elements followed by a line containing all the elements. For example,

 # Comment.
 num_elts=9
 1 2 3 4 5 6 7 8 9
Parameters:
vVector to write.
fnameName of the file to read the vector from.
Returns:
On success, NULL is returned; otherwise an Error is returned.
  • ERROR_IO There was a problem writing to the file.

Definition at line 2989 of file vector_io.c.

Error* write_vector_with_header_f ( const Vector_f v,
const char *  fname 
)

Writes a single precision floating point vector.

Format of the vector written is a line containing the number of elements followed by a line containing all the elements. For example,

 # Comment.
 num_elts=9
 1 2 3 4 5 6 7 8 9
Parameters:
vVector to write.
fnameName of the file to read the vector from.
Returns:
On success, NULL is returned; otherwise an Error is returned.
  • ERROR_IO There was a problem writing to the file.

Definition at line 3025 of file vector_io.c.

Error* write_vector_with_header_d ( const Vector_d v,
const char *  fname 
)

Writes a double precision floating point vector.

Format of the vector written is a line containing the number of elements followed by a line containing all the elements. For example,

 # Comment.
 num_elts=9
 1 2 3 4 5 6 7 8 9
Parameters:
vVector to write.
fnameName of the file to read the vector from.
Returns:
On success, NULL is returned; otherwise an Error is returned.
  • ERROR_IO There was a problem writing to the file.

Definition at line 3061 of file vector_io.c.

Error* write_vector_with_header_cf ( const Vector_cf v,
const char *  fname 
)

Writes a single precision complex floating point vector.

Format of the vector written is a line containing the number of elements followed by a line containing all the elements. For example,

 # Comment.
 num_elts=3
 1 2 3 4 5 6
Parameters:
vVector to write.
fnameName of the file to read the vector from.
Returns:
On success, NULL is returned; otherwise an Error is returned.
  • ERROR_IO There was a problem writing to the file.

Definition at line 3097 of file vector_io.c.

Error* write_vector_with_header_cd ( const Vector_cd v,
const char *  fname 
)

Writes a double precision complex floating point vector.

Format of the vector written is a line containing the number of elements followed by a line containing all the elements. For example,

 # Comment.
 num_elts=3
 1 2 3 4 5 6
Parameters:
vVector to write.
fnameName of the file to read the vector from.
Returns:
On success, NULL is returned; otherwise an Error is returned.
  • ERROR_IO There was a problem writing to the file.

Definition at line 3133 of file vector_io.c.

Error* write_formatted_vector_with_header_u32 ( const Vector_u32 v,
const char *  fmt,
const char *  fname 
)

Writes a formatted 32-bit unsigned integer vector.

Format of the vector written is a line containing the number of elements followed by a line containing all the elements. For example,

 # Comment.
 num_elts=9
 1 2 3 4 5 6 7 8 9
Parameters:
vVector to write.
fmtPrintf style format for each element of the vector.
fnameName of the file to read the vector from.
Returns:
On success, NULL is returned; otherwise an Error is returned.
  • ERROR_IO There was a problem writing to the file.

Definition at line 3183 of file vector_io.c.

Error* write_formatted_vector_with_header_i32 ( const Vector_i32 v,
const char *  fmt,
const char *  fname 
)

Writes a formatted 32-bit signed integer vector.

Format of the vector written is a line containing the number of elements followed by a line containing all the elements. For example,

 # Comment.
 num_elts=9
 1 2 3 4 5 6 7 8 9
Parameters:
vVector to write.
fmtPrintf style format for each element of the vector.
fnameName of the file to read the vector from.
Returns:
On success, NULL is returned; otherwise an Error is returned.
  • ERROR_IO There was a problem writing to the file.

Definition at line 3225 of file vector_io.c.

Error* write_formatted_vector_with_header_i64 ( const Vector_i64 v,
const char *  fmt,
const char *  fname 
)

Writes a formatted 64-bit signed integer vector.

Format of the vector written is a line containing the number of elements followed by a line containing all the elements. For example,

 # Comment.
 num_elts=9
 1 2 3 4 5 6 7 8 9
Parameters:
vVector to write.
fmtPrintf style format for each element of the vector.
fnameName of the file to read the vector from.
Returns:
On success, NULL is returned; otherwise an Error is returned.
  • ERROR_IO There was a problem writing to the file.

Definition at line 3267 of file vector_io.c.

Error* write_formatted_vector_with_header_f ( const Vector_f v,
const char *  fmt,
const char *  fname 
)

Writes a formatted single precision floating point vector.

Format of the vector written is a line containing the number of elements followed by a line containing all the elements. For example,

 # Comment.
 num_elts=9
 1 2 3 4 5 6 7 8 9
Parameters:
vVector to write.
fmtPrintf style format for each element of the vector.
fnameName of the file to read the vector from.
Returns:
On success, NULL is returned; otherwise an Error is returned.
  • ERROR_IO There was a problem writing to the file.

Definition at line 3309 of file vector_io.c.

Error* write_formatted_vector_with_header_d ( const Vector_d v,
const char *  fmt,
const char *  fname 
)

Writes a formatted double precision floating point vector.

Format of the vector written is a line containing the number of elements followed by a line containing all the elements. For example,

 # Comment.
 num_elts=9
 1 2 3 4 5 6 7 8 9
Parameters:
vVector to write.
fmtPrintf style format for each element of the vector.
fnameName of the file to read the vector from.
Returns:
On success, NULL is returned; otherwise an Error is returned.
  • ERROR_IO There was a problem writing to the file.

Definition at line 3351 of file vector_io.c.

Error* write_formatted_vector_with_header_cf ( const Vector_cf v,
const char *  fmt,
const char *  fname 
)

Writes a formatted single precision complex floating point vector.

Format of the vector written is a line containing the number of elements followed by a line containing all the elements. For example,

 # Comment.
 num_elts=3
 1 2 3 4 5 6
Parameters:
vVector to write.
fmtPrintf style format for each element of the vector.
fnameName of the file to read the vector from.
Returns:
On success, NULL is returned; otherwise an Error is returned.
  • ERROR_IO There was a problem writing to the file.

Definition at line 3393 of file vector_io.c.

Error* write_formatted_vector_with_header_cd ( const Vector_cd v,
const char *  fmt,
const char *  fname 
)

Writes a formatted double precision complex floating point vector.

Format of the vector written is a line containing the number of elements followed by a line containing all the elements. For example,

 # Comment.
 num_elts=3
 1 2 3 4 5 6
Parameters:
vVector to write.
fmtPrintf style format for each element of the vector.
fnameName of the file to read the vector from.
Returns:
On success, NULL is returned; otherwise an Error is returned.
  • ERROR_IO There was a problem writing to the file.

Definition at line 3435 of file vector_io.c.

Error* write_vector_with_header_fp_u32 ( const Vector_u32 v,
FILE *  fp 
)

Writes a 32-bit unsigned integer vector.

Format of the vector written is a line containing the number of elements followed by a line containing all the elements. For example,

 # Comment.
 num_elts=9
 1 2 3 4 5 6 7 8 9
Parameters:
vVector to write.
fpName of the file to read the vector from.
Returns:
On success, NULL is returned; otherwise an Error is returned.
  • ERROR_IO There was a problem writing to the file.

Definition at line 3487 of file vector_io.c.

Error* write_vector_with_header_fp_i32 ( const Vector_i32 v,
FILE *  fp 
)

Writes a 32-bit signed integer vector.

Format of the vector written is a line containing the number of elements followed by a line containing all the elements. For example,

 # Comment.
 num_elts=9
 1 2 3 4 5 6 7 8 9
Parameters:
vVector to write.
fpName of the file to read the vector from.
Returns:
On success, NULL is returned; otherwise an Error is returned.
  • ERROR_IO There was a problem writing to the file.

Definition at line 3509 of file vector_io.c.

Error* write_vector_with_header_fp_i64 ( const Vector_i64 v,
FILE *  fp 
)

Writes a 64-bit signed integer vector.

Format of the vector written is a line containing the number of elements followed by a line containing all the elements. For example,

 # Comment.
 num_elts=9
 1 2 3 4 5 6 7 8 9
Parameters:
vVector to write.
fpName of the file to read the vector from.
Returns:
On success, NULL is returned; otherwise an Error is returned.
  • ERROR_IO There was a problem writing to the file.

Definition at line 3531 of file vector_io.c.

Error* write_vector_with_header_fp_f ( const Vector_f v,
FILE *  fp 
)

Writes a single precision floating point vector.

Format of the vector written is a line containing the number of elements followed by a line containing all the elements. For example,

 # Comment.
 num_elts=9
 1 2 3 4 5 6 7 8 9
Parameters:
vVector to write.
fpName of the file to read the vector from.
Returns:
On success, NULL is returned; otherwise an Error is returned.
  • ERROR_IO There was a problem writing to the file.

Definition at line 3557 of file vector_io.c.

Error* write_vector_with_header_fp_d ( const Vector_d v,
FILE *  fp 
)

Writes a double precision floating point vector.

Format of the vector written is a line containing the number of elements followed by a line containing all the elements. For example,

 # Comment.
 num_elts=9
 1 2 3 4 5 6 7 8 9
Parameters:
vVector to write.
fpName of the file to read the vector from.
Returns:
On success, NULL is returned; otherwise an Error is returned.
  • ERROR_IO There was a problem writing to the file.

Definition at line 3579 of file vector_io.c.

Error* write_vector_with_header_fp_cf ( const Vector_cf v,
FILE *  fp 
)

Writes a single precision complex floating point vector.

Format of the vector written is a line containing the number of elements followed by a line containing all the elements. For example,

 # Comment.
 num_elts=3
 1 2 3 4 5 6
Parameters:
vVector to write.
fpName of the file to read the vector from.
Returns:
On success, NULL is returned; otherwise an Error is returned.
  • ERROR_IO There was a problem writing to the file.

Definition at line 3601 of file vector_io.c.

Error* write_vector_with_header_fp_cd ( const Vector_cd v,
FILE *  fp 
)

Writes a double precision complex floating point vector.

Format of the vector written is a line containing the number of elements followed by a line containing all the elements. For example,

 # Comment.
 num_elts=3
 1 2 3 4 5 6
Parameters:
vVector to write.
fpName of the file to read the vector from.
Returns:
On success, NULL is returned; otherwise an Error is returned.
  • ERROR_IO There was a problem writing to the file.

Definition at line 3623 of file vector_io.c.

Error* write_formatted_vector_with_header_fp_u32 ( const Vector_u32 v,
const char *  fmt,
FILE *  fp 
)

Writes a formatted 32-bit unsigned integer vector.

Format of the vector written is a line containing the number of elements followed by a line containing all the elements. For example,

 # Comment.
 num_elts=9
 1 2 3 4 5 6 7 8 9
Parameters:
vVector to write.
fmtPrintf style format for each element of the vector.
fpName of the file to read the vector from.
Returns:
On success, NULL is returned; otherwise an Error is returned.
  • ERROR_IO There was a problem writing to the file.

Definition at line 3659 of file vector_io.c.

Error* write_formatted_vector_with_header_fp_i32 ( const Vector_i32 v,
const char *  fmt,
FILE *  fp 
)

Writes a formatted 32-bit signed integer vector.

Format of the vector written is a line containing the number of elements followed by a line containing all the elements. For example,

 # Comment.
 num_elts=9
 1 2 3 4 5 6 7 8 9
Parameters:
vVector to write.
fmtPrintf style format for each element of the vector.
fpName of the file to read the vector from.
Returns:
On success, NULL is returned; otherwise an Error is returned.
  • ERROR_IO There was a problem writing to the file.

Definition at line 3689 of file vector_io.c.

Error* write_formatted_vector_with_header_fp_i64 ( const Vector_i64 v,
const char *  fmt,
FILE *  fp 
)

Writes a formatted 64-bit signed integer vector.

Format of the vector written is a line containing the number of elements followed by a line containing all the elements. For example,

 # Comment.
 num_elts=9
 1 2 3 4 5 6 7 8 9
Parameters:
vVector to write.
fmtPrintf style format for each element of the vector.
fpName of the file to read the vector from.
Returns:
On success, NULL is returned; otherwise an Error is returned.
  • ERROR_IO There was a problem writing to the file.

Definition at line 3719 of file vector_io.c.

Error* write_formatted_vector_with_header_fp_f ( const Vector_f v,
const char *  fmt,
FILE *  fp 
)

Writes a formatted single precision floating point vector.

Format of the vector written is a line containing the number of elements followed by a line containing all the elements. For example,

 # Comment.
 num_elts=9
 1 2 3 4 5 6 7 8 9
Parameters:
vVector to write.
fmtPrintf style format for each element of the vector.
fpName of the file to read the vector from.
Returns:
On success, NULL is returned; otherwise an Error is returned.
  • ERROR_IO There was a problem writing to the file.

Definition at line 3749 of file vector_io.c.

Error* write_formatted_vector_with_header_fp_d ( const Vector_d v,
const char *  fmt,
FILE *  fp 
)

Writes a formatted double precision floating point vector.

Format of the vector written is a line containing the number of elements followed by a line containing all the elements. For example,

 # Comment.
 num_elts=9
 1 2 3 4 5 6 7 8 9
Parameters:
vVector to write.
fmtPrintf style format for each element of the vector.
fpName of the file to read the vector from.
Returns:
On success, NULL is returned; otherwise an Error is returned.
  • ERROR_IO There was a problem writing to the file.

Definition at line 3779 of file vector_io.c.

Error* write_formatted_vector_with_header_fp_cf ( const Vector_cf v,
const char *  fmt,
FILE *  fp 
)

Writes a formatted single precision complex floating point vector.

Format of the vector written is a line containing the number of elements followed by a line containing all the elements. For example,

 # Comment.
 num_elts=3
 1 2 3 4 5 6
Parameters:
vVector to write.
fmtPrintf style format for each element of the vector.
fpName of the file to read the vector from.
Returns:
On success, NULL is returned; otherwise an Error is returned.
  • ERROR_IO There was a problem writing to the file.

Definition at line 3809 of file vector_io.c.

Error* write_formatted_vector_with_header_fp_cd ( const Vector_cd v,
const char *  fmt,
FILE *  fp 
)

Writes a formatted double precision complex floating point vector.

Format of the vector written is a line containing the number of elements followed by a line containing all the elements. For example,

 # Comment.
 num_elts=3
 1 2 3 4 5 6
Parameters:
vVector to write.
fmtPrintf style format for each element of the vector.
fpName of the file to read the vector from.
Returns:
On success, NULL is returned; otherwise an Error is returned.
  • ERROR_IO There was a problem writing to the file.

Definition at line 3839 of file vector_io.c.