|
From: | Bill Greene |
Subject: | Re: Working on bvp4c |
Date: | Sat, 27 Aug 2016 14:11:52 -0400 |
Maybe I've misunderstood this but from page 6, f_{i - 1/2} is given by odefun
evaluated at the point (*):
[ (x_{i - 1} + h/2) , 0.5*(y_{i - 1} + y_{i}) - (h / 8) * (f_{ i } - f_{ i -
1}) ]
However,in order to evalue f at this point requires us to know how to
evaluate the components of f at x = (x_{i - 1} + h/2), which we do not know.
Take for example demo 1 given here:
http://octave.sourceforge.net/odepkg/function/bvp4c.html
f = @(t,u) [ u(2); -abs(u(1)) ];
Seeing as u is a function of t, in order to evaluate f at (*) do we not need
to know u as a function of t (e.g. the solution) in order to evaluate it?
Or, seeing as in this example, f does not explicitly depend on t, do we just
evaluate the u components of f at the second component of the point (*) -
effectively treating f = f(u)?
I hope this makes sense. My point essentially comes down to my
interpretation of evaluating f at the point (*). I would think that in order
to do this we must know the solution, u(t), in order to evaluate u at point
(x_{i - 1} + h/2).
Bill Greene-3 wrote
> Not sure what you mean by "_expression_". Implementation-wise,
> f(...) means call the user's odefun with the arguments in ().
> So that is what the code does with the last two equations of page 6.
> Similarly, g(...) means call the user's bcfun.
>
> Bill
>
> On Mon, Aug 22, 2016 at 12:33 PM, lakerluke <
> luke_purnell@
> >
> wrote:
>
>> The last equation on page 6 gives f_{i - 1/2} in terms of f evaluated at
>> x_{i
>> - 1} + h/2 .
>>
>> Does this not mean that we need an _expression_ for f evaluated at this mid
>> way point between mesh-values?
>>
>>
>>
>> --
>> View this message in context: http://octave.1599824.n4.
>> nabble.com/Working-on-bvp4c-tp4677540p4679405.html
>> Sent from the Octave - Maintainers mailing list archive at Nabble.com.
>>
>>
--
View this message in context: http://octave.1599824.n4.nabble.com/Working-on-bvp4c- tp4677540p4679432.html
Sent from the Octave - Maintainers mailing list archive at Nabble.com.
[Prev in Thread] | Current Thread | [Next in Thread] |