自分もやってみようと思いpythonでコードを書いてやってみた。
いくつか注意点が ↓
- シミュレーションは15日間。タイムステップは0.001d(毎日1000ステップ)。
- 同化するデータ(あるパラメーターで走らせたモデルの解)は 最初の500ステップ(半日)の一つ飛ばし→250データポイント。
lsoda-- warning..internal t (=r1) and h (=r2) are
such that in the machine, t + h = t on the next step
(h = step size). solver will continue anyway
In above, R1 = .1482457577093E+06 R2 = .1149053549906E-10
lsoda-- at current t (=r1), mxstep (=i1) steps
taken on this call before reaching tout
In above message, I1 = 500
In above message, R1 = .1482457577093E+06
Excess work done on this call (perhaps wrong Dfun type).
Run with full_output = 1 to get quantitative information.
leastsqの限界なのか 。。。
↑例えば以下のパラメーターの場合:
p_data = [1.,1.,4./spd,-2./spd,-4./spd,-6./spd,2./spd,4./spd]
p_model = [1.,1.,4/spd,-2./spd,-4./spd,-6./spd,2./spd,4./spd]
三番目の4/spdというパラメーターの初期のguessを0.1までは下げることはできたが0またはそれ以下にするとさっきのエラー文が発生する。同様に、6番目の-6/spdは-5は大丈夫だが-4にするとダメ。
よくわからん。。。