Mercurial > hg > octave-lyh
annotate scripts/polynomial/polyder.m @ 11100:cdf940db26a0
provide mxIsFunctionHandle MEX interface function
author | John W. Eaton <jwe@octave.org> |
---|---|
date | Sat, 16 Oct 2010 13:27:18 -0400 |
parents | a8ce6bdecce5 |
children | c776f063fefe |
rev | line source |
---|---|
7017 | 1 ## Copyright (C) 1995, 1996, 1997, 2000, 2005, 2006, 2007 John W. Eaton |
2313 | 2 ## |
3 ## This file is part of Octave. | |
4 ## | |
5 ## Octave is free software; you can redistribute it and/or modify it | |
6 ## under the terms of the GNU General Public License as published by | |
7016 | 7 ## the Free Software Foundation; either version 3 of the License, or (at |
8 ## your option) any later version. | |
2313 | 9 ## |
10 ## Octave is distributed in the hope that it will be useful, but | |
11 ## WITHOUT ANY WARRANTY; without even the implied warranty of | |
12 ## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU | |
13 ## General Public License for more details. | |
14 ## | |
15 ## You should have received a copy of the GNU General Public License | |
7016 | 16 ## along with Octave; see the file COPYING. If not, see |
17 ## <http://www.gnu.org/licenses/>. | |
1597 | 18 |
3458 | 19 ## -*- texinfo -*- |
10687
a8ce6bdecce5
Improve documentation strings.
Rik <octave@nomad.inbox5.com>
parents:
7017
diff
changeset
|
20 ## @deftypefn {Function File} {} polyder (@var{c}) |
5216 | 21 ## @deftypefnx {Function File} {[@var{q}] =} polyder (@var{b}, @var{a}) |
22 ## @deftypefnx {Function File} {[@var{q}, @var{r}] =} polyder (@var{b}, @var{a}) | |
3446 | 23 ## See polyderiv. |
3458 | 24 ## @end deftypefn |
1597 | 25 |
5216 | 26 ## Author: John W. Eaton |
2314 | 27 |
5216 | 28 function [q, r] = polyder (p, a) |
1597 | 29 |
30 if (nargin == 1) | |
31 q = polyderiv (p); | |
5217 | 32 elseif (nargin == 2) |
33 if (nargout == 2) | |
34 [q, r] = polyderiv (p, a); | |
5216 | 35 else |
5217 | 36 q = polyderiv (p, a); |
5216 | 37 endif |
1597 | 38 else |
6046 | 39 print_usage (); |
1597 | 40 endif |
41 | |
42 endfunction |