flaredetector: add GaussExponential function to fit flares

This commit is contained in:
2024-04-15 14:32:40 +02:00
parent 0e5c4e7a58
commit 1ecacfcaa4
+8
View File
@@ -1 +1,9 @@
import numpy as np
def GaussExpo(x, Peak, l, w):
sigma = 1/w
res1 = Peak * np.exp(-(x**2)/(2 * sigma**2))
peakX = np.argmax(res1)
res1 = res1[:peakX]
res2 = Peak * np.exp(-l * x[peakX:])
return np.append(res1, res2)