sympy / sympy

Compare 484dddd ... +51 ... 36c2e2a

Coverage Reach
polys/polytools.py polys/domains/domain.py polys/domains/pythonrational.py polys/domains/old_polynomialring.py polys/domains/expressiondomain.py polys/domains/modularinteger.py polys/domains/mpelements.py polys/domains/quotientring.py polys/domains/old_fractionfield.py polys/domains/polynomialring.py polys/domains/fractionfield.py polys/domains/algebraicfield.py polys/domains/realfield.py polys/domains/complexfield.py polys/domains/__init__.py polys/domains/finitefield.py polys/domains/ring.py polys/domains/gmpyintegerring.py polys/domains/gmpyrationalfield.py polys/domains/pythonintegerring.py polys/domains/pythonrationalfield.py polys/domains/field.py polys/domains/groundtypes.py polys/domains/integerring.py polys/domains/rationalfield.py polys/domains/compositedomain.py polys/domains/pythonfinitefield.py polys/domains/gmpyfinitefield.py polys/domains/characteristiczero.py polys/domains/simpledomain.py polys/domains/domainelement.py polys/rings.py polys/polyclasses.py polys/rootisolation.py polys/subresultants_qq_zz.py polys/ring_series.py polys/compatibility.py polys/agca/modules.py polys/agca/homomorphisms.py polys/agca/ideals.py polys/agca/extensions.py polys/agca/__init__.py polys/modulargcd.py polys/galoistools.py polys/factortools.py polys/euclidtools.py polys/polyroots.py polys/numberfields.py polys/densearith.py polys/rootoftools.py polys/densebasic.py polys/densetools.py polys/fields.py polys/polyoptions.py polys/groebnertools.py polys/polyutils.py polys/monomials.py polys/distributedmodules.py polys/sqfreetools.py polys/specialpolys.py polys/partfrac.py polys/constructor.py polys/orthopolys.py polys/polyfuncs.py polys/orderings.py polys/multivariate_resultants.py polys/polyerrors.py polys/polyquinticconst.py polys/fglmtools.py polys/heuristicgcd.py polys/__init__.py polys/dispersion.py polys/polymatrix.py polys/solvers.py polys/polyconfig.py polys/rationaltools.py integrals/rubi/constraints.py integrals/rubi/utility_function.py integrals/rubi/parsetools/parse.py integrals/rubi/parsetools/generate_tests.py integrals/rubi/parsetools/generate_rules.py integrals/rubi/rubi.py integrals/rubi/symbol.py integrals/meijerint.py integrals/manualintegrate.py integrals/transforms.py integrals/risch.py integrals/integrals.py integrals/prde.py integrals/intpoly.py integrals/heurisch.py integrals/rde.py integrals/rationaltools.py integrals/quadrature.py integrals/trigonometry.py integrals/deltafunctions.py integrals/meijerint_doc.py integrals/singularityfunctions.py integrals/__init__.py physics/quantum/spin.py physics/quantum/gate.py physics/quantum/cg.py physics/quantum/pauli.py physics/quantum/hilbert.py physics/quantum/qubit.py physics/quantum/state.py physics/quantum/sho1d.py physics/quantum/represent.py physics/quantum/identitysearch.py physics/quantum/operator.py physics/quantum/tensorproduct.py physics/quantum/circuitplot.py physics/quantum/matrixutils.py physics/quantum/circuitutils.py physics/quantum/cartesian.py physics/quantum/qexpr.py physics/quantum/operatorordering.py physics/quantum/qasm.py physics/quantum/commutator.py physics/quantum/boson.py physics/quantum/qft.py physics/quantum/shor.py physics/quantum/operatorset.py physics/quantum/qapply.py physics/quantum/fermion.py physics/quantum/density.py physics/quantum/grover.py physics/quantum/anticommutator.py physics/quantum/innerproduct.py physics/quantum/matrixcache.py physics/quantum/piab.py physics/quantum/__init__.py physics/quantum/constants.py physics/quantum/dagger.py physics/vector/vector.py physics/vector/frame.py physics/vector/functions.py physics/vector/dyadic.py physics/vector/printing.py physics/vector/point.py physics/vector/fieldfunctions.py physics/vector/__init__.py physics/mechanics/kane.py physics/mechanics/linearize.py physics/mechanics/functions.py physics/mechanics/lagrange.py physics/mechanics/system.py physics/mechanics/models.py physics/mechanics/rigidbody.py physics/mechanics/body.py physics/mechanics/particle.py physics/mechanics/__init__.py physics/units/definitions.py physics/units/dimensions.py physics/units/quantities.py physics/units/prefixes.py physics/units/util.py physics/units/systems/si.py physics/units/systems/mks.py physics/units/systems/mksa.py physics/units/systems/natural.py physics/units/systems/__init__.py physics/units/__init__.py physics/units/unitsystem.py physics/secondquant.py physics/continuum_mechanics/beam.py physics/continuum_mechanics/__init__.py physics/optics/utils.py physics/optics/gaussopt.py physics/optics/waves.py physics/optics/medium.py physics/optics/__init__.py physics/hep/gamma_matrices.py physics/wigner.py physics/paulialgebra.py physics/matrices.py physics/hydrogen.py physics/qho_1d.py physics/pring.py physics/sho.py physics/gaussopt.py physics/__init__.py core/numbers.py core/expr.py core/mul.py core/power.py core/function.py core/evalf.py core/exprtools.py core/basic.py core/add.py core/compatibility.py core/relational.py core/symbol.py core/operations.py core/facts.py core/logic.py core/sympify.py core/mod.py core/containers.py core/assumptions.py core/cache.py core/trace.py core/multidimensional.py core/decorators.py core/core.py core/singleton.py core/__init__.py core/evaluate.py core/rules.py core/backend.py core/coreerrors.py core/alphabets.py printing/pretty/pretty.py printing/pretty/stringpict.py printing/pretty/pretty_symbology.py printing/pretty/__init__.py printing/latex.py printing/mathml.py printing/str.py printing/fcode.py printing/pycode.py printing/ccode.py printing/codeprinter.py printing/octave.py printing/julia.py printing/llvmjitcode.py printing/glsl.py printing/rust.py printing/tableform.py printing/repr.py printing/theanocode.py printing/preview.py printing/rcode.py printing/mathematica.py printing/jscode.py printing/tensorflow.py printing/cxxcode.py printing/printer.py printing/dot.py printing/lambdarepr.py printing/precedence.py printing/python.py printing/__init__.py printing/conventions.py printing/tree.py printing/gtk.py printing/defaults.py functions/elementary/trigonometric.py functions/elementary/hyperbolic.py functions/elementary/piecewise.py functions/elementary/complexes.py functions/elementary/exponential.py functions/elementary/miscellaneous.py functions/elementary/integers.py functions/elementary/__init__.py functions/special/error_functions.py functions/special/bessel.py functions/special/hyper.py functions/special/gamma_functions.py functions/special/polynomials.py functions/special/zeta_functions.py functions/special/elliptic_integrals.py functions/special/delta_functions.py functions/special/bsplines.py functions/special/tensor_functions.py functions/special/spherical_harmonics.py functions/special/singularity_functions.py functions/special/mathieu_functions.py functions/special/beta_functions.py functions/special/__init__.py functions/combinatorial/numbers.py functions/combinatorial/factorials.py functions/combinatorial/__init__.py functions/__init__.py solvers/ode.py solvers/solvers.py solvers/diophantine.py solvers/solveset.py solvers/inequalities.py solvers/recurr.py solvers/pde.py solvers/bivariate.py solvers/polysys.py solvers/deutils.py solvers/decompogen.py solvers/__init__.py parsing/autolev/_antlr/autolevparser.py parsing/autolev/_antlr/autolevlexer.py parsing/autolev/_antlr/autolevlistener.py parsing/autolev/_listener_autolev_antlr.py parsing/autolev/test-examples/pydy-example-repo/chaos_pendulum.py parsing/autolev/test-examples/pydy-example-repo/non_min_pendulum.py parsing/autolev/test-examples/pydy-example-repo/double_pendulum.py parsing/autolev/test-examples/pydy-example-repo/mass_spring_damper.py parsing/autolev/test-examples/ruletest10.py parsing/autolev/test-examples/ruletest9.py parsing/autolev/test-examples/ruletest8.py parsing/autolev/test-examples/ruletest3.py parsing/autolev/test-examples/ruletest6.py parsing/autolev/test-examples/ruletest7.py parsing/autolev/test-examples/ruletest5.py parsing/autolev/test-examples/ruletest2.py parsing/autolev/test-examples/ruletest4.py parsing/autolev/test-examples/ruletest1.py parsing/autolev/test-examples/ruletest11.py parsing/autolev/test-examples/ruletest12.py parsing/autolev/_parse_autolev_antlr.py parsing/autolev/__init__.py parsing/latex/_antlr/latexparser.py parsing/latex/_antlr/latexlexer.py parsing/latex/_parse_latex_antlr.py parsing/latex/_build_latex_antlr.py parsing/latex/__init__.py parsing/latex/errors.py parsing/sympy_parser.py parsing/mathematica.py parsing/fortran/fortran_parser.py parsing/fortran/__init__.py parsing/sym_expr.py parsing/ast_parser.py parsing/maxima.py combinatorics/perm_groups.py combinatorics/permutations.py combinatorics/fp_groups.py combinatorics/free_groups.py combinatorics/coset_table.py combinatorics/tensor_can.py combinatorics/homomorphisms.py combinatorics/rewritingsystem.py combinatorics/partitions.py combinatorics/pc_groups.py combinatorics/generators.py combinatorics/util.py combinatorics/subsets.py combinatorics/prufer.py combinatorics/testutil.py combinatorics/named_groups.py combinatorics/polyhedron.py combinatorics/graycode.py combinatorics/group_constructs.py combinatorics/rewritingsystem_fsm.py combinatorics/__init__.py matrices/expressions/matexpr.py matrices/expressions/blockmatrix.py matrices/expressions/matmul.py matrices/expressions/kronecker.py matrices/expressions/hadamard.py matrices/expressions/diagonal.py matrices/expressions/matpow.py matrices/expressions/applyfunc.py matrices/expressions/matadd.py matrices/expressions/slice.py matrices/expressions/trace.py matrices/expressions/inverse.py matrices/expressions/transpose.py matrices/expressions/factorizations.py matrices/expressions/determinant.py matrices/expressions/adjoint.py matrices/expressions/dotproduct.py matrices/expressions/funcmatrix.py matrices/expressions/fourier.py matrices/expressions/__init__.py matrices/matrices.py matrices/common.py matrices/sparse.py matrices/dense.py matrices/densesolve.py matrices/sparsetools.py matrices/immutable.py matrices/normalforms.py matrices/densetools.py matrices/densearith.py matrices/__init__.py simplify/hyperexpand.py simplify/fu.py simplify/simplify.py simplify/trigsimp.py simplify/radsimp.py simplify/sqrtdenest.py simplify/powsimp.py simplify/cse_main.py simplify/gammasimp.py simplify/epathtools.py simplify/ratsimp.py simplify/combsimp.py simplify/cse_opts.py simplify/traversaltools.py simplify/__init__.py simplify/hyperexpand_doc.py utilities/runtests.py utilities/codegen.py utilities/iterables.py utilities/_compilation/compilation.py utilities/_compilation/util.py utilities/_compilation/runners.py utilities/_compilation/availability.py utilities/_compilation/__init__.py utilities/autowrap.py utilities/lambdify.py utilities/enumerative.py utilities/misc.py utilities/benchmarking.py utilities/pytest.py utilities/decorator.py utilities/matchpy_connector.py utilities/randtest.py utilities/timeutils.py utilities/memoization.py utilities/exceptions.py utilities/tmpfiles.py utilities/mathml/__init__.py utilities/source.py utilities/pkgdata.py utilities/magic.py utilities/__init__.py stats/crv_types.py stats/rv.py stats/stochastic_process_types.py stats/crv.py stats/frv.py stats/joint_rv_types.py stats/drv.py stats/joint_rv.py stats/symbolic_probability.py stats/drv_types.py stats/frv_types.py stats/random_matrix_models.py stats/rv_interface.py stats/error_prop.py stats/__init__.py stats/stochastic_process.py stats/random_matrix.py tensor/tensor.py tensor/array/ndim_array.py tensor/array/arrayop.py tensor/array/sparse_ndim_array.py tensor/array/array_comprehension.py tensor/array/dense_ndim_array.py tensor/array/mutable_ndim_array.py tensor/array/__init__.py tensor/indexed.py tensor/index_methods.py tensor/toperators.py tensor/functions.py tensor/__init__.py geometry/polygon.py geometry/line.py geometry/ellipse.py geometry/point.py geometry/plane.py geometry/util.py geometry/entity.py geometry/parabola.py geometry/curve.py geometry/__init__.py geometry/exceptions.py ntheory/factor_.py ntheory/residue_ntheory.py ntheory/generate.py ntheory/primetest.py ntheory/continued_fraction.py ntheory/partitions_.py ntheory/multinomial.py ntheory/modular.py ntheory/egyptian_fraction.py ntheory/bbp_pi.py ntheory/__init__.py series/formal.py series/sequences.py series/gruntz.py series/order.py series/fourier.py series/limits.py series/limitseq.py series/series_class.py series/approximants.py series/residues.py series/acceleration.py series/__init__.py series/kauers.py series/aseries.py series/series.py sets/sets.py sets/handlers/intersection.py sets/handlers/functions.py sets/handlers/union.py sets/handlers/power.py sets/handlers/mul.py sets/handlers/add.py sets/fancysets.py sets/ordinals.py sets/conditionset.py sets/setexpr.py sets/contains.py sets/__init__.py assumptions/handlers/matrices.py assumptions/handlers/sets.py assumptions/handlers/order.py assumptions/handlers/ntheory.py assumptions/handlers/common.py assumptions/handlers/calculus.py assumptions/handlers/__init__.py assumptions/ask.py assumptions/cnf.py assumptions/refine.py assumptions/sathandlers.py assumptions/satask.py assumptions/assume.py assumptions/ask_generated.py assumptions/__init__.py codegen/array_utils.py codegen/ast.py codegen/fnodes.py codegen/cfunctions.py codegen/approximations.py codegen/rewriting.py codegen/algorithms.py codegen/cnodes.py codegen/futils.py codegen/matrix_nodes.py codegen/pyutils.py codegen/cxxnodes.py codegen/cutils.py codegen/__init__.py holonomic/holonomic.py holonomic/recurrence.py holonomic/numerical.py holonomic/linearsolver.py holonomic/holonomicerrors.py holonomic/__init__.py plotting/plot.py plotting/intervalmath/interval_arithmetic.py plotting/intervalmath/lib_interval.py plotting/intervalmath/__init__.py plotting/experimental_lambdify.py plotting/plot_implicit.py plotting/textplot.py plotting/__init__.py logic/boolalg.py logic/algorithms/dpll2.py logic/algorithms/dpll.py logic/inference.py logic/utilities/dimacs.py logic/utilities/__init__.py logic/__init__.py vector/coordsysrect.py vector/vector.py vector/basisdependent.py vector/functions.py vector/operators.py vector/dyadic.py vector/orienters.py vector/point.py vector/scalar.py vector/deloperator.py vector/__init__.py concrete/summations.py concrete/expr_with_limits.py concrete/guess.py concrete/products.py concrete/delta.py concrete/gosper.py concrete/expr_with_intlimits.py concrete/__init__.py categories/diagram_drawing.py categories/baseclasses.py categories/__init__.py liealgebras/weyl_group.py liealgebras/type_e.py liealgebras/type_d.py liealgebras/type_b.py liealgebras/type_c.py liealgebras/type_f.py liealgebras/type_a.py liealgebras/root_system.py liealgebras/cartan_type.py liealgebras/type_g.py liealgebras/cartan_matrix.py liealgebras/dynkin_diagram.py liealgebras/__init__.py calculus/util.py calculus/finite_diff.py calculus/singularities.py calculus/euler.py calculus/__init__.py crypto/crypto.py crypto/__init__.py diffgeom/diffgeom.py diffgeom/rn.py diffgeom/__init__.py interactive/printing.py interactive/session.py interactive/ipythonprinting.py interactive/__init__.py strategies/branch/core.py strategies/branch/traverse.py strategies/branch/tools.py strategies/branch/__init__.py strategies/core.py strategies/rl.py strategies/traverse.py strategies/tree.py strategies/tools.py strategies/util.py strategies/__init__.py discrete/transforms.py discrete/convolutions.py discrete/recurrences.py discrete/__init__.py multipledispatch/dispatcher.py multipledispatch/utils.py multipledispatch/conflict.py multipledispatch/core.py multipledispatch/__init__.py algebras/quaternion.py algebras/__init__.py unify/core.py unify/usympy.py unify/rewrite.py unify/__init__.py external/importtools.py external/__init__.py __init__.py abc.py sandbox/indexed_integrals.py deprecated/class_registry.py deprecated/__init__.py this.py galgebra.py release.py

