sort_sweep_arraysο
- plasmapy.analysis.swept_langmuir.helpers.sort_sweep_arrays(
- voltage: ndarray,
- current: ndarray,
- voltage_order: Literal['ascending', 'descending'] = 'ascending',
Sort the swept langmuir
voltageandcurrenttraces to ensure thevoltagearray is either monotonically increasing or decreasing.- Parameters:
voltage (
numpy.ndarray) β 1Dnumpy.ndarrayrepresenting the voltage of the swept Langmuir trace. No units are assumed or checked, but values should be in volts.current (
numpy.ndarray) β 1Dnumpy.ndarrayrepresenting the current of the swept Langmuir trace. Values should start from a negative ion-saturation current and increase to a positive electron-saturation current. No units are assumed or checked, but values should be in amperes.voltage_order (
str) β Either'ascending'or'descending'to indicate how thevoltagearray should be sorted. (DEFAULT:'ascending')
- Returns:
voltage (
numpy.ndarray) β Sortedvoltagearray.current (
numpy.ndarray) β Matchedcurrentarray to the sortedvoltagearray.