comparison scripts/ode/private/runge_kutta_45_dorpri.m @ 20586:b7ac1e94266e

maint: Further clean up of functions in ode/private dir. * AbsRel_Norm.m, fuzzy_compare.m, integrate_adaptive.m, integrate_const.m, integrate_n_steps.m, ode_struct_value_check.m, odepkg_event_handle.m, odepkg_structure_check.m, runge_kutta_45_dorpri.m: Place latest copyright first in file. Use two spaces before beginning single-line comment. Use parentheses around variable to be tested in switch stmt. Use space between function name and opening parenthesis.
author Rik <rik@octave.org>
date Mon, 05 Oct 2015 12:03:16 -0700
parents eb9e2d187ed2
children a22d8a2eb0e5
comparison
equal deleted inserted replaced
20585:45151de7423f 20586:b7ac1e94266e
1 ## Copyright (C) 2015, Carlo de Falco
1 ## Copyright (C) 2013, Roberto Porcu' <roberto.porcu@polimi.it> 2 ## Copyright (C) 2013, Roberto Porcu' <roberto.porcu@polimi.it>
2 ## Copyright (C) 2015, Carlo de Falco
3 ## 3 ##
4 ## This file is part of Octave. 4 ## This file is part of Octave.
5 ## 5 ##
6 ## Octave is free software; you can redistribute it and/or modify it 6 ## Octave is free software; you can redistribute it and/or modify it
7 ## under the terms of the GNU General Public License as published by 7 ## under the terms of the GNU General Public License as published by
78 s = t + dt * b; 78 s = t + dt * b;
79 cc = dt * c; 79 cc = dt * c;
80 aa = dt * a; 80 aa = dt * a;
81 k = zeros (rows (x), 7); 81 k = zeros (rows (x), 7);
82 82
83 if (nargin >= 5) # options are passed 83 if (nargin >= 5) # options are passed
84 args = varargin{1}.vfunarguments; 84 args = varargin{1}.vfunarguments;
85 if (nargin >= 6) # both the options and the k values are passed 85 if (nargin >= 6) # both the options and the k values are passed
86 k(:,1) = varargin{2}(:,end); # FSAL property 86 k(:,1) = varargin{2}(:,end); # FSAL property
87 else 87 else
88 k(:,1) = feval (f, t, x, args{:}); 88 k(:,1) = feval (f, t, x, args{:});
89 endif 89 endif
90 else 90 else
91 args = {}; 91 args = {};