The utils.functions module

Utility Functions

A collection of functions frequently used in lifetime estimation business.

pylife.utils.functions.rossow_cumfreqs(N)[source]

Cumulative frequency estimator according to Rossow

Parameters:N (int) – The sample size of the statistical population
Returns:cumfreqs – The estimated cumulated frequencies of the N samples
Return type:numpy.ndarray

Notes

The returned value is the probability that the next taken sample is below the value of the i-th sample of n sorted samples.

Examples

>>> rossow_cumfreqs(1)
array([0.5])

If we have one sample, the probability that the next sample will be below it is 0.5.

>>> rossow_cumfreqs(3)
array([0.2, 0.5, 0.8])

If we have three sorted samples, the probability that the next sample will be * below the first is 0.2 * below the second is 0.5 * below the third is 0.8

References

‘Statistics of Metal Fatigue in Engineering’ page 16

https://books.google.de/books?isbn=3752857722

pylife.utils.functions.scatteringRange2std(T_inv)[source]

Converts a inverted scattering range (1/T) into standard deviation

Parameters:T_inv (float) – inverted scattering range
Returns:std – standard deviation corresponding to 1/T assuming a normal distribution
Return type:float

Notes

Actually 1/(2*norm.ppf(0.9))*np.log10(T_inv)

Inverse of std2scatteringRange()

pylife.utils.functions.std2scatteringRange(std)[source]

Converts a standard deviation into inverted scattering range (1/T)

Parameters:std (float) – standard deviation
Returns:T_inv – inverted scattering range corresponding to std assuming a normal distribution
Return type:float

Notes

Actually 10**(2*norm.ppf(0.9)*std

Inverse of scatteringRange2std()