fluidlab.objects.probes

Probes (fluidlab.objects.probes)

Provides:

class fluidlab.objects.probes.ConductivityProbe(board=None, channel=1, sample_rate=1000, has_to_config_board=True, VALVE=True)[source]

Represent a conductivity probe.

This is an example of modification.

Parameters:
board???

Object representing a board.

channelnumber

The channel index.

prepare_calibration(rho_min=1, rho_max=1.18, nb_solutions=6)[source]

Gives indications to prepare a calibration.

calibrate(rhos, duration_1measure=4.0)[source]

Calibrates the probe.

Parameters:
rhosarray_like

The density \(\rho\) of the samples (in kg/l).

duration_1measurenumber

The duration of one measurement (in s).

Notes

\(\rho(C)\) and \(U(C, T)\), where \(C\) the concentration, \(U\) the voltage and \(T\) the temperature.

plot_calibrations(rhos=None, volts=None, rho_real=None)[source]

Plots the measurements of the saved calibrations.

save_calibration(rhos, voltages)[source]

Saves the results of a calibration.

load_calibrations()[source]

Loads the data from the previous calibrations.

create_function_from_data(rhos, volts)[source]

Creates a function from data.

set_sample_rate(sample_rate)[source]

Sets the sample rate.

measure_volts(duration, sample_rate=None, return_time=False, verbose=False)[source]

Measure and return the times and voltages.

Parameters:
duration

(in s)

measure(duration, sample_rate=None, return_time=False, verbose=False)[source]

Measure and return the times and density.

Parameters:
durationnumber

(in s)

sample_ratenumber

(in Hz)

test_measure(duration=2, hastoplot=True, rho_real=None)[source]

Test the measurement.

class fluidlab.objects.probes.MovingConductivityProbe(board=None, channel=1, sample_rate=100, has_to_config_board=True, position_start=300.0, position_max=None, Deltaz=400.0)[source]

Represent a conductivity probe that can be deplaced by a traverse.

Parameters:
(for the __init__ method)
board, optional

Acquisition board.

channel{1, int}, optional

Indice of the channel in the acquisition board.

sample_rate{100, number}, optional

Sample rate of the probe.

has_to_config_board{True, bool}, optional

Has to configure the board.

position_start{300., number}, optional

Position when created (in mm).

position_max{None, number}, optional

???

Deltaz{400, number}, optional

Distance between extremal points.

move_measure(deltaz=100, speed=100, sample_rate=None, return_time=False)[source]

Move the probe while measuring.

Parameters:
deltaz: number

Distance to move (in mm).

speed: number

(in mm/s)

sample_rate: number

(in Hz)

Classes

ConductivityProbe([board, channel, ...])

Represent a conductivity probe.

MovingConductivityProbe([board, channel, ...])

Represent a conductivity probe that can be deplaced by a traverse.