No flags found

Use flags to group coverage reports by test type, project and/or folders.
Then setup custom commit statuses and notifications for each flag.

e.g., #unittest #integration

#production #enterprise

#frontend #backend

Learn more about Codecov Flags here.

Showing 15 of 37 files from the diff.

@@ -0,0 +1,2 @@
Loading
1 +
2 +
"""Used for translating Fortran source code into a SymPy expression. """

@@ -150,6 +150,7 @@
Loading
150 150
    year, years, tropical_year,
151 151
    G, gravitational_constant,
152 152
    c, speed_of_light,
153 +
    elementary_charge,
153 154
    Z0,
154 155
    hbar,
155 156
    planck,
@@ -224,9 +225,9 @@
Loading
224 225
225 226
    >>> from sympy.physics import units as u
226 227
    >>> u.find_unit('charge')
227 -
    ['C', 'coulomb', 'coulombs', 'planck_charge']
228 +
    ['C', 'coulomb', 'coulombs', 'planck_charge', 'elementary_charge']
228 229
    >>> u.find_unit(u.charge)
229 -
    ['C', 'coulomb', 'coulombs', 'planck_charge']
230 +
    ['C', 'coulomb', 'coulombs', 'planck_charge', 'elementary_charge']
230 231
    >>> u.find_unit("ampere")
231 232
    ['ampere', 'amperes']
232 233
    >>> u.find_unit('volt')

@@ -855,7 +855,7 @@
Loading
855 855
        return 1/sec(arg)
856 856
857 857
    def _eval_rewrite_as_csc(self, arg, **kwargs):
858 -
        return 1 / sec(arg)._eval_rewrite_as_csc(arg)
858 +
        return 1 / sec(arg).rewrite(csc)
859 859
860 860
    def _eval_conjugate(self):
861 861
        return self.func(self.args[0].conjugate())
@@ -1178,13 +1178,13 @@
Loading
1178 1178
        return 1/cot(arg)
1179 1179
1180 1180
    def _eval_rewrite_as_sec(self, arg, **kwargs):
1181 -
        sin_in_sec_form = sin(arg)._eval_rewrite_as_sec(arg)
1182 -
        cos_in_sec_form = cos(arg)._eval_rewrite_as_sec(arg)
1181 +
        sin_in_sec_form = sin(arg).rewrite(sec)
1182 +
        cos_in_sec_form = cos(arg).rewrite(sec)
1183 1183
        return sin_in_sec_form / cos_in_sec_form
1184 1184
1185 1185
    def _eval_rewrite_as_csc(self, arg, **kwargs):
1186 -
        sin_in_csc_form = sin(arg)._eval_rewrite_as_csc(arg)
