octave-bug-tracker
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Octave-bug-tracker] [bug #50192] ode15s does not work when the initial


From: Rik
Subject: [Octave-bug-tracker] [bug #50192] ode15s does not work when the initial value is a row
Date: Wed, 8 Feb 2017 11:42:17 -0500 (EST)
User-agent: Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:43.0) Gecko/20100101 Firefox/43.0

Follow-up Comment #5, bug #50192 (project octave):

This time the patch uploaded correctly.  I have a question, would it not be
better to check that the initial conditions are vectors, and then force them
to be column vectors?  This is what is doen in ode23.m as shown below:


  if (! isnumeric (init) || ! isvector (init))
    error ("Octave:invalid-input-arg",
           "ode23: INIT must be a numeric vector");
  endif
  init = init(:);


The current patch changes private/check_default_input.m


-    n = numel (feval (fun, trange(1), y0, yp0));
+    n = numel (feval (fun, trange(1), y0(:), yp0(:)));


This will allow matrices through because they will be turned into column
vectors, when in fact the user has probably made some mistake by using a
matrix as input. 


    _______________________________________________________

Reply to this item at:

  <http://savannah.gnu.org/bugs/?50192>

_______________________________________________
  Message sent via/by Savannah
  http://savannah.gnu.org/




reply via email to

[Prev in Thread] Current Thread [Next in Thread]