Numerical-Utility Reference

The processing details, together.

Review the numerical utilities, their inputs, and behavior. Preserve command syntax and examples when preparing an analysis workflow.

Documention on Num-Utils

Version 1.2


<a id="add"></a>

add.c:**********************************************************************
add.c: Add.c -
add.c:  This program adds the elements of two real or complex vector or
add.c:  matrix files together to produce a third file containg the sum.
add.c:
add.c: Options:
add.c:  (no options)
add.c:
add.c: Example Usage:
add.c:  add  fileA  fileB  NewSumFile
add.c:
add.c: File Types:
add.c:      In:   Real or Complex, dimensionality must match.
add.c:      Out:  (Same type and dimension as input.)
add.c:**********************************************************************

<a id="cdotpr"></a>

cdotpr.c:**********************************************************************
cdotpr.c: Cdotpr.c -
cdotpr.c:  This program computes the complex conjugate dot-product of two
cdotpr.c:  complex vector files.
cdotpr.c:
cdotpr.c: Options:
cdotpr.c:   (no options)
cdotpr.c:
cdotpr.c: Example Usage:
cdotpr.c:   cdotpr fileA  fileB
cdotpr.c:       Dot Product = 345.7
cdotpr.c:
cdotpr.c: File Types:
cdotpr.c:      In:   Complex, dimensions must match.
cdotpr.c:      Out:  (No out file. Result goes to screen (std.out).)
cdotpr.c:**********************************************************************

<a id="cmag"></a>

cmag.c:**********************************************************************
cmag.c: Cmag.c -
cmag.c:  This program converts a complex vector file into a real vector file
cmag.c:  by computing the complex-magnitude of each term.
cmag.c:
cmag.c: Options:
cmag.c: (no options)
cmag.c:
cmag.c: Example Usage:
cmag.c: cmag  infile  newfile
cmag.c:
cmag.c: File Types:
cmag.c:      In:   Complex
cmag.c:      Out:  Real
cmag.c:**********************************************************************

<a id="conjg"></a>

conjg.c:**********************************************************************
conjg.c: Conjg.c -
conjg.c:  This program conjugates a complex vector or matrix.
conjg.c:
conjg.c: Options:
conjg.c:    (no options)
conjg.c:
conjg.c: Example Usage:
conjg.c:    conjg  infile  newfile
conjg.c:
conjg.c: File Types:
conjg.c:      In:   Complex, Vector or Matrix
conjg.c:      Out:  (Same type and dimension as input file.)
conjg.c:**********************************************************************

<a id="convolve"></a>

convolve.c:**********************************************************************
convolve.c: Convolve.c -
convolve.c:  This program convolves to complex or real vectors.
convolve.c:  (Defaults to frequency domain convolution for efficiency.)
convolve.c:
convolve.c: Options:
convolve.c: -t  - Perform Time Domain Convolution. (slower)
convolve.c: -f  - Perform Frequency Domain Convolution. (default)
convolve.c:
convolve.c: Example Usage:
convolve.c: convolve infile1  infile2  outfile
convolve.c:
convolve.c: File Types:
convolve.c:      In:   Real or Complex Vectors (must match).
convolve.c:      Out:  (Same type as input files.)
convolve.c:**********************************************************************

<a id="correlate"></a>

correlate.c:**********************************************************************
correlate.c: Correlate.c -
correlate.c:  This program correlates to complex or real vectors.
correlate.c:  (Defaults to frequency domain convolution for efficiency.)
correlate.c:
correlate.c: Options:
correlate.c:    -t  - Perform Time Domain Correlation. (slower)
correlate.c:    -f  - Perform Frequency Domain Correlattion. (default)
correlate.c:
correlate.c: Example Usage:
correlate.c:    correlate infile1  infile2  outfile
correlate.c:
correlate.c: File Types:
correlate.c:      In:   Real or Complex Vectors (must match).
correlate.c:      Out:  (Same type as input files.)
correlate.c:**********************************************************************

<a id="db"></a>

db.c:**********************************************************************
db.c: DB.c -
db.c:  This program converts a real vector file from 'linear' to 'dB'.
db.c:  For example, consider the input file to be voltage magnitudes, then
db.c:  the dB are computed by taking the log of the voltage squared.
db.c:  (DeciBells are considered a 'power-ratio'.)  I.E. 20 Log10(x).
db.c:
db.c:  A check is made for negative or excessively small input values, and
db.c:  these are truncated to -150 dB.
db.c:
db.c: Options:
db.c:   (no options)
db.c:
db.c: Example Usage:
db.c:   db  infile  outfile
db.c:
db.c: Common Usage:
db.c:   fft  signals.dat  signals.fft
db.c:   cmag signals.fft  spectrum.dat
db.c:   db   spectrum.dat spectrum.db
db.c:   xgraph spectrum.db
db.c:**********************************************************************

<a id="dotpr"></a>

dotpr.c:**********************************************************************
dotpr.c: Dot.c -
dotpr.c:  This program computes the dot-product of two real or complex vector
dotpr.c:  or matrix files.
dotpr.c:
dotpr.c: Options:
dotpr.c:    (no options)
dotpr.c:
dotpr.c: Example Usage:
dotpr.c:    dot fileA  fileB
dotpr.c:        Dot Product = 345.7
dotpr.c:
dotpr.c: File Types:
dotpr.c:      In:   Real or Complex, dimensions must match.
dotpr.c:      Out:  (No out file. Result goes to screen (std.out).)
dotpr.c:**********************************************************************

<a id="extract_imaginary"></a>

extract_imaginary.c:**********************************************************************
extract_imaginary.c: Extract_imaginary.c -
extract_imaginary.c:  This program extracts the imaginary part of a complex vector file
extract_imaginary.c:  to a real vector file.
extract_imaginary.c:  Example:  Complex value (5.6, 7.8) becomes just 7.8
extract_imaginary.c:
extract_imaginary.c: Options:
extract_imaginary.c:    (no options)
extract_imaginary.c:
extract_imaginary.c: Example Usage:
extract_imaginary.c:    extract_imaginary  complexfile  realfile
extract_imaginary.c:
extract_imaginary.c: File Types:
extract_imaginary.c:    In:   Complex
extract_imaginary.c:    Out:  Real
extract_imaginary.c:**********************************************************************

<a id="extract_real"></a>

extract_real.c:**********************************************************************
extract_real.c: Extract_real.c -
extract_real.c:  This program extracts the real part of a complex vector file to a
extract_real.c:  real vector file.
extract_real.c:  Example:  Complex value (5.6, 7.8) becomes just 5.6
extract_real.c:
extract_real.c: Options:
extract_real.c: (no options)
extract_real.c:
extract_real.c: Example Usage:
extract_real.c: extract_real  complexfile  realfile
extract_real.c:
extract_real.c: File Types:
extract_real.c: In:   Complex
extract_real.c: Out:  Real
extract_real.c:**********************************************************************

<a id="fft"></a>

fft.c:**********************************************************************
fft.c: Fft.c -
fft.c:  This program reads in a complex list of data smaples, and computes
fft.c:  the corresponding complex DFT, and prints this out to a file.
fft.c:
fft.c: Options:
fft.c:  -f  - Forward FFT
fft.c:  -r  - Reverse or Inverse FFT
fft.c:  -i  - Reverse or Inverse FFT
fft.c:  -d 1    - Forward FFT
fft.c:  -d -1   - Reverse FFT
fft.c:
fft.c: Example Usage:
fft.c:  fft  infile.dat  outfile.fft
fft.c:
fft.c: File Types:
fft.c:      In:   Complex or Real
fft.c:      Out:  Complex
fft.c:**********************************************************************

<a id="fft2D"></a>

fft2D.c:**********************************************************************
fft2D.c: fft2D -
fft2D.c:  This program performs the 2D FFT on a complex matrix.
fft2D.c:
fft2D.c: Options:
fft2D.c:    -f  - Forward FFT
fft2D.c:    -r  - Reverse or Inverse FFT
fft2D.c:    -i  - Reverse or Inverse FFT
fft2D.c:    -d 1    - Forward FFT
fft2D.c:    -d -1   - Reverse FFT
fft2D.c:
fft2D.c: Example Usage:
fft2D.c:    fft2D  in_matrixfile.dat  out_transformed_matrixfile.dat
fft2D.c:
fft2D.c: File Types:
fft2D.c:      In:   Complex or Real Matrix
fft2D.c:      Out:  Complex Matrix
fft2D.c:**********************************************************************

<a id="matinvert"></a>

matinvert.c:**********************************************************************
matinvert.c: MatInvert.c -
matinvert.c:  This program inverts a square matrix file.
matinvert.c:
matinvert.c: Options:
matinvert.c:   (None.)
matinvert.c:
matinvert.c: Example Usage:
matinvert.c:    matinvert  in_matrixfile.dat  inverted_out.dat
matinvert.c:
matinvert.c: File Types:
matinvert.c:      In:   Complex or Real Matrix
matinvert.c:      Out:  Matrix of same data-type as input matrix
matinvert.c:

<a id="matmul"></a>