1187 -
        cos_in_csc_form = cos(arg)._eval_rewrite_as_csc(arg)
1186 +
        sin_in_csc_form = sin(arg).rewrite(csc)
1187 +
        cos_in_csc_form = cos(arg).rewrite(csc)
1188 1188
        return sin_in_csc_form / cos_in_csc_form
1189 1189
1190 1190
    def _eval_rewrite_as_pow(self, arg, **kwargs):
@@ -1442,13 +1442,13 @@
Loading
1442 1442
        return 1/tan(arg)
1443 1443
1444 1444
    def _eval_rewrite_as_sec(self, arg, **kwargs):
1445 -
        cos_in_sec_form = cos(arg)._eval_rewrite_as_sec(arg)
1446 -
        sin_in_sec_form = sin(arg)._eval_rewrite_as_sec(arg)
1445 +
        cos_in_sec_form = cos(arg).rewrite(sec)
1446 +
        sin_in_sec_form = sin(arg).rewrite(sec)
1447 1447
        return cos_in_sec_form / sin_in_sec_form
1448 1448
1449 1449
    def _eval_rewrite_as_csc(self, arg, **kwargs):
1450 -
        cos_in_csc_form = cos(arg)._eval_rewrite_as_csc(arg)
1451 -
        sin_in_csc_form = sin(arg)._eval_rewrite_as_csc(arg)
1450 +
        cos_in_csc_form = cos(arg).rewrite(csc)
1451 +
        sin_in_csc_form = sin(arg).rewrite(csc)
1452 1452
        return cos_in_csc_form / sin_in_csc_form
1453 1453
1454 1454
    def _eval_rewrite_as_pow(self, arg, **kwargs):
@@ -1686,10 +1686,10 @@
Loading
1686 1686
        return sin(arg)/(cos(arg)*sin(arg))
1687 1687
1688 1688
    def _eval_rewrite_as_sin(self, arg, **kwargs):
1689 -
        return (1 / cos(arg)._eval_rewrite_as_sin(arg))
1689 +
        return (1 / cos(arg).rewrite(sin))
1690 1690
1691 1691
    def _eval_rewrite_as_tan(self, arg, **kwargs):
1692 -
        return (1 / cos(arg)._eval_rewrite_as_tan(arg))
1692 +
        return (1 / cos(arg).rewrite(tan))
1693 1693
1694 1694
    def _eval_rewrite_as_csc(self, arg, **kwargs):
1695 1695
        return csc(pi / 2 - arg, evaluate=False)
@@ -1767,13 +1767,13 @@
Loading
1767 1767
        return (1 + cot_half**2)/(2*cot_half)
1768 1768
1769 1769
    def _eval_rewrite_as_cos(self, arg, **kwargs):
1770 -
        return (1 / sin(arg)._eval_rewrite_as_cos(arg))
1770 +
        return 1 / sin(arg).rewrite(cos)
1771 1771
1772 1772
    def _eval_rewrite_as_sec(self, arg, **kwargs):
1773 1773
        return sec(pi / 2 - arg, evaluate=False)
1774 1774
1775 1775
    def _eval_rewrite_as_tan(self, arg, **kwargs):
1776 -
        return (1 / sin(arg)._eval_rewrite_as_tan(arg))
1776 +
        return (1 / sin(arg).rewrite(tan))
1777 1777
1778 1778
    def fdiff(self, argindex=1):
1779 1779
        if argindex == 1:

