Re: FindMinimum Problem
- To: mathgroup at smc.vnet.net
- Subject: [mg44618] Re: FindMinimum Problem
- From: Jens-Peer Kuska <kuska at informatik.uni-leipzig.de>
- Date: Tue, 18 Nov 2003 06:41:47 -0500 (EST)
- Organization: Universitaet Leipzig
- References: <bpa1rv$19t$1@smc.vnet.net>
- Reply-to: kuska at informatik.uni-leipzig.de
- Sender: owner-wri-mathgroup at wolfram.com
Hi,
you ust make a function
foo[x_?NumericQ]:=x^2-a[0]*x/.NDSolve[{a'[z]==x*z,a[1]==1},a,{z,0,1}]
FindMinimum[foo[x],{x,-1,1}]
Regards
Jens
Jiang Xiao wrote:
>
> Hi, all,
> recently I am dealing with a problem as following, findminimum(over x)
> of a function f[a[0],x], where a[z] satisfies a differential equation
> a'[z]=x*z say. The code is like:
> FindMinimum[x^2-a[0]*x/.NDSolve[{a'[z]==x*z,a[1]==1},a,{z,0,1}],{x,-1,1}]
>
> the problem is that I can do it in mathematica 4.2, but can't in mathematica
> 5.0 now. Do anybody where is the problem?
>
> thanks,
>
> Jiang