?? d9r10.txt
字號:
Private Sub Command1_Click()
'PROGRAM D9R10
'Driver for routine MEDFIT
NPT = 100
SPREAD = 0.1
Dim X(100), Y(100), SIG(100)
IDUM& = -1984
For I = 1 To NPT
X(I) = 0.1 * I
Y(I) = -2# * X(I) + 1# + SPREAD * GASDEV(IDUM&)
SIG(I) = SPREAD
Next I
MWT = 1
Call FIT(X(), Y(), NPT, SIG(), MWT, A, B, SIGA, SIGB, CHI2, Q)
Print "According to routine FIT the result is:"
Print Tab(5)
Print "A = "; Format$(A, "#.0000"), "Uncertainty: ";
Print Format$(SIGA, "0.###0")
Print "B = "; Format$(B, "#.0000"), "Uncertainty: ";
Print Format$(SIGB, "0.###0")
Print Tab(5)
Print "Chi-squared: "; Format$(CHI2, "0.###0"); " for"; NPT; " points"
Print Tab(5)
Print "Goodness-of-fit: "; Format$(Q, "0.###0")
Print Tab(5)
Print "According to routine MEDFIT the result is:"
Print Tab(5)
Call MEDFIT(X(), Y(), NPT, A, B, ABDEV)
Print "A = "; Format$(A, "0.###0")
Print "B = "; Format$(B, "0.###0")
Print Tab(5)
Print "Absolute deviation (per data point): "; Format$(ABDEV, "0.###0")
Print Tab(5)
Print "(note: Gaussian spread is "; Format$(SPREAD, "0.#0"); ")"
End Sub
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -