[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: PDE question
From: |
Carlo de Falco |
Subject: |
Re: PDE question |
Date: |
Tue, 4 Aug 2009 01:27:26 +0200 |
On 3 Aug 2009, at 21:46, david wrote:
Thank you for your helpful info. I found odeset.m and ode45.m from
odepkg, but not pdeintrp.m, does anyone know where I can find
pdeintrp.m?
Thanks a lot!
"pdeintrp" is from the PDE toolbox, the octave-forge package
containing (mostly) the same functionalities (though with no attempt
whatsoever at implementing a compatible interface) as the PDE toolbox
is "bim".
There is no implementation of the "pdeintrp" function itself in 'bim',
as I considered it too trivial.
it would be easy to add it as follows (note that the copyright notice
and the doc string take more space than the function body itself):
------------------------------------------------------------------------
## Copyright (C) 2009 Carlo de Falco
##
## This program is free software; you can redistribute it and/or modify
## it under the terms of the GNU General Public License as published by
## the Free Software Foundation; either version 2 of the License, or
## (at your option) any later version.
##
## This program is distributed in the hope that it will be useful,
## but WITHOUT ANY WARRANTY; without even the implied warranty of
## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
## GNU General Public License for more details.
##
## You should have received a copy of the GNU General Public License
## along with Octave; see the file COPYING. If not, see
## <http://www.gnu.org/licenses/>.
## -*- texinfo -*-
## @deftypefn {Function File} address@hidden =} pdeintrp (@var{p}, @var{t},
@var{un})
## Compute the values @var{ut} of a function interpolated linearly at
triangle midpoints
## of a triangulation defined by @var{p}, @var{t} given the nodal
values @var{un}.
## @end deftypefn
## Author: Carlo de Falco <cdf _AT_ sourceforge.net>
## Created: 2009-08-04
function ut = pdeintrp (p, t, un)
ut = sum (un(t(1:3,:)),1)/3;
endfunction
-------------------------------------------------------------------------------
c.