Opened 4 years ago
Last modified 8 months ago
#26337 new enhancement
Extraneous parentheses in latex(e^-x)
Reported by: | Samuel Lelièvre | Owned by: | |
---|---|---|---|
Priority: | minor | Milestone: | sage-pending |
Component: | symbolics | Keywords: | latex, symbolic expression |
Cc: | Dave Morris, Ralf Stephan, Samuel Lelièvre | Merged in: | |
Authors: | Reviewers: | ||
Report Upstream: | N/A | Work issues: | |
Branch: | Commit: | ||
Dependencies: | Stopgaps: |
Description
Reported by Andy Howell on sage-devel.
Current:
sage: h = e^-x sage: latex(h) e^{\left(-x\right)}
Wish:
sage: h = e^-x sage: latex(h) e^{-x}
See further analysis and links in the 2018-09 sage-devel discussion.
Change History (4)
comment:1 Changed 4 years ago by
Milestone: | sage-8.4 → sage-pending |
---|
comment:2 Changed 4 years ago by
comment:3 Changed 19 months ago by
Cc: | Dave Morris added |
---|
comment:4 Changed 8 months ago by
Likewise:
sage: a = exp(2*x) sage: a # good: we need those parentheses e^(2*x) sage: latex(a) # should skip parentheses e^{\left(2 \, x\right)}
and
sage: b = exp(x/2) sage: b # good: we need those parentheses e^(1/2*x) sage: latex(b) # should skip parentheses e^{\left(\frac{1}{2} \, x\right)}
Note: See
TracTickets for help on using
tickets.
Not sure whether the fix belongs in Sage or GiNaC or Pynac. Any insight anyone?