matmul.c:**********************************************************************
matmul.c: Matmul.c -
matmul.c:  This program multiplies a matrix by a another matrix or vector to
matmul.c:  produce a new matrix file.  The input files can be real or complex,
matmul.c:  but must match.
matmul.c:
matmul.c: Options:
matmul.c:   (no options)
matmul.c:
matmul.c: Example Usage:
matmul.c:   matmul  matrixfileA  fileB  NewMatrixFile
matmul.c:
matmul.c: File Types:
matmul.c:      In:   Real or Complex, dimensions must comply.
matmul.c:      Out:  (Same type and dimension as first input.)
matinvert.c:**********************************************************************

<a id="matXvec"></a>

matXvec.c:**********************************************************************
matXvec.c: MatXvec -
matXvec.c:  This program extracts a row or column from a matrix row into a
matXvec.c:  vector.
matXvec.c:
matXvec.c: Options:
matXvec.c:  -row x  - Row to extract.
matXvec.c:  -col x  - column to extract.
matXvec.c:  Note: Rows and columns assumed to range 1 to n.
matXvec.c:    One (1) is the first row or column.
matXvec.c:    The last row or column is n, where n is the number of rows
matXvec.c:    or columns, respectively.
matXvec.c:
matXvec.c: Example Usage:
matXvec.c:  matXvec  in_matrixfile.dat  -row 3 out_vector.dat
matXvec.c:
matXvec.c: File Types:
matXvec.c:      In:   Complex or Real Matrix
matXvec.c:      Out:  Vector of same data-type as input matrix
matXvec.c:**********************************************************************

<a id="multpbp"></a>

multpbp.c:**********************************************************************
multpbp.c: Multpbp.c -
multpbp.c:  This program multiplies a vector by another vector, point-by-point.
multpbp.c:  The input files can be real or complex, but must match.
multpbp.c:
multpbp.c: Options:
multpbp.c:  (no options)
multpbp.c:
multpbp.c: Example Usage:
multpbp.c:  multpbp  fileA  fileB  File.new
multpbp.c:
multpbp.c: File Types:
multpbp.c:      In:   Real or Complex, dimensions must match.
multpbp.c:      Out:  (Same type and dimension as input files.)
multpbp.c:**********************************************************************

<a id="normalize"></a>

normalize.c:**********************************************************************
normalize.c: Normalize.c -
normalize.c:  This program normalizes a real or complex vector. In other words,
normalize.c:  it first scans the vector to determine the sum of the magnitudes
normalize.c:  of the elements, and then scales the vector, such that the sum of
normalize.c:  the magnitudes equals 1.0.
normalize.c:
normalize.c: Options:
normalize.c:  -bymax   - Changes normalization to be based on the magnitude of
normalize.c:        the maximum element, instead of the sum of the
normalize.c:        magnitudes.
normalize.c:
normalize.c: Example Usage:
normalize.c:    normalize  oldfile  newfile
normalize.c:
normalize.c: File Types:
normalize.c:      In:   Real or Complex
normalize.c:      Out:  (Same type as input.)
normalize.c:**********************************************************************

<a id="outpr"></a>

outpr.c:**********************************************************************
outpr.c: Outpr.c -
outpr.c:  This program multiplies to vectors to produce a matrix by outer
outpr.c:  product multiply.  The input files can be real or complex, but
outpr.c:  types must match.
outpr.c:
outpr.c: Options:
outpr.c:    (no options)
outpr.c:
outpr.c: Example Usage:
outpr.c:    outpr  VecA  VecB  NewMatrixFile
outpr.c:
outpr.c: File Types:
outpr.c:      In:   Real or Complex, dimensions and types must match.
outpr.c:      Out:  (Same type and dimension as first input.)
outpr.c:**********************************************************************

<a id="phase"></a>

phase.c:**********************************************************************
phase.c: Phase.c -
phase.c:  This program converts a complex vector file into a real vector file
phase.c:  containing phase, in degrees, of each term.
phase.c:
phase.c: Options:
phase.c:  -radians  - Report phase in radians instead of degrees.
phase.c:
phase.c: Example Usage:
phase.c:    phase  complexfile  newfile
phase.c:
phase.c: File Types:
phase.c:      In:   Complex
phase.c:      Out:  Real
phase.c:**********************************************************************

<a id="rand_gen"></a>

