GlassBR
All Classes Files Functions
Functions
Interpolation.py File Reference

Provides functions for linear interpolation on three-dimensional data. More...

Functions

def python.Interpolation.lin_interp (x_1, y_1, x_2, y_2, x)
 Performs linear interpolation. More...
 
def python.Interpolation.find (arr, v)
 Finds the array index for a value closest to the given value. More...
 
def python.Interpolation.extractColumn (mat, j)
 Extracts a column from a 2D matrix. More...
 
def python.Interpolation.interpY (filename, x, z)
 Linearly interpolates a y value at given x and z values. More...
 
def python.Interpolation.interpZ (filename, x, y)
 Linearly interpolates a z value at given x and y values. More...
 

Detailed Description

Provides functions for linear interpolation on three-dimensional data.

Author
Nikitha Krithnan and W. Spencer Smith
Note
Generated by Drasil v0.1-alpha

Function Documentation

◆ extractColumn()

def python.Interpolation.extractColumn (   mat,
  j 
)

Extracts a column from a 2D matrix.

Parameters
matmatrix from which column will be extracted
jindex
Returns
column of the given matrix at the given index

◆ find()

def python.Interpolation.find (   arr,
  v 
)

Finds the array index for a value closest to the given value.

Parameters
arrarray in which value should be found
vvalue whose index will be found
Returns
index of given value in given array

◆ interpY()

def python.Interpolation.interpY (   filename,
  x,
  z 
)

Linearly interpolates a y value at given x and z values.

Parameters
filenamename of file with x y and z data
xx-coordinate to interpolate at
zz-coordinate to interpolate at
Returns
y value interpolated at given x and z values

◆ interpZ()

def python.Interpolation.interpZ (   filename,
  x,
  y 
)

Linearly interpolates a z value at given x and y values.

Parameters
filenamename of file with x y and z data
xx-coordinate to interpolate at
yy-coordinate to interpolate at
Returns
z value interpolated at given x and y values

◆ lin_interp()

def python.Interpolation.lin_interp (   x_1,
  y_1,
  x_2,
  y_2,
  x 
)

Performs linear interpolation.

Parameters
x_1lower x-coordinate
y_1lower y-coordinate
x_2upper x-coordinate
y_2upper y-coordinate
xx-coordinate to interpolate at
Returns
y value interpolated at given x value