https://www.jianshu.com/p/354b1f2a5fd0
https://www.cnblogs.com/qi-yuan-008/p/12323535.html
import numpy as np
import matplotlib.pyplot as plt
from numpy import polyval
# https://baijiahao.baidu.com/s?id=1643468349140251072&wfr=spider&for=pc
# 多项式拟合代码如下
from scipy.optimize import curve_fit
def ax_bfit(x,y,calculate_x,n):
x=np.array(x)
y=np.array(y)
calculate_x=np.array(calculate_x)
fit_coef=np.polyfit(x,y,n)
calculate_y=np.polyval(fit_coef,calculate_x)
fit_coef=[round(i,3) for i in fit_coef]
plt.plot(x,y,'^')
plt.plot(calculate_x,calculate_y)
plt.show()
return fit_coef,calculate_y
def func(x,a,b,c):
return a*np.exp(b*x)*c
# 幂函数拟合
def a_xfit(x,y,calculate_x):
plt.plot(x,y,'.')
popt,pcov=curve_fit(func,x,y)
calculate_y = [func(i,popt[0],popt[1],popt[2]) for i in calculate_x]
plt.plot(calculate_x,calculate_y,'r--')
plt.show()
return popt,calculate_y
def fund(x,a,b):
return x**a+b
# 指数拟合
def x_afit(x,y,calculate_x):
plt.plot(x,y,'.')
popt,pcov= curve_fit(fund,x,y)
calculate_y=[fund(i,popt[0],popt[1]) for i in calculate_x]
popt=[round(i,3) for i in popt]
plt.plot(calculate_x,calculate_y,'r__')
plt.show()
return popt,calculate_y
if __name__ == '__main__':
# x=[1,2,3,4,5,6,7,8,9,10,11,12,13]
# y = [1, 2, 4, 26, 33, 50, 58, 84, 104, 142, 170, 186, 199]
# calculate_x = [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13,14,15,16]
dataList = [1476917.5, 1476800.0, 1476697.0, 1476697.0, 1476289.0, 1476118.0, 1475955.5, 1475810.5, 1475727.5,
1475671.0, 1475576.0, 1475497.0, 1475428.5, 1475340.0, 1475263.5, 1475153.5, 1474983.0, 1474947.5,
1474852.0, 1474789.0, 1474661.5, 1474608.5, 1474484.0, 1474468.5, 1476153.0, 1476049.0, 1475947.0,
1475870.0, 1475792.0, 1475713.5, 1474991.5, 1474777.0, 1474334.5, 1474266.0, 1474210.0, 1473672.5,
1473571.0, 1473155.5, 1473116.0, 1473042.0, 1472923.5, 1472857.5, 1472750.0, 1472635.5, 1472530.0,
1471566.0, 1471491.0, 1471464.0, 1471423.5, 1471363.5, 1471306.5, 1471252.5, 1471207.5, 1471146.0,
1471103.5, 1471077.0, 1471002.5, 1470933.5, 1470875.5, 1470764.0, 1470718.0, 1470661.0, 1470623.5,
1470623.5, 1470564.0, 1470526.5, 1470409.5, 1470478.5, 1469858.0, 1469804.5, 1469825.5, 1470201.0,
1470186.5, 1470138.5, 1470057.0, 1469579.0, 1469501.5, 1469425.0, 1469412.0, 1469402.0, 1469393.0,
1469358.5, 1469324.5, 1469288.0, 1469255.5, 1469265.5, 1469198.5, 1469132.5, 1469180.5, 1469205.5,
1469269.0, 1469289.5, 1469278.5, 1469234.5, 1469240.0, 1469223.0, 1469208.0, 1469186.5, 1469154.5,
1469172.5, 1469140.5, 1469115.5, 1469116.5, 1469121.5, 1469068.0, 1468998.5, 1468944.0, 1468903.0,
1468889.0, 1468843.5, 1468831.0, 1468818.0, 1468816.0, 1469257.0, 1469318.5, 1469402.5, 1469398.0,
1469511.5, 1469490.5, 1469432.5, 1469439.5, 1469427.0, 1469468.0, 1469468.0, 1469442.5, 1469436.0,
1469455.5, 1469381.5, 1469243.0, 1469238.0, 1468692.5, 1469425.0, 1469478.0, 1469455.0, 1469472.0,
1469405.0, 1469411.5, 1469393.5, 1469395.0, 1469438.0, 1469421.0, 1469428.5, 1469433.5, 1469322.5,
1469204.5, 1469086.0, 1469113.0, 1469185.5, 1469269.5, 1469396.0, 1469477.5, 1469490.0, 1469577.5,
1469624.5, 1469657.5, 1469701.5, 1469756.5, 1469763.5, 1469765.5, 1469814.0, 1469823.5, 1469859.5,
1469866.0, 1469866.0, 1469865.0, 1469909.5, 1469925.5, 1469918.5, 1469904.0, 1469558.5, 1469665.5,
1469665.0, 1469822.5, 1468417.0, 1468393.0, 1468376.5, 1468283.5, 1468269.0, 1468260.5, 1468244.0,
1468189.0, 1468245.5, 1468296.5, 1468296.5, 1468327.0, 1468230.5, 1468289.0, 1468280.0, 1468273.0,
1468263.5, 1469467.0, 1469288.5, 1469322.5, 1469333.0, 1469343.5, 1469339.5, 1469299.0, 1469297.5,
1469291.5, 1469236.0, 1469206.5, 1469167.5, 1469177.5, 1469157.0, 1469145.5, 1469128.0, 1469125.5,
1469092.0, 1468073.5, 1468045.0, 1467927.0, 1468056.5, 1468033.0, 1468018.5, 1468022.0, 1468008.5,
1468030.5, 1468005.0, 1467998.5, 1467988.5, 1467956.5, 1467953.5, 1467972.0, 1467983.0, 1467983.0,
1467958.5, 1467941.0, 1467921.0, 1467886.0, 1467857.5, 1467865.5, 1467843.0, 1467785.5, 1467776.5,
1467803.0, 1467783.5, 1467806.5, 1467792.5, 1467801.0, 1467801.0, 1467826.0, 1467884.5, 1467883.0,
1467883.0, 1467988.0, 1467974.0, 1467988.0, 1467954.0, 1468625.5, 1468563.0, 1468602.5, 1468641.0,
1468650.5, 1468638.5, 1468615.0, 1468652.5, 1468641.5, 1468608.0, 1468615.0, 1468598.0, 1468612.0,
1468571.5, 1468608.0, 1468585.0, 1468574.5, 1468591.0, 1468543.5, 1468541.5, 1468555.0, 1468546.5,
1468607.5, 1467933.0, 1467954.5, 1467930.0, 1467931.5, 1467896.0, 1467869.0, 1467899.5, 1467950.5,
1467977.0, 1467952.0, 1467892.0, 1467910.5, 1467994.0, 1468006.5, 1468025.0, 1468111.5, 1468158.0,
1468163.5, 1468117.0, 1468162.5, 1468194.5, 1468239.0, 1468239.0, 1468197.5, 1468199.0, 1468277.5,
1468296.0, 1468303.0, 1468319.5, 1468423.0, 1468489.0, 1468583.5, 1468583.5, 1468758.5, 1468825.5,
1468879.5, 1468886.0, 1470219.0, 1470278.0, 1470260.0, 1470340.5, 1470402.0, 1470391.0, 1470428.5,
1470478.0, 1470443.5, 1470350.0, 1470350.5, 1470390.5, 1470476.0, 1470528.5, 1470554.0, 1470626.0,
1470636.0, 1470676.0, 1470733.0, 1470773.0, 1470834.5, 1470888.5, 1471054.0, 1471146.5, 1471184.5,
1471240.5, 1471302.5, 1471362.0, 1471398.5, 1471466.5, 1471554.0, 1471623.0, 1471654.5, 1471726.5,
1471766.5, 1471812.5, 1471885.0, 1471976.0, 1472035.5, 1472055.5, 1472106.5, 1472134.0, 1472138.5,
1472237.0, 1472304.5, 1472378.5, 1472444.5, 1472510.0, 1472642.0, 1472712.0, 1472766.5, 1472787.5,
1473136.0, 1474261.5, 1474719.5, 1474719.5, 1473950.5, 1474230.0, 1474405.0, 1474504.5, 1474623.0,
1474690.5, 1474749.5, 1474865.5, 1474917.0, 1474971.0, 1475074.0, 1475145.0, 1475214.5, 1475298.5,
1474995.5, 1475258.0, 1477249.0, 1475495.0, 1477254.0, 1477374.5, 1477396.5, 1477429.0, 1477499.5,
1477585.0, 1477602.5, 1475824.5, 1475367.0, 1475285.0, 1475471.0, 1475676.5, 1475780.5, 1475802.0,
1475709.5, 1475693.5, 1475754.0, 1475784.5, 1475584.0, 1475570.5, 1475254.5, 1475273.0, 1475255.5,
1475158.0, 1475415.5, 1475430.5, 1475211.0, 1475137.5, 1475134.5, 1475061.5, 1475004.5, 1474914.5,
1474786.5, 1474667.5, 1474551.5, 1474484.0, 1474392.0, 1474248.5, 1474240.0, 1474394.5, 1474321.5,
1474321.5, 1474202.5, 1474108.5, 1473993.5, 1473860.0, 1473726.0, 1473625.0, 1473501.0, 1473332.0,
1473181.0, 1472973.0, 1472783.5, 1472589.0, 1472272.0, 1472070.0, 1471827.0, 1471555.0, 1471299.5,
1471119.0, 1470935.5, 1470758.0, 1470563.0, 1470338.0, 1470123.0, 1469909.5, 1469735.0, 1469547.5,
1469321.5, 1469194.5, 1469032.5, 1468788.0, 1468565.0, 1468322.0, 1468082.5, 1467861.0, 1467626.5,
1467437.0, 1467128.0, 1466877.0, 1466694.0, 1466500.5, 1466240.0, 1466045.0, 1465709.5, 1465471.5,
1465246.0, 1465042.0, 1464852.0, 1464631.5, 1464430.0, 1464236.5, 1464049.0, 1463877.5, 1463685.0,
1463523.0, 1463351.0, 1463208.5, 1462966.5, 1462883.5, 1462773.0, 1462773.0, 1462488.0, 1462345.0,
1462229.5, 1462082.0, 1461974.0, 1461881.0, 1461793.5, 1461679.0, 1461588.0, 1461480.0, 1461369.0,
1461280.0, 1461145.0, 1461032.5, 1460926.0, 1460855.5, 1460603.5, 1460636.5, 1460542.0, 1460417.5,
1460376.0, 1460298.5, 1460216.5, 1460043.0, 1459977.5, 1459966.0, 1459885.0, 1459871.0, 1459934.5,
1459899.0, 1459816.5, 1459773.5, 1459742.5, 1459720.0, 1459686.0, 1459595.0, 1459519.5, 1459492.5,
1459492.0, 1459435.0, 1459444.5, 1459447.5, 1459467.0, 1459479.0, 1459408.5, 1459394.0, 1459403.0,
1459418.5, 1459423.0, 1459144.0, 1459418.0, 1459384.0, 1459350.0, 1459356.5, 1459399.0, 1459486.5,
1459594.5, 1459757.0, 1459849.5, 1459849.5, 1459936.0, 1459958.5, 1460031.0, 1460105.0, 1460208.5,
1460265.5, 1460311.0, 1460356.5, 1460457.5, 1460511.0, 1460523.5, 1460578.0, 1460635.0, 1460644.5,
1460699.0, 1460725.5, 1460779.5, 1460845.0, 1460911.5, 1460967.0, 1460976.0, 1461003.5, 1461044.5,
1461142.5, 1461181.5, 1461220.5, 1461290.5, 1461339.5, 1461368.5, 1461402.5, 1461480.5, 1461527.0,
1461607.5, 1461621.0, 1461671.0, 1461708.0, 1461734.0, 1461780.0, 1461803.0, 1461833.5, 1461892.5,
1461922.0, 1461973.5, 1461973.0, 1462028.0, 1462082.0, 1462114.0, 1462142.0, 1462184.5, 1462243.5,
1462296.0, 1462334.5, 1462384.5, 1462410.0, 1462456.0, 1462499.5, 1462509.5, 1462585.5, 1462661.0,
1462661.0, 1462769.0, 1462796.0, 1462882.5, 1462942.0, 1462996.5, 1463025.5, 1463104.0, 1463175.0,
1463202.5, 1463252.5, 1463288.5, 1463382.5, 1463389.0, 1463437.5, 1463483.5, 1463571.5, 1463652.0,
1463664.0, 1463725.0, 1463832.0, 1463879.5, 1463883.5, 1463971.5, 1464044.5, 1464180.5, 1464227.0,
1464288.0, 1464340.5, 1464315.5, 1464372.0, 1464424.0, 1464501.0, 1464563.0, 1464624.0, 1464652.0,
1464690.5, 1464701.0, 1464739.5, 1466150.5, 1466638.1666666667, 1466833.0555555557, 1466953.0185185187,
1467027.3395061728, 1467106.113168724, 1467151.7043895747, 1467221.9014631917, 1467256.9671543974,
1467320.3223847991, 1467378.1074615996, 1467436.0358205333, 1467484.6786068445, 1467495.8928689482,
1467547.9642896494, 1467620.9880965499, 1467696.9960321833, 1467780.665344061, 1467860.2217813537,
1467884.0739271177, 1467879.3579757058, 1467877.7859919018, 1468030.2619973004, 1468132.4206657668,
1468235.806888589, 1468282.6022961962, 1468356.2007653986, 1466111.5, 1466212.0, 1466297.0, 1466381.5,
1466480.0, 1466560.0, 1466617.0, 1466696.0, 1466760.0, 1466822.5, 1466892.0, 1466952.0, 1467042.0,
1467158.5, 1467233.5, 1467306.5, 1467347.5, 1467422.5, 1467485.0, 1467567.5, 1467604.0, 1467668.0,
1467721.0, 1467792.0, 1467902.5, 1468008.0, 1468066.0, 1468121.5, 1468183.5, 1468275.5, 1468346.5,
1468447.5, 1468488.0, 1468549.5, 1468626.5, 1468738.5, 1468827.0, 1468899.5, 1468952.5, 1469033.0,
1469194.0, 1469267.0, 1469344.0, 1469386.5, 1469434.0, 1469504.0, 1469581.0, 1469654.5, 1469721.5,
1469802.0, 1469876.0, 1469941.0, 1470009.5, 1470094.0, 1470094.0, 1470194.5, 1470264.5, 1470324.0,
1470380.5, 1470443.0, 1470521.5, 1470564.0, 1470583.5, 1470629.5, 1470651.5, 1470240.5, 1470376.5,
1470552.0, 1470615.5, 1470758.5, 1470793.5, 1470804.5, 1470883.0, 1470890.5, 1470962.0, 1471016.5,
1471068.5, 1471106.5, 1471125.0, 1471153.0, 1471181.0, 1471238.5, 1471242.5, 1471184.5, 1471217.0,
1471243.0, 1471267.5, 1471284.5, 1471297.5, 1471318.5, 1471347.0, 1471375.0, 1471410.5, 1471464.0,
1471551.5, 1471603.0, 1471636.0, 1471657.0, 1471725.0, 1471763.5, 1471823.5, 1471960.5, 1471992.5,
1472016.5, 1472080.0, 1472072.0, 1472108.0, 1472156.5, 1472203.0, 1472173.5, 1472107.5, 1472110.0,
1472119.5, 1472083.0, 1472083.0, 1472088.0, 1472046.0, 1471980.5, 1471929.0, 1471908.5, 1471929.0,
1471904.5, 1471867.0, 1471842.0, 1471778.0, 1471783.0, 1471763.0, 1471698.5, 1471699.5, 1471636.0,
1471622.5, 1471599.5, 1471645.0, 1471648.0, 1471617.5, 1471637.5, 1471635.0, 1471642.0, 1471637.5,
1471566.0, 1471574.5, 1471541.5, 1471531.5, 1471511.5, 1471462.0, 1471426.0, 1471427.5, 1471416.0,
1471404.0, 1471352.5, 1471289.0, 1471296.5, 1471278.5, 1471292.5, 1471295.5, 1471310.0, 1471308.5,
1471294.5, 1471288.5, 1471270.0, 1471249.5, 1471277.5, 1471269.0, 1471282.0, 1471295.0, 1471321.5,
1471325.0, 1471330.0, 1471301.5, 1471317.0, 1471255.0, 1471248.0, 1471267.0, 1471172.0, 1471172.0,
1471231.5, 1471226.0, 1471237.0, 1471237.5, 1471209.0, 1471191.5, 1471185.5, 1471185.5, 1471199.5,
1471176.5, 1471211.0, 1471227.5, 1471182.5, 1471187.0, 1471223.0, 1471235.0, 1471247.5, 1471233.5,
1471239.0, 1471243.0, 1471254.5, 1471226.0, 1471254.0, 1471274.0, 1471286.0, 1471267.5, 1471274.5,
1471291.5, 1471265.5, 1471244.5, 1471280.5, 1471302.5, 1471295.0, 1471324.0, 1474501.0, 1474521.5,
1474580.5, 1474646.0, 1471318.0, 1471237.5, 1471249.5, 1471263.0, 1471258.0, 1471301.0, 1471349.0,
1471334.0, 1471343.0, 1471327.0, 1471332.5, 1474829.5, 1474848.0, 1474852.0, 1471063.5, 1471070.5,
1471063.0, 1471066.5, 1474777.5, 1471061.5, 1471066.5, 1471066.5, 1471213.0, 1471212.0, 1471162.5,
1471188.5, 1471194.5, 1471203.0, 1471113.5, 1471176.0, 1471215.0, 1471253.5, 1471251.5, 1471261.0,
1471258.5, 1471185.0, 1471205.0, 1471220.0, 1471241.5, 1471229.5, 1471237.0, 1471273.5, 1471291.0,
1471326.5, 1471343.0, 1471348.0, 1471375.0, 1471382.0, 1471391.5, 1471387.5, 1471405.5, 1471356.0,
1471350.0, 1471369.0, 1471360.5, 1471390.5, 1471384.0, 1471410.0, 1472648.6666666667, 1473057.888888889,
1471338.0, 1471410.5, 1471392.5, 1471409.5, 1471390.5, 1471400.5, 1471387.0, 1471412.0, 1471438.0,
1474995.0, 1475017.0, 1475070.0, 1475115.0, 1475127.5, 1471778.0, 1475222.0, 1475235.0, 1475241.5,
1475248.0, 1475284.5, 1475298.0, 1475298.0, 1475381.5, 1471932.0, 1471925.0, 1475469.5, 1475555.0,
1475633.5, 1475688.0, 1472330.0, 1475786.5, 1475846.5, 1475872.0, 1475913.5, 1476028.0, 1476090.5,
1476149.0, 1476213.0, 1476274.0, 1476324.0, 1476391.0, 1476483.5, 1473098.0, 1473154.5, 1476726.0,
1476814.5, 1473398.0, 1473505.0, 1473650.0, 1473716.0, 1473736.5, 1473856.5, 1473904.0, 1473968.5,
1474064.5, 1474145.5, 1474215.5, 1474306.0, 1478699.1666666667, 1474300.0, 1474297.5, 1474331.0,
1474427.0, 1478181.7222222222, 1474636.5, 1474712.5, 1474799.5, 1474886.0, 1475007.5, 1475113.5,
1475136.0, 1475270.5, 1475353.5, 1478636.574074074, 1475523.0, 1475587.0, 1475667.5, 1475739.5,
1475804.0, 1475873.0, 1475951.5, 1475951.5, 1476124.0, 1476208.0, 1476298.5, 1476350.5, 1476412.5,
1476537.5, 1476645.5, 1476775.5, 1476887.5, 1476964.5, 1477084.0, 1477204.5, 1477347.5, 1477428.0,
1477524.5, 1477683.5, 1477778.0, 1477920.5, 1478032.0, 1478172.5, 1478302.0, 1478429.5, 1478529.0,
1478629.0, 1478739.0, 1478864.0, 1478935.0, 1478966.5, 1479029.5, 1479157.0, 1479261.0, 1479349.0,
1479461.0, 1479580.5, 1479722.5, 1479852.5, 1479711.0, 1479846.0, 1479921.5, 1480072.5, 1480199.5,
1480342.5, 1480480.5, 1480563.5, 1480693.0, 1480823.5, 1481095.0, 1481274.5, 1481406.0, 1481556.0,
1481686.0, 1481795.0, 1481944.5, 1482025.0, 1482137.0, 1482255.5, 1482348.5, 1482429.0, 1482451.5,
1482451.5, 1482595.5, 1482715.0, 1482842.5, 1482938.5, 1483062.5, 1483124.5, 1483226.0, 1483307.5,
1483406.5, 1483552.5, 1483645.5, 1483807.0, 1483945.5, 1484032.0, 1484173.0, 1484302.0, 1484396.5,
1484527.5, 1484637.5, 1484766.0, 1484854.0, 1484978.0, 1485081.5, 1485140.0, 1485268.5, 1485368.5,
1485463.5, 1485579.5, 1485656.5, 1485746.0, 1485878.0, 1485970.0, 1486095.5, 1486191.5, 1486309.5,
1486397.0, 1486490.5, 1486634.5, 1486720.5, 1486786.0, 1486895.0, 1486223.5, 1486632.0, 1486922.5,
1487017.5, 1487300.0, 1487402.5, 1487482.5, 1487555.0, 1487645.0, 1487758.5, 1487870.0, 1488010.5,
1488090.0, 1488143.5, 1488251.0, 1488293.0, 1488364.0, 1488363.0, 1488363.0, 1488473.5, 1488482.0,
1488503.5, 1488563.5, 1488666.5, 1488738.5, 1488774.5, 1488811.0, 1488890.0, 1488940.0, 1489021.5,
1489114.5, 1489157.0, 1489268.5, 1489344.5, 1489417.5, 1489510.0, 1489570.5, 1489631.0, 1489741.5,
1489869.0, 1489947.5, 1490032.5, 1490118.0, 1490211.0, 1490276.5, 1490317.5, 1490405.0, 1490471.5,
1490591.0, 1490674.0, 1490765.5, 1490875.5, 1490954.5, 1491055.0, 1491143.5, 1491196.5, 1491286.0,
1491380.0, 1491462.5, 1491554.0, 1491631.0, 1491758.0, 1491826.5, 1491913.0, 1491988.5, 1492089.5,
1492211.5, 1492330.0, 1492415.5, 1492537.5, 1492654.5, 1492760.0, 1492854.0, 1492972.0, 1493093.5,
1493184.0, 1493258.0, 1493401.0, 1493401.0, 1493608.0, 1493703.0, 1493839.0, 1493969.0, 1494080.0,
1494183.0, 1494323.0, 1494457.0, 1494580.5, 1494729.5, 1494878.5, 1494977.5, 1495108.5, 1495255.5,
1495373.5, 1495482.0, 1495614.0, 1495737.5, 1495858.0, 1495973.0, 1496102.5, 1496223.5, 1496355.0,
1496425.5, 1496556.5, 1496654.5, 1496722.5, 1496824.0, 1496889.5, 1496950.5, 1497040.0, 1497132.0,
1497196.5, 1497192.5, 1497249.0, 1497298.5, 1497425.5, 1497488.5, 1497566.5, 1497638.0, 1497752.5,
1497862.0, 1497924.5, 1497971.0, 1498055.5, 1498158.0, 1498257.0, 1498364.5, 1498468.5, 1498540.0,
1498578.0, 1498647.0, 1498670.5, 1498650.0, 1498684.5, 1498729.5, 1498760.0, 1498789.0, 1498770.0,
1498770.0, 1498778.5, 1498786.5, 1498581.0, 1498605.5, 1498631.0, 1498610.5, 1498666.5, 1498701.0,
1498742.0, 1498764.0, 1498796.0, 1498798.0, 1498803.0, 1498829.0, 1498856.0, 1498874.0, 1498915.0,
1498950.0, 1498973.0, 1498977.5, 1498983.0, 1498970.5, 1498930.0, 1498890.5, 1498862.0, 1498835.5,
1498800.5, 1498749.0, 1498702.0, 1498637.5, 1498560.5, 1498527.0, 1498457.5, 1498427.0, 1498457.5,
1498454.5, 1498432.5, 1498416.5, 1498353.5, 1498286.5, 1498226.0, 1498162.0, 1498087.5, 1498088.0,
1498030.5, 1498009.5, 1497962.5, 1497886.5, 1497829.5, 1497726.5, 1497605.0, 1497518.0, 1497484.0,
1497384.5, 1497276.5, 1497193.0, 1497083.0, 1496884.0, 1496718.0, 1496718.0, 1496410.5, 1496202.5,
1496051.0, 1495970.5, 1495854.0, 1499001.5, 1499018.0, 1499247.0, 1499391.0, 1499376.0, 1499307.5,
1499193.5, 1499045.0, 1498932.0, 1498830.5, 1498795.5, 1498686.5, 1498532.5, 1498405.0, 1498260.5,
1498140.0, 1497980.0, 1497868.0, 1497720.0, 1497591.0, 1497451.0, 1497311.0, 1497100.0, 1496890.0,
1496650.5, 1496469.0, 1496253.0, 1496049.0, 1495931.0, 1495758.5, 1495607.0, 1495476.0, 1495300.0,
1495164.5, 1495033.5, 1494925.0, 1494777.5, 1494630.5, 1494477.0, 1494348.0, 1494220.0, 1494068.5,
1493902.0, 1493746.5, 1493588.0, 1493453.5, 1493296.5, 1493115.0, 1492972.0, 1492800.5, 1492632.5,
1492323.5, 1491261.5, 1490581.5, 1490581.5, 1489472.5, 1488888.5, 1488297.5, 1487825.0, 1487398.0,
1487264.5, 1487121.5, 1486999.5, 1486911.5, 1486786.0, 1486692.0, 1486542.5, 1486385.5, 1486271.0,
1486136.5, 1486020.5, 1485890.5, 1485778.0, 1485665.0, 1485536.0, 1485426.5, 1485298.5, 1485120.0,
1484999.0, 1484877.5, 1484716.0, 1484598.5, 1484437.5, 1484263.5, 1484049.0, 1483879.5, 1483654.0,
1483405.5, 1483234.0, 1483098.5, 1482960.0, 1482846.5, 1482746.0, 1482637.0, 1482519.0, 1482396.0,
1482205.0, 1481980.5, 1481831.5, 1481698.0, 1481591.0, 1481462.5, 1481343.5, 1481272.5, 1481175.5,
1481076.5, 1480975.0, 1480851.5, 1480762.0, 1480686.5, 1480578.5]
y_dataList = dataList[0:1440]
x = []
for i in range(1, 1441):
# x0List=[i]
x.append(i)
y = []
for i in y_dataList:
# y0List=[i]
y.append(i)
n=16
calculate_x=x
result=ax_bfit(x,y,calculate_x,n)
print(result[0])
print(result[1])