rand_gen.c:**************************************************************
rand_gen.c: Rand_Gen - This utility produces a random vector file.
rand_gen.c:
rand_gen.c: Command line options:
rand_gen.c: {file_name} - Output file name.
rand_gen.c: -n  - Number of samples to produce.
rand_gen.c: -seed   - Random Seed to use.
rand_gen.c: -realvec - Produce an indexed real-vector file.
rand_gen.c:
rand_gen.c: Specify values on command line, or be prompted for them.
rand_gen.c:
rand_gen.c: By default, this utility produces a complex vector, one
rand_gen.c: real-imaginary pair per line.  By using the -realvec option,
rand_gen.c: rand_gen produces an indexed real-vector file, having the
rand_gen.c: integer count of the sample and a real sample on each line.
rand_gen.c: (The realvec version is directly plotted with xgraph.
rand_gen.c:  The default complex version requires the -a option in
rand_gen.c:  xgraph, for automatic x-axis increment, for plotting.)
rand_gen.c:
rand_gen.c: Example:
rand_gen.c: rand_gen -n 100 -seed 405690  noise.dat
rand_gen.c: xgraph -a  noise.dat
rand_gen.c: Or,
rand_gen.c: sin_gen -n 100 -seed 405690 -realvec  noise.dat
rand_gen.c: xgraph noise.dat
rand_gen.c:
rand_gen.c: File Types:
rand_gen.c:      In:   (none)
rand_gen.c:      Out:  Complex (default), or Real (option)
rand_gen.c:**************************************************************

<a id="real2cmplx"></a>

real2cmplx.c:**********************************************************************
real2cmplx.c: real2cmplx.c -
real2cmplx.c:  This program converts a real vector file to a complex vector file.
real2cmplx.c:  Example:  Real value 7.8 is converted to (7.8, 0.0) complex.
real2cmplx.c:
real2cmplx.c: Options:
real2cmplx.c:   (no options)
real2cmplx.c:
real2cmplx.c: Example Usage:
real2cmplx.c:   real2cmplx  infile  newfile
real2cmplx.c:
real2cmplx.c: File Types:
real2cmplx.c:      In:   Real
real2cmplx.c:      Out:  Complex
real2cmplx.c:**********************************************************************

<a id="scale"></a>

scale.c:**********************************************************************
scale.c: Scale.c -
scale.c:  This program scales a real or complex vector or matrix file by a
scale.c:  real or complex scalar, respectively.
scale.c:
scale.c: Options:
scale.c:    -s  Scale factor
scale.c:  If input file is real, than scale factor must be real.
scale.c:  If input file is complex, than scale factor must be complex.
scale.c:    -x  For Real-Vectors only, scale the x-values (index) instead
scale.c:         of the y-values, which otherwise is assumed the default.
scale.c:
scale.c: Example Usage:
scale.c:   Scale a real file by real value 4.0.  Send results to new file.
scale.c:    scale  -s 4.0  oldfile  newfile
scale.c:
scale.c:   Scale complex file by (3.8, 2.4).   Send results to new file.
scale.c:    scale  -s 3.8 2.4  oldfile  newfile
scale.c:
scale.c: File Types:
scale.c:      In:   Real or Complex, Vector or Matrix.
scale.c:      Out:  (Same type as input.)
scale.c:**********************************************************************

<a id="shift"></a>

shift.c:**********************************************************************
shift.c: Shift.c -
shift.c:  This program shifts a real or complex vector or matrix file by a
shift.c:  real or complex scalar, respectively.  In other words, it ADDs
shift.c:  an "offset" value to each term.
shift.c:
shift.c: Options:
shift.c:   -s  Shift factor
shift.c:        If input file is real, than shift factor must be real.
shift.c:        If input file is complex, than shift factor must be complex.
shift.c:   -x  For Real-Vectors only, shift the x-values (index) instead
shift.c:        of the y-values, which otherwise is assumed the default.
shift.c:
shift.c: Example Usage:
shift.c:   Shift a real file by real value 4.0.  Send results to new file.
shift.c:    shift  -s 4.0  oldfile  newfile
shift.c:
shift.c:   Shift complex file by (3.8, 2.4).   Send results to new file.
shift.c:    shift  -s 3.8 2.4  oldfile  newfile
shift.c:
shift.c: File Types:
shift.c:      In:   Real or Complex, Vector or Matrix
shift.c:      Out:  (Same type as input.)
shift.c:**********************************************************************

<a id="sine_gen"></a>

sine_gen.c:**************************************************************
sine_gen.c: Sine_Gen - This utility produces a sinusoidal vector file.
sine_gen.c:
sine_gen.c: Command line options:
sine_gen.c: {file_name} - Output file name.
sine_gen.c: -n  - Number of samples to produce.
sine_gen.c: -freq   - Frequency, or number of cycles in the
sine_gen.c:       produced vector.
sine_gen.c: -realvec - Produce an indexed real-vector file.
sine_gen.c:
sine_gen.c: Specify values on command line, or be prompted for them.
sine_gen.c:
sine_gen.c: By default, this utility produces a complex vector, one
sine_gen.c: real-imaginary pair per line.  By using the -realvec option,
sine_gen.c: sine_gen produces an indexed real-vector file, having the
sine_gen.c: integer count of the sample and a real sample on each line.
sine_gen.c: (The realvec version is directly plotted with xgraph.
sine_gen.c:  The default complex version requires the -a option in
sine_gen.c:  xgraph, for automatic x-axis increment, for plotting.)
sine_gen.c:
sine_gen.c: Example:
sine_gen.c: sine_gen -n 100 -freq 5  sinewave.dat
sine_gen.c: xgraph -a  sinewave.dat
sine_gen.c: Or,
sine_gen.c: sin_gen -n 100 -freq 5 -realvec  sinewave.dat
sine_gen.c: xgraph sinewave.dat
sine_gen.c:
sine_gen.c: File Types:
sine_gen.c:      In:   (none)
sine_gen.c:      Out:  Complex (default), or Real (option)
sine_gen.c:**************************************************************

