Mathematica 9 is now available
Student Support Forum
Student Support Forum: 'FindMinimum NDSolve conflict' topicStudent Support Forum > General > "FindMinimum <-> NDSolve conflict"

Next Comment >Help | Reply To Topic
Author Comment/Response
09/10/12 2:46pm


could sb. help me with the following problem:
The goal is to solve a differential equation (DE) of a model system with NDSolve and apply the results to my measurements. The DE depends on a few parameters which I wanna optimize by reducing the deviation "theory <-> data" with FindMinimum. The task can be simplified/reduced to:

testFct[b_] := NDSolve[{y''[t] == 10, y[0] == b, y'[0] == 0}, y, {t, 0, 10}];

FindMinimum[Evaluate[y[t] /.testFct[b]], {t, 0, 10}, {b, 0}]

My problem is now the following error message:

NDSolve::ndinnt: Initial condition b is not a number or a rectangular array of numbers. >>

Somehow there seems to be a problem with the handover of the variables between the NDSolve and FindMinimum. Is that in general not possible in Mathematica? Are the different approaches to solve my problem?

I am very grateful for help!

URL: ,

Subject (listing for 'FindMinimum <-> NDSolve conflict')
Author Date Posted
FindMinimum <-> NDSolve conflict Enrico 09/10/12 2:46pm
Re: FindMinimum <-> NDSolve conflict Bill Simpson 09/15/12 2:53pm
Re: Re: FindMinimum <-> NDSolve conflict Enrico 09/16/12 05:03am
Re: Re: Re: FindMinimum <-> NDSolve conflict Bill Simpson 09/17/12 1:17pm
Next Comment >Help | Reply To Topic