@@ -251,7 +251,7 @@
Loading
251 251
from sympy.logic.boolalg import (BooleanAtom, And, Not, BooleanTrue,
252 252
                                BooleanFalse)
253 253
from sympy.functions import cos, exp, im, log, re, sin, tan, sqrt, \
254 -
    atan2, conjugate, Piecewise
254 +
    atan2, conjugate, Piecewise, besselj, bessely
255 255
from sympy.functions.combinatorial.factorials import factorial
256 256
from sympy.integrals.integrals import Integral, integrate
257 257
from sympy.matrices import wronskian, Matrix, eye, zeros
@@ -262,7 +262,7 @@
Loading
262 262
from sympy.series import Order
263 263
from sympy.series.series import series
264 264
from sympy.simplify import collect, logcombine, powsimp, separatevars, \
265 -
    simplify, trigsimp, posify, cse
265 +
    simplify, trigsimp, posify, cse, besselsimp
266 266
from sympy.simplify.powsimp import powdenest
267 267
from sympy.simplify.radsimp import collect_const
268 268
from sympy.solvers import solve
@@ -2432,6 +2432,7 @@
Loading
2432 2432
2433 2433
            if sol.lhs == func:
2434 2434
                s = sub_func_doit(ode_diff, func, sol.rhs)
2435 +
                s = besselsimp(s)
2435 2436
            else:
2436 2437
                testnum += 1
2437 2438
                continue

@@ -64,7 +64,7 @@
Loading
64 64
from sympy import SYMPY_DEBUG
65 65
from sympy.core import (S, Dummy, symbols, sympify, Tuple, expand, I, pi, Mul,
66 66
    EulerGamma, oo, zoo, expand_func, Add, nan, Expr)