<a id="statistics"></a>

statistics.c:**********************************************************************
statistics.c: Statistics.c -
statistics.c: This program Computes mean, variance, min, max, and optionally the
statistics.c: median, of a real vector.
statistics.c:
statistics.c: Options:
statistics.c:   -median  - Find the median (requires sufficient memory).
statistics.c:
statistics.c: Example Usage:
statistics.c:   statistics  vectorfile
statistics.c:  Or,
statistics.c:   statistics  -median  vectorfile
statistics.c:
statistics.c: File Types:
statistics.c:      In:   Real Vector.
statistics.c:      Out:  (None. Reports result to std.out (screen).)
statistics.c:**********************************************************************

<a id="sub"></a>

sub.c:**********************************************************************
sub.c: Sub.c -
sub.c:  This program subtracts the elements of one real or complex vector
sub.c:  or matrix file from another to produce a third file containg the
sub.c:  differences.
sub.c:
sub.c: Options:
sub.c:  (no options)
sub.c:
sub.c: Example Usage:
sub.c:  sub  fileA  fileB  resultFile
sub.c:
sub.c: File Types:
sub.c:      In:   Real or Complex, dimensionality must match.
sub.c:      Out:  (Same type and dimension as input.)
sub.c:**********************************************************************

<a id="transpose"></a>

transpose.c:**********************************************************************
transpose.c: Transpose.c -
transpose.c:  This program transposes a real matrix, or conjugate transposes a
transpose.c:  complex matrix.
transpose.c:
transpose.c: Options:
transpose.c:    (no options)
transpose.c:
transpose.c: Example Usage:
transpose.c:    transpose  in_matrixfile.dat  out_transposed_matrixfile.dat
transpose.c:
transpose.c: File Types:
transpose.c:      In:   Complex, Vector or Matrix
transpose.c:      Out:  (Same type and dimension as input file.)
transpose.c:**********************************************************************

<a id="ucirc"></a>

ucirc.c:**********************************************************************
ucirc.c: Ucirc.c -
ucirc.c:  This program draws the unit-circle.
ucirc.c:
ucirc.c: Options:
ucirc.c:    (no options)
ucirc.c:
ucirc.c: Example Usage:
ucirc.c:    ucirc  ucirc.dat
ucirc.c:    xgraph ucirc.dat
ucirc.c:
ucirc.c: File Types:
ucirc.c:      In:   (None.)
ucirc.c:      Out:  (xy plot file.)
ucirc.c:**********************************************************************

<a id="window"></a>

window.c:**********************************************************************
window.c: Window.c -
window.c:  This program produces windowing functions, also called amplitude
window.c:  shadings or tapers.   Used to minimize the effects of
window.c:  discontinuities at the ends of sample records.
window.c:  Defaults to Hamming window, but produces other windows by options.
window.c:
window.c: Options:
window.c:   -n  x       - Number of points. (Default = 128)
window.c:   -bartlet    - Produce bartlet or basic trianglur window.
window.c:   -triangular - Produce basic trianglur window.
window.c:   -hanning    - Produce cosine squared window.
window.c:   -hamming    - Produce Hamming window (default).
window.c:               Also called "raised-cosine".
window.c:   -blackman   - Produce Blackman window.
window.c:
window.c: Example Usage:
window.c:   window  window.dat
window.c:
window.c: File Types:
window.c:      In:   (None.)
window.c:      Out:  (Real vector file.)
window.c:**********************************************************************

<a id="zfill"></a>

zfill.c:**********************************************************************
zfill.c: Zfill.c -
zfill.c: This program appends a real or complex vector with zeros.
zfill.c:
zfill.c: Options:
zfill.c:   Use:
zfill.c:    -l  length  - Length to make the new vector.
zfill.c:   Or,
zfill.c:    -nz number  - Number of zeros to add.
zfill.c:
zfill.c: Example Usage:
zfill.c:    zfill -l 512  oldfile  newfile
zfill.c:
zfill.c: File Types:
zfill.c:      In:   Real or Complex, Vector.
zfill.c:      Out:  (Same type as input.)
zfill.c:**********************************************************************

