bugGNU Octave - Bugs: bug #58534, [octave forge] (symbolic) Expand...

 
 

bug #58534: [octave forge] (symbolic) Expand on Trigonometric Expression doesn't change it

Submitted by:  None
Submitted on:  Tue 09 Jun 2020 05:46:04 PM UTC  
 
Category:  Octave Forge Package Severity:  3 - Normal
Priority:  5 - Normal Item Group:  Matlab Compatibility
Status:  Confirmed Assigned to:  None
Originator Name:  Originator Email:  -email is unavailable-
Open/Closed:  Open Release:  dev
Operating System:  GNU/Linux

Add a New Comment (Rich Markup)
   

You are not logged in

Please log in, so followups can be emailed to you.

 

Wed 10 Jun 2020 12:05:15 AM UTC, comment #1: 

Confirmed, adding this feature should probably be made dependent on adding support for the 'ArithmeticOnly' option in the 'expand' function.

Mike Miller <mtmiller>
Project Administrator
Tue 09 Jun 2020 05:46:04 PM UTC, original submission:  

in Python:
`

>>> import sympy as sym
>>> x,y=sym.symbols("x y")
>>> sym.expand(sym.cos(x + y), trig=True)

-sin(x)*sin(y) + cos(x)*cos(y)
`

in Matlab:
`

>>> syms t
>>> expand([sin(2*t), cos(2*t)])

ans = [ 2*cos(t)*sin(t), 2*cos(t)^2 - 1]
`

in Octave:
`

>>> syms t
>>> expand([sin(2*t), cos(2*t)])

ans = (sym) [sin(2⋅t)  cos(2⋅t)]  (1×2 matrix)
`

It seems Octave is not passing `trig=True` in expand function in Python. The correction of this issue should be simple then.

Anonymous

 

(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 siko1056 (Updated the item)
  • -email is unavailable- added by None (Submitted the item)
  •  

    Do you think this task is very important?
    If so, you can add your encouragement to it.
    This task has 0 encouragements so far.

    Only project members can vote.

     

     

     

    Follow 4 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2020-06-10 mtmiller Item GroupIncorrect Result => Matlab Compatibility
        StatusNone => Confirmed
        Release5.2.0 => dev
    2020-06-09 siko1056 SummaryExpand on Trigonometric Expression doesn't change it => [octave forge] (symbolic) Expand on Trigonometric Expression doesn't change it

    Back to the top


    Powered by Savane 3.5