相关代码 |
|
Public NCOM, PCOM(50), XICOM(50) Sub LINMIN(P, XI, N, FRET) TOL = 0.0001 NCOM = N For J = 1 To N PCOM(J) = P(J) XICOM(J) = XI(J) Next J AX = 0# XX = 1# Call MNBRAK(AX, XX, BX, FA, FX, FB) FRET = BRENT(AX, XX, BX, TOL, XMIN) For J = 1 To N XI(J) = XMIN * XI(J) P(J) = P(J) + XI(J) Next J End Sub
相关资源 |
|