<a id="mdeterm"></a>

mdeterm.c:**********************************************************************
mdeterm.c: Mdeterm.c -
mdeterm.c:  This program computes the determinant of a matrix.
mdeterm.c:
mdeterm.c: Options:
mdeterm.c:   (None.)
mdeterm.c:
mdeterm.c: Example Usage:
mdeterm.c:  mdeterm  in_matrixfile.dat
mdeterm.c:
mdeterm.c: File Types:
mdeterm.c:      In:   Complex or Real Matrix
mdeterm.c:      Out:  (Reports determinant to screen.)
mdeterm.c:**********************************************************************

<a id="mat2image"></a>

mat2image.c:**********************************************************************
mat2image.c: Mat2image.c -
mat2image.c:  This program converts a matrix to an image file.
mat2image.c:  Image file is gray-scale intensity image of real matrix values or
mat2image.c:  magintude of complex matrix values.
mat2image.c:
mat2image.c: Options:
mat2image.c:   -ascii - Produce ascii ppm image file.
mat2image.c:   -brightness - Normal=0.0, darker<0.0, brighter>0.0.
mat2image.c:   -contrast - Normal=1.0, duller<1.0, more contrast>1.0.
mat2image.c:   -color - Produce color (rainbow/temperature) image.
mat2image.c:
mat2image.c: Example Usage:
mat2image.c:   mat2image  in_matrixfile.dat out_image.ppm
mat2image.c:
mat2image.c: File Types:
mat2image.c:      In:   Complex or Real Matrix
mat2image.c:      Out:  Binary ppm image file.
mat2image.c:**********************************************************************

<a id="augmatvec"></a>

augmatvec.c:**********************************************************************
augmatvec.c: Mataugv -
augmatvec.c:  This program augments a matrix by a vector.  In other words, it
augmatvec.c:  adds a row or column to a matrix from a vector file.
augmatvec.c:  The dimensions of the matrix length or height must match the vector
augmatvec.c:  length.
augmatvec.c:
augmatvec.c: Options:
augmatvec.c:    -r  - Add row to matrix, last row.
augmatvec.c:    -c  - Add column to matrix, last column.
augmatvec.c:    -row x  - Add xth row to matrix.
augmatvec.c:    -col x  - Add xth column to matrix.
augmatvec.c:  Note: Rows and columns assumed to range 1 to n.
augmatvec.c:      One (1) is the first row or column.
augmatvec.c:      The last row or column is n, where n is the number of rows
augmatvec.c:      or columns, respectively.
augmatvec.c:
augmatvec.c: Example Usage:
augmatvec.c:    mataugv  mat.dat vec.dat -row 3 out_mat.dat
augmatvec.c:
augmatvec.c: File Types:
augmatvec.c:      In:   Complex or Real Matrix
augmatvec.c:      Out:  Vector of same data-type as input matrix
augmatvec.c:**********************************************************************

<a id="join2xy"></a>

join2xy.c:**********************************************************************
join2xy.c: Join2xy.c -
join2xy.c:  This program joins 2 Real Vector files into one Real Vector file,
join2xy.c:  where the first input file becomes the x value, and the second, the
join2xy.c:  y value of the output file.
join2xy.c:  Both files should be of equal length.
join2xy.c:
join2xy.c: Options:
join2xy.c:  (no options)
join2xy.c:
join2xy.c: Example Usage:
join2xy.c:  join2xy  fileA  fileB  fileC
join2xy.c:      xgraph  fileC
join2xy.c:   Assuming fileA was:
join2xy.c:  1 400
join2xy.c:  2 500
join2xy.c:  3 600
join2xy.c:   And fileB was:
join2xy.c:  1 8
join2xy.c:  2 9
join2xy.c:  3 10
join2xy.c:   Then fileC would be:
join2xy.c:  400 8
join2xy.c:  500 9
join2xy.c:  600 10
join2xy.c:
join2xy.c: File Types:
join2xy.c:      In:   Real.
join2xy.c:      Out:  Real.
join2xy.c:
join2xy.c:***********************************************************************

<a id="histogram"></a>

histogram.c:**********************************************************************
histogram.c: Histogram.c -
histogram.c: This program plots the histogram of a real vector.
histogram.c:
histogram.c: Options:
histogram.c:      -nbins x   - Number of bins to divide histogram of values into.
histogram.c:
histogram.c: Example Usage:
histogram.c:      histogram vectorfile  histo.dat
histogram.c:      xgraph histo.dat
histogram.c:
histogram.c: File Types:
histogram.c:      In:   Real Vector.
histogram.c:      Out:  histgram.dat (plot-file)
histogram.c:**********************************************************************

<a id="barchart"></a>

barchart.c:**********************************************************************
barchart.c: BarChart.c -
barchart.c:  This program converts a real vector file into a bar-chart graph for
barchart.c:  viewing with xgraph.
barchart.c:
barchart.c: Options:
barchart.c:      -thickness 
barchart.c:       (By default, barchart sets the bar thickness based on the
barchart.c:        number of points in your file.  This option lets you override
barchart.c:       the automatic setting.  1.0 is thin, 10-is thicker, etc..)
barchart.c:      -title (title)
barchart.c:      -xtitle (x_axis_title>
barchart.c:      -ytitle (y_axis_title>
barchart.c: Note: Quotes are needed around multi-word titles.
barchart.c:
barchart.c: Example Usage:
barchart.c:      barchart  infile  graphfile
barchart.c:      xgraph graphfile
barchart.c:
barchart.c: File Types:
barchart.c:      In:   Real
barchart.c:      Out:  [graph-format]
barchart.c:**********************************************************************

<a id="differentiate"></a>

differentiate.c:**********************************************************************
differentiate.c: Differentiate.c -
differentiate.c:  This program differentiates the values in a real vector file.
differentiate.c:  It produces another vector file, which is the "differential", or
differentiate.c:  the sample-to-sample differences.
differentiate.c:
differentiate.c: Options:
differentiate.c:      (No options.)
differentiate.c:
differentiate.c: Example Usage:
differentiate.c:      differentiate infile  outfile
differentiate.c:
differentiate.c: File Types:
differentiate.c:      In:   Real
differentiate.c:      Out:  Real
differentiate.c:**********************************************************************

<a id="integrate"></a>

integrate.c:**********************************************************************
integrate.c: Integrate.c -
integrate.c:  This program integrates the values in a real vector file.
integrate.c:  It produces another vector file, which is the "running-sum".
integrate.c:
integrate.c: Options:
integrate.c:      (No options.)
integrate.c:
integrate.c: Example Usage:
integrate.c:      integrate infile  outfile
integrate.c:
integrate.c: File Types:
integrate.c:      In:   Real
integrate.c:      Out:  Real
integrate.c:**********************************************************************

<a id="nums2vec"></a>

nums2vec.c:/***********************************************************************
nums2vec.c:/* nums2vec.c -
nums2vec.c:/* This program converts a simple list of numbers, such as from Matlab
nums2vec.c:/* to NumUtils Real Vector format, by adding the header line and an
nums2vec.c:/* index column.
nums2vec.c:/*
nums2vec.c:/* Options:
nums2vec.c:/*   Use:
nums2vec.c:/*      -c  - Make a complex vector instead of a real vector.
nums2vec.c:/*      -i  - Expect index on each line of file.  ie. x y
nums2vec.c:/*              (one x-y pair per line)
nums2vec.c:/*
nums2vec.c:/* Example Usage:
nums2vec.c:/*      nums2vec oldfile  newfile
nums2vec.c:/*
nums2vec.c:/* File Types:
nums2vec.c:/*      In:   (textual list of numbers)
nums2vec.c:/*      Out:  Real or complex Vector.
nums2vec.c:/***********************************************************************

<a id="vec2nums"></a>

vec2nums.c:/************************************************************************
vec2nums.c:/* vec2nums.c -
vec2nums.c:/* This program converts real or complex vector files to simple number
vec2nums.c:/* list files, such as used by Matlab, by removing the header line and
vec2nums.c:/* index column.
vec2nums.c:/*
vec2nums.c:/* Example Usage:
vec2nums.c:/*      vec2nums vecfile  newfile
vec2nums.c:/*
vec2nums.c:/* File Types:
vec2nums.c:/*      In:   Real or complex Vector.
vec2nums.c:/*      Out:  (textual list of numbers)
vec2nums.c:/************************************************************************

<a id="enter_vec"></a>

enter_vec.c:/************************************************************************
enter_vec.c:/* enter_vec.c -
enter_vec.c:/* This program creates a new vector or matrix file, by asking a series
enter_vec.c:/* of questions.  You enter numbers at your keyboard in response to the
enter_vec.c:/* interactive prompts.
enter_vec.c:/*
enter_vec.c:/* Example Usage:
enter_vec.c:/*      entervec newfile 
enter_vec.c:/*
enter_vec.c:/* File Types:
enter_vec.c:/*      Out:  Real or complex Vector or Matrix.
enter_vec.c:/************************************************************************

<a id="identity_matrix"></a>

identity_matrix.c:/****************************************************************/
identity_matrix.c:/* Identity_Matrix - This utility produces an identity martix.  */
identity_matrix.c:/* A square matrix having all ones down the main diagonal, and  */
identity_matrix.c:/* zeros off diagonal.                                          */
identity_matrix.c:/*                                                              */
identity_matrix.c:/* Command line options:                                        */
identity_matrix.c:/*      {file_name} - Output file name.                         */
identity_matrix.c:/*      -n kk   - Create matrix of dimension kk.                */
identity_matrix.c:/*      -complex - Produce a complex matrix.                    */
identity_matrix.c:/*      -scale xx - Main diagonal will have value xx            */
identity_matrix.c:/*              instead of  1.0.                                */
identity_matrix.c:/*      -sizeofmat matname - Create matrix of dimension         */
identity_matrix.c:/*              matching that of the one in file 'matname'.     */
identity_matrix.c:/*                                                              */
identity_matrix.c:/* By default, this utility produces a real matrix of dimension */
identity_matrix.c:/* 3x3, unless otherwise specified.                             */
identity_matrix.c:/*                                                              */
identity_matrix.c:/* File Types:                                                  */
identity_matrix.c:/*      Out:  Real (default), or Complex (option)               */
identity_matrix.c:/****************************************************************/

<a id="abs"></a>

abs.c:/**********************************************************************
abs.c:/* Abs.c -
abs.c:/*  This program takes the absolute values of a real vector file.
abs.c:/*  It makes any negative values positive.
abs.c:/*  If the input file is complex, it takes the complex magnitudes.
abs.c:/*
abs.c:/* Options:
abs.c:/*      -x - Take absolute value of the abscissa (x-value) instead of
abs.c:/*           ordinate (y-value).
abs.c:/*
abs.c:/* Example Usage:
abs.c:/*      abs  infile  newfile
abs.c:/*
abs.c:/* File Types:
abs.c:/*      In:   Real or Complex
abs.c:/*      Out:  Real
abs.c:/**********************************************************************

<a id="image2matrix"></a>

image2matrix.c:/************************************************************************
image2matrix.c:/* Image2matrix.c -
image2matrix.c:/*  This program converts an image file to a NumUtils matrix file.
image2matrix.c:/*  By default, the image's intensity values become the matrix values.
image2matrix.c:/*  The output values span 0.0 to 1.0.  Maximum intensity (brightest)
image2matrix.c:/*  equals 1.0.  Mimumum intensity (darkest) equals 0.
image2matrix.c:/*  Options enable selecting conversion for either red, blue, or green
image2matrix.c:/*  (rgb) component colors to matrix values.
image2matrix.c:/*
image2matrix.c:/* Options:
image2matrix.c:/*  -red - Select the red-component of the image to matrix.
image2matrix.c:/*  -blue - Select the blue-component of the image to matrix.
image2matrix.c:/*  -green - Select the green-component of the image to matrix.
image2matrix.c:/*
image2matrix.c:/* Example Usage:
image2matrix.c:/*      image2matrix  in_imagefile.ppm  out_matrix.dat
image2matrix.c:/*
image2matrix.c:/* File Types:
image2matrix.c:/*      In:   PPM image file.
image2matrix.c:/*      Out:  Real Matrix file.
image2matrix.c:/************************************************************************

<a id="decimate"></a>

decimate.c:/************************************************************************
decimate.c:/* Decimate.c -
decimate.c:/*  This program decimates a real or complex vector by the decimation
decimate.c:/*  amount, k.  It reads one input file (having n items) to produce an
decimate.c:/*  output file containing n/k points.  I.E. It copies each kth sample
decimate.c:/*  to the output file.  This is useful for reducing the number of
decimate.c:/*  points in a vector, usually after low-pass filtering.
decimate.c:/*  This operation is also called "down-sampling", or "sub-sampling".
decimate.c:/*  Default decimation amount is 2.  I.E. Every other sample (all even
decimate.c:/*  samples, starting with sample zero).
decimate.c:/*  Writes the (i mod k) = 0 samples, from samples numbered 0 : n-1.
decimate.c:/*
decimate.c:/* Options:
decimate.c:/*      -k      = Decimation amount (default=2).
decimate.c:/*      -offset = Offset value ((i mod k) = offset), default=0.
decimate.c:/*
decimate.c:/* Example Usage:
decimate.c:/*      Decimate  file_in  -k 4  File_out
decimate.c:/*
decimate.c:/* File Types:
decimate.c:/*      In:   Real or Complex.
decimate.c:/*      Out:  (Same type and dimension as input.)
decimate.c:/************************************************************************

(Questions, Comments, & Suggestions: xgraphadmin@xgraph.org)

Return to www.xgraph.org

This page is an editorial rewrite of source documentation. Historical status, availability, and platform notes are not independently verified for a current release. Technical examples are reference material, not a live simulator.