bugGNU Octave - Bugs: bug #43311, symbolic: Wrong expected value in...

 
 

bug #43311: symbolic: Wrong expected value in symfsolve test

Submitter:  Rafael Laboissière <rlaboiss>
Submitted:  Sun 28 Sep 2014 12:07:32 AM UTC
   
 
Category:  Octave Package Severity:  3 - Normal
Priority:  5 - Normal Item Group:  Incorrect Result
Status:  Wont Fix Assigned to:  None
Originator Name:  Open/Closed:  * Closed
Release:  * dev Operating System:  * GNU/Linux
Fixed Release:  None Planned Release:  None
* Mandatory Fields

Add a New Comment Rich Markup
   

Sun 22 Feb 2015 06:29:37 AM UTC, comment #1: 

The new symbolic package does not have a symfsolve function, instead providing what looks like a Matlab compatible solve function operating on symbolic types. Closing this bug as won't fix since the symfsolve function is gone along with the old symbolic package.

Mike Miller <mtmiller>
Group Member
Sun 28 Sep 2014 12:07:32 AM UTC, original submission:  

For some reason that I do not really understand, the last test in file symfsolve.m is giving now (with Octave 3.8.2) a different result from what it used to give before, even though the solution that is found is fully valid.  This is perhaps due to recent changes in the fsolve function, which is in Octave core.  Here is what I obtain now:


octave:1> symbols
octave:2> x = sym ("x");
octave:3> y = sym ("y");
octave:4> f = x ^ 2 + 3 * x - 1;
octave:5> g = x * y - y ^ 2 + 3;
octave:6> assert (symfsolve ({f, g}, {y==1,x==2}), [1.89004; 0.30278]', 1e-5);
error: ASSERT errors for:  assert (symfsolve ({f, g}, {y == 1, x == 2}),[1.89004; 0.30278]',1e-5)

  Location  |  Observed  |  Expected  |  Reason
    (1)        -1.5873        1.89       Abs err 3.4773 exceeds tol 1e-05


The obvious fix is to change the test in inst/symfsolve.m to read:


%!assert (symfsolve ({f, g}, {y==1,x==2}), [-1.58727; 0.30278]', 1e-5);


Rafael Laboissière <rlaboiss>

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach Files:
   
   
Comment:
   

No files currently attached

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -email is unavailable- added by mtmiller (Posted a comment)
  • -email is unavailable- added by rlaboiss (Submitted the item)
  •  

    There are 0 votes so far. Votes easily highlight which items people would like to see resolved in priority, independently of the priority of the item set by tracker managers.

    Only group members can vote.

     

    Follow 2 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2015-02-22 mtmiller StatusNone Wont Fix
        Open/ClosedOpen Closed

    Back to the top

    Powered by Savane 3.13-758e.
    Corresponding source code