67 -
from sympy.core.compatibility import default_sort_key, range
67 +
from sympy.core.compatibility import default_sort_key, range, reduce
68 68
from sympy.core.mod import Mod
69 69
from sympy.functions import (exp, sqrt, root, log, lowergamma, cos,
70 70
        besseli, gamma, uppergamma, expint, erf, sin, besselj, Ei, Ci, Si, Shi,
@@ -735,7 +735,7 @@
Loading
735 735
736 736
    @property
737 737
    def closed_form(self):
738 -
        return (self.C*self.B)[0]
738 +
        return reduce(lambda s,m: s+m[0]*m[1], zip(self.C, self.B), S.Zero)
739 739
740 740
    def find_instantiations(self, func):
741 741
        """
@@ -899,7 +899,7 @@
Loading
899 899
900 900
    @property
901 901
    def closed_form(self):
902 -
        return (self.C*self.B)[0]
902 +
        return reduce(lambda s,m: s+m[0]*m[1], zip(self.C, self.B), S.Zero)
903 903
904 904
    def try_instantiate(self, func):
905 905
        """
@@ -1982,8 +1982,8 @@
Loading
1982 1982
1983 1983
        if premult == 1:
1984 1984
            C = C.applyfunc(make_simp(z0))
1985 -
        r = C*f.B.subs(f.z, z0)*premult
1986 -
        res = r[0].subs(z0, z)
1985 +
        r = reduce(lambda s,m: s+m[0]*m[1], zip(C, f.B.subs(f.z, z0)), S.Zero)*premult
1986 +
        res = r.subs(z0, z)
1987 1987
        if rewrite:
1988 1988
            res = res.rewrite(rewrite)
1989 1989
        return res

Click to load this diff.
Loading diff...

Click to load this diff.
Loading diff...

Click to load this diff.
Loading diff...

Click to load this diff.
Loading diff...

Click to load this diff.
Loading diff...

Click to load this diff.
Loading diff...

Click to load this diff.
Loading diff...

Click to load this diff.
Loading diff...

Click to load this diff.
Loading diff...

Click to load this diff.
Loading diff...

Learn more Showing 217 files with coverage changes found.

Changes in sympy/combinatorics/perm_groups.py
-30
-1
+31
Loading file...
Changes in sympy/utilities/runtests.py
-10
-3
+13
Loading file...
Changes in sympy/tensor/indexed.py
-2
+1
+1
Loading file...
Changes in sympy/stats/rv.py
-1
+1
Loading file...
Changes in sympy/logic/boolalg.py
-1
+1
Loading file...
Changes in sympy/functions/combinatorial/factorials.py
-1
+1
Loading file...
Changes in sympy/combinatorics/permutations.py
-1
-1
+2
Loading file...
Changes in sympy/solvers/solveset.py
-2
-1
+3
Loading file...
Changes in sympy/stats/crv.py
-1
+1
Loading file...
Changes in sympy/solvers/pde.py
-1
+1
Loading file...
Changes in sympy/core/add.py
-2
+2
Loading file...
Changes in sympy/calculus/util.py
-1
-1
+2
Loading file...
Changes in sympy/matrices/matrices.py
-3
-3
+6
Loading file...
Changes in sympy/functions/combinatorial/numbers.py
-2
-1
+3
Loading file...
Changes in sympy/utilities/iterables.py
-4
+4
Loading file...
Changes in sympy/matrices/dense.py
-2
+2
Loading file...
Changes in sympy/core/mul.py
-1
-5
+6
Loading file...
Changes in sympy/core/sympify.py
-1
+1
Loading file...
Changes in sympy/matrices/expressions/matexpr.py
-1
-3
+4
Loading file...
Changes in sympy/core/relational.py
-1
-1
+2
Loading file...
Changes in sympy/core/exprtools.py
-8
+5
+3
Loading file...
Changes in sympy/functions/elementary/exponential.py
-2
-2
+4
Loading file...
Changes in sympy/functions/special/hyper.py
-3
+3
Loading file...
Changes in sympy/combinatorics/homomorphisms.py
-1
-1
+2
Loading file...
Changes in sympy/diffgeom/diffgeom.py
-3
+3
Loading file...
Changes in sympy/geometry/entity.py
-1
-1
+2
Loading file...
Changes in sympy/codegen/ast.py
-1
-3
+4
Loading file...
Changes in sympy/functions/elementary/trigonometric.py
-4
-13
+17
Loading file...
Changes in sympy/functions/special/zeta_functions.py
-1
-1
+2
Loading file...
Changes in sympy/concrete/summations.py
-6
+6
Loading file...
Changes in sympy/polys/domains/old_fractionfield.py
-3
+1
+2
Loading file...
Changes in sympy/codegen/fnodes.py
-1
-1
+2
Loading file...
Changes in sympy/core/evalf.py
-3
-7
+10
Loading file...
Changes in sympy/core/numbers.py
-7
-20
+27
Loading file...
Changes in sympy/functions/special/gamma_functions.py
-6
+6
Loading file...
Changes in sympy/functions/elementary/integers.py
-1
-2
+3
Loading file...
Changes in sympy/integrals/integrals.py
-11
+11
Loading file...
Changes in sympy/polys/polyerrors.py
-2
+2
Loading file...
Changes in sympy/core/function.py
-3
-18
+21
Loading file...
Changes in sympy/core/basic.py
-17
+13
+4
Loading file...
Changes in sympy/ntheory/primetest.py
-2
-3
+5
Loading file...
Changes in sympy/functions/special/error_functions.py
-20
+18
+2
Loading file...
Changes in sympy/core/power.py
-6
-21
+27
Loading file...
Changes in sympy/solvers/solvers.py
-16
-26
+42
Loading file...
Changes in sympy/core/trace.py
-1
-1
+2
Loading file...
Changes in sympy/polys/domains/algebraicfield.py
-2
+2
Loading file...
Changes in sympy/plotting/plot.py
-22
+21
+1
Loading file...
Changes in sympy/series/gruntz.py
-4
-7
+11
Loading file...
Changes in sympy/polys/domains/polynomialring.py
-3
+3
Loading file...
Changes in sympy/polys/domains/fractionfield.py
-3
+3
Loading file...
Changes in sympy/core/decorators.py
-2
+2
Loading file...
Changes in sympy/polys/constructor.py
-3
-3
+6
Loading file...
Changes in sympy/polys/domains/expressiondomain.py
-1
-4
+5
Loading file...
Changes in sympy/utilities/misc.py
-13
+8
+5
Loading file...
Changes in sympy/polys/domains/integerring.py
-1
+1
Loading file...
Changes in sympy/solvers/bivariate.py
-2
-7
+9
Loading file...
Changes in sympy/core/expr.py
-11
-64
+75
Loading file...
Changes in sympy/polys/polymatrix.py
-2
+2
Loading file...
Changes in sympy/simplify/gammasimp.py
-7
-9
+16
Loading file...
Changes in sympy/polys/domains/rationalfield.py
-2
+1
+1
Loading file...
Changes in sympy/polys/domains/realfield.py
-1
-3
+4
Loading file...
Changes in sympy/solvers/decompogen.py
-1
-1
+2
Loading file...
Changes in sympy/sandbox/indexed_integrals.py
-2
+2
Loading file...
Changes in sympy/polys/domains/mpelements.py
-8
+8
Loading file...
Changes in sympy/polys/domains/pythonrational.py
-3
-10
+13
Loading file...
Changes in sympy/series/residues.py
-1
-1
+2
Loading file...
Changes in sympy/polys/domains/field.py
-3
+3
Loading file...
Changes in sympy/simplify/powsimp.py
-8
-18
+26
Loading file...
Changes in sympy/polys/factortools.py
-17
-39
+56
Loading file...
Changes in sympy/polys/polyutils.py
-9
-14
+23
Loading file...
Changes in sympy/printing/preview.py
-24
+14
+10
Loading file...
Changes in sympy/polys/domains/finitefield.py
-6
+6
Loading file...
Changes in sympy/polys/domains/pythonrationalfield.py
-1
-3
+4
Loading file...
Changes in sympy/printing/cxxcode.py
-9
+7
+2
Loading file...
Changes in sympy/polys/domains/pythonintegerring.py
-1
-4
+5
Loading file...
Changes in sympy/printing/printer.py
-2
-5
+7
Loading file...
Changes in sympy/polys/domains/domain.py
-8
-27
+35
Loading file...
Changes in sympy/assumptions/refine.py
-7
-8
+15
Loading file...
Changes in sympy/physics/quantum/tensorproduct.py
-21
+21
Loading file...
Changes in sympy/physics/quantum/state.py
-2
-25
+27
Loading file...
Changes in sympy/series/limits.py
-6
-11
+11
Loading file...
Changes in sympy/simplify/hyperexpand.py
-6
-138
+144
Loading file...
Changes in sympy/assumptions/handlers/ntheory.py
-5
-12
+17
Loading file...
Changes in sympy/sets/contains.py
-1
-1
+2
Loading file...
Changes in sympy/printing/codeprinter.py
-6
-31
+37
Loading file...
Changes in sympy/printing/pretty/stringpict.py
-8
-22
+30
Loading file...
Changes in sympy/functions/special/spherical_harmonics.py
-1
-9
+10
Loading file...
Changes in sympy/solvers/deutils.py
-4
-7
+11
Loading file...
Changes in sympy/solvers/inequalities.py
-21
-42
+63
Loading file...
Changes in sympy/polys/polyroots.py
-12
-72
+84
Loading file...
Changes in sympy/printing/pycode.py
-2
-53
+55
Loading file...
Changes in sympy/polys/rootoftools.py
-22
-64
+86
Loading file...
Changes in sympy/printing/tensorflow.py
-20
+17
+3
Loading file...
Changes in sympy/printing/lambdarepr.py
-10
+10
Loading file...
Changes in sympy/simplify/cse_main.py
-15
-33
+48
Loading file...
Changes in sympy/polys/solvers.py
-6
+6
Loading file...
Changes in sympy/polys/domains/compositedomain.py
-1
-1
+2
Loading file...
Changes in sympy/printing/pretty/pretty_symbology.py
-8
-30
+38
Loading file...
Changes in sympy/polys/orthopolys.py
-13
-13
+26
Loading file...
Changes in sympy/polys/densetools.py
-20
-53
+73
Loading file...
Changes in sympy/polys/domains/complexfield.py
-12
+12
Loading file...
Changes in sympy/printing/precedence.py
-4
-7
+11
Loading file...
Changes in sympy/polys/polyoptions.py
-18
-55
+73
Loading file...
Changes in sympy/polys/euclidtools.py
-11
-115
+126
Loading file...
Changes in sympy/polys/rootisolation.py
-40
-154
+194
Loading file...
Changes in sympy/polys/polyclasses.py
-213
+202
+11
Loading file...
Changes in sympy/printing/str.py
-19
-91
+110
Loading file...
Changes in sympy/polys/compatibility.py
-197
+192
+5
Loading file...
Changes in sympy/polys/densearith.py
-5
-116
+121
Loading file...
Changes in sympy/printing/conventions.py
-5
-4
+9
Loading file...
Changes in sympy/sets/sets.py
-19
-165
+184
Loading file...
Changes in sympy/plotting/plot_implicit.py
-46
+37
+9
Loading file...
Changes in sympy/physics/vector/point.py
-3
-27
+30
Loading file...
Changes in sympy/polys/rings.py
-25
-303
+328
Loading file...
Changes in sympy/sets/handlers/intersection.py
-16
-54
+70
Loading file...
Changes in sympy/physics/vector/vector.py
-77
+76
+1
Loading file...
Changes in sympy/polys/densebasic.py
-16
-130
+146
Loading file...
Changes in sympy/simplify/radsimp.py
-18
-107
+125
Loading file...
Changes in sympy/assumptions/handlers/sets.py
-13
-77
+90
Loading file...
Changes in sympy/polys/fields.py
-115
+110
+5
Loading file...
Changes in sympy/physics/units/dimensions.py
-6
-72
+78
Loading file...
Changes in sympy/printing/ccode.py
-1
-99
+100
Loading file...
Changes in sympy/series/order.py
-25
-45
+70
Loading file...
Changes in sympy/printing/rust.py
-7
-43
+50
Loading file...
Changes in sympy/printing/gtk.py
-3
+3
Loading file...
Changes in sympy/sets/setexpr.py
-1
-14
+15
Loading file...
Changes in sympy/utilities/pkgdata.py
-5
+5
Loading file...
Changes in sympy/printing/fcode.py
-121
+120
+1
Loading file...
Changes in sympy/assumptions/handlers/order.py
-22
-41
+63
Loading file...
Changes in sympy/sets/handlers/union.py
-21
+20
+1
Loading file...
Changes in sympy/series/sequences.py
-18
-112
+130
Loading file...
Changes in sympy/simplify/simplify.py
-20
-239
+259
Loading file...
Changes in sympy/polys/domains/modularinteger.py
-41
+40
+1
Loading file...
Changes in sympy/simplify/fu.py
-13
-270
+283
Loading file...
Changes in sympy/polys/polyconfig.py
-9
+9
Loading file...
Changes in sympy/polys/domains/ring.py
-2
-15
+17
Loading file...
Changes in sympy/printing/julia.py
-10
-77
+87
Loading file...
Changes in sympy/polys/polytools.py
-61
-703
+764
Loading file...
Changes in sympy/physics/units/prefixes.py
-4
-29
+33
Loading file...
Changes in sympy/polys/orderings.py
-1
-43
+44
Loading file...
Changes in sympy/series/series_class.py
-22
+17
+5
Loading file...
Changes in sympy/printing/repr.py
-5
-54
+59
Loading file...
Changes in sympy/polys/domains/old_polynomialring.py
-1
-59
+60
Loading file...
Changes in sympy/printing/octave.py
-12
-97
+109
Loading file...
Changes in sympy/plotting/experimental_lambdify.py
-113
+91
+22
Loading file...
Changes in sympy/utilities/mathml/__init__.py
-8
+8
Loading file...
Changes in sympy/physics/wigner.py
-4
-53
+57
Loading file...
Changes in sympy/polys/agca/ideals.py
-58
+52
+6
Loading file...
Changes in sympy/sets/conditionset.py
-5
-35
+40
Loading file...
Changes in sympy/physics/units/quantities.py
-7
-52
+59
Loading file...
Changes in sympy/polys/sqfreetools.py
-7
-66
+73
Loading file...
Changes in sympy/polys/monomials.py
-6
-104
+110
Loading file...
Changes in sympy/polys/numberfields.py
-9
-253
+262
Loading file...
Changes in sympy/series/fourier.py
-6
-103
+109
Loading file...
Changes in sympy/physics/quantum/spin.py
-9
-396
+405
Loading file...
Changes in sympy/printing/tree.py
-16
+16
Loading file...
Changes in sympy/polys/polyfuncs.py
-10
-55
+65
Loading file...
Changes in sympy/polys/groebnertools.py
-176
+165
+11
Loading file...
Changes in sympy/solvers/ode.py
-1643
+1558
+85
Loading file...
Changes in sympy/polys/domains/quotientring.py
-49
+46
+3
Loading file...
Changes in sympy/polys/agca/extensions.py
-51
+42
+9
Loading file...
Changes in sympy/sets/ordinals.py
-88
+80
+8
Loading file...
Changes in sympy/assumptions/handlers/calculus.py
-7
-21
+28
Loading file...
Changes in sympy/physics/vector/functions.py
-108
+107
+1
Loading file...
Changes in sympy/physics/vector/dyadic.py
-111
+101
+10
Loading file...
Changes in sympy/sets/handlers/functions.py
-6
-77
+83
Loading file...
Changes in sympy/physics/units/util.py
-5
-39
+44
Loading file...
Changes in sympy/physics/vector/frame.py
-15
-135
+150
Loading file...
Changes in sympy/series/limitseq.py
-2
-55
+57
Loading file...
Changes in sympy/polys/galoistools.py
-19
-344
+363
Loading file...
Changes in sympy/simplify/trigsimp.py
-281
+262
+19
Loading file...
Changes in sympy/sets/fancysets.py
-28
-242
+270
Loading file...
Changes in sympy/plotting/intervalmath/interval_arithmetic.py
-169
+152
+17
Loading file...
Changes in sympy/series/formal.py
-10
-368
+378
Loading file...
Changes in sympy/physics/secondquant.py
-573
+570
+3
Loading file...
Changes in sympy/polys/ring_series.py
-561
+540
+21
Loading file...
Changes in sympy/polys/partfrac.py
-2
-93
+95
Loading file...
Changes in sympy/physics/paulialgebra.py
-47
+41
+6
Loading file...
Changes in sympy/physics/units/__init__.py
-20
+20
Loading file...
Changes in sympy/sets/handlers/add.py
-20
+20
Loading file...
Changes in sympy/printing/python.py
-34
+33
+1
Loading file...
Changes in sympy/polys/agca/modules.py
-267
+267
Loading file...
Changes in sympy/physics/vector/printing.py
-117
+106
+11
Loading file...
Changes in sympy/printing/mathematica.py
-79
+77
+2
Loading file...
Changes in sympy/printing/jscode.py
-76
+73
+3
Loading file...
Changes in sympy/simplify/sqrtdenest.py
-11
-205
+216
Loading file...
Changes in sympy/printing/glsl.py
-137
+126
+11
Loading file...
Changes in sympy/polys/agca/homomorphisms.py
-122
+122
Loading file...
Changes in sympy/printing/rcode.py
-101
+98
+3
Loading file...
Changes in sympy/printing/latex.py
-11
-1026
+1037
Loading file...
Changes in sympy/printing/dot.py
-44
+44
Loading file...
Changes in sympy/physics/matrices.py
-34
+34
Loading file...
Changes in sympy/physics/units/unitsystem.py
-22
+22
Loading file...
Changes in sympy/printing/pretty/pretty.py
-4
-1174
+1178
Loading file...
Changes in sympy/polys/specialpolys.py
-117
+116
+1
Loading file...
Changes in sympy/polys/subresultants_qq_zz.py
-835
+726
+109
Loading file...
Changes in sympy/polys/multivariate_resultants.py
-86
+85
+1
Loading file...
Changes in sympy/simplify/ratsimp.py
-82
+80
+2
Loading file...
Changes in sympy/simplify/traversaltools.py
-11
+11
Loading file...
Changes in sympy/printing/mathml.py
-1270
+1245
+25
Loading file...
Changes in sympy/series/approximants.py
-38
+38
Loading file...
Changes in sympy/physics/pring.py
-10
+9
+1
Loading file...
Changes in sympy/solvers/diophantine.py
-1069
+1065
+4
Loading file...
Changes in sympy/physics/hydrogen.py
-34
+31
+3
Loading file...
Changes in sympy/physics/vector/fieldfunctions.py
-63
+63
Loading file...
Changes in sympy/printing/tableform.py
-156
+153
+3
Loading file...
Changes in sympy/polys/dispersion.py
-43
+40
+3
Loading file...
Changes in sympy/polys/fglmtools.py
-1
-70
+71
Loading file...
Changes in sympy/simplify/epathtools.py
-131
+129
+2
Loading file...
Changes in sympy/sets/handlers/power.py
-62
+59
+3
Loading file...
Changes in sympy/sets/handlers/mul.py
-32
+32
Loading file...
Changes in sympy/polys/distributedmodules.py
-204
+198
+6
Loading file...
Changes in sympy/polys/modulargcd.py
-790
+778
+12
Loading file...
Changes in sympy/series/acceleration.py
-17
+17
Loading file...
Changes in sympy/physics/qho_1d.py
-13
+13
Loading file...
Changes in sympy/series/kauers.py
-11
+11
Loading file...
Changes in sympy/physics/sho.py
-10
+10
Loading file...

53 Commits

+2
-24
+10
+16
+8
-3
-6
+17
-8
-15
-4
+11
Hiding 1 contexual commits
+68
+92
+8
-32
-868
-845
+6
-29
Hiding 1 contexual commits
+890
+846
-9
+53
-3
-3
+6
-22
+219
-53
-188
+22
+35694
-249
-35423
+2
-29011
+167
+28846
-2
-6697
+86
+6609
Hiding 2 contexual commits
+4
+12806
-16
-12786
+3 Files
+165
-12791
+10
+12946
Hiding 1 contexual commits
-3 Files
-165
+26
-4
-187
Hiding 2 contexual commits
+3 Files
+165
+13605
+46
-13486
+7271
-372
-6899
+1 Files
+44
-20834
+327
+20551
+28
-69
+11
+86
-54
-56
+4
-2
Hiding 1 contexual commits
+110
+124
-11
-3
Hiding 2 contexual commits
+1 Files
+350
+301
+21
+28
+21
+37
-4
-12
Hiding 1 contexual commits
-51
-34
+6
-23
+94
+75
-6
+25
+17
-17
+2
+32
Hiding 1 contexual commits
+2 Files
-165
-33
-20
-112
+473
+317
+34
+122
Hiding 1 contexual commits
+1 Files
+211
+175
+4
+32
Hiding 1 contexual commits
+272
+265
+12
-5
Hiding 4 contexual commits
+1 Files
+454
+497
+11
-54
Hiding 1 contexual commits
+153
+149
+1
+3
+3 Files
+1603
+2138
-105
-430
-12 Files
-3729
+17014
-314
-20429
Files Coverage
sympy +12.969% 74.670%
Project Totals (631 files) 74.670%
Loading