#11618: solve with solution_dict=True doesn't always return a list
-------------------------+--------------------------------------------------
   Reporter:  mhampton   |          Owner:  burcin              
       Type:  defect     |         Status:  new                 
   Priority:  major      |      Milestone:  sage-4.7.2          
  Component:  symbolics  |       Keywords:  solve, solution_dict
Work_issues:             |       Upstream:  N/A                 
   Reviewer:             |         Author:                      
     Merged:             |   Dependencies:                      
-------------------------+--------------------------------------------------

Comment(by leif):

 Yep:
 {{{
        * ``solution_dict`` - bool (default: False); if True or non-zero,
          return a list of dictionaries containing the solutions. If there
          are no solutions, return an empty list (rather than a list
          containing an empty dictionary). Likewise, if there's only a
          single solution, return a list containing one dictionary with
          that solution.
 }}}

 A doctest for a similar case got deleted by a reviewer, which still works
 though:
 {{{
 sage: solve([x+y==6, x-y==4], x, y, solution_dict=-1)
 [{y: 1, x: 5}]
 }}}
 And also the following works as expected:
 {{{
 sage: solve([x==0],x,solution_dict=True)
 [{x: 0}]
 }}}
 (Sage 4.7.1.{alpha2,rc0})

-- 
Ticket URL: <http://trac.sagemath.org/sage_trac/ticket/11618#comment:1>
Sage <http://www.sagemath.org>
Sage: Creating a Viable Open Source Alternative to Magma, Maple, Mathematica, 
and MATLAB

-- 
You received this message because you are subscribed to the Google Groups 
"sage-trac" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/sage-trac?hl=en.

Reply via email to