Nextvalley, Numberofpeaks – MTS Multipurpose Elite User Manual
Page 269
3. Searches between the peak load's point and the last data point.
4. Finds the next peak and returns its array index.
5. Only calculates the result if the _LoadArray data becomes greater than the value of the input
MinimumLoad.
NextValley
The NextValley function searches the data array specified in array and returns the next valley's index as
defined by the valley criteria, after the data point specified by the start index. The values within square
braces, [], are optional.
Syntax
NextValley(array, valleyCriteria, startIndex[, endIndex, threshold])
Parameters
array - The array data being analyzed for the next valley.
valleyCriteria - A percentage of the peak magnitude used to detect when a valley occurs.
startIndex - The start index of the array used in locating the valley. The first point in the array is used if
this parameter is not provided.
endIndex - The optional end index of the array used in locating the valley. The last point in the array is
used if this parameter is not provided.
threshold - The optional minimum value, in array units, which must be exceeded before the data is used
in the calculation.
Dimension
Count
Example
NextValley(_LoadArray,LoadValleyCriteria,Peak,SizeOfArray(_LoadArray)-1,MinimumLoad)
This formula:
1. Searches the _LoadArray data.
2. Looks for the next increase in the _LoadArray data's value that corresponds to the input
LoadValleyCriteria.
3. Searches between the peak load's point and the last data point.
4. Finds the next valley and returns its array index.
5. Only calculates the result if the _LoadArray data becomes greater than the value of the input
MinimumLoad.
NumberOfPeaks
The NumberOfPeaks function determines the number of peaks in a region that meet the specified peak
criterion.
Returns
The number of peaks found in the region.
MTS TestSuite | 269
Working with Variables