Release Notes for 1.3 - sympy/sympy GitHub Wiki
These are the release notes for SymPy 1.3. You can also find release notes for previous versions.
SymPy 1.3 was released on September 14, 2018.
This version of SymPy has been tested on Python 2.7, 3.4, 3.5, 3.6, 3.7 and PyPy. See our Python version support policy for more information on when we plan to drop support for older Python versions.
Install SymPy with
pip install -U sympy
or if you use Anaconda
conda install sympy
Starting with this release, the release notes are written by pull request authors in the pull request description and automatically compiled using a bot.
Backwards compatibility breaks and deprecations
-
Symbols no longer automatically convert to functions when called, e.g., if
f = Symbol('f')
,f(t)
is now aTypeError
. To create a function, usef = Function('f')
orf = symbols('f', cls=Function)
. -
.integrate()
has been renamed to.compute_expectation()
insympy.stats
in order to avoid confusion with the integrals module. -
classof()
anda2idx()
insympy.matrices.matrices
have been deprecated in favor of the same functions insympy.matrices.common
(#15109). -
The
source()
function has been deprecated. Useinspect.getsource
or??
in IPython instead. (#14905).
Major Changes
-
codegen
-
CodePrinter
and subclasses can generate code for unknown Functions if the new optionallow_unknown_functions=True
is passed. (#15085 by @bjodah, #15215 by @cbm755) -
Octave/Matlab printing supports more functions and has better test coverage. (#14821 by @cbm755)
-
made Octave printing of the two-argument zeta function unsupported, as it differs from SymPy's definition (#14962 by @ethankward)
-
-
combinatorics
-
CosetTable.coset_table_max_limit
is no longer overwritten whenmax_cosets
keyword is used (#15167 by @valglad) -
It is now possible to get the injection of the group returned by subgroup into the parent
FpGroup
(#14968 by @RavicharanN)
-
-
core
-
Singleton classes with the same name that are defined twice now properly re-register on the
S
object. (#15163 by @asmeurer) -
Fix an issue with undefined functions defined with a custom
eval
(likeFunction('f', eval=...)
). (#15174 by @asmeurer) -
Symbol
f
no longer automatically becomes a Function inf(x)
. (#9064 by @cbm755 and @skirpichev) -
fixed a bug in the simplification of inverses, such as
simplify(log(exp(x)), inverse=True)
. (#15033 by @normalhuman) -
fixed a wrong result with certain multivariable derivatives like
f(x, y).diff(y, y, x, y, x)
(#15008 by @asmeurer) -
fixed a bug about commutativity of Mul with AccumBounds (#14990 by @maurogaravello)
-
-
discrete
-
added
mobius_transform
andinverse_mobius_transform
methods todiscrete.transforms
(#14853 by @sidhantnagpal) -
added
convolution_subset
method andsubset
keyword inconvolution
method (#14878 by @sidhantnagpal) -
added
covering_product
method in convolution submodule (#14928 by @sidhantnagpal) -
added
intersecting_product
method in convolution submodule (#14954 by @sidhantnagpal) -
rename the submodules
discrete.convolution
anddiscrete.recurrence
todiscrete.convolutions
anddiscrete.recurrences
, respectively. (#14969 by @sidhantnagpal)
-
-
functions
-
UndefinedFunctions which coincidentally match known functions no longer evaluate numerically (#15095 by @cbm755)
-
Piecewise with no arguments not allowed anymore (#15010 by @ramvenkat98)
-
Piecewise evaluated with no matching conditions gives nan (#15010 by @ramvenkat98)
- fixed a bug with evalf for RisingFactorial and FallingFactorial (#14955 by @ramvenkat98)
-
-
integrals
-
added method
principal_value
to classIntegral
to calculate Cauchy's principal value along with tests. (#15036 by @avishrivastava11) -
fix pretty printing of integral transforms
noconds=False
(#14695 by @asmeurer and @smichr) -
inverse Laplace transform of exp is shifted Dirac delta (#14965 by @cbm755)
-
fixed a issue related to a wrong result in integrate (#14991 by @maurogaravello)
-
Made rubi stable. (#14756 by @ashishkg0022)
-
Added missing utility functions (#14756 by @ashishkg0022)
-
Added large test set (#14756 by @ashishkg0022)
-
Fix missing factor of
2*pi*I
in inverse Laplace and Mellin transforms. (#14963 by @cbm755)
-
-
interactive
-
matrices
- added implementation of
IndexError
for non int-indices inrow_insert()
andcol_insert()
(#15155 by @avishrivastava11)
-
Fixed
simplify
flag not working ineigenvals()
(#15125 by @sylee957) -
derivative of trace of matrix now returns the correct result. (#15128 by @Upabjojr)
-
Added missing square matrix check in eigenvals() (#15119 by @sylee957)
-
unused imports are removed from matrices.py to clean up the code. (#15107 by @czgdp1807)
-
Accelerated eigenvalue calculation for triangular matrices (#15030 by @ethankward)
-
fixed
np.array(Matrix(...), dtype=float)
(#14944 by @ethankward)
- added implementation of
-
parsing
- Added an example output verification test for the autolev parser. (#15165 by @moorepants and @NikhilPappu)
-
Made changes to _listener_autolev_antlr in parsing.autolev. Revamped the processVariables function quite a bit. Changed the mass function and the pydy output code a bit followed by some minor changes. Made some minor changes to other files in parsing.autolev. (#15006 by @NikhilPappu)
-
Also changed some code in tests/test_autolev.py (Added commented test code for the GitLab repo tests and changed zip to zip_longest which is more correct. (#15006 by @NikhilPappu)
- Added a submodule autolev which can be used to parse Autolev code to SymPy code. (#14758 by @NikhilPappu)
-
physics.continuum_mechanics
-
Beam3D
can now solve for reaction loads (#15068 by @jashan498) -
Beams with variable second moment(or elastic modulus) can now be solved (#15029 by @jashan498)
-
Return type of slope and deflection methods for composite beams changed to
Add
in form ofSingularityFunction
terms, instead of a Piecewise. (#15052 by @jashan498) -
added methods to plot shear force, bending moment, slope and deflection. (#14967 by @jashan498)
-
slope and deflection methods now return integral constants along with expression if insufficient boundary conditions to solve those constants are passed. (#14446 by @jashan498)
-
added more Beam examples. (#14453 by @jashan498)
-
-
physics.mechanics
-
Added a .subs(kindiffdict()) in the forcing full method of kane.py. This is required for the pydy numerical code to work in some cases. This doesn't break any tests. (#15006 by @NikhilPappu)
-
Added a test for the center_of_mass() function in test_functions.py. (#15013 by @NikhilPappu)
-
Added a center of mass function in functions.py which returns the position vector of the center of mass of a system of bodies.
(#14758 by @NikhilPappu)
-
Added a corner case check in kane.py (Passes dummy symbols to q_ind and kd_eqs if not passed in to prevent errors which shouldn't occur).
(#14758 by @NikhilPappu)
-
-
physics.units
-
checking for consistency of terms is no longer done at instantiation (#14923 by @smichr)
-
check_dimensions
was added to units/util.py to check expressions for dimensional consistency (#14923 by @smichr) -
__radd__
and__rmul__
are defined for Dimensions (#14923 by @smichr) -
quantity_simplify
now reduces all Quantities in an Expr with the same Dimension to the same internally canonical Quantity (#14923 by @smichr)
-
-
physics.vector
- Added a test for _w_diff_dcm in test_frame.py. (#15013 by @NikhilPappu)
- Changed _w_diff_dcm in frame.py to get the correct results. (#14758 by @NikhilPappu)
-
polys
-
added clear_cache to CRoofOf (#15175 by @jksuom and @smichr)
-
added
min_degree
andmax_degree
arguments toitermonomials
(#15020 by @czgdp1807)
-
-
printing
-
Keyword arguments to the
dotprint
function no longer affect consecutive calls. (#15163 by @asmeurer) -
Add
StrPrinter
,print_ccode
,print_fcode
,print_glsl
,print_jscode
,print_latex
,print_mathml
,print_rcode
, andpycode
tofrom sympy import *
. (#15162 by @asmeurer) -
fix latex printing of Indexed results #15059 (#15151 by @ayushmankoul)
-
Fixed a bug when latex printing unevaluated pow with 1 as the base (#15060 by @ethankward)
-
The
dotprint()
function is now included withfrom sympy import *
. (#15096 by @sylee957) -
replaced **kwargs with explicit variable name (#15080 by @yatna)
-
Improved the
latex()
function docstring format. (#15040 by @moorepants)
-
-
simplify
-
solvers
- added transcendental equation solver and exponential solver for
solveset
(#14736 by @smichr and @Yathartha22) - added a new solver for logarithmic equations as part of
_transolve
insolvers.solveset
(#14792 by @smichr and @Yathartha22)
- added transcendental equation solver and exponential solver for
-
stats
-
renamed .integrate( ) to .compute_expectation( ) in sympy.stats in order to avoid confusion with the integrals module. (#15176 by @Upabjojr)
-
Allow calculation of expectation of indexed joint random symbols (#15079 by @akash9712)
-
Add
JointRV
to allow user to create Joint random variables (#14989 by @akash9712) -
Add
MarginalDistribution
,CompoundDistribution
(#14989 by @akash9712) -
Ability to handle compound distributions (#14989 by @akash9712)
-
-
tensor
-
Added naming for IndexedBase and Indexed types (#15004 by @ArifAhmed1995)
-
Avoid passing kw_args to Expr during IndexedBase object creation (#15004 by @ArifAhmed1995)
-
-
utilities
-
lambdify uses scipy automatically if available (#14992 by @ramvenkat98)
-
fixed a bug with lambdify on curly bracket symbols (#15011 by @bPhysicist)
-
Correctly wrap rationals in
lambdify(modules='mpmath')
. This preventsnsolve
from losing precision when the expression has rationals. (#14976 by @asmeurer)
-
other
-
Added a guide pydy_for_autolev_users.rst in the mechanics part of the documentation. (#15077 by @NikhilPappu)
-
Added the Gotchas section in autolev_parser.rst in the mechanics part of the documentation. (#15066 by @NikhilPappu)
-
Removed .interp and .tokens from parsing/latex. (#15104 by @NikhilPappu)
-
Updated setup.py and Manifest.in for the Autolev and LaTeX parser files. (#15104 by @NikhilPappu)
-
Removed test_antlr_generation() from test_latex.py. (#15104 by @NikhilPappu)
-
Added the issues and future improvements sections to autolev_parser.rst in the mechanics part of the documentation. (#15067 by @NikhilPappu)
-
Added documentation for the Autolev Parser under Mechanics. Added the Introduction and Usage sections. (#15046 by @NikhilPappu)
-
Authors
The following people contributed at least one patch to this release (names are given in alphabetical order by last name). A total of 41 people contributed to this release. People with a * by their names contributed a patch for the first time for this release; 10 people contributed for the first time for this release.
Thanks to everyone who contributed to this release!
- Arif Ahmed
- Bilal Ahmed*
- Francesco Bonazzi
- Raoul Bourquin
- Ondřej Čertík
- Ravi charan
- czgdp1807*
- Björn Dahlgren
- Dimas Abreu Archanjo Dutra*
- eward
- Isuru Fernando
- Mauro Garavello
- Ashish Kumar Gaurav
- Valeriia Gladkova
- Thomas Hisch
- Miro Hrončok*
- Yathartha Joshi
- Sudarshan Kamath*
- Sergey B Kirpichev
- Ayushman Koul*
- Leonid Kovalev
- Amit Kumar
- S.Y. Lee*
- Jared Lumpe
- Colin B. Macdonald
- Aaron Meurer
- Jason Moore
- Sidhant Nagpal
- Abdullah Javed Nesar
- Nikhil Pappu
- Arihant Parsoya
- ramvenkat98*
- Avi Shrivastava*
- Gagandeep Singh
- Jashanpreet Singh
- Chris Smith
- Kalevi Suominen
- Wes Turner
- Akash Vaish
- Yatna Verma*
- Ethan Ward