From 4c1c96d5e3cd8459c2a7364bbbdd5b33e01e3310 Mon Sep 17 00:00:00 2001 From: Erik De Bonte Date: Thu, 2 May 2024 12:23:41 -0700 Subject: [PATCH] black on sympy-stubs --- stubs/sympy-stubs/__init__.pyi | 903 +++++++++++- stubs/sympy-stubs/algebras/quaternion.pyi | 198 +-- stubs/sympy-stubs/assumptions/__init__.pyi | 15 +- stubs/sympy-stubs/assumptions/ask.pyi | 232 +--- .../sympy-stubs/assumptions/ask_generated.pyi | 8 +- stubs/sympy-stubs/assumptions/assume.pyi | 94 +- stubs/sympy-stubs/assumptions/cnf.pyi | 192 +-- stubs/sympy-stubs/assumptions/facts.pyi | 24 +- .../assumptions/handlers/__init__.pyi | 2 +- .../assumptions/handlers/calculus.pyi | 56 +- .../assumptions/handlers/common.pyi | 75 +- .../assumptions/handlers/matrices.pyi | 416 ++---- .../assumptions/handlers/ntheory.pyi | 100 +- .../assumptions/handlers/order.pyi | 176 +-- .../sympy-stubs/assumptions/handlers/sets.pyi | 276 +--- .../assumptions/predicates/common.pyi | 8 +- .../assumptions/predicates/matrices.pyi | 15 - .../assumptions/predicates/ntheory.pyi | 3 - .../assumptions/predicates/order.pyi | 7 - stubs/sympy-stubs/assumptions/refine.pyi | 35 +- .../assumptions/relation/__init__.pyi | 2 +- .../assumptions/relation/binrel.pyi | 44 +- .../assumptions/relation/equality.pyi | 81 +- stubs/sympy-stubs/assumptions/satask.pyi | 24 +- stubs/sympy-stubs/assumptions/sathandlers.pyi | 77 +- stubs/sympy-stubs/assumptions/wrapper.pyi | 21 +- stubs/sympy-stubs/calculus/__init__.pyi | 20 +- .../calculus/accumulationbounds.pyi | 92 +- stubs/sympy-stubs/calculus/euler.pyi | 5 +- stubs/sympy-stubs/calculus/finite_diff.pyi | 13 +- stubs/sympy-stubs/calculus/singularities.pyi | 29 +- stubs/sympy-stubs/calculus/util.pyi | 36 +- stubs/sympy-stubs/categories/__init__.pyi | 14 +- stubs/sympy-stubs/categories/baseclasses.pyi | 120 +- .../categories/diagram_drawing.pyi | 102 +- stubs/sympy-stubs/codegen/__init__.pyi | 16 +- stubs/sympy-stubs/codegen/ast.pyi | 227 +--- stubs/sympy-stubs/codegen/cfunctions.pyi | 76 +- stubs/sympy-stubs/codegen/cnodes.pyi | 20 +- stubs/sympy-stubs/codegen/fnodes.pyi | 64 +- stubs/sympy-stubs/codegen/pynodes.pyi | 6 +- .../sympy-stubs/combinatorics/coset_table.pyi | 138 +- stubs/sympy-stubs/combinatorics/fp_groups.pyi | 192 +-- .../sympy-stubs/combinatorics/free_groups.pyi | 277 +--- stubs/sympy-stubs/combinatorics/galois.pyi | 92 +- .../sympy-stubs/combinatorics/generators.pyi | 24 +- stubs/sympy-stubs/combinatorics/graycode.pyi | 57 +- .../combinatorics/group_constructs.pyi | 3 +- .../combinatorics/homomorphisms.pyi | 71 +- .../combinatorics/named_groups.pyi | 31 +- .../sympy-stubs/combinatorics/partitions.pyi | 107 +- stubs/sympy-stubs/combinatorics/pc_groups.pyi | 65 +- .../sympy-stubs/combinatorics/perm_groups.pyi | 437 ++---- .../combinatorics/permutations.pyi | 310 ++--- .../sympy-stubs/combinatorics/polyhedron.pyi | 43 +- stubs/sympy-stubs/combinatorics/prufer.pyi | 54 +- .../combinatorics/rewritingsystem.pyi | 34 +- .../combinatorics/rewritingsystem_fsm.pyi | 23 +- stubs/sympy-stubs/combinatorics/subsets.pyi | 97 +- .../sympy-stubs/combinatorics/tensor_can.pyi | 52 +- stubs/sympy-stubs/combinatorics/testutil.pyi | 7 +- stubs/sympy-stubs/concrete/__init__.pyi | 2 +- stubs/sympy-stubs/concrete/delta.pyi | 8 +- .../concrete/expr_with_intlimits.pyi | 27 +- .../sympy-stubs/concrete/expr_with_limits.pyi | 47 +- stubs/sympy-stubs/concrete/gosper.pyi | 12 +- stubs/sympy-stubs/concrete/products.pyi | 26 +- stubs/sympy-stubs/concrete/summations.pyi | 67 +- stubs/sympy-stubs/conftest.pyi | 31 +- stubs/sympy-stubs/core/__init__.pyi | 102 +- stubs/sympy-stubs/core/add.pyi | 73 +- stubs/sympy-stubs/core/assumptions.pyi | 40 +- stubs/sympy-stubs/core/basic.pyi | 203 +-- stubs/sympy-stubs/core/cache.pyi | 27 +- stubs/sympy-stubs/core/containers.pyi | 174 +-- stubs/sympy-stubs/core/core.pyi | 12 +- stubs/sympy-stubs/core/decorators.pyi | 29 +- stubs/sympy-stubs/core/evalf.pyi | 183 +-- stubs/sympy-stubs/core/expr.pyi | 539 +++----- stubs/sympy-stubs/core/exprtools.pyi | 166 +-- stubs/sympy-stubs/core/facts.pyi | 68 +- stubs/sympy-stubs/core/function.pyi | 310 ++--- stubs/sympy-stubs/core/kind.pyi | 65 +- stubs/sympy-stubs/core/logic.pyi | 85 +- stubs/sympy-stubs/core/mod.pyi | 6 +- stubs/sympy-stubs/core/mul.pyi | 77 +- stubs/sympy-stubs/core/multidimensional.pyi | 21 +- stubs/sympy-stubs/core/numbers.pyi | 1117 +++++---------- stubs/sympy-stubs/core/operations.pyi | 56 +- stubs/sympy-stubs/core/parameters.pyi | 18 +- stubs/sympy-stubs/core/power.pyi | 77 +- stubs/sympy-stubs/core/random.pyi | 16 +- stubs/sympy-stubs/core/relational.pyi | 187 +-- stubs/sympy-stubs/core/rules.pyi | 19 +- stubs/sympy-stubs/core/singleton.pyi | 24 +- stubs/sympy-stubs/core/sorting.pyi | 14 +- stubs/sympy-stubs/core/symbol.pyi | 104 +- stubs/sympy-stubs/core/sympify.pyi | 19 +- stubs/sympy-stubs/core/traversal.pyi | 42 +- stubs/sympy-stubs/crypto/crypto.pyi | 233 +--- stubs/sympy-stubs/diffgeom/__init__.pyi | 27 +- stubs/sympy-stubs/diffgeom/diffgeom.pyi | 450 ++---- stubs/sympy-stubs/discrete/__init__.pyi | 14 +- stubs/sympy-stubs/discrete/convolutions.pyi | 28 +- stubs/sympy-stubs/discrete/recurrences.pyi | 9 +- stubs/sympy-stubs/discrete/transforms.pyi | 32 +- stubs/sympy-stubs/external/importtools.pyi | 17 +- stubs/sympy-stubs/external/pythonmpq.pyi | 104 +- .../functions/combinatorial/factorials.pyi | 49 +- .../functions/combinatorial/numbers.pyi | 129 +- .../functions/elementary/complexes.pyi | 98 +- .../functions/elementary/exponential.pyi | 96 +- .../functions/elementary/hyperbolic.pyi | 221 +-- .../functions/elementary/miscellaneous.pyi | 53 +- .../functions/elementary/piecewise.pyi | 58 +- .../functions/elementary/trigonometric.pyi | 261 +--- .../sympy-stubs/functions/special/bessel.pyi | 127 +- .../functions/special/beta_functions.pyi | 31 +- .../functions/special/bsplines.pyi | 12 +- .../functions/special/delta_functions.pyi | 31 +- .../functions/special/elliptic_integrals.pyi | 37 +- .../functions/special/error_functions.pyi | 187 +-- .../functions/special/gamma_functions.pyi | 76 +- stubs/sympy-stubs/functions/special/hyper.pyi | 203 +-- .../functions/special/mathieu_functions.pyi | 38 +- .../functions/special/polynomials.pyi | 107 +- .../special/singularity_functions.pyi | 11 +- .../functions/special/spherical_harmonics.pyi | 23 +- .../functions/special/tensor_functions.pyi | 58 +- .../functions/special/zeta_functions.pyi | 39 +- stubs/sympy-stubs/geometry/curve.pyi | 54 +- stubs/sympy-stubs/geometry/ellipse.pyi | 221 +-- stubs/sympy-stubs/geometry/entity.pyi | 111 +- stubs/sympy-stubs/geometry/line.pyi | 268 +--- stubs/sympy-stubs/geometry/parabola.pyi | 62 +- stubs/sympy-stubs/geometry/plane.pyi | 100 +- stubs/sympy-stubs/geometry/point.pyi | 232 +--- stubs/sympy-stubs/geometry/polygon.pyi | 377 ++--- stubs/sympy-stubs/geometry/util.pyi | 52 +- stubs/sympy-stubs/holonomic/__init__.pyi | 12 +- stubs/sympy-stubs/holonomic/holonomic.pyi | 189 +-- stubs/sympy-stubs/holonomic/recurrence.pyi | 71 +- stubs/sympy-stubs/integrals/__init__.pyi | 31 +- .../sympy-stubs/integrals/deltafunctions.pyi | 8 +- stubs/sympy-stubs/integrals/heurisch.pyi | 38 +- stubs/sympy-stubs/integrals/integrals.pyi | 41 +- stubs/sympy-stubs/integrals/laplace.pyi | 30 +- .../sympy-stubs/integrals/manualintegrate.pyi | 507 ++----- stubs/sympy-stubs/integrals/meijerint.pyi | 14 +- stubs/sympy-stubs/integrals/prde.pyi | 79 +- stubs/sympy-stubs/integrals/rationaltools.pyi | 20 +- stubs/sympy-stubs/integrals/rde.pyi | 58 +- stubs/sympy-stubs/integrals/risch.pyi | 179 +-- .../integrals/singularityfunctions.pyi | 4 +- stubs/sympy-stubs/integrals/transforms.pyi | 159 +-- stubs/sympy-stubs/interactive/__init__.pyi | 2 +- stubs/sympy-stubs/interactive/printing.pyi | 24 +- stubs/sympy-stubs/interactive/session.pyi | 37 +- stubs/sympy-stubs/interactive/traversal.pyi | 4 +- stubs/sympy-stubs/liealgebras/cartan_type.pyi | 20 +- stubs/sympy-stubs/liealgebras/type_a.pyi | 46 +- stubs/sympy-stubs/liealgebras/type_b.pyi | 42 +- stubs/sympy-stubs/liealgebras/type_c.pyi | 42 +- stubs/sympy-stubs/liealgebras/type_d.pyi | 42 +- stubs/sympy-stubs/liealgebras/type_e.pyi | 38 +- stubs/sympy-stubs/liealgebras/type_f.pyi | 38 +- stubs/sympy-stubs/liealgebras/type_g.pyi | 34 +- stubs/sympy-stubs/logic/__init__.pyi | 23 +- stubs/sympy-stubs/logic/algorithms/dpll.pyi | 42 +- stubs/sympy-stubs/logic/algorithms/dpll2.pyi | 18 +- .../logic/algorithms/minisat22_wrapper.pyi | 8 +- .../logic/algorithms/pycosat_wrapper.pyi | 6 +- stubs/sympy-stubs/logic/boolalg.pyi | 362 ++--- stubs/sympy-stubs/logic/inference.pyi | 63 +- stubs/sympy-stubs/matrices/__init__.pyi | 76 +- stubs/sympy-stubs/matrices/dense.pyi | 115 +- .../matrices/expressions/__init__.pyi | 43 +- .../matrices/expressions/adjoint.pyi | 14 +- .../matrices/expressions/applyfunc.pyi | 22 +- .../matrices/expressions/blockmatrix.pyi | 152 +-- .../matrices/expressions/companion.pyi | 14 +- .../matrices/expressions/determinant.pyi | 41 +- .../matrices/expressions/diagonal.pyi | 35 +- .../matrices/expressions/dotproduct.pyi | 10 +- .../matrices/expressions/factorizations.pyi | 71 +- .../matrices/expressions/fourier.pyi | 11 +- .../matrices/expressions/funcmatrix.pyi | 14 +- .../matrices/expressions/hadamard.pyi | 41 +- .../matrices/expressions/inverse.pyi | 21 +- .../matrices/expressions/kronecker.pyi | 54 +- .../matrices/expressions/matadd.pyi | 27 +- .../matrices/expressions/matexpr.pyi | 295 ++-- .../matrices/expressions/matmul.pyi | 73 +- .../matrices/expressions/matpow.pyi | 22 +- .../matrices/expressions/permutation.pyi | 32 +- .../sympy-stubs/matrices/expressions/sets.pyi | 14 +- .../matrices/expressions/slice.pyi | 24 +- .../matrices/expressions/special.pyi | 114 +- .../matrices/expressions/trace.pyi | 21 +- .../matrices/expressions/transpose.pyi | 21 +- stubs/sympy-stubs/matrices/immutable.pyi | 46 +- stubs/sympy-stubs/matrices/normalforms.pyi | 12 +- stubs/sympy-stubs/matrices/repmatrix.pyi | 75 +- stubs/sympy-stubs/matrices/sparse.pyi | 64 +- stubs/sympy-stubs/matrices/utilities.pyi | 10 +- .../sympy-stubs/multipledispatch/__init__.pyi | 2 +- .../sympy-stubs/multipledispatch/conflict.pyi | 34 +- stubs/sympy-stubs/multipledispatch/core.pyi | 7 +- .../multipledispatch/dispatcher.pyi | 115 +- stubs/sympy-stubs/multipledispatch/utils.pyi | 12 +- stubs/sympy-stubs/ntheory/__init__.pyi | 74 +- .../ntheory/continued_fraction.pyi | 20 +- stubs/sympy-stubs/ntheory/digits.pyi | 12 +- stubs/sympy-stubs/ntheory/ecm.pyi | 26 +- .../sympy-stubs/ntheory/egyptian_fraction.pyi | 24 +- stubs/sympy-stubs/ntheory/factor_.pyi | 205 ++- stubs/sympy-stubs/ntheory/generate.pyi | 88 +- stubs/sympy-stubs/ntheory/modular.pyi | 20 +- stubs/sympy-stubs/ntheory/multinomial.pyi | 24 +- stubs/sympy-stubs/ntheory/partitions_.pyi | 5 +- stubs/sympy-stubs/ntheory/primetest.pyi | 33 +- stubs/sympy-stubs/ntheory/qs.pyi | 19 +- stubs/sympy-stubs/ntheory/residue_ntheory.pyi | 60 +- stubs/sympy-stubs/parsing/__init__.pyi | 2 +- stubs/sympy-stubs/parsing/sympy_parser.pyi | 120 +- stubs/sympy-stubs/physics/__init__.pyi | 2 +- .../sympy-stubs/physics/control/__init__.pyi | 26 +- .../physics/control/control_plots.pyi | 91 +- stubs/sympy-stubs/physics/control/lti.pyi | 525 +++---- stubs/sympy-stubs/physics/matrices.pyi | 14 +- stubs/sympy-stubs/physics/units/__init__.pyi | 368 ++++- .../physics/units/definitions/__init__.pyi | 303 ++++- .../sympy-stubs/physics/units/dimensions.pyi | 152 +-- stubs/sympy-stubs/physics/units/prefixes.pyi | 44 +- .../sympy-stubs/physics/units/quantities.pyi | 53 +- .../sympy-stubs/physics/units/unitsystem.pyi | 62 +- stubs/sympy-stubs/physics/units/util.pyi | 12 +- stubs/sympy-stubs/plotting/__init__.pyi | 14 +- .../plotting/intervalmath/__init__.pyi | 27 +- .../intervalmath/interval_arithmetic.pyi | 92 +- .../intervalmath/interval_membership.pyi | 47 +- .../plotting/intervalmath/lib_interval.pyi | 92 +- stubs/sympy-stubs/plotting/plot.pyi | 328 ++--- stubs/sympy-stubs/plotting/plot_implicit.pyi | 27 +- .../plotting/pygletplot/__init__.pyi | 6 +- .../plotting/pygletplot/color_scheme.pyi | 40 +- .../plotting/pygletplot/managed_window.pyi | 30 +- .../sympy-stubs/plotting/pygletplot/plot.pyi | 83 +- .../plotting/pygletplot/plot_axes.pyi | 111 +- .../plotting/pygletplot/plot_camera.pyi | 46 +- .../plotting/pygletplot/plot_controller.pyi | 38 +- .../plotting/pygletplot/plot_curve.pyi | 10 +- .../plotting/pygletplot/plot_interval.pyi | 79 +- .../plotting/pygletplot/plot_mode.pyi | 15 +- .../plotting/pygletplot/plot_mode_base.pyi | 31 +- .../plotting/pygletplot/plot_modes.pyi | 12 +- .../plotting/pygletplot/plot_object.pyi | 6 +- .../plotting/pygletplot/plot_rotation.pyi | 22 +- .../plotting/pygletplot/plot_surface.pyi | 10 +- .../plotting/pygletplot/plot_window.pyi | 28 +- .../sympy-stubs/plotting/pygletplot/util.pyi | 92 +- stubs/sympy-stubs/plotting/textplot.pyi | 20 +- stubs/sympy-stubs/polys/__init__.pyi | 178 ++- stubs/sympy-stubs/polys/agca/extensions.pyi | 157 +-- .../sympy-stubs/polys/agca/homomorphisms.pyi | 96 +- stubs/sympy-stubs/polys/agca/ideals.pyi | 125 +- stubs/sympy-stubs/polys/agca/modules.pyi | 363 ++--- stubs/sympy-stubs/polys/appellseqs.pyi | 40 +- stubs/sympy-stubs/polys/compatibility.pyi | 1210 +++++------------ stubs/sympy-stubs/polys/constructor.pyi | 10 +- stubs/sympy-stubs/polys/densearith.pyi | 286 ++-- stubs/sympy-stubs/polys/densebasic.pyi | 264 +--- stubs/sympy-stubs/polys/densetools.pyi | 148 +- stubs/sympy-stubs/polys/dispersion.pyi | 8 +- .../sympy-stubs/polys/distributedmodules.pyi | 114 +- stubs/sympy-stubs/polys/domains/__init__.pyi | 24 +- .../polys/domains/algebraicfield.pyi | 126 +- .../polys/domains/characteristiczero.pyi | 6 +- .../polys/domains/complexfield.pyi | 117 +- .../polys/domains/compositedomain.pyi | 10 +- stubs/sympy-stubs/polys/domains/domain.pyi | 340 ++--- .../polys/domains/expressiondomain.pyi | 202 +-- .../polys/domains/expressionrawdomain.pyi | 29 +- stubs/sympy-stubs/polys/domains/field.pyi | 42 +- .../sympy-stubs/polys/domains/finitefield.pyi | 75 +- .../polys/domains/fractionfield.pyi | 134 +- .../polys/domains/gaussiandomains.pyi | 244 +--- .../polys/domains/gmpyintegerring.pyi | 70 +- .../polys/domains/gmpyrationalfield.pyi | 70 +- .../sympy-stubs/polys/domains/integerring.pyi | 100 +- .../polys/domains/modularinteger.pyi | 116 +- .../sympy-stubs/polys/domains/mpelements.pyi | 29 +- .../polys/domains/old_fractionfield.pyi | 102 +- .../polys/domains/old_polynomialring.pyi | 151 +- .../polys/domains/polynomialring.pyi | 142 +- .../polys/domains/pythonintegerring.pyi | 73 +- .../polys/domains/pythonrational.pyi | 3 +- .../polys/domains/pythonrationalfield.pyi | 46 +- .../polys/domains/quotientring.pyi | 115 +- .../polys/domains/rationalfield.pyi | 81 +- stubs/sympy-stubs/polys/domains/realfield.pyi | 97 +- stubs/sympy-stubs/polys/domains/ring.pyi | 58 +- .../polys/domains/simpledomain.pyi | 4 +- stubs/sympy-stubs/polys/euclidtools.pyi | 289 ++-- stubs/sympy-stubs/polys/factortools.pyi | 156 +-- stubs/sympy-stubs/polys/fglmtools.pyi | 4 +- stubs/sympy-stubs/polys/fields.pyi | 213 +-- stubs/sympy-stubs/polys/galoistools.pyi | 276 +--- stubs/sympy-stubs/polys/groebnertools.pyi | 106 +- stubs/sympy-stubs/polys/heuristicgcd.pyi | 3 +- stubs/sympy-stubs/polys/matrices/__init__.pyi | 2 +- stubs/sympy-stubs/polys/matrices/ddm.pyi | 210 +-- stubs/sympy-stubs/polys/matrices/dense.pyi | 61 +- .../polys/matrices/domainmatrix.pyi | 281 +--- .../polys/matrices/domainscalar.pyi | 78 +- stubs/sympy-stubs/polys/matrices/eigen.pyi | 8 +- stubs/sympy-stubs/polys/matrices/linsolve.pyi | 4 +- stubs/sympy-stubs/polys/matrices/lll.pyi | 8 +- .../polys/matrices/normalforms.pyi | 16 +- stubs/sympy-stubs/polys/matrices/sdm.pyi | 237 +--- stubs/sympy-stubs/polys/monomials.pyi | 147 +- .../polys/numberfields/__init__.pyi | 13 +- .../sympy-stubs/polys/numberfields/basis.pyi | 8 +- .../polys/numberfields/galois_resolvents.pyi | 66 +- .../polys/numberfields/galoisgroups.pyi | 16 +- .../polys/numberfields/minpoly.pyi | 8 +- .../polys/numberfields/modules.pyi | 439 ++---- .../sympy-stubs/polys/numberfields/primes.pyi | 67 +- .../polys/numberfields/subfield.pyi | 24 +- .../polys/numberfields/utilities.pyi | 53 +- stubs/sympy-stubs/polys/orderings.pyi | 116 +- stubs/sympy-stubs/polys/orthopolys.pyi | 76 +- stubs/sympy-stubs/polys/partfrac.pyi | 24 +- stubs/sympy-stubs/polys/polyclasses.pyi | 959 ++++--------- stubs/sympy-stubs/polys/polyconfig.pyi | 17 +- stubs/sympy-stubs/polys/polyerrors.pyi | 139 +- stubs/sympy-stubs/polys/polyfuncs.pyi | 20 +- stubs/sympy-stubs/polys/polymatrix.pyi | 113 +- stubs/sympy-stubs/polys/polyoptions.pyi | 208 +-- stubs/sympy-stubs/polys/polyquinticconst.pyi | 51 +- stubs/sympy-stubs/polys/polyroots.pyi | 52 +- stubs/sympy-stubs/polys/polytools.pyi | 1034 ++++---------- stubs/sympy-stubs/polys/polyutils.pyi | 26 +- stubs/sympy-stubs/polys/rationaltools.pyi | 4 +- stubs/sympy-stubs/polys/ring_series.pyi | 142 +- stubs/sympy-stubs/polys/rings.pyi | 661 +++------ stubs/sympy-stubs/polys/rootisolation.pyi | 298 ++-- stubs/sympy-stubs/polys/rootoftools.pyi | 98 +- stubs/sympy-stubs/polys/solvers.pyi | 21 +- stubs/sympy-stubs/polys/specialpolys.pyi | 58 +- stubs/sympy-stubs/polys/sqfreetools.pyi | 110 +- stubs/sympy-stubs/printing/__init__.pyi | 44 +- stubs/sympy-stubs/printing/c.pyi | 19 +- stubs/sympy-stubs/printing/codeprinter.pyi | 43 +- stubs/sympy-stubs/printing/conventions.pyi | 7 +- stubs/sympy-stubs/printing/cxx.pyi | 9 +- stubs/sympy-stubs/printing/dot.pyi | 23 +- stubs/sympy-stubs/printing/fortran.pyi | 11 +- stubs/sympy-stubs/printing/glsl.pyi | 19 +- stubs/sympy-stubs/printing/gtk.pyi | 4 +- stubs/sympy-stubs/printing/jscode.pyi | 18 +- stubs/sympy-stubs/printing/julia.pyi | 19 +- stubs/sympy-stubs/printing/lambdarepr.pyi | 22 +- stubs/sympy-stubs/printing/latex.pyi | 42 +- stubs/sympy-stubs/printing/maple.pyi | 14 +- stubs/sympy-stubs/printing/mathematica.pyi | 11 +- stubs/sympy-stubs/printing/mathml.pyi | 41 +- stubs/sympy-stubs/printing/numpy.pyi | 27 +- stubs/sympy-stubs/printing/octave.pyi | 19 +- stubs/sympy-stubs/printing/precedence.pyi | 34 +- .../sympy-stubs/printing/pretty/__init__.pyi | 2 +- stubs/sympy-stubs/printing/pretty/pretty.pyi | 30 +- .../printing/pretty/pretty_symbology.pyi | 51 +- .../printing/pretty/stringpict.pyi | 120 +- stubs/sympy-stubs/printing/preview.pyi | 27 +- stubs/sympy-stubs/printing/printer.pyi | 45 +- stubs/sympy-stubs/printing/pycode.pyi | 19 +- stubs/sympy-stubs/printing/python.pyi | 14 +- stubs/sympy-stubs/printing/rcode.pyi | 18 +- stubs/sympy-stubs/printing/repr.pyi | 13 +- stubs/sympy-stubs/printing/rust.pyi | 18 +- stubs/sympy-stubs/printing/str.pyi | 25 +- stubs/sympy-stubs/printing/tableform.pyi | 26 +- stubs/sympy-stubs/printing/tensorflow.pyi | 11 +- stubs/sympy-stubs/printing/tree.pyi | 16 +- stubs/sympy-stubs/series/__init__.pyi | 21 +- stubs/sympy-stubs/series/approximants.pyi | 4 +- stubs/sympy-stubs/series/formal.pyi | 280 ++-- stubs/sympy-stubs/series/fourier.pyi | 129 +- stubs/sympy-stubs/series/gruntz.pyi | 91 +- stubs/sympy-stubs/series/limits.pyi | 25 +- stubs/sympy-stubs/series/limitseq.pyi | 12 +- stubs/sympy-stubs/series/order.pyi | 45 +- stubs/sympy-stubs/series/sequences.pyi | 271 +--- stubs/sympy-stubs/series/series_class.pyi | 38 +- stubs/sympy-stubs/sets/__init__.pyi | 30 +- stubs/sympy-stubs/sets/conditionset.pyi | 20 +- stubs/sympy-stubs/sets/contains.pyi | 14 +- stubs/sympy-stubs/sets/fancysets.pyi | 195 +-- stubs/sympy-stubs/sets/handlers/add.pyi | 41 +- stubs/sympy-stubs/sets/handlers/functions.pyi | 49 +- .../sets/handlers/intersection.pyi | 103 +- stubs/sympy-stubs/sets/handlers/issubset.pyi | 65 +- stubs/sympy-stubs/sets/handlers/mul.pyi | 33 +- stubs/sympy-stubs/sets/handlers/power.pyi | 29 +- stubs/sympy-stubs/sets/handlers/union.pyi | 73 +- stubs/sympy-stubs/sets/ordinals.pyi | 120 +- stubs/sympy-stubs/sets/powerset.pyi | 22 +- stubs/sympy-stubs/sets/setexpr.pyi | 87 +- stubs/sympy-stubs/sets/sets.pyi | 592 +++----- stubs/sympy-stubs/simplify/__init__.pyi | 35 +- stubs/sympy-stubs/simplify/combsimp.pyi | 6 +- stubs/sympy-stubs/simplify/cse_main.pyi | 90 +- stubs/sympy-stubs/simplify/cse_opts.pyi | 8 +- stubs/sympy-stubs/simplify/epathtools.pyi | 21 +- stubs/sympy-stubs/simplify/fu.pyi | 120 +- stubs/sympy-stubs/simplify/gammasimp.pyi | 9 +- stubs/sympy-stubs/simplify/hyperexpand.pyi | 293 +--- stubs/sympy-stubs/simplify/powsimp.pyi | 7 +- stubs/sympy-stubs/simplify/radsimp.pyi | 54 +- stubs/sympy-stubs/simplify/ratsimp.pyi | 8 +- stubs/sympy-stubs/simplify/simplify.pyi | 87 +- stubs/sympy-stubs/simplify/sqrtdenest.pyi | 23 +- stubs/sympy-stubs/simplify/trigsimp.pyi | 16 +- stubs/sympy-stubs/solvers/__init__.pyi | 45 +- stubs/sympy-stubs/solvers/bivariate.pyi | 6 +- stubs/sympy-stubs/solvers/decompogen.pyi | 8 +- stubs/sympy-stubs/solvers/deutils.pyi | 5 +- .../solvers/diophantine/__init__.pyi | 2 +- .../solvers/diophantine/diophantine.pyi | 355 ++--- stubs/sympy-stubs/solvers/inequalities.pyi | 32 +- stubs/sympy-stubs/solvers/ode/__init__.pyi | 14 +- .../solvers/ode/hypergeometric.pyi | 20 +- stubs/sympy-stubs/solvers/ode/lie_group.pyi | 39 +- stubs/sympy-stubs/solvers/ode/ode.pyi | 127 +- stubs/sympy-stubs/solvers/ode/riccati.pyi | 92 +- stubs/sympy-stubs/solvers/ode/single.pyi | 90 +- stubs/sympy-stubs/solvers/ode/subscheck.pyi | 12 +- stubs/sympy-stubs/solvers/ode/systems.pyi | 43 +- stubs/sympy-stubs/solvers/pde.pyi | 35 +- stubs/sympy-stubs/solvers/polysys.pyi | 20 +- stubs/sympy-stubs/solvers/recurr.pyi | 16 +- stubs/sympy-stubs/solvers/solvers.pyi | 62 +- stubs/sympy-stubs/solvers/solveset.pyi | 62 +- stubs/sympy-stubs/stats/__init__.pyi | 159 ++- stubs/sympy-stubs/stats/compound_rv.pyi | 91 +- stubs/sympy-stubs/stats/crv.pyi | 170 +-- stubs/sympy-stubs/stats/crv_types.pyi | 758 ++++------- stubs/sympy-stubs/stats/drv.pyi | 129 +- stubs/sympy-stubs/stats/drv_types.pyi | 131 +- stubs/sympy-stubs/stats/frv.pyi | 257 +--- stubs/sympy-stubs/stats/frv_types.pyi | 315 ++--- stubs/sympy-stubs/stats/joint_rv.pyi | 141 +- stubs/sympy-stubs/stats/joint_rv_types.pyi | 181 +-- .../stats/matrix_distributions.pyi | 143 +- stubs/sympy-stubs/stats/random_matrix.pyi | 14 +- .../stats/random_matrix_models.pyi | 152 +-- stubs/sympy-stubs/stats/rv.pyi | 471 +++---- stubs/sympy-stubs/stats/rv_interface.pyi | 136 +- .../stats/sampling/sample_numpy.pyi | 81 +- .../stats/sampling/sample_pymc.pyi | 64 +- .../stats/sampling/sample_scipy.pyi | 87 +- .../sympy-stubs/stats/stochastic_process.pyi | 30 +- .../stats/stochastic_process_types.pyi | 370 ++--- .../symbolic_multivariate_probability.pyi | 40 +- .../stats/symbolic_probability.pyi | 124 +- stubs/sympy-stubs/strategies/__init__.pyi | 24 +- .../strategies/branch/__init__.pyi | 16 +- stubs/sympy-stubs/strategies/branch/core.pyi | 44 +- stubs/sympy-stubs/strategies/branch/tools.pyi | 4 +- .../strategies/branch/traverse.pyi | 8 +- stubs/sympy-stubs/strategies/core.pyi | 49 +- stubs/sympy-stubs/strategies/rl.pyi | 32 +- stubs/sympy-stubs/strategies/tools.pyi | 12 +- stubs/sympy-stubs/strategies/traverse.pyi | 20 +- stubs/sympy-stubs/strategies/tree.pyi | 16 +- stubs/sympy-stubs/tensor/__init__.pyi | 22 +- stubs/sympy-stubs/tensor/array/__init__.pyi | 19 +- .../tensor/array/array_comprehension.pyi | 68 +- .../tensor/array/array_derivatives.pyi | 10 +- stubs/sympy-stubs/tensor/array/arrayop.pyi | 56 +- .../tensor/array/dense_ndim_array.pyi | 56 +- .../array/expressions/array_expressions.pyi | 365 ++--- .../expressions/arrayexpr_derivatives.pyi | 82 +- .../expressions/from_array_to_indexed.pyi | 13 +- .../expressions/from_array_to_matrix.pyi | 113 +- .../expressions/from_indexed_to_array.pyi | 18 +- .../tensor/array/mutable_ndim_array.pyi | 10 +- stubs/sympy-stubs/tensor/array/ndim_array.pyi | 118 +- .../tensor/array/sparse_ndim_array.pyi | 52 +- stubs/sympy-stubs/tensor/functions.pyi | 25 +- stubs/sympy-stubs/tensor/index_methods.pyi | 31 +- stubs/sympy-stubs/tensor/indexed.pyi | 116 +- stubs/sympy-stubs/tensor/tensor.pyi | 1084 +++++---------- stubs/sympy-stubs/testing/__init__.pyi | 2 +- stubs/sympy-stubs/testing/runtests.pyi | 207 +-- stubs/sympy-stubs/unify/__init__.pyi | 2 +- stubs/sympy-stubs/unify/core.pyi | 91 +- stubs/sympy-stubs/unify/rewrite.pyi | 4 +- stubs/sympy-stubs/unify/usympy.pyi | 35 +- stubs/sympy-stubs/utilities/__init__.pyi | 28 +- stubs/sympy-stubs/utilities/decorator.pyi | 44 +- stubs/sympy-stubs/utilities/enumerative.pyi | 87 +- stubs/sympy-stubs/utilities/exceptions.pyi | 29 +- stubs/sympy-stubs/utilities/iterables.pyi | 268 ++-- stubs/sympy-stubs/utilities/lambdify.pyi | 25 +- stubs/sympy-stubs/utilities/magic.pyi | 5 +- .../sympy-stubs/utilities/mathml/__init__.pyi | 15 +- stubs/sympy-stubs/utilities/memoization.pyi | 8 +- stubs/sympy-stubs/utilities/misc.pyi | 50 +- stubs/sympy-stubs/utilities/source.pyi | 8 +- stubs/sympy-stubs/utilities/timeutils.pyi | 7 +- stubs/sympy-stubs/vector/basisdependent.pyi | 156 +-- stubs/sympy-stubs/vector/coordsysrect.pyi | 101 +- stubs/sympy-stubs/vector/deloperator.pyi | 21 +- stubs/sympy-stubs/vector/dyadic.pyi | 54 +- stubs/sympy-stubs/vector/functions.pyi | 36 +- stubs/sympy-stubs/vector/implicitregion.pyi | 39 +- stubs/sympy-stubs/vector/integrals.pyi | 17 +- stubs/sympy-stubs/vector/operators.pyi | 48 +- stubs/sympy-stubs/vector/orienters.pyi | 91 +- stubs/sympy-stubs/vector/parametricregion.pyi | 49 +- stubs/sympy-stubs/vector/point.pyi | 18 +- stubs/sympy-stubs/vector/scalar.pyi | 16 +- stubs/sympy-stubs/vector/vector.pyi | 111 +- 525 files changed, 15579 insertions(+), 32599 deletions(-) diff --git a/stubs/sympy-stubs/__init__.pyi b/stubs/sympy-stubs/__init__.pyi index 609f4870..43a8aa94 100644 --- a/stubs/sympy-stubs/__init__.pyi +++ b/stubs/sympy-stubs/__init__.pyi @@ -923,11 +923,904 @@ from sympy.utilities import ( if sys.version_info < (3, 8): ... -if 'dev' in __version__: - def enable_warnings() -> None: - ... - +if "dev" in __version__: + def enable_warnings() -> None: ... + SYMPY_DEBUG: bool = ... test = ... doctest = ... -__all__ = ['__version__', 'sympify', 'SympifyError', 'cacheit', 'Basic', 'Atom', 'preorder_traversal', 'S', 'Expr', 'AtomicExpr', 'UnevaluatedExpr', 'Symbol', 'Wild', 'Dummy', 'symbols', 'var', 'Number', 'Float', 'Rational', 'Integer', 'NumberSymbol', 'RealNumber', 'igcd', 'ilcm', 'seterr', 'E', 'I', 'nan', 'oo', 'pi', 'zoo', 'AlgebraicNumber', 'comp', 'mod_inverse', 'Pow', 'integer_nthroot', 'integer_log', 'Mul', 'prod', 'Add', 'Mod', 'Rel', 'Eq', 'Ne', 'Lt', 'Le', 'Gt', 'Ge', 'Equality', 'GreaterThan', 'LessThan', 'Unequality', 'StrictGreaterThan', 'StrictLessThan', 'vectorize', 'Lambda', 'WildFunction', 'Derivative', 'diff', 'FunctionClass', 'Function', 'Subs', 'expand', 'PoleError', 'count_ops', 'expand_mul', 'expand_log', 'expand_func', 'expand_trig', 'expand_complex', 'expand_multinomial', 'nfloat', 'expand_power_base', 'expand_power_exp', 'arity', 'PrecisionExhausted', 'N', 'evalf', 'Tuple', 'Dict', 'gcd_terms', 'factor_terms', 'factor_nc', 'evaluate', 'Catalan', 'EulerGamma', 'GoldenRatio', 'TribonacciConstant', 'bottom_up', 'use', 'postorder_traversal', 'default_sort_key', 'ordered', 'to_cnf', 'to_dnf', 'to_nnf', 'And', 'Or', 'Not', 'Xor', 'Nand', 'Nor', 'Implies', 'Equivalent', 'ITE', 'POSform', 'SOPform', 'simplify_logic', 'bool_map', 'true', 'false', 'satisfiable', 'AppliedPredicate', 'Predicate', 'AssumptionsContext', 'assuming', 'Q', 'ask', 'register_handler', 'remove_handler', 'refine', 'Poly', 'PurePoly', 'poly_from_expr', 'parallel_poly_from_expr', 'degree', 'total_degree', 'degree_list', 'LC', 'LM', 'LT', 'pdiv', 'prem', 'pquo', 'pexquo', 'div', 'rem', 'quo', 'exquo', 'half_gcdex', 'gcdex', 'invert', 'subresultants', 'resultant', 'discriminant', 'cofactors', 'gcd_list', 'gcd', 'lcm_list', 'lcm', 'terms_gcd', 'trunc', 'monic', 'content', 'primitive', 'compose', 'decompose', 'sturm', 'gff_list', 'gff', 'sqf_norm', 'sqf_part', 'sqf_list', 'sqf', 'factor_list', 'factor', 'intervals', 'refine_root', 'count_roots', 'real_roots', 'nroots', 'ground_roots', 'nth_power_roots_poly', 'cancel', 'reduced', 'groebner', 'is_zero_dimensional', 'GroebnerBasis', 'poly', 'symmetrize', 'horner', 'interpolate', 'rational_interpolate', 'viete', 'together', 'BasePolynomialError', 'ExactQuotientFailed', 'PolynomialDivisionFailed', 'OperationNotSupported', 'HeuristicGCDFailed', 'HomomorphismFailed', 'IsomorphismFailed', 'ExtraneousFactors', 'EvaluationFailed', 'RefinementFailed', 'CoercionFailed', 'NotInvertible', 'NotReversible', 'NotAlgebraic', 'DomainError', 'PolynomialError', 'UnificationFailed', 'GeneratorsError', 'GeneratorsNeeded', 'ComputationFailed', 'UnivariatePolynomialError', 'MultivariatePolynomialError', 'PolificationFailed', 'OptionError', 'FlagError', 'minpoly', 'minimal_polynomial', 'primitive_element', 'field_isomorphism', 'to_number_field', 'isolate', 'round_two', 'prime_decomp', 'prime_valuation', 'galois_group', 'itermonomials', 'Monomial', 'lex', 'grlex', 'grevlex', 'ilex', 'igrlex', 'igrevlex', 'CRootOf', 'rootof', 'RootOf', 'ComplexRootOf', 'RootSum', 'roots', 'Domain', 'FiniteField', 'IntegerRing', 'RationalField', 'RealField', 'ComplexField', 'PythonFiniteField', 'GMPYFiniteField', 'PythonIntegerRing', 'GMPYIntegerRing', 'PythonRational', 'GMPYRationalField', 'AlgebraicField', 'PolynomialRing', 'FractionField', 'ExpressionDomain', 'FF_python', 'FF_gmpy', 'ZZ_python', 'ZZ_gmpy', 'QQ_python', 'QQ_gmpy', 'GF', 'FF', 'ZZ', 'QQ', 'ZZ_I', 'QQ_I', 'RR', 'CC', 'EX', 'EXRAW', 'construct_domain', 'swinnerton_dyer_poly', 'cyclotomic_poly', 'symmetric_poly', 'random_poly', 'interpolating_poly', 'jacobi_poly', 'chebyshevt_poly', 'chebyshevu_poly', 'hermite_poly', 'hermite_prob_poly', 'legendre_poly', 'laguerre_poly', 'apart', 'apart_list', 'assemble_partfrac_list', 'Options', 'ring', 'xring', 'vring', 'sring', 'field', 'xfield', 'vfield', 'sfield', 'Order', 'O', 'limit', 'Limit', 'gruntz', 'series', 'approximants', 'residue', 'EmptySequence', 'SeqPer', 'SeqFormula', 'sequence', 'SeqAdd', 'SeqMul', 'fourier_series', 'fps', 'difference_delta', 'limit_seq', 'factorial', 'factorial2', 'rf', 'ff', 'binomial', 'RisingFactorial', 'FallingFactorial', 'subfactorial', 'carmichael', 'fibonacci', 'lucas', 'motzkin', 'tribonacci', 'harmonic', 'bernoulli', 'bell', 'euler', 'catalan', 'genocchi', 'andre', 'partition', 'sqrt', 'root', 'Min', 'Max', 'Id', 'real_root', 'Rem', 'cbrt', 're', 'im', 'sign', 'Abs', 'conjugate', 'arg', 'polar_lift', 'periodic_argument', 'unbranched_argument', 'principal_branch', 'transpose', 'adjoint', 'polarify', 'unpolarify', 'sin', 'cos', 'tan', 'sec', 'csc', 'cot', 'sinc', 'asin', 'acos', 'atan', 'asec', 'acsc', 'acot', 'atan2', 'exp_polar', 'exp', 'ln', 'log', 'LambertW', 'sinh', 'cosh', 'tanh', 'coth', 'sech', 'csch', 'asinh', 'acosh', 'atanh', 'acoth', 'asech', 'acsch', 'floor', 'ceiling', 'frac', 'Piecewise', 'piecewise_fold', 'piecewise_exclusive', 'erf', 'erfc', 'erfi', 'erf2', 'erfinv', 'erfcinv', 'erf2inv', 'Ei', 'expint', 'E1', 'li', 'Li', 'Si', 'Ci', 'Shi', 'Chi', 'fresnels', 'fresnelc', 'gamma', 'lowergamma', 'uppergamma', 'polygamma', 'loggamma', 'digamma', 'trigamma', 'multigamma', 'dirichlet_eta', 'zeta', 'lerchphi', 'polylog', 'stieltjes', 'Eijk', 'LeviCivita', 'KroneckerDelta', 'SingularityFunction', 'DiracDelta', 'Heaviside', 'bspline_basis', 'bspline_basis_set', 'interpolating_spline', 'besselj', 'bessely', 'besseli', 'besselk', 'hankel1', 'hankel2', 'jn', 'yn', 'jn_zeros', 'hn1', 'hn2', 'airyai', 'airybi', 'airyaiprime', 'airybiprime', 'marcumq', 'hyper', 'meijerg', 'appellf1', 'legendre', 'assoc_legendre', 'hermite', 'hermite_prob', 'chebyshevt', 'chebyshevu', 'chebyshevu_root', 'chebyshevt_root', 'laguerre', 'assoc_laguerre', 'gegenbauer', 'jacobi', 'jacobi_normalized', 'Ynm', 'Ynm_c', 'Znm', 'elliptic_k', 'elliptic_f', 'elliptic_e', 'elliptic_pi', 'beta', 'mathieus', 'mathieuc', 'mathieusprime', 'mathieucprime', 'riemann_xi', 'betainc', 'betainc_regularized', 'nextprime', 'prevprime', 'prime', 'primerange', 'randprime', 'Sieve', 'sieve', 'primorial', 'cycle_length', 'composite', 'compositepi', 'isprime', 'divisors', 'proper_divisors', 'factorint', 'multiplicity', 'perfect_power', 'pollard_pm1', 'pollard_rho', 'primefactors', 'totient', 'trailing', 'divisor_count', 'proper_divisor_count', 'divisor_sigma', 'factorrat', 'reduced_totient', 'primenu', 'primeomega', 'mersenne_prime_exponent', 'is_perfect', 'is_mersenne_prime', 'is_abundant', 'is_deficient', 'is_amicable', 'abundance', 'npartitions', 'is_primitive_root', 'is_quad_residue', 'legendre_symbol', 'jacobi_symbol', 'n_order', 'sqrt_mod', 'quadratic_residues', 'primitive_root', 'nthroot_mod', 'is_nthpow_residue', 'sqrt_mod_iter', 'mobius', 'discrete_log', 'quadratic_congruence', 'binomial_coefficients', 'binomial_coefficients_list', 'multinomial_coefficients', 'continued_fraction_periodic', 'continued_fraction_iterator', 'continued_fraction_reduce', 'continued_fraction_convergents', 'continued_fraction', 'egyptian_fraction', 'product', 'Product', 'summation', 'Sum', 'fft', 'ifft', 'ntt', 'intt', 'fwht', 'ifwht', 'mobius_transform', 'inverse_mobius_transform', 'convolution', 'covering_product', 'intersecting_product', 'simplify', 'hypersimp', 'hypersimilar', 'logcombine', 'separatevars', 'posify', 'besselsimp', 'kroneckersimp', 'signsimp', 'nsimplify', 'FU', 'fu', 'sqrtdenest', 'cse', 'epath', 'EPath', 'hyperexpand', 'collect', 'rcollect', 'radsimp', 'collect_const', 'fraction', 'numer', 'denom', 'trigsimp', 'exptrigsimp', 'powsimp', 'powdenest', 'combsimp', 'gammasimp', 'ratsimp', 'ratsimpmodprime', 'Set', 'Interval', 'Union', 'EmptySet', 'FiniteSet', 'ProductSet', 'Intersection', 'imageset', 'DisjointUnion', 'Complement', 'SymmetricDifference', 'ImageSet', 'Range', 'ComplexRegion', 'Reals', 'Contains', 'ConditionSet', 'Ordinal', 'OmegaPower', 'ord0', 'PowerSet', 'Naturals', 'Naturals0', 'UniversalSet', 'Integers', 'Rationals', 'Complexes', 'solve', 'solve_linear_system', 'solve_linear_system_LU', 'solve_undetermined_coeffs', 'nsolve', 'solve_linear', 'checksol', 'det_quick', 'inv_quick', 'check_assumptions', 'failing_assumptions', 'diophantine', 'rsolve', 'rsolve_poly', 'rsolve_ratio', 'rsolve_hyper', 'checkodesol', 'classify_ode', 'dsolve', 'homogeneous_order', 'solve_poly_system', 'solve_triangulated', 'pde_separate', 'pde_separate_add', 'pde_separate_mul', 'pdsolve', 'classify_pde', 'checkpdesol', 'ode_order', 'reduce_inequalities', 'reduce_abs_inequality', 'reduce_abs_inequalities', 'solve_poly_inequality', 'solve_rational_inequalities', 'solve_univariate_inequality', 'decompogen', 'solveset', 'linsolve', 'linear_eq_to_matrix', 'nonlinsolve', 'substitution', 'ShapeError', 'NonSquareMatrixError', 'GramSchmidt', 'casoratian', 'diag', 'eye', 'hessian', 'jordan_cell', 'list2numpy', 'matrix2numpy', 'matrix_multiply_elementwise', 'ones', 'randMatrix', 'rot_axis1', 'rot_axis2', 'rot_axis3', 'symarray', 'wronskian', 'zeros', 'MutableDenseMatrix', 'DeferredVector', 'MatrixBase', 'Matrix', 'MutableMatrix', 'MutableSparseMatrix', 'banded', 'ImmutableDenseMatrix', 'ImmutableSparseMatrix', 'ImmutableMatrix', 'SparseMatrix', 'MatrixSlice', 'BlockDiagMatrix', 'BlockMatrix', 'FunctionMatrix', 'Identity', 'Inverse', 'MatAdd', 'MatMul', 'MatPow', 'MatrixExpr', 'MatrixSymbol', 'Trace', 'Transpose', 'ZeroMatrix', 'OneMatrix', 'blockcut', 'block_collapse', 'matrix_symbols', 'Adjoint', 'hadamard_product', 'HadamardProduct', 'HadamardPower', 'Determinant', 'det', 'diagonalize_vector', 'DiagMatrix', 'DiagonalMatrix', 'DiagonalOf', 'trace', 'DotProduct', 'kronecker_product', 'KroneckerProduct', 'PermutationMatrix', 'MatrixPermute', 'Permanent', 'per', 'rot_ccw_axis1', 'rot_ccw_axis2', 'rot_ccw_axis3', 'rot_givens', 'Point', 'Point2D', 'Point3D', 'Line', 'Ray', 'Segment', 'Line2D', 'Segment2D', 'Ray2D', 'Line3D', 'Segment3D', 'Ray3D', 'Plane', 'Ellipse', 'Circle', 'Polygon', 'RegularPolygon', 'Triangle', 'rad', 'deg', 'are_similar', 'centroid', 'convex_hull', 'idiff', 'intersection', 'closest_points', 'farthest_points', 'GeometryError', 'Curve', 'Parabola', 'flatten', 'group', 'take', 'subsets', 'variations', 'numbered_symbols', 'cartes', 'capture', 'dict_merge', 'prefixes', 'postfixes', 'sift', 'topological_sort', 'unflatten', 'has_dups', 'has_variety', 'reshape', 'rotations', 'filldedent', 'lambdify', 'threaded', 'xthreaded', 'public', 'memoize_property', 'timed', 'integrate', 'Integral', 'line_integrate', 'mellin_transform', 'inverse_mellin_transform', 'MellinTransform', 'InverseMellinTransform', 'laplace_transform', 'inverse_laplace_transform', 'LaplaceTransform', 'InverseLaplaceTransform', 'fourier_transform', 'inverse_fourier_transform', 'FourierTransform', 'InverseFourierTransform', 'sine_transform', 'inverse_sine_transform', 'SineTransform', 'InverseSineTransform', 'cosine_transform', 'inverse_cosine_transform', 'CosineTransform', 'InverseCosineTransform', 'hankel_transform', 'inverse_hankel_transform', 'HankelTransform', 'InverseHankelTransform', 'singularityintegrate', 'IndexedBase', 'Idx', 'Indexed', 'get_contraction_structure', 'get_indices', 'shape', 'MutableDenseNDimArray', 'ImmutableDenseNDimArray', 'MutableSparseNDimArray', 'ImmutableSparseNDimArray', 'NDimArray', 'tensorproduct', 'tensorcontraction', 'tensordiagonal', 'derive_by_array', 'permutedims', 'Array', 'DenseNDimArray', 'SparseNDimArray', 'parse_expr', 'euler_equations', 'singularities', 'is_increasing', 'is_strictly_increasing', 'is_decreasing', 'is_strictly_decreasing', 'is_monotonic', 'finite_diff_weights', 'apply_finite_diff', 'differentiate_finite', 'periodicity', 'not_empty_in', 'AccumBounds', 'is_convex', 'stationary_points', 'minimum', 'maximum', 'Quaternion', 'pager_print', 'pretty', 'pretty_print', 'pprint', 'pprint_use_unicode', 'pprint_try_use_unicode', 'latex', 'print_latex', 'multiline_latex', 'mathml', 'print_mathml', 'python', 'print_python', 'pycode', 'ccode', 'print_ccode', 'smtlib_code', 'glsl_code', 'print_glsl', 'cxxcode', 'fcode', 'print_fcode', 'rcode', 'print_rcode', 'jscode', 'print_jscode', 'julia_code', 'mathematica_code', 'octave_code', 'rust_code', 'print_gtk', 'preview', 'srepr', 'print_tree', 'StrPrinter', 'sstr', 'sstrrepr', 'TableForm', 'dotprint', 'maple_code', 'print_maple_code', 'plot', 'textplot', 'plot_backends', 'plot_implicit', 'plot_parametric', 'init_session', 'init_printing', 'interactive_traversal', 'test', 'doctest'] +__all__ = [ + "__version__", + "sympify", + "SympifyError", + "cacheit", + "Basic", + "Atom", + "preorder_traversal", + "S", + "Expr", + "AtomicExpr", + "UnevaluatedExpr", + "Symbol", + "Wild", + "Dummy", + "symbols", + "var", + "Number", + "Float", + "Rational", + "Integer", + "NumberSymbol", + "RealNumber", + "igcd", + "ilcm", + "seterr", + "E", + "I", + "nan", + "oo", + "pi", + "zoo", + "AlgebraicNumber", + "comp", + "mod_inverse", + "Pow", + "integer_nthroot", + "integer_log", + "Mul", + "prod", + "Add", + "Mod", + "Rel", + "Eq", + "Ne", + "Lt", + "Le", + "Gt", + "Ge", + "Equality", + "GreaterThan", + "LessThan", + "Unequality", + "StrictGreaterThan", + "StrictLessThan", + "vectorize", + "Lambda", + "WildFunction", + "Derivative", + "diff", + "FunctionClass", + "Function", + "Subs", + "expand", + "PoleError", + "count_ops", + "expand_mul", + "expand_log", + "expand_func", + "expand_trig", + "expand_complex", + "expand_multinomial", + "nfloat", + "expand_power_base", + "expand_power_exp", + "arity", + "PrecisionExhausted", + "N", + "evalf", + "Tuple", + "Dict", + "gcd_terms", + "factor_terms", + "factor_nc", + "evaluate", + "Catalan", + "EulerGamma", + "GoldenRatio", + "TribonacciConstant", + "bottom_up", + "use", + "postorder_traversal", + "default_sort_key", + "ordered", + "to_cnf", + "to_dnf", + "to_nnf", + "And", + "Or", + "Not", + "Xor", + "Nand", + "Nor", + "Implies", + "Equivalent", + "ITE", + "POSform", + "SOPform", + "simplify_logic", + "bool_map", + "true", + "false", + "satisfiable", + "AppliedPredicate", + "Predicate", + "AssumptionsContext", + "assuming", + "Q", + "ask", + "register_handler", + "remove_handler", + "refine", + "Poly", + "PurePoly", + "poly_from_expr", + "parallel_poly_from_expr", + "degree", + "total_degree", + "degree_list", + "LC", + "LM", + "LT", + "pdiv", + "prem", + "pquo", + "pexquo", + "div", + "rem", + "quo", + "exquo", + "half_gcdex", + "gcdex", + "invert", + "subresultants", + "resultant", + "discriminant", + "cofactors", + "gcd_list", + "gcd", + "lcm_list", + "lcm", + "terms_gcd", + "trunc", + "monic", + "content", + "primitive", + "compose", + "decompose", + "sturm", + "gff_list", + "gff", + "sqf_norm", + "sqf_part", + "sqf_list", + "sqf", + "factor_list", + "factor", + "intervals", + "refine_root", + "count_roots", + "real_roots", + "nroots", + "ground_roots", + "nth_power_roots_poly", + "cancel", + "reduced", + "groebner", + "is_zero_dimensional", + "GroebnerBasis", + "poly", + "symmetrize", + "horner", + "interpolate", + "rational_interpolate", + "viete", + "together", + "BasePolynomialError", + "ExactQuotientFailed", + "PolynomialDivisionFailed", + "OperationNotSupported", + "HeuristicGCDFailed", + "HomomorphismFailed", + "IsomorphismFailed", + "ExtraneousFactors", + "EvaluationFailed", + "RefinementFailed", + "CoercionFailed", + "NotInvertible", + "NotReversible", + "NotAlgebraic", + "DomainError", + "PolynomialError", + "UnificationFailed", + "GeneratorsError", + "GeneratorsNeeded", + "ComputationFailed", + "UnivariatePolynomialError", + "MultivariatePolynomialError", + "PolificationFailed", + "OptionError", + "FlagError", + "minpoly", + "minimal_polynomial", + "primitive_element", + "field_isomorphism", + "to_number_field", + "isolate", + "round_two", + "prime_decomp", + "prime_valuation", + "galois_group", + "itermonomials", + "Monomial", + "lex", + "grlex", + "grevlex", + "ilex", + "igrlex", + "igrevlex", + "CRootOf", + "rootof", + "RootOf", + "ComplexRootOf", + "RootSum", + "roots", + "Domain", + "FiniteField", + "IntegerRing", + "RationalField", + "RealField", + "ComplexField", + "PythonFiniteField", + "GMPYFiniteField", + "PythonIntegerRing", + "GMPYIntegerRing", + "PythonRational", + "GMPYRationalField", + "AlgebraicField", + "PolynomialRing", + "FractionField", + "ExpressionDomain", + "FF_python", + "FF_gmpy", + "ZZ_python", + "ZZ_gmpy", + "QQ_python", + "QQ_gmpy", + "GF", + "FF", + "ZZ", + "QQ", + "ZZ_I", + "QQ_I", + "RR", + "CC", + "EX", + "EXRAW", + "construct_domain", + "swinnerton_dyer_poly", + "cyclotomic_poly", + "symmetric_poly", + "random_poly", + "interpolating_poly", + "jacobi_poly", + "chebyshevt_poly", + "chebyshevu_poly", + "hermite_poly", + "hermite_prob_poly", + "legendre_poly", + "laguerre_poly", + "apart", + "apart_list", + "assemble_partfrac_list", + "Options", + "ring", + "xring", + "vring", + "sring", + "field", + "xfield", + "vfield", + "sfield", + "Order", + "O", + "limit", + "Limit", + "gruntz", + "series", + "approximants", + "residue", + "EmptySequence", + "SeqPer", + "SeqFormula", + "sequence", + "SeqAdd", + "SeqMul", + "fourier_series", + "fps", + "difference_delta", + "limit_seq", + "factorial", + "factorial2", + "rf", + "ff", + "binomial", + "RisingFactorial", + "FallingFactorial", + "subfactorial", + "carmichael", + "fibonacci", + "lucas", + "motzkin", + "tribonacci", + "harmonic", + "bernoulli", + "bell", + "euler", + "catalan", + "genocchi", + "andre", + "partition", + "sqrt", + "root", + "Min", + "Max", + "Id", + "real_root", + "Rem", + "cbrt", + "re", + "im", + "sign", + "Abs", + "conjugate", + "arg", + "polar_lift", + "periodic_argument", + "unbranched_argument", + "principal_branch", + "transpose", + "adjoint", + "polarify", + "unpolarify", + "sin", + "cos", + "tan", + "sec", + "csc", + "cot", + "sinc", + "asin", + "acos", + "atan", + "asec", + "acsc", + "acot", + "atan2", + "exp_polar", + "exp", + "ln", + "log", + "LambertW", + "sinh", + "cosh", + "tanh", + "coth", + "sech", + "csch", + "asinh", + "acosh", + "atanh", + "acoth", + "asech", + "acsch", + "floor", + "ceiling", + "frac", + "Piecewise", + "piecewise_fold", + "piecewise_exclusive", + "erf", + "erfc", + "erfi", + "erf2", + "erfinv", + "erfcinv", + "erf2inv", + "Ei", + "expint", + "E1", + "li", + "Li", + "Si", + "Ci", + "Shi", + "Chi", + "fresnels", + "fresnelc", + "gamma", + "lowergamma", + "uppergamma", + "polygamma", + "loggamma", + "digamma", + "trigamma", + "multigamma", + "dirichlet_eta", + "zeta", + "lerchphi", + "polylog", + "stieltjes", + "Eijk", + "LeviCivita", + "KroneckerDelta", + "SingularityFunction", + "DiracDelta", + "Heaviside", + "bspline_basis", + "bspline_basis_set", + "interpolating_spline", + "besselj", + "bessely", + "besseli", + "besselk", + "hankel1", + "hankel2", + "jn", + "yn", + "jn_zeros", + "hn1", + "hn2", + "airyai", + "airybi", + "airyaiprime", + "airybiprime", + "marcumq", + "hyper", + "meijerg", + "appellf1", + "legendre", + "assoc_legendre", + "hermite", + "hermite_prob", + "chebyshevt", + "chebyshevu", + "chebyshevu_root", + "chebyshevt_root", + "laguerre", + "assoc_laguerre", + "gegenbauer", + "jacobi", + "jacobi_normalized", + "Ynm", + "Ynm_c", + "Znm", + "elliptic_k", + "elliptic_f", + "elliptic_e", + "elliptic_pi", + "beta", + "mathieus", + "mathieuc", + "mathieusprime", + "mathieucprime", + "riemann_xi", + "betainc", + "betainc_regularized", + "nextprime", + "prevprime", + "prime", + "primerange", + "randprime", + "Sieve", + "sieve", + "primorial", + "cycle_length", + "composite", + "compositepi", + "isprime", + "divisors", + "proper_divisors", + "factorint", + "multiplicity", + "perfect_power", + "pollard_pm1", + "pollard_rho", + "primefactors", + "totient", + "trailing", + "divisor_count", + "proper_divisor_count", + "divisor_sigma", + "factorrat", + "reduced_totient", + "primenu", + "primeomega", + "mersenne_prime_exponent", + "is_perfect", + "is_mersenne_prime", + "is_abundant", + "is_deficient", + "is_amicable", + "abundance", + "npartitions", + "is_primitive_root", + "is_quad_residue", + "legendre_symbol", + "jacobi_symbol", + "n_order", + "sqrt_mod", + "quadratic_residues", + "primitive_root", + "nthroot_mod", + "is_nthpow_residue", + "sqrt_mod_iter", + "mobius", + "discrete_log", + "quadratic_congruence", + "binomial_coefficients", + "binomial_coefficients_list", + "multinomial_coefficients", + "continued_fraction_periodic", + "continued_fraction_iterator", + "continued_fraction_reduce", + "continued_fraction_convergents", + "continued_fraction", + "egyptian_fraction", + "product", + "Product", + "summation", + "Sum", + "fft", + "ifft", + "ntt", + "intt", + "fwht", + "ifwht", + "mobius_transform", + "inverse_mobius_transform", + "convolution", + "covering_product", + "intersecting_product", + "simplify", + "hypersimp", + "hypersimilar", + "logcombine", + "separatevars", + "posify", + "besselsimp", + "kroneckersimp", + "signsimp", + "nsimplify", + "FU", + "fu", + "sqrtdenest", + "cse", + "epath", + "EPath", + "hyperexpand", + "collect", + "rcollect", + "radsimp", + "collect_const", + "fraction", + "numer", + "denom", + "trigsimp", + "exptrigsimp", + "powsimp", + "powdenest", + "combsimp", + "gammasimp", + "ratsimp", + "ratsimpmodprime", + "Set", + "Interval", + "Union", + "EmptySet", + "FiniteSet", + "ProductSet", + "Intersection", + "imageset", + "DisjointUnion", + "Complement", + "SymmetricDifference", + "ImageSet", + "Range", + "ComplexRegion", + "Reals", + "Contains", + "ConditionSet", + "Ordinal", + "OmegaPower", + "ord0", + "PowerSet", + "Naturals", + "Naturals0", + "UniversalSet", + "Integers", + "Rationals", + "Complexes", + "solve", + "solve_linear_system", + "solve_linear_system_LU", + "solve_undetermined_coeffs", + "nsolve", + "solve_linear", + "checksol", + "det_quick", + "inv_quick", + "check_assumptions", + "failing_assumptions", + "diophantine", + "rsolve", + "rsolve_poly", + "rsolve_ratio", + "rsolve_hyper", + "checkodesol", + "classify_ode", + "dsolve", + "homogeneous_order", + "solve_poly_system", + "solve_triangulated", + "pde_separate", + "pde_separate_add", + "pde_separate_mul", + "pdsolve", + "classify_pde", + "checkpdesol", + "ode_order", + "reduce_inequalities", + "reduce_abs_inequality", + "reduce_abs_inequalities", + "solve_poly_inequality", + "solve_rational_inequalities", + "solve_univariate_inequality", + "decompogen", + "solveset", + "linsolve", + "linear_eq_to_matrix", + "nonlinsolve", + "substitution", + "ShapeError", + "NonSquareMatrixError", + "GramSchmidt", + "casoratian", + "diag", + "eye", + "hessian", + "jordan_cell", + "list2numpy", + "matrix2numpy", + "matrix_multiply_elementwise", + "ones", + "randMatrix", + "rot_axis1", + "rot_axis2", + "rot_axis3", + "symarray", + "wronskian", + "zeros", + "MutableDenseMatrix", + "DeferredVector", + "MatrixBase", + "Matrix", + "MutableMatrix", + "MutableSparseMatrix", + "banded", + "ImmutableDenseMatrix", + "ImmutableSparseMatrix", + "ImmutableMatrix", + "SparseMatrix", + "MatrixSlice", + "BlockDiagMatrix", + "BlockMatrix", + "FunctionMatrix", + "Identity", + "Inverse", + "MatAdd", + "MatMul", + "MatPow", + "MatrixExpr", + "MatrixSymbol", + "Trace", + "Transpose", + "ZeroMatrix", + "OneMatrix", + "blockcut", + "block_collapse", + "matrix_symbols", + "Adjoint", + "hadamard_product", + "HadamardProduct", + "HadamardPower", + "Determinant", + "det", + "diagonalize_vector", + "DiagMatrix", + "DiagonalMatrix", + "DiagonalOf", + "trace", + "DotProduct", + "kronecker_product", + "KroneckerProduct", + "PermutationMatrix", + "MatrixPermute", + "Permanent", + "per", + "rot_ccw_axis1", + "rot_ccw_axis2", + "rot_ccw_axis3", + "rot_givens", + "Point", + "Point2D", + "Point3D", + "Line", + "Ray", + "Segment", + "Line2D", + "Segment2D", + "Ray2D", + "Line3D", + "Segment3D", + "Ray3D", + "Plane", + "Ellipse", + "Circle", + "Polygon", + "RegularPolygon", + "Triangle", + "rad", + "deg", + "are_similar", + "centroid", + "convex_hull", + "idiff", + "intersection", + "closest_points", + "farthest_points", + "GeometryError", + "Curve", + "Parabola", + "flatten", + "group", + "take", + "subsets", + "variations", + "numbered_symbols", + "cartes", + "capture", + "dict_merge", + "prefixes", + "postfixes", + "sift", + "topological_sort", + "unflatten", + "has_dups", + "has_variety", + "reshape", + "rotations", + "filldedent", + "lambdify", + "threaded", + "xthreaded", + "public", + "memoize_property", + "timed", + "integrate", + "Integral", + "line_integrate", + "mellin_transform", + "inverse_mellin_transform", + "MellinTransform", + "InverseMellinTransform", + "laplace_transform", + "inverse_laplace_transform", + "LaplaceTransform", + "InverseLaplaceTransform", + "fourier_transform", + "inverse_fourier_transform", + "FourierTransform", + "InverseFourierTransform", + "sine_transform", + "inverse_sine_transform", + "SineTransform", + "InverseSineTransform", + "cosine_transform", + "inverse_cosine_transform", + "CosineTransform", + "InverseCosineTransform", + "hankel_transform", + "inverse_hankel_transform", + "HankelTransform", + "InverseHankelTransform", + "singularityintegrate", + "IndexedBase", + "Idx", + "Indexed", + "get_contraction_structure", + "get_indices", + "shape", + "MutableDenseNDimArray", + "ImmutableDenseNDimArray", + "MutableSparseNDimArray", + "ImmutableSparseNDimArray", + "NDimArray", + "tensorproduct", + "tensorcontraction", + "tensordiagonal", + "derive_by_array", + "permutedims", + "Array", + "DenseNDimArray", + "SparseNDimArray", + "parse_expr", + "euler_equations", + "singularities", + "is_increasing", + "is_strictly_increasing", + "is_decreasing", + "is_strictly_decreasing", + "is_monotonic", + "finite_diff_weights", + "apply_finite_diff", + "differentiate_finite", + "periodicity", + "not_empty_in", + "AccumBounds", + "is_convex", + "stationary_points", + "minimum", + "maximum", + "Quaternion", + "pager_print", + "pretty", + "pretty_print", + "pprint", + "pprint_use_unicode", + "pprint_try_use_unicode", + "latex", + "print_latex", + "multiline_latex", + "mathml", + "print_mathml", + "python", + "print_python", + "pycode", + "ccode", + "print_ccode", + "smtlib_code", + "glsl_code", + "print_glsl", + "cxxcode", + "fcode", + "print_fcode", + "rcode", + "print_rcode", + "jscode", + "print_jscode", + "julia_code", + "mathematica_code", + "octave_code", + "rust_code", + "print_gtk", + "preview", + "srepr", + "print_tree", + "StrPrinter", + "sstr", + "sstrrepr", + "TableForm", + "dotprint", + "maple_code", + "print_maple_code", + "plot", + "textplot", + "plot_backends", + "plot_implicit", + "plot_parametric", + "init_session", + "init_printing", + "interactive_traversal", + "test", + "doctest", +] diff --git a/stubs/sympy-stubs/algebras/quaternion.pyi b/stubs/sympy-stubs/algebras/quaternion.pyi index cdd4238a..8bdb3803 100644 --- a/stubs/sympy-stubs/algebras/quaternion.pyi +++ b/stubs/sympy-stubs/algebras/quaternion.pyi @@ -10,165 +10,65 @@ from sympy.matrices.dense import MutableDenseMatrix class Quaternion(Expr): _op_priority = ... is_commutative = ... - def __new__(cls, a=..., b=..., c=..., d=..., real_field=..., norm=...) -> Self: - ... - - def set_norm(self, norm) -> None: - ... - + def __new__(cls, a=..., b=..., c=..., d=..., real_field=..., norm=...) -> Self: ... + def set_norm(self, norm) -> None: ... @property - def a(self): - ... - + def a(self): ... @property - def b(self): - ... - + def b(self): ... @property - def c(self): - ... - + def c(self): ... @property - def d(self): - ... - + def d(self): ... @property - def real_field(self): - ... - + def real_field(self): ... @property - def product_matrix_left(self) -> MutableDenseMatrix: - ... - + def product_matrix_left(self) -> MutableDenseMatrix: ... @property - def product_matrix_right(self) -> MutableDenseMatrix: - ... - - def to_Matrix(self, vector_only=...) -> MutableDenseMatrix: - ... - + def product_matrix_right(self) -> MutableDenseMatrix: ... + def to_Matrix(self, vector_only=...) -> MutableDenseMatrix: ... @classmethod - def from_Matrix(cls, elements) -> Quaternion: - ... - + def from_Matrix(cls, elements) -> Quaternion: ... @classmethod - def from_euler(cls, angles, seq) -> Any: - ... - - def to_euler(self, seq, angle_addition=..., avoid_square_root=...) -> tuple[int, ...]: - ... - + def from_euler(cls, angles, seq) -> Any: ... + def to_euler(self, seq, angle_addition=..., avoid_square_root=...) -> tuple[int, ...]: ... @classmethod - def from_axis_angle(cls, vector, angle) -> Self: - ... - + def from_axis_angle(cls, vector, angle) -> Self: ... @classmethod - def from_rotation_matrix(cls, M) -> Quaternion: - ... - - def __add__(self, other) -> Quaternion: - ... - - def __radd__(self, other) -> Quaternion: - ... - - def __sub__(self, other) -> Quaternion: - ... - - def __mul__(self, other) -> Quaternion: - ... - - def __rmul__(self, other) -> Quaternion: - ... - - def __pow__(self, p) -> NotImplementedType | Quaternion | Literal[1]: - ... - - def __neg__(self) -> Quaternion: - ... - - def __truediv__(self, other): - ... - - def __rtruediv__(self, other): - ... - - def diff(self, *symbols, **kwargs) -> Self: - ... - - def add(self, other) -> Quaternion: - ... - - def mul(self, other) -> Quaternion: - ... - - def norm(self) -> Pow: - ... - - def normalize(self): - ... - - def inverse(self): - ... - - def pow(self, p) -> NotImplementedType | Quaternion | Literal[1]: - ... - - def exp(self) -> Quaternion: - ... - - def pow_cos_sin(self, p): - ... - - def integrate(self, *args) -> Quaternion: - ... - + def from_rotation_matrix(cls, M) -> Quaternion: ... + def __add__(self, other) -> Quaternion: ... + def __radd__(self, other) -> Quaternion: ... + def __sub__(self, other) -> Quaternion: ... + def __mul__(self, other) -> Quaternion: ... + def __rmul__(self, other) -> Quaternion: ... + def __pow__(self, p) -> NotImplementedType | Quaternion | Literal[1]: ... + def __neg__(self) -> Quaternion: ... + def __truediv__(self, other): ... + def __rtruediv__(self, other): ... + def diff(self, *symbols, **kwargs) -> Self: ... + def add(self, other) -> Quaternion: ... + def mul(self, other) -> Quaternion: ... + def norm(self) -> Pow: ... + def normalize(self): ... + def inverse(self): ... + def pow(self, p) -> NotImplementedType | Quaternion | Literal[1]: ... + def exp(self) -> Quaternion: ... + def pow_cos_sin(self, p): ... + def integrate(self, *args) -> Quaternion: ... @staticmethod - def rotate_point(pin, r) -> tuple[Any, Any, Any]: - ... - - def to_axis_angle(self) -> tuple[tuple[Any, Any, Any], Any]: - ... - - def to_rotation_matrix(self, v=..., homogeneous=...) -> MutableDenseMatrix: - ... - - def scalar_part(self): - ... - - def vector_part(self) -> Quaternion: - ... - - def axis(self) -> Quaternion: - ... - - def is_pure(self): - ... - - def is_zero_quaternion(self) -> bool | None: - ... - - def angle(self) -> type[UndefinedFunction]: - ... - - def arc_coplanar(self, other) -> bool | None: - ... - + def rotate_point(pin, r) -> tuple[Any, Any, Any]: ... + def to_axis_angle(self) -> tuple[tuple[Any, Any, Any], Any]: ... + def to_rotation_matrix(self, v=..., homogeneous=...) -> MutableDenseMatrix: ... + def scalar_part(self): ... + def vector_part(self) -> Quaternion: ... + def axis(self) -> Quaternion: ... + def is_pure(self): ... + def is_zero_quaternion(self) -> bool | None: ... + def angle(self) -> type[UndefinedFunction]: ... + def arc_coplanar(self, other) -> bool | None: ... @classmethod - def vector_coplanar(cls, q1, q2, q3) -> Any | bool | None: - ... - - def parallel(self, other): - ... - - def orthogonal(self, other): - ... - - def index_vector(self) -> Quaternion: - ... - - def mensor(self) -> type[UndefinedFunction]: - ... - - - + def vector_coplanar(cls, q1, q2, q3) -> Any | bool | None: ... + def parallel(self, other): ... + def orthogonal(self, other): ... + def index_vector(self) -> Quaternion: ... + def mensor(self) -> type[UndefinedFunction]: ... diff --git a/stubs/sympy-stubs/assumptions/__init__.pyi b/stubs/sympy-stubs/assumptions/__init__.pyi index 91919902..96b8d9c5 100644 --- a/stubs/sympy-stubs/assumptions/__init__.pyi +++ b/stubs/sympy-stubs/assumptions/__init__.pyi @@ -3,4 +3,17 @@ from sympy.assumptions.assume import AppliedPredicate, AssumptionsContext, Predi from sympy.assumptions.refine import refine from sympy.assumptions.relation import AppliedBinaryRelation, BinaryRelation -__all__ = ['AppliedPredicate', 'Predicate', 'AssumptionsContext', 'assuming', 'global_assumptions', 'Q', 'ask', 'register_handler', 'remove_handler', 'refine', 'BinaryRelation', 'AppliedBinaryRelation'] +__all__ = [ + "AppliedPredicate", + "Predicate", + "AssumptionsContext", + "assuming", + "global_assumptions", + "Q", + "ask", + "register_handler", + "remove_handler", + "refine", + "BinaryRelation", + "AppliedBinaryRelation", +] diff --git a/stubs/sympy-stubs/assumptions/ask.pyi b/stubs/sympy-stubs/assumptions/ask.pyi index 7ebfaeb8..d9e32dfd 100644 --- a/stubs/sympy-stubs/assumptions/ask.pyi +++ b/stubs/sympy-stubs/assumptions/ask.pyi @@ -10,234 +10,118 @@ from sympy.utilities.decorator import memoize_property class AssumptionKeys: @memoize_property - def hermitian(self) -> UndefinedPredicate | HermitianPredicate: - ... - + def hermitian(self) -> UndefinedPredicate | HermitianPredicate: ... @memoize_property - def antihermitian(self) -> UndefinedPredicate | AntihermitianPredicate: - ... - + def antihermitian(self) -> UndefinedPredicate | AntihermitianPredicate: ... @memoize_property - def real(self) -> UndefinedPredicate | RealPredicate: - ... - + def real(self) -> UndefinedPredicate | RealPredicate: ... @memoize_property - def extended_real(self) -> UndefinedPredicate | ExtendedRealPredicate: - ... - + def extended_real(self) -> UndefinedPredicate | ExtendedRealPredicate: ... @memoize_property - def imaginary(self) -> UndefinedPredicate | ImaginaryPredicate: - ... - + def imaginary(self) -> UndefinedPredicate | ImaginaryPredicate: ... @memoize_property - def complex(self) -> UndefinedPredicate | ComplexPredicate: - ... - + def complex(self) -> UndefinedPredicate | ComplexPredicate: ... @memoize_property - def algebraic(self) -> UndefinedPredicate | AlgebraicPredicate: - ... - + def algebraic(self) -> UndefinedPredicate | AlgebraicPredicate: ... @memoize_property - def transcendental(self) -> UndefinedPredicate | TranscendentalPredicate: - ... - + def transcendental(self) -> UndefinedPredicate | TranscendentalPredicate: ... @memoize_property - def integer(self) -> UndefinedPredicate | IntegerPredicate: - ... - + def integer(self) -> UndefinedPredicate | IntegerPredicate: ... @memoize_property - def rational(self) -> UndefinedPredicate | RationalPredicate: - ... - + def rational(self) -> UndefinedPredicate | RationalPredicate: ... @memoize_property - def irrational(self) -> UndefinedPredicate | IrrationalPredicate: - ... - + def irrational(self) -> UndefinedPredicate | IrrationalPredicate: ... @memoize_property - def finite(self) -> UndefinedPredicate | FinitePredicate: - ... - + def finite(self) -> UndefinedPredicate | FinitePredicate: ... @memoize_property - def infinite(self) -> UndefinedPredicate | InfinitePredicate: - ... - + def infinite(self) -> UndefinedPredicate | InfinitePredicate: ... @memoize_property - def positive_infinite(self) -> UndefinedPredicate | PositiveInfinitePredicate: - ... - + def positive_infinite(self) -> UndefinedPredicate | PositiveInfinitePredicate: ... @memoize_property - def negative_infinite(self) -> UndefinedPredicate | NegativeInfinitePredicate: - ... - + def negative_infinite(self) -> UndefinedPredicate | NegativeInfinitePredicate: ... @memoize_property - def positive(self) -> UndefinedPredicate | PositivePredicate: - ... - + def positive(self) -> UndefinedPredicate | PositivePredicate: ... @memoize_property - def negative(self) -> UndefinedPredicate | NegativePredicate: - ... - + def negative(self) -> UndefinedPredicate | NegativePredicate: ... @memoize_property - def zero(self) -> UndefinedPredicate | ZeroPredicate: - ... - + def zero(self) -> UndefinedPredicate | ZeroPredicate: ... @memoize_property - def extended_positive(self) -> UndefinedPredicate | ExtendedPositivePredicate: - ... - + def extended_positive(self) -> UndefinedPredicate | ExtendedPositivePredicate: ... @memoize_property - def extended_negative(self) -> UndefinedPredicate | ExtendedNegativePredicate: - ... - + def extended_negative(self) -> UndefinedPredicate | ExtendedNegativePredicate: ... @memoize_property - def nonzero(self) -> UndefinedPredicate | NonZeroPredicate: - ... - + def nonzero(self) -> UndefinedPredicate | NonZeroPredicate: ... @memoize_property - def nonpositive(self) -> UndefinedPredicate | NonPositivePredicate: - ... - + def nonpositive(self) -> UndefinedPredicate | NonPositivePredicate: ... @memoize_property - def nonnegative(self) -> UndefinedPredicate | NonNegativePredicate: - ... - + def nonnegative(self) -> UndefinedPredicate | NonNegativePredicate: ... @memoize_property - def extended_nonzero(self) -> UndefinedPredicate | ExtendedNonZeroPredicate: - ... - + def extended_nonzero(self) -> UndefinedPredicate | ExtendedNonZeroPredicate: ... @memoize_property - def extended_nonpositive(self) -> UndefinedPredicate | ExtendedNonPositivePredicate: - ... - + def extended_nonpositive(self) -> UndefinedPredicate | ExtendedNonPositivePredicate: ... @memoize_property - def extended_nonnegative(self) -> UndefinedPredicate | ExtendedNonNegativePredicate: - ... - + def extended_nonnegative(self) -> UndefinedPredicate | ExtendedNonNegativePredicate: ... @memoize_property - def even(self) -> UndefinedPredicate | EvenPredicate: - ... - + def even(self) -> UndefinedPredicate | EvenPredicate: ... @memoize_property - def odd(self) -> UndefinedPredicate | OddPredicate: - ... - + def odd(self) -> UndefinedPredicate | OddPredicate: ... @memoize_property - def prime(self) -> UndefinedPredicate | PrimePredicate: - ... - + def prime(self) -> UndefinedPredicate | PrimePredicate: ... @memoize_property - def composite(self) -> UndefinedPredicate | CompositePredicate: - ... - + def composite(self) -> UndefinedPredicate | CompositePredicate: ... @memoize_property - def commutative(self) -> UndefinedPredicate | CommutativePredicate: - ... - + def commutative(self) -> UndefinedPredicate | CommutativePredicate: ... @memoize_property - def is_true(self) -> UndefinedPredicate | IsTruePredicate: - ... - + def is_true(self) -> UndefinedPredicate | IsTruePredicate: ... @memoize_property - def symmetric(self) -> UndefinedPredicate | SymmetricPredicate: - ... - + def symmetric(self) -> UndefinedPredicate | SymmetricPredicate: ... @memoize_property - def invertible(self) -> UndefinedPredicate | InvertiblePredicate: - ... - + def invertible(self) -> UndefinedPredicate | InvertiblePredicate: ... @memoize_property - def orthogonal(self) -> UndefinedPredicate | OrthogonalPredicate: - ... - + def orthogonal(self) -> UndefinedPredicate | OrthogonalPredicate: ... @memoize_property - def unitary(self) -> UndefinedPredicate | UnitaryPredicate: - ... - + def unitary(self) -> UndefinedPredicate | UnitaryPredicate: ... @memoize_property - def positive_definite(self) -> UndefinedPredicate | PositiveDefinitePredicate: - ... - + def positive_definite(self) -> UndefinedPredicate | PositiveDefinitePredicate: ... @memoize_property - def upper_triangular(self) -> UndefinedPredicate | UpperTriangularPredicate: - ... - + def upper_triangular(self) -> UndefinedPredicate | UpperTriangularPredicate: ... @memoize_property - def lower_triangular(self) -> UndefinedPredicate | LowerTriangularPredicate: - ... - + def lower_triangular(self) -> UndefinedPredicate | LowerTriangularPredicate: ... @memoize_property - def diagonal(self) -> UndefinedPredicate | DiagonalPredicate: - ... - + def diagonal(self) -> UndefinedPredicate | DiagonalPredicate: ... @memoize_property - def fullrank(self) -> UndefinedPredicate | FullRankPredicate: - ... - + def fullrank(self) -> UndefinedPredicate | FullRankPredicate: ... @memoize_property - def square(self) -> UndefinedPredicate | SquarePredicate: - ... - + def square(self) -> UndefinedPredicate | SquarePredicate: ... @memoize_property - def integer_elements(self) -> UndefinedPredicate | IntegerElementsPredicate: - ... - + def integer_elements(self) -> UndefinedPredicate | IntegerElementsPredicate: ... @memoize_property - def real_elements(self) -> UndefinedPredicate | RealElementsPredicate: - ... - + def real_elements(self) -> UndefinedPredicate | RealElementsPredicate: ... @memoize_property - def complex_elements(self) -> UndefinedPredicate | ComplexElementsPredicate: - ... - + def complex_elements(self) -> UndefinedPredicate | ComplexElementsPredicate: ... @memoize_property - def singular(self) -> UndefinedPredicate | SingularPredicate: - ... - + def singular(self) -> UndefinedPredicate | SingularPredicate: ... @memoize_property - def normal(self) -> UndefinedPredicate | NormalPredicate: - ... - + def normal(self) -> UndefinedPredicate | NormalPredicate: ... @memoize_property - def triangular(self) -> UndefinedPredicate | TriangularPredicate: - ... - + def triangular(self) -> UndefinedPredicate | TriangularPredicate: ... @memoize_property - def unit_triangular(self) -> UndefinedPredicate | UnitTriangularPredicate: - ... - + def unit_triangular(self) -> UndefinedPredicate | UnitTriangularPredicate: ... @memoize_property - def eq(self) -> UndefinedPredicate | EqualityPredicate: - ... - + def eq(self) -> UndefinedPredicate | EqualityPredicate: ... @memoize_property - def ne(self) -> UndefinedPredicate | UnequalityPredicate: - ... - + def ne(self) -> UndefinedPredicate | UnequalityPredicate: ... @memoize_property - def gt(self) -> UndefinedPredicate | StrictGreaterThanPredicate: - ... - + def gt(self) -> UndefinedPredicate | StrictGreaterThanPredicate: ... @memoize_property - def ge(self) -> UndefinedPredicate | GreaterThanPredicate: - ... - + def ge(self) -> UndefinedPredicate | GreaterThanPredicate: ... @memoize_property - def lt(self) -> UndefinedPredicate | StrictLessThanPredicate: - ... - + def lt(self) -> UndefinedPredicate | StrictLessThanPredicate: ... @memoize_property - def le(self) -> UndefinedPredicate | LessThanPredicate: - ... - - + def le(self) -> UndefinedPredicate | LessThanPredicate: ... Q = ... -def ask(proposition, assumptions=..., context=...) -> bool | None: - ... - -def register_handler(key, handler) -> None: - ... - -def remove_handler(key, handler) -> None: - ... +def ask(proposition, assumptions=..., context=...) -> bool | None: ... +def register_handler(key, handler) -> None: ... +def remove_handler(key, handler) -> None: ... diff --git a/stubs/sympy-stubs/assumptions/ask_generated.pyi b/stubs/sympy-stubs/assumptions/ask_generated.pyi index 351cc7ba..5bd519e7 100644 --- a/stubs/sympy-stubs/assumptions/ask_generated.pyi +++ b/stubs/sympy-stubs/assumptions/ask_generated.pyi @@ -4,10 +4,6 @@ from sympy.assumptions.cnf import AND, OR, Literal from sympy.core.cache import cacheit @cacheit -def get_all_known_facts() -> set[frozenset[OR | AND | Literal]]: - ... - +def get_all_known_facts() -> set[frozenset[OR | AND | Literal]]: ... @cacheit -def get_known_facts_dict() -> dict[Any, Any]: - ... - +def get_known_facts_dict() -> dict[Any, Any]: ... diff --git a/stubs/sympy-stubs/assumptions/assume.pyi b/stubs/sympy-stubs/assumptions/assume.pyi index a5dcfe44..4f0d9643 100644 --- a/stubs/sympy-stubs/assumptions/assume.pyi +++ b/stubs/sympy-stubs/assumptions/assume.pyi @@ -5,97 +5,51 @@ from sympy.core.basic import Basic from sympy.logic.boolalg import Boolean class AssumptionsContext(set): - def add(self, *assumptions) -> None: - ... - - + def add(self, *assumptions) -> None: ... global_assumptions = ... + class AppliedPredicate(Boolean): __slots__ = ... - def __new__(cls, predicate, *args) -> Self: - ... - + def __new__(cls, predicate, *args) -> Self: ... @property - def arg(self) -> Basic: - ... - + def arg(self) -> Basic: ... @property - def function(self) -> Basic: - ... - + def function(self) -> Basic: ... @property - def arguments(self) -> tuple[Basic, ...]: - ... - + def arguments(self) -> tuple[Basic, ...]: ... @property - def binary_symbols(self) -> set[Basic] | set[Any]: - ... - - + def binary_symbols(self) -> set[Basic] | set[Any]: ... class PredicateMeta(type): - def __new__(cls, clsname, bases, dct) -> Self: # type: ignore - ... - - @property - def __doc__(cls): + def __new__(cls, clsname, bases, dct) -> Self: # type: ignore ... - + @property + def __doc__(cls): ... class Predicate(Boolean, metaclass=PredicateMeta): is_Atom = ... - def __new__(cls, *args, **kwargs) -> UndefinedPredicate | Self: - ... - + def __new__(cls, *args, **kwargs) -> UndefinedPredicate | Self: ... @property - def name(self) -> str: - ... - + def name(self) -> str: ... @classmethod - def register(cls, *types, **kwargs): - ... - + def register(cls, *types, **kwargs): ... @classmethod - def register_many(cls, *types, **kwargs) -> Callable[..., None]: - ... - - def __call__(self, *args) -> AppliedPredicate: - ... - - def eval(self, args, assumptions=...) -> None: - ... - - + def register_many(cls, *types, **kwargs) -> Callable[..., None]: ... + def __call__(self, *args) -> AppliedPredicate: ... + def eval(self, args, assumptions=...) -> None: ... class UndefinedPredicate(Predicate): handler = ... - def __new__(cls, name, handlers=...) -> Self: - ... - + def __new__(cls, name, handlers=...) -> Self: ... @property - def name(self) -> Basic: - ... - - def __getnewargs__(self) -> tuple[Basic]: - ... - - def __call__(self, expr) -> AppliedPredicate: - ... - - def add_handler(self, handler) -> None: - ... - - def remove_handler(self, handler) -> None: - ... - - def eval(self, args, assumptions=...) -> Any | None: - ... - - + def name(self) -> Basic: ... + def __getnewargs__(self) -> tuple[Basic]: ... + def __call__(self, expr) -> AppliedPredicate: ... + def add_handler(self, handler) -> None: ... + def remove_handler(self, handler) -> None: ... + def eval(self, args, assumptions=...) -> Any | None: ... @contextmanager -def assuming(*assumptions) -> Generator[None, Any, None]: - ... - +def assuming(*assumptions) -> Generator[None, Any, None]: ... diff --git a/stubs/sympy-stubs/assumptions/cnf.pyi b/stubs/sympy-stubs/assumptions/cnf.pyi index bdd654cb..e2edc7a2 100644 --- a/stubs/sympy-stubs/assumptions/cnf.pyi +++ b/stubs/sympy-stubs/assumptions/cnf.pyi @@ -3,168 +3,74 @@ from typing import Any, Self from sympy.core.logic import And class Literal: - def __new__(cls, lit, is_Not=...) -> OR | AND | Literal | Self: - ... - + def __new__(cls, lit, is_Not=...) -> OR | AND | Literal | Self: ... @property - def arg(self): - ... - - def rcall(self, expr) -> Self: - ... - - def __invert__(self) -> Literal: - ... - - def __str__(self) -> str: - ... - - __repr__ = ... - def __eq__(self, other) -> bool: - ... - - def __hash__(self) -> int: - ... - + def arg(self): ... + def rcall(self, expr) -> Self: ... + def __invert__(self) -> Literal: ... + def __str__(self) -> str: ... + __repr__ = ... + def __eq__(self, other) -> bool: ... + def __hash__(self) -> int: ... class OR: - def __init__(self, *args) -> None: - ... - + def __init__(self, *args) -> None: ... @property - def args(self) -> list[Any]: - ... - - def rcall(self, expr) -> Self: - ... - - def __invert__(self) -> AND: - ... - - def __hash__(self) -> int: - ... - - def __eq__(self, other) -> bool: - ... - - def __str__(self) -> str: - ... - - __repr__ = ... + def args(self) -> list[Any]: ... + def rcall(self, expr) -> Self: ... + def __invert__(self) -> AND: ... + def __hash__(self) -> int: ... + def __eq__(self, other) -> bool: ... + def __str__(self) -> str: ... + __repr__ = ... class AND: - def __init__(self, *args) -> None: - ... - - def __invert__(self) -> OR: - ... - + def __init__(self, *args) -> None: ... + def __invert__(self) -> OR: ... @property - def args(self) -> list[Any]: - ... - - def rcall(self, expr) -> Self: - ... - - def __hash__(self) -> int: - ... - - def __eq__(self, other) -> bool: - ... - - def __str__(self) -> str: - ... - - __repr__ = ... + def args(self) -> list[Any]: ... + def rcall(self, expr) -> Self: ... + def __hash__(self) -> int: ... + def __eq__(self, other) -> bool: ... + def __str__(self) -> str: ... + __repr__ = ... -def to_NNF(expr, composite_map=...) -> OR | AND | Literal: - ... - -def distribute_AND_over_OR(expr) -> CNF | None: - ... +def to_NNF(expr, composite_map=...) -> OR | AND | Literal: ... +def distribute_AND_over_OR(expr) -> CNF | None: ... class CNF: - def __init__(self, clauses=...) -> None: - ... - - def add(self, prop) -> None: - ... - - def __str__(self) -> str: - ... - - def extend(self, props) -> Self: - ... - - def copy(self) -> CNF: - ... - - def add_clauses(self, clauses) -> None: - ... - + def __init__(self, clauses=...) -> None: ... + def add(self, prop) -> None: ... + def __str__(self) -> str: ... + def extend(self, props) -> Self: ... + def copy(self) -> CNF: ... + def add_clauses(self, clauses) -> None: ... @classmethod - def from_prop(cls, prop) -> Self: - ... - - def __iand__(self, other) -> Self: - ... - - def all_predicates(self) -> set[Any]: - ... - - def rcall(self, expr) -> CNF | None: - ... - + def from_prop(cls, prop) -> Self: ... + def __iand__(self, other) -> Self: ... + def all_predicates(self) -> set[Any]: ... + def rcall(self, expr) -> CNF | None: ... @classmethod - def all_or(cls, *cnfs): - ... - + def all_or(cls, *cnfs): ... @classmethod - def all_and(cls, *cnfs): - ... - + def all_and(cls, *cnfs): ... @classmethod - def to_CNF(cls, expr) -> CNF | None: - ... - + def to_CNF(cls, expr) -> CNF | None: ... @classmethod - def CNF_to_cnf(cls, cnf) -> And: - ... - - + def CNF_to_cnf(cls, cnf) -> And: ... class EncodedCNF: - def __init__(self, data=..., encoding=...) -> None: - ... - - def from_cnf(self, cnf) -> None: - ... - + def __init__(self, data=..., encoding=...) -> None: ... + def from_cnf(self, cnf) -> None: ... @property - def symbols(self) -> list[Any]: - ... - + def symbols(self) -> list[Any]: ... @property - def variables(self) -> range: - ... - - def copy(self) -> EncodedCNF: - ... - - def add_prop(self, prop) -> None: - ... - - def add_from_cnf(self, cnf) -> None: - ... - - def encode_arg(self, arg) -> int: - ... - - def encode(self, clause) -> set[int | Any]: - ... - - - + def variables(self) -> range: ... + def copy(self) -> EncodedCNF: ... + def add_prop(self, prop) -> None: ... + def add_from_cnf(self, cnf) -> None: ... + def encode_arg(self, arg) -> int: ... + def encode(self, clause) -> set[int | Any]: ... diff --git a/stubs/sympy-stubs/assumptions/facts.pyi b/stubs/sympy-stubs/assumptions/facts.pyi index ffccf377..c064b1e6 100644 --- a/stubs/sympy-stubs/assumptions/facts.pyi +++ b/stubs/sympy-stubs/assumptions/facts.pyi @@ -4,23 +4,11 @@ from sympy.core.cache import cacheit from sympy.core.logic import And @cacheit -def get_composite_predicates() -> dict[Any, Any]: - ... - +def get_composite_predicates() -> dict[Any, Any]: ... @cacheit -def get_known_facts(x=...) -> And: - ... - -def generate_known_facts_dict(keys, fact) -> dict[Any, Any]: - ... - +def get_known_facts(x=...) -> And: ... +def generate_known_facts_dict(keys, fact) -> dict[Any, Any]: ... @cacheit -def get_known_facts_keys() -> list[Any]: - ... - -def single_fact_lookup(known_facts_keys, known_facts_cnf) -> dict[Any, Any]: - ... - -def ask_full_inference(proposition, assumptions, known_facts_cnf) -> bool | None: - ... - +def get_known_facts_keys() -> list[Any]: ... +def single_fact_lookup(known_facts_keys, known_facts_cnf) -> dict[Any, Any]: ... +def ask_full_inference(proposition, assumptions, known_facts_cnf) -> bool | None: ... diff --git a/stubs/sympy-stubs/assumptions/handlers/__init__.pyi b/stubs/sympy-stubs/assumptions/handlers/__init__.pyi index 89ccaafa..a96ed6c9 100644 --- a/stubs/sympy-stubs/assumptions/handlers/__init__.pyi +++ b/stubs/sympy-stubs/assumptions/handlers/__init__.pyi @@ -1,3 +1,3 @@ from sympy.assumptions.handlers.common import AskHandler, CommonHandler, test_closed_group -__all__ = ['AskHandler', 'CommonHandler', 'test_closed_group'] +__all__ = ["AskHandler", "CommonHandler", "test_closed_group"] diff --git a/stubs/sympy-stubs/assumptions/handlers/calculus.pyi b/stubs/sympy-stubs/assumptions/handlers/calculus.pyi index 95228d4b..3793b366 100644 --- a/stubs/sympy-stubs/assumptions/handlers/calculus.pyi +++ b/stubs/sympy-stubs/assumptions/handlers/calculus.pyi @@ -22,58 +22,30 @@ from sympy.core.numbers import ( from sympy.functions import cos, exp, log, sign, sin @FinitePredicate.register(Symbol) -def _(expr, assumptions) -> Literal[True] | None: - ... - +def _(expr, assumptions) -> Literal[True] | None: ... @FinitePredicate.register(Add) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @FinitePredicate.register(Mul) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @FinitePredicate.register(Pow) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @FinitePredicate.register(exp) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @FinitePredicate.register(log) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @FinitePredicate.register_many(cos, sin, Number, Pi, Exp1, GoldenRatio, TribonacciConstant, ImaginaryUnit, sign) -def _(expr, assumptions) -> Literal[True]: - ... - +def _(expr, assumptions) -> Literal[True]: ... @FinitePredicate.register_many(ComplexInfinity, Infinity, NegativeInfinity) -def _(expr, assumptions) -> Literal[False]: - ... - +def _(expr, assumptions) -> Literal[False]: ... @FinitePredicate.register(NaN) -def _(expr, assumptions) -> None: - ... - +def _(expr, assumptions) -> None: ... @InfinitePredicate.register_many(ComplexInfinity, Infinity, NegativeInfinity) -def _(expr, assumptions) -> Literal[True]: - ... - +def _(expr, assumptions) -> Literal[True]: ... @PositiveInfinitePredicate.register(Infinity) -def _(expr, assumptions) -> Literal[True]: - ... - +def _(expr, assumptions) -> Literal[True]: ... @PositiveInfinitePredicate.register_many(NegativeInfinity, ComplexInfinity) -def _(expr, assumptions) -> Literal[False]: - ... - +def _(expr, assumptions) -> Literal[False]: ... @NegativeInfinitePredicate.register(NegativeInfinity) -def _(expr, assumptions) -> Literal[True]: - ... - +def _(expr, assumptions) -> Literal[True]: ... @NegativeInfinitePredicate.register_many(Infinity, ComplexInfinity) -def _(expr, assumptions) -> Literal[False]: - ... - +def _(expr, assumptions) -> Literal[False]: ... diff --git a/stubs/sympy-stubs/assumptions/handlers/common.pyi b/stubs/sympy-stubs/assumptions/handlers/common.pyi index 5296dbb7..1a2f9d2f 100644 --- a/stubs/sympy-stubs/assumptions/handlers/common.pyi +++ b/stubs/sympy-stubs/assumptions/handlers/common.pyi @@ -7,79 +7,42 @@ from sympy.core.numbers import NaN, Number from sympy.logic.boolalg import And, BooleanFalse, BooleanTrue, Equivalent, Implies, Not, Or class AskHandler: - def __new__(cls, *args, **kwargs) -> Self: - ... - - + def __new__(cls, *args, **kwargs) -> Self: ... class CommonHandler(AskHandler): @staticmethod - def AlwaysTrue(expr, assumptions) -> Literal[True]: - ... - + def AlwaysTrue(expr, assumptions) -> Literal[True]: ... @staticmethod - def AlwaysFalse(expr, assumptions) -> Literal[False]: - ... - + def AlwaysFalse(expr, assumptions) -> Literal[False]: ... @staticmethod - def AlwaysNone(expr, assumptions) -> None: - ... - - NaN = ... + def AlwaysNone(expr, assumptions) -> None: ... + NaN = ... @CommutativePredicate.register(Symbol) -def _(expr, assumptions) -> bool: - ... - +def _(expr, assumptions) -> bool: ... @CommutativePredicate.register(Basic) -def _(expr, assumptions) -> bool: - ... - +def _(expr, assumptions) -> bool: ... @CommutativePredicate.register(Number) -def _(expr, assumptions) -> Literal[True]: - ... - +def _(expr, assumptions) -> Literal[True]: ... @CommutativePredicate.register(NaN) -def _(expr, assumptions) -> Literal[True]: - ... - +def _(expr, assumptions) -> Literal[True]: ... @IsTruePredicate.register(bool) -def _(expr, assumptions): - ... - +def _(expr, assumptions): ... @IsTruePredicate.register(BooleanTrue) -def _(expr, assumptions) -> Literal[True]: - ... - +def _(expr, assumptions) -> Literal[True]: ... @IsTruePredicate.register(BooleanFalse) -def _(expr, assumptions) -> Literal[False]: - ... - +def _(expr, assumptions) -> Literal[False]: ... @IsTruePredicate.register(AppliedPredicate) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @IsTruePredicate.register(Not) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @IsTruePredicate.register(Or) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @IsTruePredicate.register(And) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @IsTruePredicate.register(Implies) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @IsTruePredicate.register(Equivalent) -def _(expr, assumptions) -> bool | None: - ... - -def test_closed_group(expr, assumptions, key) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... +def test_closed_group(expr, assumptions, key) -> bool | None: ... diff --git a/stubs/sympy-stubs/assumptions/handlers/matrices.pyi b/stubs/sympy-stubs/assumptions/handlers/matrices.pyi index 24334fa3..f6ada825 100644 --- a/stubs/sympy-stubs/assumptions/handlers/matrices.pyi +++ b/stubs/sympy-stubs/assumptions/handlers/matrices.pyi @@ -40,415 +40,207 @@ from sympy.matrices.expressions.factorizations import Factorization from sympy.matrices.expressions.fourier import DFT @SquarePredicate.register(MatrixExpr) -def _(expr, assumptions): - ... - +def _(expr, assumptions): ... @SymmetricPredicate.register(MatMul) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @SymmetricPredicate.register(MatPow) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @SymmetricPredicate.register(MatAdd) -def _(expr, assumptions) -> bool: - ... - +def _(expr, assumptions) -> bool: ... @SymmetricPredicate.register(MatrixSymbol) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @SymmetricPredicate.register_many(OneMatrix, ZeroMatrix) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @SymmetricPredicate.register_many(Inverse, Transpose) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @SymmetricPredicate.register(MatrixSlice) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @SymmetricPredicate.register(Identity) -def _(expr, assumptions) -> Literal[True]: - ... - +def _(expr, assumptions) -> Literal[True]: ... @InvertiblePredicate.register(MatMul) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @InvertiblePredicate.register(MatPow) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @InvertiblePredicate.register(MatAdd) -def _(expr, assumptions) -> None: - ... - +def _(expr, assumptions) -> None: ... @InvertiblePredicate.register(MatrixSymbol) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @InvertiblePredicate.register_many(Identity, Inverse) -def _(expr, assumptions) -> Literal[True]: - ... - +def _(expr, assumptions) -> Literal[True]: ... @InvertiblePredicate.register(ZeroMatrix) -def _(expr, assumptions) -> Literal[False]: - ... - +def _(expr, assumptions) -> Literal[False]: ... @InvertiblePredicate.register(OneMatrix) -def _(expr, assumptions): - ... - +def _(expr, assumptions): ... @InvertiblePredicate.register(Transpose) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @InvertiblePredicate.register(MatrixSlice) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @InvertiblePredicate.register(MatrixBase) -def _(expr, assumptions) -> Literal[False]: - ... - +def _(expr, assumptions) -> Literal[False]: ... @InvertiblePredicate.register(MatrixExpr) -def _(expr, assumptions) -> Literal[False] | None: - ... - +def _(expr, assumptions) -> Literal[False] | None: ... @InvertiblePredicate.register(BlockMatrix) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @InvertiblePredicate.register(BlockDiagMatrix) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @OrthogonalPredicate.register(MatMul) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @OrthogonalPredicate.register(MatPow) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @OrthogonalPredicate.register(MatAdd) -def _(expr, assumptions) -> Literal[True] | None: - ... - +def _(expr, assumptions) -> Literal[True] | None: ... @OrthogonalPredicate.register(MatrixSymbol) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @OrthogonalPredicate.register(Identity) -def _(expr, assumptions) -> Literal[True]: - ... - +def _(expr, assumptions) -> Literal[True]: ... @OrthogonalPredicate.register(ZeroMatrix) -def _(expr, assumptions) -> Literal[False]: - ... - +def _(expr, assumptions) -> Literal[False]: ... @OrthogonalPredicate.register_many(Inverse, Transpose) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @OrthogonalPredicate.register(MatrixSlice) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @OrthogonalPredicate.register(Factorization) -def _(expr, assumptions) -> Literal[True] | None: - ... - +def _(expr, assumptions) -> Literal[True] | None: ... @UnitaryPredicate.register(MatMul) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @UnitaryPredicate.register(MatPow) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @UnitaryPredicate.register(MatrixSymbol) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @UnitaryPredicate.register_many(Inverse, Transpose) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @UnitaryPredicate.register(MatrixSlice) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @UnitaryPredicate.register_many(DFT, Identity) -def _(expr, assumptions) -> Literal[True]: - ... - +def _(expr, assumptions) -> Literal[True]: ... @UnitaryPredicate.register(ZeroMatrix) -def _(expr, assumptions) -> Literal[False]: - ... - +def _(expr, assumptions) -> Literal[False]: ... @UnitaryPredicate.register(Factorization) -def _(expr, assumptions) -> Literal[True] | None: - ... - +def _(expr, assumptions) -> Literal[True] | None: ... @FullRankPredicate.register(MatMul) -def _(expr, assumptions) -> Literal[True] | None: - ... - +def _(expr, assumptions) -> Literal[True] | None: ... @FullRankPredicate.register(MatPow) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @FullRankPredicate.register(Identity) -def _(expr, assumptions) -> Literal[True]: - ... - +def _(expr, assumptions) -> Literal[True]: ... @FullRankPredicate.register(ZeroMatrix) -def _(expr, assumptions) -> Literal[False]: - ... - +def _(expr, assumptions) -> Literal[False]: ... @FullRankPredicate.register(OneMatrix) -def _(expr, assumptions): - ... - +def _(expr, assumptions): ... @FullRankPredicate.register_many(Inverse, Transpose) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @FullRankPredicate.register(MatrixSlice) -def _(expr, assumptions) -> Literal[True] | None: - ... - +def _(expr, assumptions) -> Literal[True] | None: ... @PositiveDefinitePredicate.register(MatMul) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @PositiveDefinitePredicate.register(MatPow) -def _(expr, assumptions) -> Literal[True] | None: - ... - +def _(expr, assumptions) -> Literal[True] | None: ... @PositiveDefinitePredicate.register(MatAdd) -def _(expr, assumptions) -> Literal[True] | None: - ... - +def _(expr, assumptions) -> Literal[True] | None: ... @PositiveDefinitePredicate.register(MatrixSymbol) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @PositiveDefinitePredicate.register(Identity) -def _(expr, assumptions) -> Literal[True]: - ... - +def _(expr, assumptions) -> Literal[True]: ... @PositiveDefinitePredicate.register(ZeroMatrix) -def _(expr, assumptions) -> Literal[False]: - ... - +def _(expr, assumptions) -> Literal[False]: ... @PositiveDefinitePredicate.register(OneMatrix) -def _(expr, assumptions): - ... - +def _(expr, assumptions): ... @PositiveDefinitePredicate.register_many(Inverse, Transpose) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @PositiveDefinitePredicate.register(MatrixSlice) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @UpperTriangularPredicate.register(MatMul) -def _(expr, assumptions) -> Literal[True] | None: - ... - +def _(expr, assumptions) -> Literal[True] | None: ... @UpperTriangularPredicate.register(MatAdd) -def _(expr, assumptions) -> Literal[True] | None: - ... - +def _(expr, assumptions) -> Literal[True] | None: ... @UpperTriangularPredicate.register(MatPow) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @UpperTriangularPredicate.register(MatrixSymbol) -def _(expr, assumptions) -> Literal[True] | None: - ... - +def _(expr, assumptions) -> Literal[True] | None: ... @UpperTriangularPredicate.register_many(Identity, ZeroMatrix) -def _(expr, assumptions) -> Literal[True]: - ... - +def _(expr, assumptions) -> Literal[True]: ... @UpperTriangularPredicate.register(OneMatrix) -def _(expr, assumptions): - ... - +def _(expr, assumptions): ... @UpperTriangularPredicate.register(Transpose) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @UpperTriangularPredicate.register(Inverse) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @UpperTriangularPredicate.register(MatrixSlice) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @UpperTriangularPredicate.register(Factorization) -def _(expr, assumptions) -> Literal[True] | None: - ... - +def _(expr, assumptions) -> Literal[True] | None: ... @LowerTriangularPredicate.register(MatMul) -def _(expr, assumptions) -> Literal[True] | None: - ... - +def _(expr, assumptions) -> Literal[True] | None: ... @LowerTriangularPredicate.register(MatAdd) -def _(expr, assumptions) -> Literal[True] | None: - ... - +def _(expr, assumptions) -> Literal[True] | None: ... @LowerTriangularPredicate.register(MatPow) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @LowerTriangularPredicate.register(MatrixSymbol) -def _(expr, assumptions) -> Literal[True] | None: - ... - +def _(expr, assumptions) -> Literal[True] | None: ... @LowerTriangularPredicate.register_many(Identity, ZeroMatrix) -def _(expr, assumptions) -> Literal[True]: - ... - +def _(expr, assumptions) -> Literal[True]: ... @LowerTriangularPredicate.register(OneMatrix) -def _(expr, assumptions): - ... - +def _(expr, assumptions): ... @LowerTriangularPredicate.register(Transpose) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @LowerTriangularPredicate.register(Inverse) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @LowerTriangularPredicate.register(MatrixSlice) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @LowerTriangularPredicate.register(Factorization) -def _(expr, assumptions) -> Literal[True] | None: - ... - +def _(expr, assumptions) -> Literal[True] | None: ... @DiagonalPredicate.register(MatMul) -def _(expr, assumptions) -> Literal[True] | None: - ... - +def _(expr, assumptions) -> Literal[True] | None: ... @DiagonalPredicate.register(MatPow) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @DiagonalPredicate.register(MatAdd) -def _(expr, assumptions) -> Literal[True] | None: - ... - +def _(expr, assumptions) -> Literal[True] | None: ... @DiagonalPredicate.register(MatrixSymbol) -def _(expr, assumptions) -> Literal[True] | None: - ... - +def _(expr, assumptions) -> Literal[True] | None: ... @DiagonalPredicate.register(OneMatrix) -def _(expr, assumptions): - ... - +def _(expr, assumptions): ... @DiagonalPredicate.register_many(Inverse, Transpose) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @DiagonalPredicate.register(MatrixSlice) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @DiagonalPredicate.register_many(DiagonalMatrix, DiagMatrix, Identity, ZeroMatrix) -def _(expr, assumptions) -> Literal[True]: - ... - +def _(expr, assumptions) -> Literal[True]: ... @DiagonalPredicate.register(Factorization) -def _(expr, assumptions) -> Literal[True] | None: - ... - -def BM_elements(predicate, expr, assumptions) -> bool: - ... - -def MS_elements(predicate, expr, assumptions) -> bool | None: - ... - -def MatMul_elements(matrix_predicate, scalar_predicate, expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> Literal[True] | None: ... +def BM_elements(predicate, expr, assumptions) -> bool: ... +def MS_elements(predicate, expr, assumptions) -> bool | None: ... +def MatMul_elements(matrix_predicate, scalar_predicate, expr, assumptions) -> bool | None: ... @IntegerElementsPredicate.register_many(Determinant, HadamardProduct, MatAdd, Trace, Transpose) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @IntegerElementsPredicate.register(MatPow) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @IntegerElementsPredicate.register_many(Identity, OneMatrix, ZeroMatrix) -def _(expr, assumptions) -> Literal[True]: - ... - +def _(expr, assumptions) -> Literal[True]: ... @IntegerElementsPredicate.register(MatMul) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @IntegerElementsPredicate.register(MatrixSlice) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @IntegerElementsPredicate.register(BlockMatrix) -def _(expr, assumptions) -> bool: - ... - +def _(expr, assumptions) -> bool: ... @RealElementsPredicate.register_many(Determinant, Factorization, HadamardProduct, MatAdd, Trace, Transpose) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @RealElementsPredicate.register(MatPow) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @RealElementsPredicate.register(MatMul) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @RealElementsPredicate.register(MatrixSlice) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @RealElementsPredicate.register(BlockMatrix) -def _(expr, assumptions) -> bool: - ... - +def _(expr, assumptions) -> bool: ... @ComplexElementsPredicate.register_many(Determinant, Factorization, HadamardProduct, Inverse, MatAdd, Trace, Transpose) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @ComplexElementsPredicate.register(MatPow) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @ComplexElementsPredicate.register(MatMul) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @ComplexElementsPredicate.register(MatrixSlice) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @ComplexElementsPredicate.register(BlockMatrix) -def _(expr, assumptions) -> bool: - ... - +def _(expr, assumptions) -> bool: ... @ComplexElementsPredicate.register(DFT) -def _(expr, assumptions) -> Literal[True]: - ... - +def _(expr, assumptions) -> Literal[True]: ... diff --git a/stubs/sympy-stubs/assumptions/handlers/ntheory.pyi b/stubs/sympy-stubs/assumptions/handlers/ntheory.pyi index 515148bb..7e03620e 100644 --- a/stubs/sympy-stubs/assumptions/handlers/ntheory.pyi +++ b/stubs/sympy-stubs/assumptions/handlers/ntheory.pyi @@ -6,102 +6,52 @@ from sympy.core.numbers import ImaginaryUnit, Infinity, Integer, NaN, NegativeIn from sympy.functions import Abs, im, re @PrimePredicate.register(Expr) -def _(expr, assumptions): - ... - +def _(expr, assumptions): ... @PrimePredicate.register(Basic) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @PrimePredicate.register(Mul) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @PrimePredicate.register(Pow) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @PrimePredicate.register(Integer) -def _(expr, assumptions) -> bool: - ... - +def _(expr, assumptions) -> bool: ... @PrimePredicate.register_many(Rational, Infinity, NegativeInfinity, ImaginaryUnit) -def _(expr, assumptions) -> Literal[False]: - ... - +def _(expr, assumptions) -> Literal[False]: ... @PrimePredicate.register(Float) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @PrimePredicate.register(NumberSymbol) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @PrimePredicate.register(NaN) -def _(expr, assumptions) -> None: - ... - +def _(expr, assumptions) -> None: ... @CompositePredicate.register(Expr) -def _(expr, assumptions): - ... - +def _(expr, assumptions): ... @CompositePredicate.register(Basic) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @EvenPredicate.register(Expr) -def _(expr, assumptions): - ... - +def _(expr, assumptions): ... @EvenPredicate.register(Basic) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @EvenPredicate.register(Mul) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @EvenPredicate.register(Add) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @EvenPredicate.register(Pow) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @EvenPredicate.register(Integer) -def _(expr, assumptions) -> bool: - ... - +def _(expr, assumptions) -> bool: ... @EvenPredicate.register_many(Rational, Infinity, NegativeInfinity, ImaginaryUnit) -def _(expr, assumptions) -> Literal[False]: - ... - +def _(expr, assumptions) -> Literal[False]: ... @EvenPredicate.register(NumberSymbol) -def _(expr, assumptions) -> bool: - ... - +def _(expr, assumptions) -> bool: ... @EvenPredicate.register(Abs) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @EvenPredicate.register(re) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @EvenPredicate.register(im) -def _(expr, assumptions) -> Literal[True] | None: - ... - +def _(expr, assumptions) -> Literal[True] | None: ... @EvenPredicate.register(NaN) -def _(expr, assumptions) -> None: - ... - +def _(expr, assumptions) -> None: ... @OddPredicate.register(Expr) -def _(expr, assumptions): - ... - +def _(expr, assumptions): ... @OddPredicate.register(Basic) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... diff --git a/stubs/sympy-stubs/assumptions/handlers/order.pyi b/stubs/sympy-stubs/assumptions/handlers/order.pyi index 17174533..48cb362c 100644 --- a/stubs/sympy-stubs/assumptions/handlers/order.pyi +++ b/stubs/sympy-stubs/assumptions/handlers/order.pyi @@ -20,178 +20,90 @@ from sympy.matrices import Determinant, Trace from sympy.matrices.expressions.matexpr import MatrixElement @NegativePredicate.register(Basic) -def _(expr, assumptions) -> Literal[False] | None: - ... - +def _(expr, assumptions) -> Literal[False] | None: ... @NegativePredicate.register(Expr) -def _(expr, assumptions): - ... - +def _(expr, assumptions): ... @NegativePredicate.register(Add) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @NegativePredicate.register(Mul) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @NegativePredicate.register(Pow) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @NegativePredicate.register_many(Abs, ImaginaryUnit) -def _(expr, assumptions) -> Literal[False]: - ... - +def _(expr, assumptions) -> Literal[False]: ... @NegativePredicate.register(exp) -def _(expr, assumptions) -> Literal[False]: - ... - +def _(expr, assumptions) -> Literal[False]: ... @NonNegativePredicate.register(Basic) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @NonNegativePredicate.register(Expr) -def _(expr, assumptions): - ... - +def _(expr, assumptions): ... @NonZeroPredicate.register(Expr) -def _(expr, assumptions): - ... - +def _(expr, assumptions): ... @NonZeroPredicate.register(Basic) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @NonZeroPredicate.register(Add) -def _(expr, assumptions) -> Literal[True] | None: - ... - +def _(expr, assumptions) -> Literal[True] | None: ... @NonZeroPredicate.register(Mul) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @NonZeroPredicate.register(Pow) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @NonZeroPredicate.register(Abs) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @NonZeroPredicate.register(NaN) -def _(expr, assumptions) -> None: - ... - +def _(expr, assumptions) -> None: ... @ZeroPredicate.register(Expr) -def _(expr, assumptions): - ... - +def _(expr, assumptions): ... @ZeroPredicate.register(Basic) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @ZeroPredicate.register(Mul) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @NonPositivePredicate.register(Expr) -def _(expr, assumptions): - ... - +def _(expr, assumptions): ... @NonPositivePredicate.register(Basic) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @PositivePredicate.register(Expr) -def _(expr, assumptions): - ... - +def _(expr, assumptions): ... @PositivePredicate.register(Basic) -def _(expr, assumptions) -> Literal[False] | None: - ... - +def _(expr, assumptions) -> Literal[False] | None: ... @PositivePredicate.register(Mul) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @PositivePredicate.register(Add) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @PositivePredicate.register(Pow) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @PositivePredicate.register(exp) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @PositivePredicate.register(log) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @PositivePredicate.register(factorial) -def _(expr, assumptions) -> Literal[True] | None: - ... - +def _(expr, assumptions) -> Literal[True] | None: ... @PositivePredicate.register(ImaginaryUnit) -def _(expr, assumptions) -> Literal[False]: - ... - +def _(expr, assumptions) -> Literal[False]: ... @PositivePredicate.register(Abs) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @PositivePredicate.register(Trace) -def _(expr, assumptions) -> Literal[True] | None: - ... - +def _(expr, assumptions) -> Literal[True] | None: ... @PositivePredicate.register(Determinant) -def _(expr, assumptions) -> Literal[True] | None: - ... - +def _(expr, assumptions) -> Literal[True] | None: ... @PositivePredicate.register(MatrixElement) -def _(expr, assumptions) -> Literal[True] | None: - ... - +def _(expr, assumptions) -> Literal[True] | None: ... @PositivePredicate.register(atan) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @PositivePredicate.register(asin) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @PositivePredicate.register(acos) -def _(expr, assumptions) -> Literal[True] | None: - ... - +def _(expr, assumptions) -> Literal[True] | None: ... @PositivePredicate.register(acot) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @PositivePredicate.register(NaN) -def _(expr, assumptions) -> None: - ... - +def _(expr, assumptions) -> None: ... @ExtendedNegativePredicate.register(object) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @ExtendedPositivePredicate.register(object) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @ExtendedNonZeroPredicate.register(object) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @ExtendedNonPositivePredicate.register(object) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @ExtendedNonNegativePredicate.register(object) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... diff --git a/stubs/sympy-stubs/assumptions/handlers/sets.pyi b/stubs/sympy-stubs/assumptions/handlers/sets.pyi index 0fc0ddda..261dabea 100644 --- a/stubs/sympy-stubs/assumptions/handlers/sets.pyi +++ b/stubs/sympy-stubs/assumptions/handlers/sets.pyi @@ -35,278 +35,140 @@ from sympy.matrices import Determinant, MatrixBase, Trace from sympy.matrices.expressions.matexpr import MatrixElement @IntegerPredicate.register_many(int, Integer) -def _(expr, assumptions) -> Literal[True]: - ... - +def _(expr, assumptions) -> Literal[True]: ... @IntegerPredicate.register_many(Exp1, GoldenRatio, ImaginaryUnit, Infinity, NegativeInfinity, Pi, Rational, TribonacciConstant) -def _(expr, assumptions) -> Literal[False]: - ... - +def _(expr, assumptions) -> Literal[False]: ... @IntegerPredicate.register(Expr) -def _(expr, assumptions): - ... - +def _(expr, assumptions): ... @IntegerPredicate.register_many(Add, Pow) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @IntegerPredicate.register(Mul) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @IntegerPredicate.register(Abs) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @IntegerPredicate.register_many(Determinant, MatrixElement, Trace) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @RationalPredicate.register(Rational) -def _(expr, assumptions) -> Literal[True]: - ... - +def _(expr, assumptions) -> Literal[True]: ... @RationalPredicate.register(Float) -def _(expr, assumptions) -> None: - ... - +def _(expr, assumptions) -> None: ... @RationalPredicate.register_many(Exp1, GoldenRatio, ImaginaryUnit, Infinity, NegativeInfinity, Pi, TribonacciConstant) -def _(expr, assumptions) -> Literal[False]: - ... - +def _(expr, assumptions) -> Literal[False]: ... @RationalPredicate.register(Expr) -def _(expr, assumptions): - ... - +def _(expr, assumptions): ... @RationalPredicate.register_many(Add, Mul) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @RationalPredicate.register(Pow) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @RationalPredicate.register_many(asin, atan, cos, sin, tan) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @RationalPredicate.register(exp) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @RationalPredicate.register_many(acot, cot) -def _(expr, assumptions) -> Literal[False] | None: - ... - +def _(expr, assumptions) -> Literal[False] | None: ... @RationalPredicate.register_many(acos, log) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @IrrationalPredicate.register(Expr) -def _(expr, assumptions): - ... - +def _(expr, assumptions): ... @IrrationalPredicate.register(Basic) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @RealPredicate.register_many(Abs, Exp1, Float, GoldenRatio, im, Pi, Rational, re, TribonacciConstant) -def _(expr, assumptions) -> Literal[True]: - ... - +def _(expr, assumptions) -> Literal[True]: ... @RealPredicate.register_many(ImaginaryUnit, Infinity, NegativeInfinity) -def _(expr, assumptions) -> Literal[False]: - ... - +def _(expr, assumptions) -> Literal[False]: ... @RealPredicate.register(Expr) -def _(expr, assumptions): - ... - +def _(expr, assumptions): ... @RealPredicate.register(Add) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @RealPredicate.register(Mul) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @RealPredicate.register(Pow) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @RealPredicate.register_many(cos, sin) -def _(expr, assumptions) -> Literal[True] | None: - ... - +def _(expr, assumptions) -> Literal[True] | None: ... @RealPredicate.register(exp) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @RealPredicate.register(log) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @RealPredicate.register_many(Determinant, MatrixElement, Trace) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @ExtendedRealPredicate.register(object) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @ExtendedRealPredicate.register_many(Infinity, NegativeInfinity) -def _(expr, assumptions) -> Literal[True]: - ... - +def _(expr, assumptions) -> Literal[True]: ... @ExtendedRealPredicate.register_many(Add, Mul, Pow) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @HermitianPredicate.register(object) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @HermitianPredicate.register(Add) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @HermitianPredicate.register(Mul) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @HermitianPredicate.register(Pow) -def _(expr, assumptions) -> Literal[True]: - ... - +def _(expr, assumptions) -> Literal[True]: ... @HermitianPredicate.register_many(cos, sin) -def _(expr, assumptions) -> Literal[True]: - ... - +def _(expr, assumptions) -> Literal[True]: ... @HermitianPredicate.register(exp) -def _(expr, assumptions) -> Literal[True]: - ... - +def _(expr, assumptions) -> Literal[True]: ... @HermitianPredicate.register(MatrixBase) -def _(mat, assumptions) -> bool: - ... - +def _(mat, assumptions) -> bool: ... @ComplexPredicate.register_many(Abs, cos, exp, im, ImaginaryUnit, log, Number, NumberSymbol, re, sin) -def _(expr, assumptions) -> Literal[True]: - ... - +def _(expr, assumptions) -> Literal[True]: ... @ComplexPredicate.register_many(Infinity, NegativeInfinity) -def _(expr, assumptions) -> Literal[False]: - ... - +def _(expr, assumptions) -> Literal[False]: ... @ComplexPredicate.register(Expr) -def _(expr, assumptions): - ... - +def _(expr, assumptions): ... @ComplexPredicate.register_many(Add, Mul) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @ComplexPredicate.register(Pow) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @ComplexPredicate.register_many(Determinant, MatrixElement, Trace) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @ComplexPredicate.register(NaN) -def _(expr, assumptions) -> None: - ... - +def _(expr, assumptions) -> None: ... @ImaginaryPredicate.register(ImaginaryUnit) -def _(expr, assumptions) -> Literal[True]: - ... - +def _(expr, assumptions) -> Literal[True]: ... @ImaginaryPredicate.register(Expr) -def _(expr, assumptions): - ... - +def _(expr, assumptions): ... @ImaginaryPredicate.register(Add) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @ImaginaryPredicate.register(Mul) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @ImaginaryPredicate.register(Pow) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @ImaginaryPredicate.register(log) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @ImaginaryPredicate.register(exp) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @ImaginaryPredicate.register_many(Number, NumberSymbol) -def _(expr, assumptions) -> bool: - ... - +def _(expr, assumptions) -> bool: ... @ImaginaryPredicate.register(NaN) -def _(expr, assumptions) -> None: - ... - +def _(expr, assumptions) -> None: ... @AntihermitianPredicate.register(object) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @AntihermitianPredicate.register(Add) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @AntihermitianPredicate.register(Mul) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @AntihermitianPredicate.register(Pow) -def _(expr, assumptions) -> bool: - ... - +def _(expr, assumptions) -> bool: ... @AntihermitianPredicate.register(MatrixBase) -def _(mat, assumptions) -> bool: - ... - +def _(mat, assumptions) -> bool: ... @AlgebraicPredicate.register_many(AlgebraicNumber, Float, GoldenRatio, ImaginaryUnit, TribonacciConstant) -def _(expr, assumptions) -> Literal[True]: - ... - +def _(expr, assumptions) -> Literal[True]: ... @AlgebraicPredicate.register_many(ComplexInfinity, Exp1, Infinity, NegativeInfinity, Pi) -def _(expr, assumptions) -> Literal[False]: - ... - +def _(expr, assumptions) -> Literal[False]: ... @AlgebraicPredicate.register_many(Add, Mul) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @AlgebraicPredicate.register(Pow) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @AlgebraicPredicate.register(Rational) -def _(expr, assumptions): - ... - +def _(expr, assumptions): ... @AlgebraicPredicate.register_many(asin, atan, cos, sin, tan) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @AlgebraicPredicate.register(exp) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... @AlgebraicPredicate.register_many(acot, cot) -def _(expr, assumptions) -> Literal[False] | None: - ... - +def _(expr, assumptions) -> Literal[False] | None: ... @AlgebraicPredicate.register_many(acos, log) -def _(expr, assumptions) -> bool | None: - ... - +def _(expr, assumptions) -> bool | None: ... diff --git a/stubs/sympy-stubs/assumptions/predicates/common.pyi b/stubs/sympy-stubs/assumptions/predicates/common.pyi index a07454fb..dbb7b08c 100644 --- a/stubs/sympy-stubs/assumptions/predicates/common.pyi +++ b/stubs/sympy-stubs/assumptions/predicates/common.pyi @@ -7,13 +7,9 @@ class CommutativePredicate(Predicate): name = ... handler = ... - binrelpreds = ... + class IsTruePredicate(Predicate): name = ... handler = ... - def __call__(self, arg) -> AppliedPredicate | Any: - ... - - - + def __call__(self, arg) -> AppliedPredicate | Any: ... diff --git a/stubs/sympy-stubs/assumptions/predicates/matrices.pyi b/stubs/sympy-stubs/assumptions/predicates/matrices.pyi index 5975f823..07d543cd 100644 --- a/stubs/sympy-stubs/assumptions/predicates/matrices.pyi +++ b/stubs/sympy-stubs/assumptions/predicates/matrices.pyi @@ -7,18 +7,14 @@ class SquarePredicate(Predicate): name: LiteralString = ... handler: Dispatcher = ... - - class SymmetricPredicate(Predicate): name: LiteralString = ... handler: Dispatcher = ... - class InvertiblePredicate(Predicate): name: LiteralString = ... handler: Dispatcher = ... - class OrthogonalPredicate(Predicate): name: LiteralString = ... handler: Dispatcher = ... @@ -27,47 +23,38 @@ class UnitaryPredicate(Predicate): name: LiteralString = ... handler: Dispatcher = ... - class FullRankPredicate(Predicate): name: LiteralString = ... handler: Dispatcher = ... - class PositiveDefinitePredicate(Predicate): name: LiteralString = ... handler: Dispatcher = ... - class UpperTriangularPredicate(Predicate): name: LiteralString = ... handler: Dispatcher = ... - class LowerTriangularPredicate(Predicate): name: LiteralString = ... handler: Dispatcher = ... - class DiagonalPredicate(Predicate): name: LiteralString = ... handler: Dispatcher = ... - class IntegerElementsPredicate(Predicate): name: LiteralString = ... handler: Dispatcher = ... - class RealElementsPredicate(Predicate): name: LiteralString = ... handler: Dispatcher = ... - class ComplexElementsPredicate(Predicate): name: LiteralString = ... handler: Dispatcher = ... - class SingularPredicate(Predicate): name: LiteralString = ... handler: Dispatcher = ... @@ -76,12 +63,10 @@ class NormalPredicate(Predicate): name: LiteralString = ... handler: Dispatcher = ... - class TriangularPredicate(Predicate): name: LiteralString = ... handler: Dispatcher = ... - class UnitTriangularPredicate(Predicate): name: LiteralString = ... handler: Dispatcher = ... diff --git a/stubs/sympy-stubs/assumptions/predicates/ntheory.pyi b/stubs/sympy-stubs/assumptions/predicates/ntheory.pyi index 038de51f..6ec4c53c 100644 --- a/stubs/sympy-stubs/assumptions/predicates/ntheory.pyi +++ b/stubs/sympy-stubs/assumptions/predicates/ntheory.pyi @@ -7,17 +7,14 @@ class PrimePredicate(Predicate): name: LiteralString = ... handler: Dispatcher = ... - class CompositePredicate(Predicate): name: LiteralString = ... handler: Dispatcher = ... - class EvenPredicate(Predicate): name: LiteralString = ... handler: Dispatcher = ... - class OddPredicate(Predicate): name: LiteralString = ... handler: Dispatcher = ... diff --git a/stubs/sympy-stubs/assumptions/predicates/order.pyi b/stubs/sympy-stubs/assumptions/predicates/order.pyi index bc9ca791..8a4a0aec 100644 --- a/stubs/sympy-stubs/assumptions/predicates/order.pyi +++ b/stubs/sympy-stubs/assumptions/predicates/order.pyi @@ -7,17 +7,14 @@ class NegativePredicate(Predicate): name: LiteralString = ... handler: Dispatcher = ... - class NonNegativePredicate(Predicate): name: LiteralString = ... handler: Dispatcher = ... - class NonZeroPredicate(Predicate): name: LiteralString = ... handler: Dispatcher = ... - class ZeroPredicate(Predicate): name: LiteralString = ... handler: Dispatcher = ... @@ -30,12 +27,10 @@ class PositivePredicate(Predicate): name: LiteralString = ... handler: Dispatcher = ... - class ExtendedPositivePredicate(Predicate): name: LiteralString = ... handler: Dispatcher = ... - class ExtendedNegativePredicate(Predicate): name: LiteralString = ... handler: Dispatcher = ... @@ -44,12 +39,10 @@ class ExtendedNonZeroPredicate(Predicate): name: LiteralString = ... handler: Dispatcher = ... - class ExtendedNonPositivePredicate(Predicate): name: LiteralString = ... handler: Dispatcher = ... - class ExtendedNonNegativePredicate(Predicate): name: LiteralString = ... handler: Dispatcher = ... diff --git a/stubs/sympy-stubs/assumptions/refine.pyi b/stubs/sympy-stubs/assumptions/refine.pyi index 9f1ad924..437386f0 100644 --- a/stubs/sympy-stubs/assumptions/refine.pyi +++ b/stubs/sympy-stubs/assumptions/refine.pyi @@ -6,31 +6,14 @@ from sympy.core.function import UndefinedFunction from sympy.logic.boolalg import Boolean from sympy.matrices.expressions.matexpr import MatrixElement -def refine(expr, assumptions=...) -> Basic: - ... - -def refine_abs(expr, assumptions) -> None: - ... - -def refine_Pow(expr, assumptions): - ... - -def refine_atan2(expr, assumptions) -> type[UndefinedFunction]: - ... - -def refine_re(expr, assumptions) -> Basic | None: - ... - -def refine_im(expr, assumptions) -> Basic | None: - ... - -def refine_arg(expr, assumptions) -> None: - ... - -def refine_sign(expr, assumptions): - ... - -def refine_matrixelement(expr, assumptions) -> MatrixElement | None: - ... +def refine(expr, assumptions=...) -> Basic: ... +def refine_abs(expr, assumptions) -> None: ... +def refine_Pow(expr, assumptions): ... +def refine_atan2(expr, assumptions) -> type[UndefinedFunction]: ... +def refine_re(expr, assumptions) -> Basic | None: ... +def refine_im(expr, assumptions) -> Basic | None: ... +def refine_arg(expr, assumptions) -> None: ... +def refine_sign(expr, assumptions): ... +def refine_matrixelement(expr, assumptions) -> MatrixElement | None: ... handlers_dict: dict[str, Callable[[Expr, Boolean], Expr]] = ... diff --git a/stubs/sympy-stubs/assumptions/relation/__init__.pyi b/stubs/sympy-stubs/assumptions/relation/__init__.pyi index a2d90446..8761b5cd 100644 --- a/stubs/sympy-stubs/assumptions/relation/__init__.pyi +++ b/stubs/sympy-stubs/assumptions/relation/__init__.pyi @@ -1,3 +1,3 @@ from sympy.assumptions.relation.binrel import AppliedBinaryRelation, BinaryRelation -__all__ = ['BinaryRelation', 'AppliedBinaryRelation'] +__all__ = ["BinaryRelation", "AppliedBinaryRelation"] diff --git a/stubs/sympy-stubs/assumptions/relation/binrel.pyi b/stubs/sympy-stubs/assumptions/relation/binrel.pyi index 8fde70f8..01541f8b 100644 --- a/stubs/sympy-stubs/assumptions/relation/binrel.pyi +++ b/stubs/sympy-stubs/assumptions/relation/binrel.pyi @@ -5,48 +5,26 @@ from sympy.core.basic import Basic from sympy.core.logic import Not __all__ = ["BinaryRelation", "AppliedBinaryRelation"] + class BinaryRelation(Predicate): is_reflexive: Optional[bool] = ... is_symmetric: Optional[bool] = ... - def __call__(self, *args) -> AppliedBinaryRelation: - ... - + def __call__(self, *args) -> AppliedBinaryRelation: ... @property - def reversed(self) -> Self | None: - ... - + def reversed(self) -> Self | None: ... @property - def negated(self) -> None: - ... - - def eval(self, args, assumptions=...) -> bool: - ... - - + def negated(self) -> None: ... + def eval(self, args, assumptions=...) -> bool: ... class AppliedBinaryRelation(AppliedPredicate): @property - def lhs(self) -> Basic: - ... - + def lhs(self) -> Basic: ... @property - def rhs(self) -> Basic: - ... - + def rhs(self) -> Basic: ... @property - def reversed(self) -> Self: - ... - + def reversed(self) -> Self: ... @property - def reversedsign(self) -> Self: - ... - + def reversedsign(self) -> Self: ... @property - def negated(self) -> Not: - ... - - def __bool__(self) -> bool: - ... - - - + def negated(self) -> Not: ... + def __bool__(self) -> bool: ... diff --git a/stubs/sympy-stubs/assumptions/relation/equality.pyi b/stubs/sympy-stubs/assumptions/relation/equality.pyi index 5d076c07..65dd456d 100644 --- a/stubs/sympy-stubs/assumptions/relation/equality.pyi +++ b/stubs/sympy-stubs/assumptions/relation/equality.pyi @@ -2,20 +2,23 @@ from typing import Any from sympy.assumptions.relation.binrel import BinaryRelation -__all__ = ['EqualityPredicate', 'UnequalityPredicate', 'StrictGreaterThanPredicate', 'GreaterThanPredicate', 'StrictLessThanPredicate', 'LessThanPredicate'] +__all__ = [ + "EqualityPredicate", + "UnequalityPredicate", + "StrictGreaterThanPredicate", + "GreaterThanPredicate", + "StrictLessThanPredicate", + "LessThanPredicate", +] + class EqualityPredicate(BinaryRelation): is_reflexive = ... is_symmetric = ... name = ... handler = ... @property - def negated(self) -> Any: - ... - - def eval(self, args, assumptions=...): - ... - - + def negated(self) -> Any: ... + def eval(self, args, assumptions=...): ... class UnequalityPredicate(BinaryRelation): is_reflexive = ... @@ -23,13 +26,8 @@ class UnequalityPredicate(BinaryRelation): name = ... handler = ... @property - def negated(self) -> Any: - ... - - def eval(self, args, assumptions=...): - ... - - + def negated(self) -> Any: ... + def eval(self, args, assumptions=...): ... class StrictGreaterThanPredicate(BinaryRelation): is_reflexive = ... @@ -37,17 +35,10 @@ class StrictGreaterThanPredicate(BinaryRelation): name = ... handler = ... @property - def reversed(self) -> Any: - ... - + def reversed(self) -> Any: ... @property - def negated(self) -> Any: - ... - - def eval(self, args, assumptions=...): - ... - - + def negated(self) -> Any: ... + def eval(self, args, assumptions=...): ... class GreaterThanPredicate(BinaryRelation): is_reflexive = ... @@ -55,17 +46,10 @@ class GreaterThanPredicate(BinaryRelation): name = ... handler = ... @property - def reversed(self) -> Any: - ... - + def reversed(self) -> Any: ... @property - def negated(self) -> Any: - ... - - def eval(self, args, assumptions=...): - ... - - + def negated(self) -> Any: ... + def eval(self, args, assumptions=...): ... class StrictLessThanPredicate(BinaryRelation): is_reflexive = ... @@ -73,17 +57,10 @@ class StrictLessThanPredicate(BinaryRelation): name = ... handler = ... @property - def reversed(self) -> Any: - ... - + def reversed(self) -> Any: ... @property - def negated(self) -> Any: - ... - - def eval(self, args, assumptions=...): - ... - - + def negated(self) -> Any: ... + def eval(self, args, assumptions=...): ... class LessThanPredicate(BinaryRelation): is_reflexive = ... @@ -91,15 +68,7 @@ class LessThanPredicate(BinaryRelation): name = ... handler = ... @property - def reversed(self) -> Any: - ... - + def reversed(self) -> Any: ... @property - def negated(self) -> Any: - ... - - def eval(self, args, assumptions=...): - ... - - - + def negated(self) -> Any: ... + def eval(self, args, assumptions=...): ... diff --git a/stubs/sympy-stubs/assumptions/satask.pyi b/stubs/sympy-stubs/assumptions/satask.pyi index 1b6b6870..49fc271f 100644 --- a/stubs/sympy-stubs/assumptions/satask.pyi +++ b/stubs/sympy-stubs/assumptions/satask.pyi @@ -2,21 +2,9 @@ from typing import Any from sympy.assumptions.cnf import CNF, EncodedCNF -def satask(proposition, assumptions=..., context=..., use_known_facts=..., iterations=...) -> bool | None: - ... - -def check_satisfiability(prop, _prop, factbase) -> bool | None: - ... - -def extract_predargs(proposition, assumptions=..., context=...) -> set[Any]: - ... - -def find_symbols(pred) -> set[Any]: - ... - -def get_relevant_clsfacts(exprs, relevant_facts=...) -> tuple[Any, CNF | Any]: - ... - -def get_all_relevant_facts(proposition, assumptions, context, use_known_facts=..., iterations=...) -> EncodedCNF: - ... - +def satask(proposition, assumptions=..., context=..., use_known_facts=..., iterations=...) -> bool | None: ... +def check_satisfiability(prop, _prop, factbase) -> bool | None: ... +def extract_predargs(proposition, assumptions=..., context=...) -> set[Any]: ... +def find_symbols(pred) -> set[Any]: ... +def get_relevant_clsfacts(exprs, relevant_facts=...) -> tuple[Any, CNF | Any]: ... +def get_all_relevant_facts(proposition, assumptions, context, use_known_facts=..., iterations=...) -> EncodedCNF: ... diff --git a/stubs/sympy-stubs/assumptions/sathandlers.pyi b/stubs/sympy-stubs/assumptions/sathandlers.pyi index 05abd8ba..a763fd92 100644 --- a/stubs/sympy-stubs/assumptions/sathandlers.pyi +++ b/stubs/sympy-stubs/assumptions/sathandlers.pyi @@ -7,77 +7,42 @@ from sympy.functions.elementary.complexes import Abs from sympy.logic.boolalg import Implies from sympy.matrices.expressions import MatMul -def allargs(symbol, fact, expr) -> And: - ... - -def anyarg(symbol, fact, expr) -> Or: - ... - -def exactlyonearg(symbol, fact, expr) -> Or: - ... +def allargs(symbol, fact, expr) -> And: ... +def anyarg(symbol, fact, expr) -> Or: ... +def exactlyonearg(symbol, fact, expr) -> Or: ... class ClassFactRegistry: - def __init__(self) -> None: - ... - - def register(self, cls) -> Callable[..., Any]: - ... - - def multiregister(self, *classes) -> Callable[..., Any]: - ... - - def __getitem__(self, key) -> tuple[frozenset[Any], frozenset[Any]]: - ... - - def __call__(self, expr) -> set[Any]: - ... - - + def __init__(self) -> None: ... + def register(self, cls) -> Callable[..., Any]: ... + def multiregister(self, *classes) -> Callable[..., Any]: ... + def __getitem__(self, key) -> tuple[frozenset[Any], frozenset[Any]]: ... + def __call__(self, expr) -> set[Any]: ... class_fact_registry = ... x = ... -@class_fact_registry.multiregister(Abs) -def _(expr) -> list[Any]: - ... +@class_fact_registry.multiregister(Abs) +def _(expr) -> list[Any]: ... @class_fact_registry.multiregister(Add) -def _(expr) -> list[Any]: - ... - +def _(expr) -> list[Any]: ... @class_fact_registry.register(Add) -def _(expr) -> Implies: - ... - +def _(expr) -> Implies: ... @class_fact_registry.multiregister(Mul) -def _(expr) -> list[Any]: - ... - +def _(expr) -> list[Any]: ... @class_fact_registry.register(Mul) -def _(expr) -> Implies: - ... - +def _(expr) -> Implies: ... @class_fact_registry.register(Mul) -def _(expr) -> Implies: - ... - +def _(expr) -> Implies: ... @class_fact_registry.register(Mul) -def _(expr) -> Implies: - ... - +def _(expr) -> Implies: ... @class_fact_registry.register(Mul) -def _(expr) -> Implies: - ... - +def _(expr) -> Implies: ... @class_fact_registry.register(MatMul) -def _(expr) -> Implies: - ... - +def _(expr) -> Implies: ... @class_fact_registry.multiregister(Pow) -def _(expr) -> list[Any]: - ... +def _(expr) -> list[Any]: ... _old_assump_getters = ... -@class_fact_registry.multiregister(Number, NumberSymbol, ImaginaryUnit) -def _(expr) -> list[Any]: - ... +@class_fact_registry.multiregister(Number, NumberSymbol, ImaginaryUnit) +def _(expr) -> list[Any]: ... diff --git a/stubs/sympy-stubs/assumptions/wrapper.pyi b/stubs/sympy-stubs/assumptions/wrapper.pyi index 5314e73f..2e538ddd 100644 --- a/stubs/sympy-stubs/assumptions/wrapper.pyi +++ b/stubs/sympy-stubs/assumptions/wrapper.pyi @@ -2,13 +2,11 @@ from typing import Callable, Self from sympy.core.basic import Basic -def make_eval_method(fact) -> Callable[..., bool | None]: - ... +def make_eval_method(fact) -> Callable[..., bool | None]: ... class AssumptionsWrapper(Basic): - def __new__(cls, expr, assumptions=...) -> Self: - ... - + def __new__(cls, expr, assumptions=...) -> Self: ... + _eval_is_algebraic = ... _eval_is_antihermitian = ... _eval_is_commutative = ... @@ -41,13 +39,6 @@ class AssumptionsWrapper(Basic): _eval_is_transcendental = ... _eval_is_zero = ... - -def is_infinite(obj, assumptions=...) -> bool | None: - ... - -def is_extended_real(obj, assumptions=...) -> bool | None: - ... - -def is_extended_nonnegative(obj, assumptions=...) -> bool | None: - ... - +def is_infinite(obj, assumptions=...) -> bool | None: ... +def is_extended_real(obj, assumptions=...) -> bool | None: ... +def is_extended_nonnegative(obj, assumptions=...) -> bool | None: ... diff --git a/stubs/sympy-stubs/calculus/__init__.pyi b/stubs/sympy-stubs/calculus/__init__.pyi index d32b498b..2606d62a 100644 --- a/stubs/sympy-stubs/calculus/__init__.pyi +++ b/stubs/sympy-stubs/calculus/__init__.pyi @@ -11,4 +11,22 @@ from sympy.calculus.singularities import ( ) from sympy.calculus.util import is_convex, maximum, minimum, not_empty_in, periodicity, stationary_points -__all__ = ['euler_equations', 'singularities', 'is_increasing', 'is_strictly_increasing', 'is_decreasing', 'is_strictly_decreasing', 'is_monotonic', 'finite_diff_weights', 'apply_finite_diff', 'differentiate_finite', 'periodicity', 'not_empty_in', 'is_convex', 'stationary_points', 'minimum', 'maximum', 'AccumBounds'] +__all__ = [ + "euler_equations", + "singularities", + "is_increasing", + "is_strictly_increasing", + "is_decreasing", + "is_strictly_decreasing", + "is_monotonic", + "finite_diff_weights", + "apply_finite_diff", + "differentiate_finite", + "periodicity", + "not_empty_in", + "is_convex", + "stationary_points", + "minimum", + "maximum", + "AccumBounds", +] diff --git a/stubs/sympy-stubs/calculus/accumulationbounds.pyi b/stubs/sympy-stubs/calculus/accumulationbounds.pyi index 6074d75f..4d5dfde8 100644 --- a/stubs/sympy-stubs/calculus/accumulationbounds.pyi +++ b/stubs/sympy-stubs/calculus/accumulationbounds.pyi @@ -11,75 +11,41 @@ from sympy.series.order import Order class AccumulationBounds(Expr): is_extended_real = ... is_number = ... - def __new__(cls, min, max) -> Self: - ... - + def __new__(cls, min, max) -> Self: ... + _op_priority = ... @property - def min(self) -> Basic: - ... - + def min(self) -> Basic: ... @property - def max(self) -> Basic: - ... - + def max(self) -> Basic: ... @property - def delta(self): - ... - + def delta(self): ... @property - def mid(self): - ... - - @_sympifyit('other', NotImplemented) - def __add__(self, other) -> AccumBounds | Order | NotImplementedType: - ... - + def mid(self): ... + @_sympifyit("other", NotImplemented) + def __add__(self, other) -> AccumBounds | Order | NotImplementedType: ... + __radd__ = ... - def __neg__(self) -> AccumBounds: - ... - - @_sympifyit('other', NotImplemented) - def __sub__(self, other) -> AccumBounds | Order | NotImplementedType: - ... - - @_sympifyit('other', NotImplemented) - def __rsub__(self, other): - ... - - @_sympifyit('other', NotImplemented) - def __mul__(self, other) -> Self | AccumBounds | Order | NotImplementedType: - ... - - __rmul__ = ... - @_sympifyit('other', NotImplemented) - def __truediv__(self, other): - ... - - @_sympifyit('other', NotImplemented) - def __rtruediv__(self, other) -> AccumBounds | Order | NotImplementedType: - ... - - @_sympifyit('other', NotImplemented) - def __pow__(self, other): - ... - - @_sympifyit('other', NotImplemented) - def __rpow__(self, other) -> Self | Pow: - ... - - def __abs__(self) -> AccumBounds | Self: - ... - - def __contains__(self, other) -> And | bool: - ... - - def intersection(self, other) -> AccumBounds | Self | None: - ... - - def union(self, other) -> AccumBounds | None: - ... - + def __neg__(self) -> AccumBounds: ... + @_sympifyit("other", NotImplemented) + def __sub__(self, other) -> AccumBounds | Order | NotImplementedType: ... + @_sympifyit("other", NotImplemented) + def __rsub__(self, other): ... + @_sympifyit("other", NotImplemented) + def __mul__(self, other) -> Self | AccumBounds | Order | NotImplementedType: ... + __rmul__ = ... + @_sympifyit("other", NotImplemented) + def __truediv__(self, other): ... + @_sympifyit("other", NotImplemented) + def __rtruediv__(self, other) -> AccumBounds | Order | NotImplementedType: ... + @_sympifyit("other", NotImplemented) + def __pow__(self, other): ... + @_sympifyit("other", NotImplemented) + def __rpow__(self, other) -> Self | Pow: ... + def __abs__(self) -> AccumBounds | Self: ... + def __contains__(self, other) -> And | bool: ... + def intersection(self, other) -> AccumBounds | Self | None: ... + def union(self, other) -> AccumBounds | None: ... AccumBounds = AccumulationBounds diff --git a/stubs/sympy-stubs/calculus/euler.pyi b/stubs/sympy-stubs/calculus/euler.pyi index c018362d..dee0a788 100644 --- a/stubs/sympy-stubs/calculus/euler.pyi +++ b/stubs/sympy-stubs/calculus/euler.pyi @@ -1,6 +1,3 @@ - from typing import Any -def euler_equations(L, funcs=..., vars=...) -> list[Any]: - ... - +def euler_equations(L, funcs=..., vars=...) -> list[Any]: ... diff --git a/stubs/sympy-stubs/calculus/finite_diff.pyi b/stubs/sympy-stubs/calculus/finite_diff.pyi index 72f7a8d9..ca7cdcb8 100644 --- a/stubs/sympy-stubs/calculus/finite_diff.pyi +++ b/stubs/sympy-stubs/calculus/finite_diff.pyi @@ -1,12 +1,5 @@ - from typing import Literal -def finite_diff_weights(order, x_list, x0=...) -> list[list[list[int]]]: - ... - -def apply_finite_diff(order, x_list, y_list, x0=...) -> Literal[0]: - ... - -def differentiate_finite(expr, *symbols, points=..., x0=..., wrt=..., evaluate=...): - ... - +def finite_diff_weights(order, x_list, x0=...) -> list[list[list[int]]]: ... +def apply_finite_diff(order, x_list, y_list, x0=...) -> Literal[0]: ... +def differentiate_finite(expr, *symbols, points=..., x0=..., wrt=..., evaluate=...): ... diff --git a/stubs/sympy-stubs/calculus/singularities.pyi b/stubs/sympy-stubs/calculus/singularities.pyi index 40443d60..6cb1818f 100644 --- a/stubs/sympy-stubs/calculus/singularities.pyi +++ b/stubs/sympy-stubs/calculus/singularities.pyi @@ -1,22 +1,7 @@ - -def singularities(expression, symbol, domain=...): - ... - -def monotonicity_helper(expression, predicate, interval=..., symbol=...): - ... - -def is_increasing(expression, interval=..., symbol=...): - ... - -def is_strictly_increasing(expression, interval=..., symbol=...): - ... - -def is_decreasing(expression, interval=..., symbol=...): - ... - -def is_strictly_decreasing(expression, interval=..., symbol=...): - ... - -def is_monotonic(expression, interval=..., symbol=...) -> bool: - ... - +def singularities(expression, symbol, domain=...): ... +def monotonicity_helper(expression, predicate, interval=..., symbol=...): ... +def is_increasing(expression, interval=..., symbol=...): ... +def is_strictly_increasing(expression, interval=..., symbol=...): ... +def is_decreasing(expression, interval=..., symbol=...): ... +def is_strictly_decreasing(expression, interval=..., symbol=...): ... +def is_monotonic(expression, interval=..., symbol=...) -> bool: ... diff --git a/stubs/sympy-stubs/calculus/util.pyi b/stubs/sympy-stubs/calculus/util.pyi index 1b223f54..0fe16f7b 100644 --- a/stubs/sympy-stubs/calculus/util.pyi +++ b/stubs/sympy-stubs/calculus/util.pyi @@ -3,30 +3,12 @@ from typing import Any from sympy import Union from sympy.sets.sets import FiniteSet, Set -def continuous_domain(f, symbol, domain): - ... - -def function_range(f, symbol, domain) -> FiniteSet: - ... - -def not_empty_in(finset_intersection, *syms) -> FiniteSet | Union | None: - ... - -def periodicity(f, symbol, check=...): - ... - -def lcim(numbers) -> Any | None: - ... - -def is_convex(f, *syms, domain=...) -> bool: - ... - -def stationary_points(f, symbol, domain=...) -> Set: - ... - -def maximum(f, symbol, domain=...): - ... - -def minimum(f, symbol, domain=...): - ... - +def continuous_domain(f, symbol, domain): ... +def function_range(f, symbol, domain) -> FiniteSet: ... +def not_empty_in(finset_intersection, *syms) -> FiniteSet | Union | None: ... +def periodicity(f, symbol, check=...): ... +def lcim(numbers) -> Any | None: ... +def is_convex(f, *syms, domain=...) -> bool: ... +def stationary_points(f, symbol, domain=...) -> Set: ... +def maximum(f, symbol, domain=...): ... +def minimum(f, symbol, domain=...): ... diff --git a/stubs/sympy-stubs/categories/__init__.pyi b/stubs/sympy-stubs/categories/__init__.pyi index 010cc500..b5927d8a 100644 --- a/stubs/sympy-stubs/categories/__init__.pyi +++ b/stubs/sympy-stubs/categories/__init__.pyi @@ -1,4 +1,16 @@ from sympy.categories.baseclasses import Category, CompositeMorphism, Diagram, IdentityMorphism, Morphism, NamedMorphism, Object from sympy.categories.diagram_drawing import DiagramGrid, XypicDiagramDrawer, preview_diagram, xypic_draw_diagram -__all__ = ['Object', 'Morphism', 'IdentityMorphism', 'NamedMorphism', 'CompositeMorphism', 'Category', 'Diagram', 'DiagramGrid', 'XypicDiagramDrawer', 'xypic_draw_diagram', 'preview_diagram'] +__all__ = [ + "Object", + "Morphism", + "IdentityMorphism", + "NamedMorphism", + "CompositeMorphism", + "Category", + "Diagram", + "DiagramGrid", + "XypicDiagramDrawer", + "xypic_draw_diagram", + "preview_diagram", +] diff --git a/stubs/sympy-stubs/categories/baseclasses.pyi b/stubs/sympy-stubs/categories/baseclasses.pyi index 63fb7dd7..e2f36898 100644 --- a/stubs/sympy-stubs/categories/baseclasses.pyi +++ b/stubs/sympy-stubs/categories/baseclasses.pyi @@ -6,120 +6,56 @@ from sympy.sets import Set class Class(Set): is_proper = ... - -class Object(Symbol): - ... - +class Object(Symbol): ... class Morphism(Basic): - def __new__(cls, domain, codomain): - ... - + def __new__(cls, domain, codomain): ... @property - def domain(self) -> Basic: - ... - + def domain(self) -> Basic: ... @property - def codomain(self) -> Basic: - ... - - def compose(self, other) -> Morphism | CompositeMorphism: - ... - - def __mul__(self, other) -> Morphism | CompositeMorphism: - ... - - + def codomain(self) -> Basic: ... + def compose(self, other) -> Morphism | CompositeMorphism: ... + def __mul__(self, other) -> Morphism | CompositeMorphism: ... class IdentityMorphism(Morphism): - def __new__(cls, domain) -> Self: - ... - + def __new__(cls, domain) -> Self: ... @property - def codomain(self) -> Basic: - ... - - + def codomain(self) -> Basic: ... class NamedMorphism(Morphism): - def __new__(cls, domain, codomain, name) -> Self: - ... - + def __new__(cls, domain, codomain, name) -> Self: ... @property - def name(self): - ... - - + def name(self): ... class CompositeMorphism(Morphism): - def __new__(cls, *components) -> Morphism | Self: - ... - + def __new__(cls, *components) -> Morphism | Self: ... @property - def components(self) -> Basic: - ... - + def components(self) -> Basic: ... @property - def domain(self): - ... - + def domain(self): ... @property - def codomain(self): - ... - - def flatten(self, new_name) -> NamedMorphism: - ... - - + def codomain(self): ... + def flatten(self, new_name) -> NamedMorphism: ... class Category(Basic): - def __new__(cls, name, objects=..., commutative_diagrams=...) -> Self: - ... - + def __new__(cls, name, objects=..., commutative_diagrams=...) -> Self: ... @property - def name(self): - ... - + def name(self): ... @property - def objects(self) -> Basic: - ... - + def objects(self) -> Basic: ... @property - def commutative_diagrams(self) -> Basic: - ... - - def hom(self, A, B): - ... - - def all_morphisms(self): - ... - - + def commutative_diagrams(self) -> Basic: ... + def hom(self, A, B): ... + def all_morphisms(self): ... class Diagram(Basic): - def __new__(cls, *args) -> Self: - ... - + def __new__(cls, *args) -> Self: ... @property - def premises(self) -> Basic: - ... - + def premises(self) -> Basic: ... @property - def conclusions(self) -> Basic: - ... - + def conclusions(self) -> Basic: ... @property - def objects(self) -> Basic: - ... - - def hom(self, A, B) -> tuple[Any, Any]: - ... - - def is_subdiagram(self, diagram) -> bool: - ... - - def subdiagram_from_objects(self, objects) -> Diagram: - ... - - - + def objects(self) -> Basic: ... + def hom(self, A, B) -> tuple[Any, Any]: ... + def is_subdiagram(self, diagram) -> bool: ... + def subdiagram_from_objects(self, objects) -> Diagram: ... diff --git a/stubs/sympy-stubs/categories/diagram_drawing.pyi b/stubs/sympy-stubs/categories/diagram_drawing.pyi index 6390e57c..bf8acf73 100644 --- a/stubs/sympy-stubs/categories/diagram_drawing.pyi +++ b/stubs/sympy-stubs/categories/diagram_drawing.pyi @@ -3,84 +3,50 @@ from typing import Any from sympy.utilities.decorator import doctest_depends_on __doctest_requires__ = ... + class _GrowableGrid: - def __init__(self, width, height) -> None: - ... - + def __init__(self, width, height) -> None: ... @property - def width(self) -> Any: - ... - + def width(self) -> Any: ... @property - def height(self) -> Any: - ... - - def __getitem__(self, i_j): - ... - - def __setitem__(self, i_j, newvalue) -> None: - ... - - def append_row(self) -> None: - ... - - def append_column(self) -> None: - ... - - def prepend_row(self) -> None: - ... - - def prepend_column(self) -> None: - ... - - + def height(self) -> Any: ... + def __getitem__(self, i_j): ... + def __setitem__(self, i_j, newvalue) -> None: ... + def append_row(self) -> None: ... + def append_column(self) -> None: ... + def prepend_row(self) -> None: ... + def prepend_column(self) -> None: ... class DiagramGrid: - def __init__(self, diagram, groups=..., **hints) -> None: - ... - + def __init__(self, diagram, groups=..., **hints) -> None: ... @property - def width(self): - ... - + def width(self): ... @property - def height(self): - ... - - def __getitem__(self, i_j): - ... - + def height(self): ... + def __getitem__(self, i_j): ... @property - def morphisms(self) -> dict[Any, Any]: - ... - - def __str__(self) -> str: - ... - - + def morphisms(self) -> dict[Any, Any]: ... + def __str__(self) -> str: ... class ArrowStringDescription: - def __init__(self, unit, curving, curving_amount, looping_start, looping_end, horizontal_direction, vertical_direction, label_position, label) -> None: - ... - - def __str__(self) -> str: - ... - - + def __init__( + self, + unit, + curving, + curving_amount, + looping_start, + looping_end, + horizontal_direction, + vertical_direction, + label_position, + label, + ) -> None: ... + def __str__(self) -> str: ... class XypicDiagramDrawer: - def __init__(self) -> None: - ... - - def draw(self, diagram, grid, masked=..., diagram_format=...): - ... - - - -def xypic_draw_diagram(diagram, masked=..., diagram_format=..., groups=..., **hints): - ... - -@doctest_depends_on(exe=('latex', 'dvipng'), modules=('pyglet', )) -def preview_diagram(diagram, masked=..., diagram_format=..., groups=..., output=..., viewer=..., euler=..., **hints) -> None: - ... + def __init__(self) -> None: ... + def draw(self, diagram, grid, masked=..., diagram_format=...): ... +def xypic_draw_diagram(diagram, masked=..., diagram_format=..., groups=..., **hints): ... +@doctest_depends_on(exe=("latex", "dvipng"), modules=("pyglet",)) +def preview_diagram(diagram, masked=..., diagram_format=..., groups=..., output=..., viewer=..., euler=..., **hints) -> None: ... diff --git a/stubs/sympy-stubs/codegen/__init__.pyi b/stubs/sympy-stubs/codegen/__init__.pyi index a6f808e0..4c568188 100644 --- a/stubs/sympy-stubs/codegen/__init__.pyi +++ b/stubs/sympy-stubs/codegen/__init__.pyi @@ -14,4 +14,18 @@ from sympy.codegen.ast import ( aug_assign, ) -__all__ = ['Assignment', 'aug_assign', 'CodeBlock', 'For', 'Attribute', 'Variable', 'Declaration', 'While', 'Scope', 'Print', 'FunctionPrototype', 'FunctionDefinition', 'FunctionCall'] +__all__ = [ + "Assignment", + "aug_assign", + "CodeBlock", + "For", + "Attribute", + "Variable", + "Declaration", + "While", + "Scope", + "Print", + "FunctionPrototype", + "FunctionDefinition", + "FunctionCall", +] diff --git a/stubs/sympy-stubs/codegen/ast.pyi b/stubs/sympy-stubs/codegen/ast.pyi index e5e3e71e..a1860dd4 100644 --- a/stubs/sympy-stubs/codegen/ast.pyi +++ b/stubs/sympy-stubs/codegen/ast.pyi @@ -8,7 +8,6 @@ from sympy.core.numbers import Float, Integer class CodegenAST(Basic): __slots__ = ... - class Token(CodegenAST): __slots__: tuple[str, ...] = ... _fields = ... @@ -16,256 +15,160 @@ class Token(CodegenAST): not_in_args: list[str] = ... indented_args = ... @property - def is_Atom(self) -> bool: - ... - - def __new__(cls, *args, **kwargs) -> Self: - ... - - def __eq__(self, other) -> bool: - ... - - def __hash__(self) -> int: - ... - - _sympystr = ... - def __repr__(self): - ... - - def kwargs(self, exclude=..., apply=...) -> dict[Any, Any]: - ... - + def is_Atom(self) -> bool: ... + def __new__(cls, *args, **kwargs) -> Self: ... + def __eq__(self, other) -> bool: ... + def __hash__(self) -> int: ... + _sympystr = ... + def __repr__(self): ... + def kwargs(self, exclude=..., apply=...) -> dict[Any, Any]: ... -class BreakToken(Token): - ... - +class BreakToken(Token): ... break_ = ... -class ContinueToken(Token): - ... +class ContinueToken(Token): ... continue_ = ... -class NoneToken(Token): - def __eq__(self, other) -> bool: - ... - - def __hash__(self) -> int: - ... - +class NoneToken(Token): + def __eq__(self, other) -> bool: ... + def __hash__(self) -> int: ... none = ... + class AssignmentBase(CodegenAST): - def __new__(cls, lhs, rhs) -> Self: - ... - + def __new__(cls, lhs, rhs) -> Self: ... @property - def lhs(self) -> Basic: - ... - + def lhs(self) -> Basic: ... @property - def rhs(self) -> Basic: - ... - - + def rhs(self) -> Basic: ... class Assignment(AssignmentBase): op = ... - class AugmentedAssignment(AssignmentBase): binop: str = ... @property - def op(self) -> str: - ... - - + def op(self) -> str: ... class AddAugmentedAssignment(AugmentedAssignment): binop = ... - class SubAugmentedAssignment(AugmentedAssignment): binop = ... - class MulAugmentedAssignment(AugmentedAssignment): binop = ... - class DivAugmentedAssignment(AugmentedAssignment): binop = ... - class ModAugmentedAssignment(AugmentedAssignment): binop = ... - augassign_classes = ... -def aug_assign(lhs, op, rhs): - ... + +def aug_assign(lhs, op, rhs): ... class CodeBlock(CodegenAST): - def __new__(cls, *args) -> Self: - ... - - def __iter__(self) -> Iterator[Basic]: - ... - + def __new__(cls, *args) -> Self: ... + def __iter__(self) -> Iterator[Basic]: ... + _sympystr = ... @property - def free_symbols(self) -> set[Basic]: - ... - + def free_symbols(self) -> set[Basic]: ... @classmethod - def topological_sort(cls, assignments) -> Self: - ... - - def cse(self, symbols=..., optimizations=..., postprocess=..., order=...) -> Self: - ... - - + def topological_sort(cls, assignments) -> Self: ... + def cse(self, symbols=..., optimizations=..., postprocess=..., order=...) -> Self: ... class For(Token): _fields = ... _construct_target = ... - class String(Atom, Token): _fields = ... not_in_args = ... is_Atom = ... - def kwargs(self, exclude=..., apply=...) -> dict[Any, Any]: - ... - + def kwargs(self, exclude=..., apply=...) -> dict[Any, Any]: ... @property - def func(self) -> Callable[[], Self]: - ... - - - -class QuotedString(String): - ... - - -class Comment(String): - ... + def func(self) -> Callable[[], Self]: ... +class QuotedString(String): ... +class Comment(String): ... class Node(Token): __slots__: tuple[str, ...] = ... _fields = ... defaults: dict[str, Any] = ... _construct_attrs = ... - def attr_params(self, looking_for) -> None: - ... - - + def attr_params(self, looking_for) -> None: ... class Type(Token): __slots__: tuple[str, ...] = ... _fields = ... _construct_name = String @classmethod - def from_expr(cls, expr) -> FloatBaseType | IntBaseType | ComplexBaseType | Type: - ... - - def cast_check(self, value, rtol=..., atol=..., precision_targets=...): - ... - - + def from_expr(cls, expr) -> FloatBaseType | IntBaseType | ComplexBaseType | Type: ... + def cast_check(self, value, rtol=..., atol=..., precision_targets=...): ... class IntBaseType(Type): __slots__ = ... cast_nocheck = ... - class _SizedIntType(IntBaseType): __slots__ = ... _fields = ... _construct_nbits = Integer - class SignedIntType(_SizedIntType): __slots__ = ... @property - def min(self) -> Any: - ... - + def min(self) -> Any: ... @property - def max(self) -> Any: - ... - - + def max(self) -> Any: ... class UnsignedIntType(_SizedIntType): __slots__ = ... @property - def min(self) -> Literal[0]: - ... - + def min(self) -> Literal[0]: ... @property - def max(self) -> Literal[0]: - ... - - + def max(self) -> Literal[0]: ... two = ... + class FloatBaseType(Type): __slots__ = ... cast_nocheck = Float - class FloatType(FloatBaseType): __slots__ = ... _fields = ... _construct_nexp = _construct_nmant = _construct_nbits = Integer @property - def max_exponent(self) -> Expr: - ... - + def max_exponent(self) -> Expr: ... @property - def min_exponent(self): - ... - + def min_exponent(self): ... @property - def max(self): - ... - + def max(self): ... @property - def tiny(self): - ... - + def tiny(self): ... @property - def eps(self): - ... - + def eps(self): ... @property - def dig(self) -> type[UndefinedFunction]: - ... - + def dig(self) -> type[UndefinedFunction]: ... @property - def decimal_dig(self) -> type[UndefinedFunction]: - ... - - def cast_nocheck(self, value) -> float | Float: - ... - - + def decimal_dig(self) -> type[UndefinedFunction]: ... + def cast_nocheck(self, value) -> float | Float: ... class ComplexBaseType(FloatBaseType): __slots__ = ... - def cast_nocheck(self, value) -> Float: - ... - - + def cast_nocheck(self, value) -> Float: ... class ComplexType(ComplexBaseType, FloatType): __slots__ = ... - intc = ... intp = ... int8 = ... @@ -289,15 +192,16 @@ real = ... integer = ... complex_ = ... bool_ = ... + class Attribute(Token): _fields = ... defaults = ... _construct_name = String _construct_parameters = ... - value_const = ... pointer_const = ... + class Variable(Node): __slots__ = ... _fields = ... @@ -305,24 +209,17 @@ class Variable(Node): _construct_symbol = ... _construct_value = ... @classmethod - def deduced(cls, symbol, value=..., attrs=..., cast_check=...) -> Variable | Self: - ... - - def as_Declaration(self, **kwargs) -> Declaration: - ... - + def deduced(cls, symbol, value=..., attrs=..., cast_check=...) -> Variable | Self: ... + def as_Declaration(self, **kwargs) -> Declaration: ... + __lt__ = ... __le__ = ... __ge__ = ... __gt__ = ... - class Pointer(Variable): __slots__ = ... - def __getitem__(self, key) -> Element: - ... - - + def __getitem__(self, key) -> Element: ... class Element(Token): _fields = ... @@ -332,28 +229,24 @@ class Element(Token): _construct_strides = ... _construct_offset = ... - class Declaration(Token): _fields = ... _construct_variable = Variable - class While(Token): _fields = ... _construct_condition = ... - class Scope(Token): _fields = ... - class Stream(Token): _fields = ... _construct_name = String - stdout = ... stderr = ... + class Print(Token): _fields = ... defaults = ... @@ -361,35 +254,25 @@ class Print(Token): _construct_format_string = QuotedString _construct_file = Stream - class FunctionPrototype(Node): __slots__ = ... _fields: tuple[str, ...] = ... _construct_return_type = Type _construct_name = String @classmethod - def from_FunctionDefinition(cls, func_def) -> Self: - ... - - + def from_FunctionDefinition(cls, func_def) -> Self: ... class FunctionDefinition(FunctionPrototype): __slots__ = ... _fields = ... @classmethod - def from_FunctionPrototype(cls, func_proto, body) -> Self: - ... - - + def from_FunctionPrototype(cls, func_proto, body) -> Self: ... class Return(Token): _fields = ... _construct_return = ... - class FunctionCall(Token, Expr): _fields = ... _construct_name = String _construct_function_args = ... - - diff --git a/stubs/sympy-stubs/codegen/cfunctions.pyi b/stubs/sympy-stubs/codegen/cfunctions.pyi index 7d8326b6..56dbe599 100644 --- a/stubs/sympy-stubs/codegen/cfunctions.pyi +++ b/stubs/sympy-stubs/codegen/cfunctions.pyi @@ -4,94 +4,66 @@ from sympy.core.power import Pow class expm1(Function): nargs = ... - def fdiff(self, argindex=...) -> type[UndefinedFunction]: - ... - + def fdiff(self, argindex=...) -> type[UndefinedFunction]: ... + _eval_rewrite_as_tractable = ... @classmethod - def eval(cls, arg) -> None: - ... - - + def eval(cls, arg) -> None: ... class log1p(Function): nargs = ... - def fdiff(self, argindex=...): - ... - + def fdiff(self, argindex=...): ... + _eval_rewrite_as_tractable = ... @classmethod - def eval(cls, arg) -> type[UndefinedFunction] | None: - ... - - + def eval(cls, arg) -> type[UndefinedFunction] | None: ... _Two = ... + class exp2(Function): nargs = ... - def fdiff(self, argindex=...): - ... - + def fdiff(self, argindex=...): ... + _eval_rewrite_as_tractable = ... @classmethod - def eval(cls, arg) -> Pow | None: - ... - - + def eval(cls, arg) -> Pow | None: ... class log2(Function): nargs = ... - def fdiff(self, argindex=...): - ... - + def fdiff(self, argindex=...): ... @classmethod - def eval(cls, arg) -> None: - ... - - _eval_rewrite_as_tractable = ... + def eval(cls, arg) -> None: ... + _eval_rewrite_as_tractable = ... class fma(Function): nargs = ... - def fdiff(self, argindex=...) -> Basic: - ... - - + def fdiff(self, argindex=...) -> Basic: ... _Ten = ... + class log10(Function): nargs = ... - def fdiff(self, argindex=...): - ... - + def fdiff(self, argindex=...): ... @classmethod - def eval(cls, arg) -> None: - ... - - _eval_rewrite_as_tractable = ... + def eval(cls, arg) -> None: ... + _eval_rewrite_as_tractable = ... class Sqrt(Function): nargs = ... - def fdiff(self, argindex=...): - ... - - _eval_rewrite_as_tractable = ... + def fdiff(self, argindex=...): ... + _eval_rewrite_as_tractable = ... class Cbrt(Function): nargs = ... - def fdiff(self, argindex=...): - ... - - _eval_rewrite_as_tractable = ... + def fdiff(self, argindex=...): ... + _eval_rewrite_as_tractable = ... class hypot(Function): nargs = ... - def fdiff(self, argindex=...): - ... - - _eval_rewrite_as_tractable = ... - + def fdiff(self, argindex=...): ... + _eval_rewrite_as_tractable = ... diff --git a/stubs/sympy-stubs/codegen/cnodes.pyi b/stubs/sympy-stubs/codegen/cnodes.pyi index f51281c7..87841cc8 100644 --- a/stubs/sympy-stubs/codegen/cnodes.pyi +++ b/stubs/sympy-stubs/codegen/cnodes.pyi @@ -7,52 +7,38 @@ void = ... restrict = ... volatile = ... static = ... -def alignof(arg) -> FunctionCall: - ... -def sizeof(arg) -> FunctionCall: - ... +def alignof(arg) -> FunctionCall: ... +def sizeof(arg) -> FunctionCall: ... class CommaOperator(Basic): - def __new__(cls, *args) -> Self: - ... - - + def __new__(cls, *args) -> Self: ... class Label(Node): _fields = ... defaults = ... _construct_name = String - class goto(Token): _fields = ... _construct_label = Label - class PreDecrement(Basic): nargs = ... - class PostDecrement(Basic): nargs = ... - class PreIncrement(Basic): nargs = ... - class PostIncrement(Basic): nargs = ... - class struct(Node): _fields = ... defaults = ... _construct_name = String - class union(struct): __slots__ = ... - - diff --git a/stubs/sympy-stubs/codegen/fnodes.pyi b/stubs/sympy-stubs/codegen/fnodes.pyi index 195812fc..6c3d8069 100644 --- a/stubs/sympy-stubs/codegen/fnodes.pyi +++ b/stubs/sympy-stubs/codegen/fnodes.pyi @@ -13,18 +13,17 @@ intent_in = ... intent_out = ... intent_inout = ... allocatable = ... + class Program(Token): _fields = ... _construct_name = String _construct_body = ... - class use_rename(Token): _fields = ... _construct_local = String _construct_original = String - class use(Token): _fields = ... defaults = ... @@ -32,27 +31,23 @@ class use(Token): _construct_rename = ... _construct_only = ... - class Module(Token): _fields = ... defaults = ... _construct_name = String _construct_definitions = ... - class Subroutine(Node): __slots__ = ... _fields = ... _construct_name = String _construct_parameters = ... - class SubroutineCall(Token): _fields = ... _construct_name = ... _construct_subroutine_args = ... - class Do(Token): _fields = ... defaults = ... @@ -63,12 +58,10 @@ class Do(Token): _construct_step = ... _construct_concurrent = ... - class ArrayConstructor(Token): _fields = ... _construct_elements = ... - class ImpliedDoLoop(Token): _fields = ... defaults = ... @@ -78,41 +71,23 @@ class ImpliedDoLoop(Token): _construct_last = ... _construct_step = ... - class Extent(Basic): - def __new__(cls, *args) -> Self: - ... - - + def __new__(cls, *args) -> Self: ... assumed_extent = ... -def dimension(*args) -> Attribute: - ... - -assumed_size = ... -def array(symbol, dim, intent=..., *, attrs=..., value=..., type=...) -> Variable: - ... - -def allocated(array) -> FunctionCall: - ... - -def lbound(array, dim=..., kind=...) -> FunctionCall: - ... - -def ubound(array, dim=..., kind=...) -> FunctionCall: - ... - -def shape(source, kind=...) -> FunctionCall: - ... -def size(array, dim=..., kind=...) -> FunctionCall: - ... +def dimension(*args) -> Attribute: ... -def reshape(source, shape, pad=..., order=...) -> FunctionCall: - ... +assumed_size = ... -def bind_C(name=...) -> Attribute: - ... +def array(symbol, dim, intent=..., *, attrs=..., value=..., type=...) -> Variable: ... +def allocated(array) -> FunctionCall: ... +def lbound(array, dim=..., kind=...) -> FunctionCall: ... +def ubound(array, dim=..., kind=...) -> FunctionCall: ... +def shape(source, kind=...) -> FunctionCall: ... +def size(array, dim=..., kind=...) -> FunctionCall: ... +def reshape(source, shape, pad=..., order=...) -> FunctionCall: ... +def bind_C(name=...) -> Attribute: ... class GoTo(Token): _fields = ... @@ -120,67 +95,52 @@ class GoTo(Token): _construct_labels = ... _construct_expr = ... - class FortranReturn(Token): _fields = ... defaults = ... _construct_return_value = ... - class FFunction(Function): _required_standard = ... - class F95Function(FFunction): _required_standard = ... - class isign(FFunction): nargs = ... - class dsign(FFunction): nargs = ... - class cmplx(FFunction): nargs = ... - class kind(FFunction): nargs = ... - class merge(F95Function): nargs = ... - class _literal(Float): _token: str = ... _decimals: int = ... - class literal_sp(_literal): _token = ... _decimals = ... - class literal_dp(_literal): _token = ... _decimals = ... - class sum_(Token, Expr): _fields = ... defaults = ... _construct_array = ... _construct_dim = ... - class product_(Token, Expr): _fields = ... defaults = ... _construct_array = ... _construct_dim = ... - - diff --git a/stubs/sympy-stubs/codegen/pynodes.pyi b/stubs/sympy-stubs/codegen/pynodes.pyi index 053ada22..1d6aafdf 100644 --- a/stubs/sympy-stubs/codegen/pynodes.pyi +++ b/stubs/sympy-stubs/codegen/pynodes.pyi @@ -1,11 +1,7 @@ from sympy.codegen.abstract_nodes import List as AbstractList from sympy.codegen.ast import Token -class List(AbstractList): - ... - +class List(AbstractList): ... class NumExprEvaluate(Token): _fields = ... - - diff --git a/stubs/sympy-stubs/combinatorics/coset_table.pyi b/stubs/sympy-stubs/combinatorics/coset_table.pyi index e2a60bba..ce216599 100644 --- a/stubs/sympy-stubs/combinatorics/coset_table.pyi +++ b/stubs/sympy-stubs/combinatorics/coset_table.pyi @@ -6,110 +6,42 @@ class CosetTable(DefaultPrinting): coset_table_max_limit = ... coset_table_limit = ... max_stack_size = ... - def __init__(self, fp_grp, subgroup, max_cosets=...) -> None: - ... - + def __init__(self, fp_grp, subgroup, max_cosets=...) -> None: ... @property - def omega(self) -> list[int]: - ... - - def copy(self) -> Self: - ... - - def __str__(self) -> str: - ... - + def omega(self) -> list[int]: ... + def copy(self) -> Self: ... + def __str__(self) -> str: ... + __repr__ = ... @property - def n(self) -> int: - ... - - def is_complete(self) -> bool: - ... - - def define(self, alpha, x, modified=...) -> None: - ... - - def define_c(self, alpha, x) -> None: - ... - - def scan_c(self, alpha, word) -> None: - ... - - def coincidence_c(self, alpha, beta) -> None: - ... - - def scan(self, alpha, word, y=..., fill=..., modified=...) -> None: - ... - - def scan_check(self, alpha, word) -> bool: - ... - - def merge(self, k, lamda, q, w=..., modified=...) -> None: - ... - - def rep(self, k, modified=...): - ... - - def coincidence(self, alpha, beta, w=..., modified=...) -> None: - ... - - def scan_and_fill(self, alpha, word) -> None: - ... - - def scan_and_fill_c(self, alpha, word) -> None: - ... - - def look_ahead(self) -> None: - ... - - def process_deductions(self, R_c_x, R_c_x_inv) -> None: - ... - - def process_deductions_check(self, R_c_x, R_c_x_inv) -> bool: - ... - - def switch(self, beta, gamma) -> None: - ... - - def standardize(self) -> None: - ... - - def compress(self) -> None: - ... - - def conjugates(self, R) -> list[Any]: - ... - - def coset_representative(self, coset) -> None: - ... - - def modified_define(self, alpha, x) -> None: - ... - - def modified_scan(self, alpha, w, y, fill=...) -> None: - ... - - def modified_scan_and_fill(self, alpha, w, y) -> None: - ... - - def modified_merge(self, k, lamda, w, q) -> None: - ... - - def modified_rep(self, k) -> None: - ... - - def modified_coincidence(self, alpha, beta, w) -> None: - ... - - - -def coset_enumeration_r(fp_grp, Y, max_cosets=..., draft=..., incomplete=..., modified=...) -> CosetTable: - ... - -def modified_coset_enumeration_r(fp_grp, Y, max_cosets=..., draft=..., incomplete=...) -> CosetTable: - ... - -def coset_enumeration_c(fp_grp, Y, max_cosets=..., draft=..., incomplete=...) -> CosetTable: - ... + def n(self) -> int: ... + def is_complete(self) -> bool: ... + def define(self, alpha, x, modified=...) -> None: ... + def define_c(self, alpha, x) -> None: ... + def scan_c(self, alpha, word) -> None: ... + def coincidence_c(self, alpha, beta) -> None: ... + def scan(self, alpha, word, y=..., fill=..., modified=...) -> None: ... + def scan_check(self, alpha, word) -> bool: ... + def merge(self, k, lamda, q, w=..., modified=...) -> None: ... + def rep(self, k, modified=...): ... + def coincidence(self, alpha, beta, w=..., modified=...) -> None: ... + def scan_and_fill(self, alpha, word) -> None: ... + def scan_and_fill_c(self, alpha, word) -> None: ... + def look_ahead(self) -> None: ... + def process_deductions(self, R_c_x, R_c_x_inv) -> None: ... + def process_deductions_check(self, R_c_x, R_c_x_inv) -> bool: ... + def switch(self, beta, gamma) -> None: ... + def standardize(self) -> None: ... + def compress(self) -> None: ... + def conjugates(self, R) -> list[Any]: ... + def coset_representative(self, coset) -> None: ... + def modified_define(self, alpha, x) -> None: ... + def modified_scan(self, alpha, w, y, fill=...) -> None: ... + def modified_scan_and_fill(self, alpha, w, y) -> None: ... + def modified_merge(self, k, lamda, w, q) -> None: ... + def modified_rep(self, k) -> None: ... + def modified_coincidence(self, alpha, beta, w) -> None: ... +def coset_enumeration_r(fp_grp, Y, max_cosets=..., draft=..., incomplete=..., modified=...) -> CosetTable: ... +def modified_coset_enumeration_r(fp_grp, Y, max_cosets=..., draft=..., incomplete=...) -> CosetTable: ... +def coset_enumeration_c(fp_grp, Y, max_cosets=..., draft=..., incomplete=...) -> CosetTable: ... diff --git a/stubs/sympy-stubs/combinatorics/fp_groups.pyi b/stubs/sympy-stubs/combinatorics/fp_groups.pyi index 3fe11016..d760ffc9 100644 --- a/stubs/sympy-stubs/combinatorics/fp_groups.pyi +++ b/stubs/sympy-stubs/combinatorics/fp_groups.pyi @@ -7,164 +7,74 @@ from sympy.printing.defaults import DefaultPrinting from sympy.utilities import public @public -def fp_group(fr_grp, relators=...) -> tuple[FpGroup, *tuple[Any, ...]]: - ... - +def fp_group(fr_grp, relators=...) -> tuple[FpGroup, *tuple[Any, ...]]: ... @public -def xfp_group(fr_grp, relators=...) -> tuple[FpGroup, Callable[[], Any]]: - ... - +def xfp_group(fr_grp, relators=...) -> tuple[FpGroup, Callable[[], Any]]: ... @public -def vfp_group(fr_grpm, relators) -> FpGroup: - ... +def vfp_group(fr_grpm, relators) -> FpGroup: ... class FpGroup(DefaultPrinting): is_group = ... is_FpGroup = ... is_PermutationGroup = ... - def __init__(self, fr_grp, relators) -> None: - ... - - def make_confluent(self) -> None: - ... - - def reduce(self, word): - ... - - def equals(self, word1, word2) -> bool | None: - ... - + def __init__(self, fr_grp, relators) -> None: ... + def make_confluent(self) -> None: ... + def reduce(self, word): ... + def equals(self, word1, word2) -> bool | None: ... @property - def identity(self): - ... - - def __contains__(self, g) -> bool: - ... - - def subgroup(self, gens, C=..., homomorphism=...) -> tuple[FpGroup, GroupHomomorphism] | FpGroup: - ... - - def coset_enumeration(self, H, strategy=..., max_cosets=..., draft=..., incomplete=...) -> CosetTable: - ... - - def standardize_coset_table(self) -> None: - ... - - def coset_table(self, H, strategy=..., max_cosets=..., draft=..., incomplete=...) -> list[list[None]]: - ... - - def order(self, strategy=...) -> int | Any: - ... - - def most_frequent_generator(self): - ... - - def random(self): - ... - - def index(self, H, strategy=...) -> int: - ... - - def __str__(self) -> str: - ... - + def identity(self): ... + def __contains__(self, g) -> bool: ... + def subgroup(self, gens, C=..., homomorphism=...) -> tuple[FpGroup, GroupHomomorphism] | FpGroup: ... + def coset_enumeration(self, H, strategy=..., max_cosets=..., draft=..., incomplete=...) -> CosetTable: ... + def standardize_coset_table(self) -> None: ... + def coset_table(self, H, strategy=..., max_cosets=..., draft=..., incomplete=...) -> list[list[None]]: ... + def order(self, strategy=...) -> int | Any: ... + def most_frequent_generator(self): ... + def random(self): ... + def index(self, H, strategy=...) -> int: ... + def __str__(self) -> str: ... + __repr__ = ... - def derived_series(self) -> list[Any]: - ... - - def lower_central_series(self) -> list[Any]: - ... - - def center(self) -> list[Any]: - ... - - def derived_subgroup(self) -> list[Any]: - ... - - def centralizer(self, other) -> list[Any]: - ... - - def normal_closure(self, other) -> list[Any]: - ... - + def derived_series(self) -> list[Any]: ... + def lower_central_series(self) -> list[Any]: ... + def center(self) -> list[Any]: ... + def derived_subgroup(self) -> list[Any]: ... + def centralizer(self, other) -> list[Any]: ... + def normal_closure(self, other) -> list[Any]: ... @property - def is_abelian(self) -> Any: - ... - + def is_abelian(self) -> Any: ... @property - def is_nilpotent(self) -> Any: - ... - + def is_nilpotent(self) -> Any: ... @property - def is_solvable(self) -> Any: - ... - + def is_solvable(self) -> Any: ... @property - def elements(self) -> list[Any] | None: - ... - + def elements(self) -> list[Any] | None: ... @property - def is_cyclic(self) -> bool: - ... - - def abelian_invariants(self) -> list[Any]: - ... - - def composition_series(self) -> list[Any]: - ... - - + def is_cyclic(self) -> bool: ... + def abelian_invariants(self) -> list[Any]: ... + def composition_series(self) -> list[Any]: ... class FpSubgroup(DefaultPrinting): - def __init__(self, G, gens, normal=...) -> None: - ... - - def __contains__(self, g) -> bool: - ... - - def order(self): - ... - - def to_FpGroup(self) -> Any: - ... - - def __str__(self) -> str: - ... - - __repr__ = ... - - -def low_index_subgroups(G, N, Y=...) -> list[Any]: - ... - -def descendant_subgroups(S, C, R1_c_list, x, R2, N, Y) -> None: - ... + def __init__(self, G, gens, normal=...) -> None: ... + def __contains__(self, g) -> bool: ... + def order(self): ... + def to_FpGroup(self) -> Any: ... + def __str__(self) -> str: ... -def try_descendant(S, C, R1_c_list, R2, N, alpha, x, beta, Y) -> None: - ... - -def first_in_class(C, Y=...) -> bool: - ... - -def simplify_presentation(*args, change_gens=...) -> FpGroup | tuple[Any, Any] | tuple[Any | list[Any], Any | list[Any]]: - ... - -def elimination_technique_1(gens, rels, identity) -> tuple[list[Any], list[Any]]: - ... - -def define_schreier_generators(C, homomorphism=...) -> None: - ... - -def reidemeister_relators(C) -> None: - ... - -def rewrite(C, alpha, w): - ... - -def elimination_technique_2(C) -> tuple[Any, Any]: - ... + __repr__ = ... -def reidemeister_presentation(fp_grp, H, C=..., homomorphism=...) -> tuple[tuple[Any, ...], tuple[Any, ...], list[Any]] | tuple[tuple[Any, ...], tuple[Any, ...]]: - ... +def low_index_subgroups(G, N, Y=...) -> list[Any]: ... +def descendant_subgroups(S, C, R1_c_list, x, R2, N, Y) -> None: ... +def try_descendant(S, C, R1_c_list, R2, N, alpha, x, beta, Y) -> None: ... +def first_in_class(C, Y=...) -> bool: ... +def simplify_presentation(*args, change_gens=...) -> FpGroup | tuple[Any, Any] | tuple[Any | list[Any], Any | list[Any]]: ... +def elimination_technique_1(gens, rels, identity) -> tuple[list[Any], list[Any]]: ... +def define_schreier_generators(C, homomorphism=...) -> None: ... +def reidemeister_relators(C) -> None: ... +def rewrite(C, alpha, w): ... +def elimination_technique_2(C) -> tuple[Any, Any]: ... +def reidemeister_presentation( + fp_grp, H, C=..., homomorphism=... +) -> tuple[tuple[Any, ...], tuple[Any, ...], list[Any]] | tuple[tuple[Any, ...], tuple[Any, ...]]: ... FpGroupElement = FreeGroupElement diff --git a/stubs/sympy-stubs/combinatorics/free_groups.pyi b/stubs/sympy-stubs/combinatorics/free_groups.pyi index 7a92a76a..3ece265d 100644 --- a/stubs/sympy-stubs/combinatorics/free_groups.pyi +++ b/stubs/sympy-stubs/combinatorics/free_groups.pyi @@ -7,234 +7,101 @@ from sympy.printing.defaults import DefaultPrinting from sympy.utilities import public @public -def free_group(symbols) -> tuple[FreeGroup, *tuple[Any, ...]]: - ... - +def free_group(symbols) -> tuple[FreeGroup, *tuple[Any, ...]]: ... @public -def xfree_group(symbols) -> tuple[FreeGroup, Any]: - ... - +def xfree_group(symbols) -> tuple[FreeGroup, Any]: ... @public -def vfree_group(symbols) -> FreeGroup: - ... +def vfree_group(symbols) -> FreeGroup: ... _free_group_cache: dict[int, FreeGroup] = ... + class FreeGroup(DefaultPrinting): is_associative = ... is_group = ... is_FreeGroup = ... is_PermutationGroup = ... relators: list[Expr] = ... - def __new__(cls, symbols) -> Self | FreeGroup: - ... - - def clone(self, symbols=...) -> Self: - ... - - def __contains__(self, i) -> Literal[False]: - ... - - def __hash__(self) -> int: - ... - - def __len__(self): - ... - - def __str__(self) -> str: - ... - + def __new__(cls, symbols) -> Self | FreeGroup: ... + def clone(self, symbols=...) -> Self: ... + def __contains__(self, i) -> Literal[False]: ... + def __hash__(self) -> int: ... + def __len__(self): ... + def __str__(self) -> str: ... + __repr__ = ... - def __getitem__(self, index) -> Self: - ... - - def __eq__(self, other) -> bool: - ... - - def index(self, gen): - ... - - def order(self): - ... - + def __getitem__(self, index) -> Self: ... + def __eq__(self, other) -> bool: ... + def index(self, gen): ... + def order(self): ... @property - def elements(self) -> set[Any]: - ... - + def elements(self) -> set[Any]: ... @property - def rank(self): - ... - + def rank(self): ... @property - def is_abelian(self) -> bool: - ... - + def is_abelian(self) -> bool: ... @property - def identity(self): - ... - - def contains(self, g) -> bool: - ... - - def center(self) -> set[Any]: - ... - - + def identity(self): ... + def contains(self, g) -> bool: ... + def center(self) -> set[Any]: ... class FreeGroupElement(CantSympify, DefaultPrinting, tuple): is_assoc_word = ... - def new(self, init) -> Self: - ... - + def new(self, init) -> Self: ... + _hash = ... - def __hash__(self) -> int: - ... - - def copy(self) -> Self: - ... - + def __hash__(self) -> int: ... + def copy(self) -> Self: ... @property - def is_identity(self) -> bool: - ... - + def is_identity(self) -> bool: ... @property - def array_form(self) -> tuple[Any, ...]: - ... - + def array_form(self) -> tuple[Any, ...]: ... @property - def letter_form(self) -> tuple[Any, ...]: - ... - - def __getitem__(self, i): - ... - - def index(self, gen) -> int: - ... - + def letter_form(self) -> tuple[Any, ...]: ... + def __getitem__(self, i): ... + def index(self, gen) -> int: ... @property - def letter_form_elm(self) -> list[Any]: - ... - + def letter_form_elm(self) -> list[Any]: ... @property - def ext_rep(self) -> tuple[Any, ...]: - ... - - def __contains__(self, gen) -> bool: - ... - - def __str__(self) -> str: - ... - - __repr__ = ... - def __pow__(self, n) -> Self: - ... - - def __mul__(self, other) -> Self: - ... - - def __truediv__(self, other): - ... - - def __rtruediv__(self, other): - ... - - def __add__(self, other) -> NotImplementedType: - ... - - def inverse(self): - ... - - def order(self): - ... - - def commutator(self, other): - ... - - def eliminate_words(self, words, _all=..., inverse=...) -> Self: - ... - - def eliminate_word(self, gen, by=..., _all=..., inverse=...) -> Self: - ... - - def __len__(self) -> int: - ... - - def __eq__(self, other) -> bool: - ... - - def __lt__(self, other) -> bool: - ... - - def __le__(self, other) -> bool: - ... - - def __gt__(self, other) -> bool: - ... - - def __ge__(self, other) -> bool: - ... - - def exponent_sum(self, gen): - ... - - def generator_count(self, gen): - ... - - def subword(self, from_i, to_j, strict=...): - ... - - def subword_index(self, word, start=...) -> int: - ... - - def is_dependent(self, word) -> bool: - ... - - def is_independent(self, word) -> bool: - ... - - def contains_generators(self) -> set[Any]: - ... - - def cyclic_subword(self, from_i, to_j): - ... - - def cyclic_conjugates(self) -> set[Any]: - ... - - def is_cyclic_conjugate(self, w) -> bool: - ... - - def number_syllables(self) -> int: - ... - - def exponent_syllable(self, i): - ... - - def generator_syllable(self, i): - ... - - def sub_syllables(self, from_i, to_j): - ... - - def substituted_word(self, from_i, to_j, by): - ... - - def is_cyclically_reduced(self) -> Literal[True]: - ... - - def identity_cyclic_reduction(self) -> Self: - ... - - def cyclic_reduction(self, removed=...) -> tuple[Self | Any, Any] | Self: - ... - - def power_of(self, other) -> bool: - ... - - + def ext_rep(self) -> tuple[Any, ...]: ... + def __contains__(self, gen) -> bool: ... + def __str__(self) -> str: ... -def letter_form_to_array_form(array_form, group) -> list[Any] | None: - ... - -def zero_mul_simp(l, index) -> None: - ... + __repr__ = ... + def __pow__(self, n) -> Self: ... + def __mul__(self, other) -> Self: ... + def __truediv__(self, other): ... + def __rtruediv__(self, other): ... + def __add__(self, other) -> NotImplementedType: ... + def inverse(self): ... + def order(self): ... + def commutator(self, other): ... + def eliminate_words(self, words, _all=..., inverse=...) -> Self: ... + def eliminate_word(self, gen, by=..., _all=..., inverse=...) -> Self: ... + def __len__(self) -> int: ... + def __eq__(self, other) -> bool: ... + def __lt__(self, other) -> bool: ... + def __le__(self, other) -> bool: ... + def __gt__(self, other) -> bool: ... + def __ge__(self, other) -> bool: ... + def exponent_sum(self, gen): ... + def generator_count(self, gen): ... + def subword(self, from_i, to_j, strict=...): ... + def subword_index(self, word, start=...) -> int: ... + def is_dependent(self, word) -> bool: ... + def is_independent(self, word) -> bool: ... + def contains_generators(self) -> set[Any]: ... + def cyclic_subword(self, from_i, to_j): ... + def cyclic_conjugates(self) -> set[Any]: ... + def is_cyclic_conjugate(self, w) -> bool: ... + def number_syllables(self) -> int: ... + def exponent_syllable(self, i): ... + def generator_syllable(self, i): ... + def sub_syllables(self, from_i, to_j): ... + def substituted_word(self, from_i, to_j, by): ... + def is_cyclically_reduced(self) -> Literal[True]: ... + def identity_cyclic_reduction(self) -> Self: ... + def cyclic_reduction(self, removed=...) -> tuple[Self | Any, Any] | Self: ... + def power_of(self, other) -> bool: ... +def letter_form_to_array_form(array_form, group) -> list[Any] | None: ... +def zero_mul_simp(l, index) -> None: ... diff --git a/stubs/sympy-stubs/combinatorics/galois.pyi b/stubs/sympy-stubs/combinatorics/galois.pyi index e48f7dc7..f6d91b18 100644 --- a/stubs/sympy-stubs/combinatorics/galois.pyi +++ b/stubs/sympy-stubs/combinatorics/galois.pyi @@ -5,25 +5,16 @@ from sympy.combinatorics.perm_groups import PermutationGroup class S1TransitiveSubgroups(Enum): S1 = ... - def get_perm_group(self) -> PermutationGroup: - ... - - + def get_perm_group(self) -> PermutationGroup: ... class S2TransitiveSubgroups(Enum): S2 = ... - def get_perm_group(self) -> PermutationGroup: - ... - - + def get_perm_group(self) -> PermutationGroup: ... class S3TransitiveSubgroups(Enum): A3 = ... S3 = ... - def get_perm_group(self) -> PermutationGroup | None: - ... - - + def get_perm_group(self) -> PermutationGroup | None: ... class S4TransitiveSubgroups(Enum): C4 = ... @@ -31,10 +22,7 @@ class S4TransitiveSubgroups(Enum): D4 = ... A4 = ... S4 = ... - def get_perm_group(self) -> PermutationGroup | None: - ... - - + def get_perm_group(self) -> PermutationGroup | None: ... class S5TransitiveSubgroups(Enum): C5 = ... @@ -42,10 +30,7 @@ class S5TransitiveSubgroups(Enum): M20 = ... A5 = ... S5 = ... - def get_perm_group(self) -> PermutationGroup | None: - ... - - + def get_perm_group(self) -> PermutationGroup | None: ... class S6TransitiveSubgroups(Enum): C6 = ... @@ -64,53 +49,20 @@ class S6TransitiveSubgroups(Enum): PGL2F5 = ... A6 = ... S6 = ... - def get_perm_group(self) -> PermutationGroup | None: - ... - - - -def four_group() -> PermutationGroup: - ... - -def M20() -> PermutationGroup: - ... - -def S3_in_S6() -> PermutationGroup: - ... - -def A4_in_S6() -> PermutationGroup: - ... - -def S4m() -> PermutationGroup: - ... - -def S4p() -> PermutationGroup: - ... - -def A4xC2() -> PermutationGroup: - ... - -def S4xC2() -> PermutationGroup: - ... - -def G18() -> PermutationGroup: - ... - -def G36m() -> PermutationGroup: - ... - -def G36p() -> PermutationGroup: - ... - -def G72() -> PermutationGroup: - ... - -def PSL2F5() -> PermutationGroup: - ... - -def PGL2F5() -> PermutationGroup: - ... - -def find_transitive_subgroups_of_S6(*targets, print_report=...) -> dict[Any, Any]: - ... - + def get_perm_group(self) -> PermutationGroup | None: ... + +def four_group() -> PermutationGroup: ... +def M20() -> PermutationGroup: ... +def S3_in_S6() -> PermutationGroup: ... +def A4_in_S6() -> PermutationGroup: ... +def S4m() -> PermutationGroup: ... +def S4p() -> PermutationGroup: ... +def A4xC2() -> PermutationGroup: ... +def S4xC2() -> PermutationGroup: ... +def G18() -> PermutationGroup: ... +def G36m() -> PermutationGroup: ... +def G36p() -> PermutationGroup: ... +def G72() -> PermutationGroup: ... +def PSL2F5() -> PermutationGroup: ... +def PGL2F5() -> PermutationGroup: ... +def find_transitive_subgroups_of_S6(*targets, print_report=...) -> dict[Any, Any]: ... diff --git a/stubs/sympy-stubs/combinatorics/generators.pyi b/stubs/sympy-stubs/combinatorics/generators.pyi index a94b0df6..30a4ce76 100644 --- a/stubs/sympy-stubs/combinatorics/generators.pyi +++ b/stubs/sympy-stubs/combinatorics/generators.pyi @@ -2,21 +2,9 @@ from typing import Any, Generator from sympy.combinatorics.permutations import Permutation -def symmetric(n) -> Generator[Permutation, Any, None]: - ... - -def cyclic(n) -> Generator[Permutation, Any, None]: - ... - -def alternating(n) -> Generator[Permutation, Any, None]: - ... - -def dihedral(n) -> Generator[Permutation, Any, None]: - ... - -def rubik_cube_generators() -> list[Permutation]: - ... - -def rubik(n) -> list[Any]: - ... - +def symmetric(n) -> Generator[Permutation, Any, None]: ... +def cyclic(n) -> Generator[Permutation, Any, None]: ... +def alternating(n) -> Generator[Permutation, Any, None]: ... +def dihedral(n) -> Generator[Permutation, Any, None]: ... +def rubik_cube_generators() -> list[Permutation]: ... +def rubik(n) -> list[Any]: ... diff --git a/stubs/sympy-stubs/combinatorics/graycode.pyi b/stubs/sympy-stubs/combinatorics/graycode.pyi index 66d443e0..9f8b47e6 100644 --- a/stubs/sympy-stubs/combinatorics/graycode.pyi +++ b/stubs/sympy-stubs/combinatorics/graycode.pyi @@ -6,52 +6,23 @@ class GrayCode(Basic): _skip = ... _current = ... _rank = ... - def __new__(cls, n, *args, **kw_args) -> Self: - ... - - def next(self, delta=...) -> GrayCode: - ... - + def __new__(cls, n, *args, **kw_args) -> Self: ... + def next(self, delta=...) -> GrayCode: ... @property - def selections(self): - ... - + def selections(self): ... @property - def n(self) -> Basic: - ... - - def generate_gray(self, **hints) -> Generator[str, Any, None]: - ... - - def skip(self) -> None: - ... - + def n(self) -> Basic: ... + def generate_gray(self, **hints) -> Generator[str, Any, None]: ... + def skip(self) -> None: ... @property - def rank(self) -> int: - ... - + def rank(self) -> int: ... @property - def current(self) -> str: - ... - + def current(self) -> str: ... @classmethod - def unrank(cls, n, rank) -> str: - ... - - - -def random_bitstring(n) -> str: - ... - -def gray_to_bin(bin_list) -> LiteralString: - ... - -def bin_to_gray(bin_list) -> LiteralString: - ... - -def get_subset_from_bitstring(super_set, bitstring) -> list[Any]: - ... - -def graycode_subsets(gray_code_set) -> Generator[list[Any], Any, None]: - ... + def unrank(cls, n, rank) -> str: ... +def random_bitstring(n) -> str: ... +def gray_to_bin(bin_list) -> LiteralString: ... +def bin_to_gray(bin_list) -> LiteralString: ... +def get_subset_from_bitstring(super_set, bitstring) -> list[Any]: ... +def graycode_subsets(gray_code_set) -> Generator[list[Any], Any, None]: ... diff --git a/stubs/sympy-stubs/combinatorics/group_constructs.pyi b/stubs/sympy-stubs/combinatorics/group_constructs.pyi index 553b327c..f6626fab 100644 --- a/stubs/sympy-stubs/combinatorics/group_constructs.pyi +++ b/stubs/sympy-stubs/combinatorics/group_constructs.pyi @@ -1,6 +1,5 @@ from sympy.combinatorics.perm_groups import PermutationGroup _af_new = ... -def DirectProduct(*groups) -> PermutationGroup: - ... +def DirectProduct(*groups) -> PermutationGroup: ... diff --git a/stubs/sympy-stubs/combinatorics/homomorphisms.pyi b/stubs/sympy-stubs/combinatorics/homomorphisms.pyi index 47ddf7e4..6be0fa65 100644 --- a/stubs/sympy-stubs/combinatorics/homomorphisms.pyi +++ b/stubs/sympy-stubs/combinatorics/homomorphisms.pyi @@ -4,56 +4,21 @@ from sympy.combinatorics.fp_groups import FpSubgroup from sympy.combinatorics.perm_groups import PermutationGroup class GroupHomomorphism: - def __init__(self, domain, codomain, images) -> None: - ... - - def invert(self, g) -> list[Any] | None: - ... - - def kernel(self) -> PermutationGroup | FpSubgroup: - ... - - def image(self) -> PermutationGroup | FpSubgroup: - ... - - def __call__(self, elem) -> list[Any]: - ... - - def is_injective(self) -> bool: - ... - - def is_surjective(self) -> None: - ... - - def is_isomorphism(self) -> Literal[False] | None: - ... - - def is_trivial(self) -> bool: - ... - - def compose(self, other) -> GroupHomomorphism: - ... - - def restrict_to(self, H) -> GroupHomomorphism: - ... - - def invert_subgroup(self, H) -> PermutationGroup: - ... - - - -def homomorphism(domain, codomain, gens, images=..., check=...) -> GroupHomomorphism: - ... - -def orbit_homomorphism(group, omega) -> GroupHomomorphism: - ... - -def block_homomorphism(group, blocks) -> GroupHomomorphism: - ... - -def group_isomorphism(G, H, isomorphism=...) -> tuple[Literal[True], GroupHomomorphism] | tuple[Literal[False], None] | bool: - ... - -def is_isomorphic(G, H) -> tuple[Literal[True], GroupHomomorphism] | tuple[Literal[False], None] | bool: - ... - + def __init__(self, domain, codomain, images) -> None: ... + def invert(self, g) -> list[Any] | None: ... + def kernel(self) -> PermutationGroup | FpSubgroup: ... + def image(self) -> PermutationGroup | FpSubgroup: ... + def __call__(self, elem) -> list[Any]: ... + def is_injective(self) -> bool: ... + def is_surjective(self) -> None: ... + def is_isomorphism(self) -> Literal[False] | None: ... + def is_trivial(self) -> bool: ... + def compose(self, other) -> GroupHomomorphism: ... + def restrict_to(self, H) -> GroupHomomorphism: ... + def invert_subgroup(self, H) -> PermutationGroup: ... + +def homomorphism(domain, codomain, gens, images=..., check=...) -> GroupHomomorphism: ... +def orbit_homomorphism(group, omega) -> GroupHomomorphism: ... +def block_homomorphism(group, blocks) -> GroupHomomorphism: ... +def group_isomorphism(G, H, isomorphism=...) -> tuple[Literal[True], GroupHomomorphism] | tuple[Literal[False], None] | bool: ... +def is_isomorphic(G, H) -> tuple[Literal[True], GroupHomomorphism] | tuple[Literal[False], None] | bool: ... diff --git a/stubs/sympy-stubs/combinatorics/named_groups.pyi b/stubs/sympy-stubs/combinatorics/named_groups.pyi index 037cacc5..05969290 100644 --- a/stubs/sympy-stubs/combinatorics/named_groups.pyi +++ b/stubs/sympy-stubs/combinatorics/named_groups.pyi @@ -1,27 +1,12 @@ from sympy.combinatorics.perm_groups import PermutationGroup _af_new = ... -def AbelianGroup(*cyclic_orders) -> PermutationGroup: - ... - -def AlternatingGroup(n) -> PermutationGroup: - ... - -def set_alternating_group_properties(G, n, degree) -> None: - ... - -def CyclicGroup(n) -> PermutationGroup: - ... - -def DihedralGroup(n) -> PermutationGroup: - ... - -def SymmetricGroup(n) -> PermutationGroup: - ... - -def set_symmetric_group_properties(G, n, degree) -> None: - ... - -def RubikGroup(n) -> PermutationGroup: - ... +def AbelianGroup(*cyclic_orders) -> PermutationGroup: ... +def AlternatingGroup(n) -> PermutationGroup: ... +def set_alternating_group_properties(G, n, degree) -> None: ... +def CyclicGroup(n) -> PermutationGroup: ... +def DihedralGroup(n) -> PermutationGroup: ... +def SymmetricGroup(n) -> PermutationGroup: ... +def set_symmetric_group_properties(G, n, degree) -> None: ... +def RubikGroup(n) -> PermutationGroup: ... diff --git a/stubs/sympy-stubs/combinatorics/partitions.pyi b/stubs/sympy-stubs/combinatorics/partitions.pyi index a6693829..6ad5341c 100644 --- a/stubs/sympy-stubs/combinatorics/partitions.pyi +++ b/stubs/sympy-stubs/combinatorics/partitions.pyi @@ -7,87 +7,44 @@ from sympy.sets.sets import FiniteSet class Partition(FiniteSet): _rank = ... _partition = ... - def __new__(cls, *partition) -> Self: - ... - - def sort_key(self, order=...) -> tuple[tuple[tuple[Literal[5], Literal[0], str], tuple[int, tuple[Any, ...]], Any, Any] | Any | tuple[tuple[Literal[10, 0], Literal[0], str | Any], tuple[int, tuple[Any, ...]] | tuple[Literal[1], tuple[str]], Any, Any], ...]: - ... - + def __new__(cls, *partition) -> Self: ... + def sort_key(self, order=...) -> tuple[ + tuple[tuple[Literal[5], Literal[0], str], tuple[int, tuple[Any, ...]], Any, Any] + | Any + | tuple[ + tuple[Literal[10, 0], Literal[0], str | Any], tuple[int, tuple[Any, ...]] | tuple[Literal[1], tuple[str]], Any, Any + ], + ..., + ]: ... @property - def partition(self) -> list[Any]: - ... - - def __add__(self, other) -> Partition: - ... - - def __sub__(self, other) -> Partition: - ... - - def __le__(self, other) -> bool: - ... - - def __lt__(self, other) -> bool: - ... - + def partition(self) -> list[Any]: ... + def __add__(self, other) -> Partition: ... + def __sub__(self, other) -> Partition: ... + def __le__(self, other) -> bool: ... + def __lt__(self, other) -> bool: ... @property - def rank(self) -> int: - ... - + def rank(self) -> int: ... @property - def RGS(self) -> tuple[Any, ...]: - ... - + def RGS(self) -> tuple[Any, ...]: ... @classmethod - def from_rgs(cls, rgs, elements) -> Partition: - ... - - + def from_rgs(cls, rgs, elements) -> Partition: ... class IntegerPartition(Basic): _dict = ... _keys = ... - def __new__(cls, partition, integer=...) -> Self: - ... - - def prev_lex(self) -> IntegerPartition: - ... - - def next_lex(self) -> IntegerPartition: - ... - - def as_dict(self) -> dict[str, str]: - ... - + def __new__(cls, partition, integer=...) -> Self: ... + def prev_lex(self) -> IntegerPartition: ... + def next_lex(self) -> IntegerPartition: ... + def as_dict(self) -> dict[str, str]: ... @property - def conjugate(self): - ... - - def __lt__(self, other) -> bool: - ... - - def __le__(self, other) -> bool: - ... - - def as_ferrers(self, char=...) -> LiteralString: - ... - - def __str__(self) -> str: - ... - - - -def random_integer_partition(n, seed=...) -> list[Any]: - ... - -def RGS_generalized(m): - ... - -def RGS_enum(m) -> type[UndefinedFunction] | Literal[0, 1]: - ... - -def RGS_unrank(rank, m) -> list[Any]: - ... - -def RGS_rank(rgs) -> Literal[0]: - ... - + def conjugate(self): ... + def __lt__(self, other) -> bool: ... + def __le__(self, other) -> bool: ... + def as_ferrers(self, char=...) -> LiteralString: ... + def __str__(self) -> str: ... + +def random_integer_partition(n, seed=...) -> list[Any]: ... +def RGS_generalized(m): ... +def RGS_enum(m) -> type[UndefinedFunction] | Literal[0, 1]: ... +def RGS_unrank(rank, m) -> list[Any]: ... +def RGS_rank(rgs) -> Literal[0]: ... diff --git a/stubs/sympy-stubs/combinatorics/pc_groups.pyi b/stubs/sympy-stubs/combinatorics/pc_groups.pyi index cbdc415c..3df1a59c 100644 --- a/stubs/sympy-stubs/combinatorics/pc_groups.pyi +++ b/stubs/sympy-stubs/combinatorics/pc_groups.pyi @@ -5,53 +5,22 @@ from sympy.printing.defaults import DefaultPrinting class PolycyclicGroup(DefaultPrinting): is_group = ... is_solvable = ... - def __init__(self, pc_sequence, pc_series, relative_order, collector=...) -> None: - ... - - def is_prime_order(self) -> bool: - ... - - def length(self) -> int: - ... - - + def __init__(self, pc_sequence, pc_series, relative_order, collector=...) -> None: ... + def is_prime_order(self) -> bool: ... + def length(self) -> int: ... class Collector(DefaultPrinting): - def __init__(self, pcgs, pc_series, relative_order, free_group_=..., pc_presentation=...) -> None: - ... - - def minimal_uncollected_subword(self, word) -> tuple[tuple[Any, Any]] | tuple[tuple[Any, Any], tuple[Any, Literal[1, -1]]] | None: - ... - - def relations(self) -> tuple[dict[Any, Any], dict[Any, Any]]: - ... - - def subword_index(self, word, w) -> tuple[Literal[-1], Literal[-1]] | tuple[int, int]: - ... - - def map_relation(self, w): - ... - - def collected_word(self, word): - ... - - def pc_relators(self) -> dict[Any, Any]: - ... - - def exponent_vector(self, element) -> list[int]: - ... - - def depth(self, element) -> int: - ... - - def leading_exponent(self, element) -> int | None: - ... - - def induced_pcgs(self, gens) -> list[int]: - ... - - def constructive_membership_test(self, ipcgs, g) -> list[int] | Literal[False]: - ... - - - + def __init__(self, pcgs, pc_series, relative_order, free_group_=..., pc_presentation=...) -> None: ... + def minimal_uncollected_subword( + self, word + ) -> tuple[tuple[Any, Any]] | tuple[tuple[Any, Any], tuple[Any, Literal[1, -1]]] | None: ... + def relations(self) -> tuple[dict[Any, Any], dict[Any, Any]]: ... + def subword_index(self, word, w) -> tuple[Literal[-1], Literal[-1]] | tuple[int, int]: ... + def map_relation(self, w): ... + def collected_word(self, word): ... + def pc_relators(self) -> dict[Any, Any]: ... + def exponent_vector(self, element) -> list[int]: ... + def depth(self, element) -> int: ... + def leading_exponent(self, element) -> int | None: ... + def induced_pcgs(self, gens) -> list[int]: ... + def constructive_membership_test(self, ipcgs, g) -> list[int] | Literal[False]: ... diff --git a/stubs/sympy-stubs/combinatorics/perm_groups.pyi b/stubs/sympy-stubs/combinatorics/perm_groups.pyi index a24c8ef3..23ecaa82 100644 --- a/stubs/sympy-stubs/combinatorics/perm_groups.pyi +++ b/stubs/sympy-stubs/combinatorics/perm_groups.pyi @@ -8,312 +8,153 @@ from sympy.core.function import UndefinedFunction rmul = ... _af_new = ... + class PermutationGroup(Basic): is_group = ... - def __new__(cls, *args, dups=..., **kwargs) -> Self: - ... - - def __init__(self, *args, **kwargs) -> None: - ... - - def __getitem__(self, i): - ... - - def __contains__(self, i) -> bool: - ... - - def __len__(self) -> int: - ... - - def equals(self, other) -> bool: - ... - - def __mul__(self, other) -> Coset | PermutationGroup: - ... - - @property - def base(self) -> list[Any]: - ... - - def baseswap(self, base, strong_gens, pos, randomized=..., transversals=..., basic_orbits=..., strong_gens_distr=...) -> tuple[Any, Any]: - ... - - @property - def basic_orbits(self) -> list[list[Any]]: - ... - - @property - def basic_stabilizers(self) -> list[Any]: - ... - - @property - def basic_transversals(self) -> list[None] | None: - ... - - def composition_series(self) -> list[Any]: - ... - - def coset_transversal(self, H) -> list[Any | Basic | list[Any] | Permutation] | list[Permutation]: - ... - - def coset_table(self, H) -> list[Any] | None: - ... - - def center(self) -> Self | PermutationGroup | None: - ... - - def centralizer(self, other) -> Self | PermutationGroup | None: - ... - - def commutator(self, G, H) -> PermutationGroup | None: - ... - - def coset_factor(self, g, factor_index=...) -> list[Any]: - ... - - def generator_product(self, g, original=...) -> list[Any]: - ... - - def coset_rank(self, g) -> int | None: - ... - - def coset_unrank(self, rank, af=...) -> list[Any] | Permutation | None: - ... - - @property - def degree(self): - ... - - @property - def identity(self) -> Permutation: - ... - - @property - def elements(self) -> set[Any | Basic | list[Any] | Permutation]: - ... - - def derived_series(self) -> list[Self]: - ... - - def derived_subgroup(self) -> PermutationGroup | None: - ... - - def generate(self, method=..., af=...) -> Generator[Any | Basic | list[Any] | Permutation, Any, None] | Generator[list[int] | Permutation | list[Any], Any, None]: - ... - - def generate_dimino(self, af=...) -> Generator[list[int] | Permutation | list[Any], Any, None]: - ... - - def generate_schreier_sims(self, af=...) -> Generator[Any | Basic | list[Any] | Permutation, Any, None]: - ... - - @property - def generators(self) -> list[Basic]: - ... - - def contains(self, g, strict=...) -> bool: - ... - - @property - def is_perfect(self) -> bool: - ... - - @property - def is_abelian(self) -> bool: - ... - - def abelian_invariants(self) -> list[Any]: - ... - - def is_elementary(self, p) -> bool: - ... - - def is_alt_sym(self, eps=..., _random_prec=...) -> bool: - ... - - @property - def is_nilpotent(self) -> bool: - ... - - def is_normal(self, gr, strict=...) -> bool: - ... - - def is_primitive(self, randomized=...) -> bool: - ... - - def minimal_blocks(self, randomized=...) -> list[Any] | Literal[False]: - ... - - @property - def is_solvable(self) -> bool: - ... - - def is_subgroup(self, G, strict=...) -> bool: - ... - - @property - def is_polycyclic(self) -> bool: - ... - - def is_transitive(self, strict=...) -> bool: - ... - - @property - def is_trivial(self) -> bool: - ... - - def lower_central_series(self) -> list[Self]: - ... - - @property - def max_div(self) -> Literal[1] | None: - ... - - def minimal_block(self, points) -> list[Any] | Literal[False]: - ... - - def conjugacy_class(self, x) -> set[Any]: - ... - - def conjugacy_classes(self) -> list[set[Permutation]]: - ... - - def normal_closure(self, other, k=...) -> PermutationGroup | None: - ... - - def orbit(self, alpha, action=...) -> set[Any] | set[tuple[Any, ...]] | None: - ... - - def orbit_rep(self, alpha, beta, schreier_vector=...) -> Permutation | Literal[False]: - ... - - def orbit_transversal(self, alpha, pairs=...) -> list[tuple[Any, Permutation]] | list[tuple[Any, list[int]]] | tuple[list[tuple[Any, Permutation]] | list[tuple[Any, list[int]]], dict[Any, list[Any]]] | list[list[int]] | tuple[list[list[int]], dict[Any, list[Any]]] | list[Permutation] | tuple[list[Permutation], dict[Any, list[Any]]]: - ... - - def orbits(self, rep=...) -> list[Any]: - ... - - def order(self) -> int | type[UndefinedFunction]: - ... - - def index(self, H) -> None: - ... - - @property - def is_symmetric(self) -> bool: - ... - - @property - def is_alternating(self) -> bool: - ... - - @property - def is_cyclic(self) -> bool: - ... - - @property - def is_dihedral(self) -> bool: - ... - - def pointwise_stabilizer(self, points, incremental=...) -> PermutationGroup: - ... - - def make_perm(self, n, seed=...) -> Permutation: - ... - - def random(self, af=...) -> list[Any] | Permutation | None: - ... - - def random_pr(self, gen_count=..., iterations=..., _random_prec=...) -> Permutation: - ... - - def random_stab(self, alpha, schreier_vector=..., _random_prec=...) -> Permutation: - ... - - def schreier_sims(self) -> None: - ... - - def schreier_sims_incremental(self, base=..., gens=..., slp_dict=...) -> tuple[Any | list[Any], list[Basic] | Any, dict[Basic | Any, list[Basic | Any]]] | tuple[Any | list[Any], list[Basic] | Any] | tuple[Any | list[Any], list[Basic | Any], dict[Any, Any]] | tuple[Any | list[Any], list[Basic | Any]]: - ... - - def schreier_sims_random(self, base=..., gens=..., consec_succ=..., _random_prec=...) -> tuple[Any | list[Any], list[Any]]: - ... - - def schreier_vector(self, alpha): - ... - - def stabilizer(self, alpha) -> PermGroup: - ... - - @property - def strong_gens(self) -> list[Basic] | list[Basic | Any]: - ... - - def subgroup(self, gens) -> PermutationGroup: - ... - - def subgroup_search(self, prop, base=..., strong_gens=..., tests=..., init_subgroup=...) -> PermutationGroup: - ... - - @property - def transitivity_degree(self) -> int: - ... - - def sylow_subgroup(self, p) -> PermutationGroup | Self: - ... - - def strong_presentation(self) -> FpGroup | tuple[Any, Any] | tuple[Any | list[Any], Any | list[Any]]: - ... - - def presentation(self, eliminate_gens=...) -> FpGroup | tuple[Any, Any] | tuple[Any | list[Any], Any | list[Any]] | Any: - ... - - def polycyclic_group(self) -> PolycyclicGroup: - ... - - + def __new__(cls, *args, dups=..., **kwargs) -> Self: ... + def __init__(self, *args, **kwargs) -> None: ... + def __getitem__(self, i): ... + def __contains__(self, i) -> bool: ... + def __len__(self) -> int: ... + def equals(self, other) -> bool: ... + def __mul__(self, other) -> Coset | PermutationGroup: ... + @property + def base(self) -> list[Any]: ... + def baseswap( + self, base, strong_gens, pos, randomized=..., transversals=..., basic_orbits=..., strong_gens_distr=... + ) -> tuple[Any, Any]: ... + @property + def basic_orbits(self) -> list[list[Any]]: ... + @property + def basic_stabilizers(self) -> list[Any]: ... + @property + def basic_transversals(self) -> list[None] | None: ... + def composition_series(self) -> list[Any]: ... + def coset_transversal(self, H) -> list[Any | Basic | list[Any] | Permutation] | list[Permutation]: ... + def coset_table(self, H) -> list[Any] | None: ... + def center(self) -> Self | PermutationGroup | None: ... + def centralizer(self, other) -> Self | PermutationGroup | None: ... + def commutator(self, G, H) -> PermutationGroup | None: ... + def coset_factor(self, g, factor_index=...) -> list[Any]: ... + def generator_product(self, g, original=...) -> list[Any]: ... + def coset_rank(self, g) -> int | None: ... + def coset_unrank(self, rank, af=...) -> list[Any] | Permutation | None: ... + @property + def degree(self): ... + @property + def identity(self) -> Permutation: ... + @property + def elements(self) -> set[Any | Basic | list[Any] | Permutation]: ... + def derived_series(self) -> list[Self]: ... + def derived_subgroup(self) -> PermutationGroup | None: ... + def generate( + self, method=..., af=... + ) -> ( + Generator[Any | Basic | list[Any] | Permutation, Any, None] | Generator[list[int] | Permutation | list[Any], Any, None] + ): ... + def generate_dimino(self, af=...) -> Generator[list[int] | Permutation | list[Any], Any, None]: ... + def generate_schreier_sims(self, af=...) -> Generator[Any | Basic | list[Any] | Permutation, Any, None]: ... + @property + def generators(self) -> list[Basic]: ... + def contains(self, g, strict=...) -> bool: ... + @property + def is_perfect(self) -> bool: ... + @property + def is_abelian(self) -> bool: ... + def abelian_invariants(self) -> list[Any]: ... + def is_elementary(self, p) -> bool: ... + def is_alt_sym(self, eps=..., _random_prec=...) -> bool: ... + @property + def is_nilpotent(self) -> bool: ... + def is_normal(self, gr, strict=...) -> bool: ... + def is_primitive(self, randomized=...) -> bool: ... + def minimal_blocks(self, randomized=...) -> list[Any] | Literal[False]: ... + @property + def is_solvable(self) -> bool: ... + def is_subgroup(self, G, strict=...) -> bool: ... + @property + def is_polycyclic(self) -> bool: ... + def is_transitive(self, strict=...) -> bool: ... + @property + def is_trivial(self) -> bool: ... + def lower_central_series(self) -> list[Self]: ... + @property + def max_div(self) -> Literal[1] | None: ... + def minimal_block(self, points) -> list[Any] | Literal[False]: ... + def conjugacy_class(self, x) -> set[Any]: ... + def conjugacy_classes(self) -> list[set[Permutation]]: ... + def normal_closure(self, other, k=...) -> PermutationGroup | None: ... + def orbit(self, alpha, action=...) -> set[Any] | set[tuple[Any, ...]] | None: ... + def orbit_rep(self, alpha, beta, schreier_vector=...) -> Permutation | Literal[False]: ... + def orbit_transversal( + self, alpha, pairs=... + ) -> ( + list[tuple[Any, Permutation]] + | list[tuple[Any, list[int]]] + | tuple[list[tuple[Any, Permutation]] | list[tuple[Any, list[int]]], dict[Any, list[Any]]] + | list[list[int]] + | tuple[list[list[int]], dict[Any, list[Any]]] + | list[Permutation] + | tuple[list[Permutation], dict[Any, list[Any]]] + ): ... + def orbits(self, rep=...) -> list[Any]: ... + def order(self) -> int | type[UndefinedFunction]: ... + def index(self, H) -> None: ... + @property + def is_symmetric(self) -> bool: ... + @property + def is_alternating(self) -> bool: ... + @property + def is_cyclic(self) -> bool: ... + @property + def is_dihedral(self) -> bool: ... + def pointwise_stabilizer(self, points, incremental=...) -> PermutationGroup: ... + def make_perm(self, n, seed=...) -> Permutation: ... + def random(self, af=...) -> list[Any] | Permutation | None: ... + def random_pr(self, gen_count=..., iterations=..., _random_prec=...) -> Permutation: ... + def random_stab(self, alpha, schreier_vector=..., _random_prec=...) -> Permutation: ... + def schreier_sims(self) -> None: ... + def schreier_sims_incremental( + self, base=..., gens=..., slp_dict=... + ) -> ( + tuple[Any | list[Any], list[Basic] | Any, dict[Basic | Any, list[Basic | Any]]] + | tuple[Any | list[Any], list[Basic] | Any] + | tuple[Any | list[Any], list[Basic | Any], dict[Any, Any]] + | tuple[Any | list[Any], list[Basic | Any]] + ): ... + def schreier_sims_random( + self, base=..., gens=..., consec_succ=..., _random_prec=... + ) -> tuple[Any | list[Any], list[Any]]: ... + def schreier_vector(self, alpha): ... + def stabilizer(self, alpha) -> PermGroup: ... + @property + def strong_gens(self) -> list[Basic] | list[Basic | Any]: ... + def subgroup(self, gens) -> PermutationGroup: ... + def subgroup_search(self, prop, base=..., strong_gens=..., tests=..., init_subgroup=...) -> PermutationGroup: ... + @property + def transitivity_degree(self) -> int: ... + def sylow_subgroup(self, p) -> PermutationGroup | Self: ... + def strong_presentation(self) -> FpGroup | tuple[Any, Any] | tuple[Any | list[Any], Any | list[Any]]: ... + def presentation(self, eliminate_gens=...) -> FpGroup | tuple[Any, Any] | tuple[Any | list[Any], Any | list[Any]] | Any: ... + def polycyclic_group(self) -> PolycyclicGroup: ... PermGroup = PermutationGroup + class SymmetricPermutationGroup(Basic): - def __new__(cls, deg) -> Self: - ... - - def __init__(self, *args, **kwargs) -> None: - ... - - def __contains__(self, i) -> bool: - ... - - def order(self) -> type[UndefinedFunction]: - ... - + def __new__(cls, deg) -> Self: ... + def __init__(self, *args, **kwargs) -> None: ... + def __contains__(self, i) -> bool: ... + def order(self) -> type[UndefinedFunction]: ... @property - def degree(self) -> Basic: - ... - + def degree(self) -> Basic: ... @property - def identity(self) -> Permutation: - ... - - + def identity(self) -> Permutation: ... class Coset(Basic): - def __new__(cls, g, H, G=..., dir=...) -> Self: - ... - - def __init__(self, *args, **kwargs) -> None: - ... - + def __new__(cls, g, H, G=..., dir=...) -> Self: ... + def __init__(self, *args, **kwargs) -> None: ... @property - def is_left_coset(self) -> bool: - ... - + def is_left_coset(self) -> bool: ... @property - def is_right_coset(self) -> bool: - ... - - def as_list(self) -> list[Any]: - ... - - - + def is_right_coset(self) -> bool: ... + def as_list(self) -> list[Any]: ... diff --git a/stubs/sympy-stubs/combinatorics/permutations.pyi b/stubs/sympy-stubs/combinatorics/permutations.pyi index 19f0ccf2..7ba61ff8 100644 --- a/stubs/sympy-stubs/combinatorics/permutations.pyi +++ b/stubs/sympy-stubs/combinatorics/permutations.pyi @@ -6,35 +6,16 @@ from sympy.core.expr import Expr from sympy.core.numbers import Integer class Cycle(dict): - def __missing__(self, arg) -> int: - ... - - def __iter__(self) -> Generator[Any, Any, None]: - ... - - def __call__(self, *other) -> Cycle: - ... - - def list(self, size=...) -> list[Any]: - ... - - def __repr__(self) -> str: - ... - - def __str__(self) -> str: - ... - - def __init__(self, *args) -> None: - ... - + def __missing__(self, arg) -> int: ... + def __iter__(self) -> Generator[Any, Any, None]: ... + def __call__(self, *other) -> Cycle: ... + def list(self, size=...) -> list[Any]: ... + def __repr__(self) -> str: ... + def __str__(self) -> str: ... + def __init__(self, *args) -> None: ... @property - def size(self) -> Literal[0]: - ... - - def copy(self) -> Cycle: - ... - - + def size(self) -> Literal[0]: ... + def copy(self) -> Cycle: ... class Permutation(Atom): is_Permutation = ... @@ -43,234 +24,99 @@ class Permutation(Atom): _cycle_structure = ... _size = ... _rank = ... - def __new__(cls, *args, size=..., **kwargs): - ... - + def __new__(cls, *args, size=..., **kwargs): ... @property - def array_form(self): - ... - - def list(self, size=...): - ... - + def array_form(self): ... + def list(self, size=...): ... @property - def cyclic_form(self) -> list[Any]: - ... - + def cyclic_form(self) -> list[Any]: ... @property - def full_cyclic_form(self) -> list[Any]: - ... - + def full_cyclic_form(self) -> list[Any]: ... @property - def size(self) -> None: - ... - - def support(self) -> list[int]: - ... - - def __add__(self, other) -> Self: - ... - - def __sub__(self, other) -> Self: - ... - + def size(self) -> None: ... + def support(self) -> list[int]: ... + def __add__(self, other) -> Self: ... + def __sub__(self, other) -> Self: ... @staticmethod - def rmul(*args): - ... - + def rmul(*args): ... @classmethod - def rmul_with_af(cls, *args) -> Self: - ... - - def mul_inv(self, other) -> Self: - ... - - def __rmul__(self, other) -> Coset | Self: - ... - - def __mul__(self, other) -> Coset | Self: - ... - - def commutes_with(self, other) -> bool: - ... - - def __pow__(self, n) -> Self: - ... - - def __rxor__(self, i) -> list[Any] | Coset | Permutation: - ... - - def __xor__(self, h) -> Self: - ... - - def transpositions(self) -> list[Any]: - ... - + def rmul_with_af(cls, *args) -> Self: ... + def mul_inv(self, other) -> Self: ... + def __rmul__(self, other) -> Coset | Self: ... + def __mul__(self, other) -> Coset | Self: ... + def commutes_with(self, other) -> bool: ... + def __pow__(self, n) -> Self: ... + def __rxor__(self, i) -> list[Any] | Coset | Permutation: ... + def __xor__(self, h) -> Self: ... + def transpositions(self) -> list[Any]: ... @classmethod - def from_sequence(cls, i, key=...) -> Permutation: - ... - - def __invert__(self) -> Self: - ... - - def __iter__(self) -> Generator[Any, Any, None]: - ... - - def __repr__(self): - ... - - def __call__(self, *i) -> list[Any] | Coset | Self: - ... - - def atoms(self) -> set[Any]: - ... - - def apply(self, i) -> Integer | AppliedPermutation: - ... - - def next_lex(self) -> Self | None: - ... - + def from_sequence(cls, i, key=...) -> Permutation: ... + def __invert__(self) -> Self: ... + def __iter__(self) -> Generator[Any, Any, None]: ... + def __repr__(self): ... + def __call__(self, *i) -> list[Any] | Coset | Self: ... + def atoms(self) -> set[Any]: ... + def apply(self, i) -> Integer | AppliedPermutation: ... + def next_lex(self) -> Self | None: ... @classmethod - def unrank_nonlex(cls, n, r) -> Self: - ... - - def rank_nonlex(self, inv_perm=...) -> Literal[0]: - ... - - def next_nonlex(self) -> Self | None: - ... - - def rank(self) -> int: - ... - + def unrank_nonlex(cls, n, r) -> Self: ... + def rank_nonlex(self, inv_perm=...) -> Literal[0]: ... + def next_nonlex(self) -> Self | None: ... + def rank(self) -> int: ... @property - def cardinality(self) -> int: - ... - - def parity(self) -> int: - ... - + def cardinality(self) -> int: ... + def parity(self) -> int: ... @property - def is_even(self) -> bool: - ... - + def is_even(self) -> bool: ... @property - def is_odd(self) -> bool: - ... - + def is_odd(self) -> bool: ... @property - def is_Singleton(self) -> bool: - ... - + def is_Singleton(self) -> bool: ... @property - def is_Empty(self) -> bool: - ... - + def is_Empty(self) -> bool: ... @property - def is_identity(self) -> bool: - ... - + def is_identity(self) -> bool: ... @property - def is_Identity(self) -> bool: - ... - - def ascents(self) -> list[int]: - ... - - def descents(self) -> list[int]: - ... - - def max(self) -> Literal[0]: - ... - - def min(self) -> int: - ... - - def inversions(self) -> int: - ... - - def commutator(self, x) -> Self: - ... - - def signature(self) -> Literal[1, -1]: - ... - - def order(self) -> Any: - ... - - def length(self) -> int: - ... - + def is_Identity(self) -> bool: ... + def ascents(self) -> list[int]: ... + def descents(self) -> list[int]: ... + def max(self) -> Literal[0]: ... + def min(self) -> int: ... + def inversions(self) -> int: ... + def commutator(self, x) -> Self: ... + def signature(self) -> Literal[1, -1]: ... + def order(self) -> Any: ... + def length(self) -> int: ... @property - def cycle_structure(self) -> dict[Any, int]: - ... - + def cycle_structure(self) -> dict[Any, int]: ... @property - def cycles(self) -> int: - ... - - def index(self) -> int: - ... - - def runs(self) -> list[Any]: - ... - - def inversion_vector(self) -> list[int]: - ... - - def rank_trotterjohnson(self) -> int: - ... - + def cycles(self) -> int: ... + def index(self) -> int: ... + def runs(self) -> list[Any]: ... + def inversion_vector(self) -> list[int]: ... + def rank_trotterjohnson(self) -> int: ... @classmethod - def unrank_trotterjohnson(cls, size, rank) -> Self: - ... - - def next_trotterjohnson(self) -> Self | None: - ... - - def get_precedence_matrix(self): - ... - - def get_precedence_distance(self, other): - ... - - def get_adjacency_matrix(self): - ... - - def get_adjacency_distance(self, other): - ... - - def get_positional_distance(self, other) -> int: - ... - + def unrank_trotterjohnson(cls, size, rank) -> Self: ... + def next_trotterjohnson(self) -> Self | None: ... + def get_precedence_matrix(self): ... + def get_precedence_distance(self, other): ... + def get_adjacency_matrix(self): ... + def get_adjacency_distance(self, other): ... + def get_positional_distance(self, other) -> int: ... @classmethod - def josephus(cls, m, n, s=...) -> Self: - ... - + def josephus(cls, m, n, s=...) -> Self: ... @classmethod - def from_inversion_vector(cls, inversion) -> Self: - ... - + def from_inversion_vector(cls, inversion) -> Self: ... @classmethod - def random(cls, n) -> Self: - ... - + def random(cls, n) -> Self: ... @classmethod - def unrank_lex(cls, size, rank) -> Self: - ... - - def resize(self, n) -> Permutation | Self: - ... - - print_cyclic = ... + def unrank_lex(cls, size, rank) -> Self: ... + def resize(self, n) -> Permutation | Self: ... + print_cyclic = ... Perm = Permutation _af_new = ... -class AppliedPermutation(Expr): - def __new__(cls, perm, x, evaluate=...) -> Self: - ... - - +class AppliedPermutation(Expr): + def __new__(cls, perm, x, evaluate=...) -> Self: ... diff --git a/stubs/sympy-stubs/combinatorics/polyhedron.pyi b/stubs/sympy-stubs/combinatorics/polyhedron.pyi index 60cf1338..e074e02d 100644 --- a/stubs/sympy-stubs/combinatorics/polyhedron.pyi +++ b/stubs/sympy-stubs/combinatorics/polyhedron.pyi @@ -4,47 +4,28 @@ from sympy.core import Basic from sympy.sets.sets import FiniteSet rmul = ... + class Polyhedron(Basic): _edges = ... - def __new__(cls, corners, faces=..., pgroup=...) -> Self: - ... - + def __new__(cls, corners, faces=..., pgroup=...) -> Self: ... @property - def corners(self) -> tuple[Any, ...] | Basic: - ... - + def corners(self) -> tuple[Any, ...] | Basic: ... + vertices = ... @property - def array_form(self) -> list[int]: - ... - + def array_form(self) -> list[int]: ... @property - def cyclic_form(self) -> list[Any]: - ... - + def cyclic_form(self) -> list[Any]: ... @property - def size(self) -> int: - ... - + def size(self) -> int: ... @property - def faces(self): - ... - + def faces(self): ... @property - def pgroup(self): - ... - + def pgroup(self): ... @property - def edges(self) -> FiniteSet: - ... - - def rotate(self, perm) -> None: - ... - - def reset(self) -> None: - ... - - + def edges(self) -> FiniteSet: ... + def rotate(self, perm) -> None: ... + def reset(self) -> None: ... tetrahedron = ... cube = ... diff --git a/stubs/sympy-stubs/combinatorics/prufer.pyi b/stubs/sympy-stubs/combinatorics/prufer.pyi index c4041b54..a3b13c3e 100644 --- a/stubs/sympy-stubs/combinatorics/prufer.pyi +++ b/stubs/sympy-stubs/combinatorics/prufer.pyi @@ -8,52 +8,24 @@ class Prufer(Basic): _nodes = ... _rank = ... @property - def prufer_repr(self) -> list[Any]: - ... - + def prufer_repr(self) -> list[Any]: ... @property - def tree_repr(self) -> list[Any]: - ... - + def tree_repr(self) -> list[Any]: ... @property - def nodes(self) -> None: - ... - + def nodes(self) -> None: ... @property - def rank(self) -> int: - ... - + def rank(self) -> int: ... @property - def size(self) -> int: - ... - + def size(self) -> int: ... @staticmethod - def to_prufer(tree, n) -> list[Any]: - ... - + def to_prufer(tree, n) -> list[Any]: ... @staticmethod - def to_tree(prufer) -> list[Any]: - ... - + def to_tree(prufer) -> list[Any]: ... @staticmethod - def edges(*runs) -> tuple[list[Any], Any]: - ... - - def prufer_rank(self) -> Literal[0]: - ... - + def edges(*runs) -> tuple[list[Any], Any]: ... + def prufer_rank(self) -> Literal[0]: ... @classmethod - def unrank(cls, rank, n) -> Prufer: - ... - - def __new__(cls, *args, **kw_args) -> Self: - ... - - def next(self, delta=...) -> Prufer: - ... - - def prev(self, delta=...) -> Prufer: - ... - - - + def unrank(cls, rank, n) -> Prufer: ... + def __new__(cls, *args, **kw_args) -> Self: ... + def next(self, delta=...) -> Prufer: ... + def prev(self, delta=...) -> Prufer: ... diff --git a/stubs/sympy-stubs/combinatorics/rewritingsystem.pyi b/stubs/sympy-stubs/combinatorics/rewritingsystem.pyi index 1428ddc3..57ac0c6f 100644 --- a/stubs/sympy-stubs/combinatorics/rewritingsystem.pyi +++ b/stubs/sympy-stubs/combinatorics/rewritingsystem.pyi @@ -1,30 +1,12 @@ from typing import Any class RewritingSystem: - def __init__(self, group) -> None: - ... - - def set_max(self, n) -> None: - ... - + def __init__(self, group) -> None: ... + def set_max(self, n) -> None: ... @property - def is_confluent(self) -> bool: - ... - - def add_rule(self, w1, w2, check=...) -> set[Any]: - ... - - def make_confluent(self, check=...) -> bool | None: - ... - - def reduce(self, word, exclude=...): - ... - - def construct_automaton(self) -> None: - ... - - def reduce_using_automaton(self, word): - ... - - - + def is_confluent(self) -> bool: ... + def add_rule(self, w1, w2, check=...) -> set[Any]: ... + def make_confluent(self, check=...) -> bool | None: ... + def reduce(self, word, exclude=...): ... + def construct_automaton(self) -> None: ... + def reduce_using_automaton(self, word): ... diff --git a/stubs/sympy-stubs/combinatorics/rewritingsystem_fsm.pyi b/stubs/sympy-stubs/combinatorics/rewritingsystem_fsm.pyi index b6d322fe..ff7952b3 100644 --- a/stubs/sympy-stubs/combinatorics/rewritingsystem_fsm.pyi +++ b/stubs/sympy-stubs/combinatorics/rewritingsystem_fsm.pyi @@ -1,23 +1,10 @@ from typing import LiteralString class State: - def __init__(self, name, state_machine, state_type=..., rh_rule=...) -> None: - ... - - def add_transition(self, letter, state) -> None: - ... - - + def __init__(self, name, state_machine, state_type=..., rh_rule=...) -> None: ... + def add_transition(self, letter, state) -> None: ... class StateMachine: - def __init__(self, name, automaton_alphabet) -> None: - ... - - def add_state(self, state_name, state_type=..., rh_rule=...) -> None: - ... - - def __repr__(self) -> LiteralString: - ... - - - + def __init__(self, name, automaton_alphabet) -> None: ... + def add_state(self, state_name, state_type=..., rh_rule=...) -> None: ... + def __repr__(self) -> LiteralString: ... diff --git a/stubs/sympy-stubs/combinatorics/subsets.pyi b/stubs/sympy-stubs/combinatorics/subsets.pyi index bccb026d..f8d1dfa2 100644 --- a/stubs/sympy-stubs/combinatorics/subsets.pyi +++ b/stubs/sympy-stubs/combinatorics/subsets.pyi @@ -7,90 +7,41 @@ class Subset: _rank_graycode = ... _subset = ... _superset = ... - def __new__(cls, subset, superset) -> Self: - ... - - def __eq__(self, other) -> bool: - ... - - def iterate_binary(self, k) -> Subset: - ... - - def next_binary(self) -> Subset: - ... - - def prev_binary(self) -> Subset: - ... - - def next_lexicographic(self) -> Subset: - ... - - def prev_lexicographic(self) -> Subset: - ... - - def iterate_graycode(self, k) -> Subset: - ... - - def next_gray(self) -> Subset: - ... - - def prev_gray(self) -> Subset: - ... - + def __new__(cls, subset, superset) -> Self: ... + def __eq__(self, other) -> bool: ... + def iterate_binary(self, k) -> Subset: ... + def next_binary(self) -> Subset: ... + def prev_binary(self) -> Subset: ... + def next_lexicographic(self) -> Subset: ... + def prev_lexicographic(self) -> Subset: ... + def iterate_graycode(self, k) -> Subset: ... + def next_gray(self) -> Subset: ... + def prev_gray(self) -> Subset: ... @property - def rank_binary(self) -> int: - ... - + def rank_binary(self) -> int: ... @property - def rank_lexicographic(self) -> int: - ... - + def rank_lexicographic(self) -> int: ... @property - def rank_gray(self) -> int: - ... - + def rank_gray(self) -> int: ... @property - def subset(self) -> None: - ... - + def subset(self) -> None: ... @property - def size(self) -> int: - ... - + def size(self) -> int: ... @property - def superset(self) -> None: - ... - + def superset(self) -> None: ... @property - def superset_size(self) -> int: - ... - + def superset_size(self) -> int: ... @property - def cardinality(self) -> Any: - ... - + def cardinality(self) -> Any: ... @classmethod - def subset_from_bitlist(cls, super_set, bitlist) -> Subset: - ... - + def subset_from_bitlist(cls, super_set, bitlist) -> Subset: ... @classmethod - def bitlist_from_subset(cls, subset, superset) -> str: - ... - + def bitlist_from_subset(cls, subset, superset) -> str: ... @classmethod - def unrank_binary(cls, rank, superset) -> Subset: - ... - + def unrank_binary(cls, rank, superset) -> Subset: ... @classmethod - def unrank_gray(cls, rank, superset) -> Subset: - ... - + def unrank_gray(cls, rank, superset) -> Subset: ... @classmethod - def subset_indices(cls, subset, superset) -> list[Any]: - ... - - - -def ksubsets(superset, k) -> combinations[Any]: - ... + def subset_indices(cls, subset, superset) -> list[Any]: ... +def ksubsets(superset, k) -> combinations[Any]: ... diff --git a/stubs/sympy-stubs/combinatorics/tensor_can.pyi b/stubs/sympy-stubs/combinatorics/tensor_can.pyi index b141f505..b6adecd1 100644 --- a/stubs/sympy-stubs/combinatorics/tensor_can.pyi +++ b/stubs/sympy-stubs/combinatorics/tensor_can.pyi @@ -3,40 +3,24 @@ from typing import Any, Literal from sympy.combinatorics.permutations import Perm from sympy.core.basic import Basic -def dummy_sgs(dummies, sym, n) -> list[Any]: - ... - -def transversal2coset(size, base, transversal) -> list[Any]: - ... - -def double_coset_can_rep(dummies, sym, b_S, sgens, S_transversals, g) -> Literal[0]: - ... - -def canonical_free(base, gens, g, num_free) -> list[Any]: - ... - -def canonicalize(g, dummies, msym, *v) -> list[Any] | Literal[0]: - ... - -def perm_af_direct_product(gens1, gens2, signed=...) -> list[list[Any]]: - ... - -def bsgs_direct_product(base1, gens1, base2, gens2, signed=...) -> tuple[list[Any], list[Perm]]: - ... - -def get_symmetric_group_sgs(n, antisym=...) -> tuple[list[Any], list[Perm]] | tuple[list[int], list[Perm]]: - ... +def dummy_sgs(dummies, sym, n) -> list[Any]: ... +def transversal2coset(size, base, transversal) -> list[Any]: ... +def double_coset_can_rep(dummies, sym, b_S, sgens, S_transversals, g) -> Literal[0]: ... +def canonical_free(base, gens, g, num_free) -> list[Any]: ... +def canonicalize(g, dummies, msym, *v) -> list[Any] | Literal[0]: ... +def perm_af_direct_product(gens1, gens2, signed=...) -> list[list[Any]]: ... +def bsgs_direct_product(base1, gens1, base2, gens2, signed=...) -> tuple[list[Any], list[Perm]]: ... +def get_symmetric_group_sgs(n, antisym=...) -> tuple[list[Any], list[Perm]] | tuple[list[int], list[Perm]]: ... riemann_bsgs = ... -def get_transversals(base, gens) -> list[Any] | list[dict[Any, Any]]: - ... - -def get_minimal_bsgs(base, gens) -> tuple[Any | list[Any], list[Basic] | Any | list[Basic | Any]] | None: - ... - -def tensor_gens(base, gens, list_free_indices, sym=...) -> tuple[Any, list[Any], list[Perm]] | tuple[Any, Any | list[Any], list[Perm] | list[Any | Perm]] | tuple[Any, list[Any], list[Perm] | list[Any | Perm]]: - ... - -def gens_products(*v) -> tuple[Any | None, Any | list[Any], list[list[int]] | list[Perm | Any]]: - ... +def get_transversals(base, gens) -> list[Any] | list[dict[Any, Any]]: ... +def get_minimal_bsgs(base, gens) -> tuple[Any | list[Any], list[Basic] | Any | list[Basic | Any]] | None: ... +def tensor_gens( + base, gens, list_free_indices, sym=... +) -> ( + tuple[Any, list[Any], list[Perm]] + | tuple[Any, Any | list[Any], list[Perm] | list[Any | Perm]] + | tuple[Any, list[Any], list[Perm] | list[Any | Perm]] +): ... +def gens_products(*v) -> tuple[Any | None, Any | list[Any], list[list[int]] | list[Perm | Any]]: ... diff --git a/stubs/sympy-stubs/combinatorics/testutil.pyi b/stubs/sympy-stubs/combinatorics/testutil.pyi index 4f51d020..ea5b48e1 100644 --- a/stubs/sympy-stubs/combinatorics/testutil.pyi +++ b/stubs/sympy-stubs/combinatorics/testutil.pyi @@ -1,9 +1,6 @@ from typing import Any, Literal rmul = ... -def canonicalize_naive(g, dummies, sym, *v) -> list[Any] | Literal[0]: - ... - -def graph_certificate(gr) -> list[Any] | Literal[0]: - ... +def canonicalize_naive(g, dummies, sym, *v) -> list[Any] | Literal[0]: ... +def graph_certificate(gr) -> list[Any] | Literal[0]: ... diff --git a/stubs/sympy-stubs/concrete/__init__.pyi b/stubs/sympy-stubs/concrete/__init__.pyi index 8c7e8a84..0da4c217 100644 --- a/stubs/sympy-stubs/concrete/__init__.pyi +++ b/stubs/sympy-stubs/concrete/__init__.pyi @@ -1,4 +1,4 @@ from sympy.concrete.products import Product, product from sympy.concrete.summations import Sum, summation -__all__ = ['product', 'Product', 'summation', 'Sum'] +__all__ = ["product", "Product", "summation", "Sum"] diff --git a/stubs/sympy-stubs/concrete/delta.pyi b/stubs/sympy-stubs/concrete/delta.pyi index 866e3ba4..37497a19 100644 --- a/stubs/sympy-stubs/concrete/delta.pyi +++ b/stubs/sympy-stubs/concrete/delta.pyi @@ -7,10 +7,6 @@ from sympy.core.relational import Equality, Ne, Relational from sympy.functions.elementary.piecewise import Piecewise @cacheit -def deltaproduct(f, limit) -> Equality | Relational | Ne | Any: - ... - +def deltaproduct(f, limit) -> Equality | Relational | Ne | Any: ... @cacheit -def deltasummation(f, limit, no_piecewise=...) -> Equality | Relational | Ne | Basic | Piecewise | Sum: - ... - +def deltasummation(f, limit, no_piecewise=...) -> Equality | Relational | Ne | Basic | Piecewise | Sum: ... diff --git a/stubs/sympy-stubs/concrete/expr_with_intlimits.pyi b/stubs/sympy-stubs/concrete/expr_with_intlimits.pyi index 7cf25033..3e0c0ba8 100644 --- a/stubs/sympy-stubs/concrete/expr_with_intlimits.pyi +++ b/stubs/sympy-stubs/concrete/expr_with_intlimits.pyi @@ -3,28 +3,13 @@ from typing import Self from sympy.concrete.expr_with_limits import ExprWithLimits class ReorderError(NotImplementedError): - def __init__(self, expr, msg) -> None: - ... - - + def __init__(self, expr, msg) -> None: ... class ExprWithIntLimits(ExprWithLimits): __slots__ = ... - def change_index(self, var, trafo, newvar=...) -> Self: - ... - - def index(self, x) -> int: - ... - - def reorder(self, *arg) -> Self: - ... - - def reorder_limit(self, x, y) -> Self: - ... - + def change_index(self, var, trafo, newvar=...) -> Self: ... + def index(self, x) -> int: ... + def reorder(self, *arg) -> Self: ... + def reorder_limit(self, x, y) -> Self: ... @property - def has_empty_sequence(self) -> bool | None: - ... - - - + def has_empty_sequence(self) -> bool | None: ... diff --git a/stubs/sympy-stubs/concrete/expr_with_limits.pyi b/stubs/sympy-stubs/concrete/expr_with_limits.pyi index 777402c2..f38baf10 100644 --- a/stubs/sympy-stubs/concrete/expr_with_limits.pyi +++ b/stubs/sympy-stubs/concrete/expr_with_limits.pyi @@ -7,51 +7,26 @@ from sympy.core.relational import Equality, Ne, Relational class ExprWithLimits(Expr): __slots__ = ... - def __new__(cls, function, *symbols, **assumptions) -> Equality | Relational | Ne | Self: - ... - + def __new__(cls, function, *symbols, **assumptions) -> Equality | Relational | Ne | Self: ... @property - def function(self) -> Basic: - ... - + def function(self) -> Basic: ... @property - def kind(self) -> Kind: - ... - + def kind(self) -> Kind: ... @property - def limits(self) -> tuple[Basic, ...]: - ... - + def limits(self) -> tuple[Basic, ...]: ... @property - def variables(self) -> list[Any]: - ... - + def variables(self) -> list[Any]: ... @property - def bound_symbols(self) -> list[Any]: - ... - + def bound_symbols(self) -> list[Any]: ... @property - def free_symbols(self) -> set[Any]: - ... - + def free_symbols(self) -> set[Any]: ... @property - def is_number(self) -> bool: - ... - + def is_number(self) -> bool: ... @property - def has_finite_limits(self) -> bool | None: - ... - + def has_finite_limits(self) -> bool | None: ... @property - def has_reversed_limits(self) -> bool | None: - ... - - + def has_reversed_limits(self) -> bool | None: ... class AddWithLimits(ExprWithLimits): __slots__ = ... - def __new__(cls, function, *symbols, **assumptions) -> Equality | Relational | Ne | Self: - ... - - - + def __new__(cls, function, *symbols, **assumptions) -> Equality | Relational | Ne | Self: ... diff --git a/stubs/sympy-stubs/concrete/gosper.pyi b/stubs/sympy-stubs/concrete/gosper.pyi index ac834e98..5e656873 100644 --- a/stubs/sympy-stubs/concrete/gosper.pyi +++ b/stubs/sympy-stubs/concrete/gosper.pyi @@ -1,11 +1,5 @@ from typing import Any -def gosper_normal(f, g, n, polys=...) -> tuple[Any, Any, Any]: - ... - -def gosper_term(f, n) -> Any | None: - ... - -def gosper_sum(f, k) -> Any | None: - ... - +def gosper_normal(f, g, n, polys=...) -> tuple[Any, Any, Any]: ... +def gosper_term(f, n) -> Any | None: ... +def gosper_sum(f, k) -> Any | None: ... diff --git a/stubs/sympy-stubs/concrete/products.pyi b/stubs/sympy-stubs/concrete/products.pyi index 48e81720..87736ee1 100644 --- a/stubs/sympy-stubs/concrete/products.pyi +++ b/stubs/sympy-stubs/concrete/products.pyi @@ -10,25 +10,13 @@ from sympy.series.order import Order class Product(ExprWithIntLimits): __slots__ = ... limits: tTuple[tTuple[Symbol, Expr, Expr]] - def __new__(cls, function, *symbols, **assumptions) -> Equality | Relational | Ne | Self: - ... - + def __new__(cls, function, *symbols, **assumptions) -> Equality | Relational | Ne | Self: ... @property - def term(self) -> Basic: - ... - - function = ... - def doit(self, **hints) -> tuple[Any, ...] | Self | Basic | Equality | Order | Relational | Ne | Any: - ... - - def is_convergent(self): - ... - - def reverse_order(self, *indices) -> Product: - ... - - + def term(self) -> Basic: ... -def product(*args, **kwargs) -> Equality | Relational | Ne: - ... + function = ... + def doit(self, **hints) -> tuple[Any, ...] | Self | Basic | Equality | Order | Relational | Ne | Any: ... + def is_convergent(self): ... + def reverse_order(self, *indices) -> Product: ... +def product(*args, **kwargs) -> Equality | Relational | Ne: ... diff --git a/stubs/sympy-stubs/concrete/summations.pyi b/stubs/sympy-stubs/concrete/summations.pyi index 2ee3e17f..c089a0c1 100644 --- a/stubs/sympy-stubs/concrete/summations.pyi +++ b/stubs/sympy-stubs/concrete/summations.pyi @@ -12,50 +12,23 @@ from sympy.series.order import Order class Sum(AddWithLimits, ExprWithIntLimits): __slots__ = ... limits: tTuple[tTuple[Symbol, Expr, Expr]] - def __new__(cls, function, *symbols, **assumptions) -> Equality | Relational | Ne | Self: - ... - - def doit(self, **hints) -> tuple[Any, ...] | Self | Order | Any | Piecewise | Basic | Equality | Relational | Ne | Sum | None: - ... - - def eval_zeta_function(self, f, limits) -> Piecewise | None: - ... - - def is_convergent(self): - ... - - def is_absolutely_convergent(self): - ... - - def euler_maclaurin(self, m=..., n=..., eps=..., eval_integral=...) -> tuple[Any, Any] | tuple[Any | Basic, Any] | tuple[Any | Order | Basic, Any] | tuple[Any, int]: - ... - - def reverse_order(self, *indices) -> Sum: - ... - - - -def summation(f, *symbols, **kwargs) -> Equality | Relational | Ne: - ... - -def telescopic_direct(L, R, n, limits) -> Order: - ... - -def telescopic(L, R, limits) -> Order | None: - ... - -def eval_sum(f, limits) -> Piecewise | Equality | Relational | Ne | Basic | Sum | Order | None: - ... - -def eval_sum_direct(expr, limits) -> Order: - ... - -def eval_sum_symbolic(f, limits): - ... - -def eval_sum_hyper(f, i_a_b) -> Piecewise | None: - ... - -def eval_sum_residue(f, i_a_b): - ... - + def __new__(cls, function, *symbols, **assumptions) -> Equality | Relational | Ne | Self: ... + def doit( + self, **hints + ) -> tuple[Any, ...] | Self | Order | Any | Piecewise | Basic | Equality | Relational | Ne | Sum | None: ... + def eval_zeta_function(self, f, limits) -> Piecewise | None: ... + def is_convergent(self): ... + def is_absolutely_convergent(self): ... + def euler_maclaurin( + self, m=..., n=..., eps=..., eval_integral=... + ) -> tuple[Any, Any] | tuple[Any | Basic, Any] | tuple[Any | Order | Basic, Any] | tuple[Any, int]: ... + def reverse_order(self, *indices) -> Sum: ... + +def summation(f, *symbols, **kwargs) -> Equality | Relational | Ne: ... +def telescopic_direct(L, R, n, limits) -> Order: ... +def telescopic(L, R, limits) -> Order | None: ... +def eval_sum(f, limits) -> Piecewise | Equality | Relational | Ne | Basic | Sum | Order | None: ... +def eval_sum_direct(expr, limits) -> Order: ... +def eval_sum_symbolic(f, limits): ... +def eval_sum_hyper(f, i_a_b) -> Piecewise | None: ... +def eval_sum_residue(f, i_a_b): ... diff --git a/stubs/sympy-stubs/conftest.pyi b/stubs/sympy-stubs/conftest.pyi index a88761f6..1a668c9b 100644 --- a/stubs/sympy-stubs/conftest.pyi +++ b/stubs/sympy-stubs/conftest.pyi @@ -1,26 +1,13 @@ import pytest sp = ... -def process_split(config, items) -> None: - ... - -def pytest_report_header(config) -> str: - ... - -def pytest_terminal_summary(terminalreporter) -> None: - ... - -def pytest_addoption(parser) -> None: - ... - -def pytest_collection_modifyitems(config, items) -> None: - ... - -@pytest.fixture(autouse=True, scope='module') -def file_clear_cache() -> None: - ... - -@pytest.fixture(autouse=True, scope='module') -def check_disabled(request) -> None: - ... +def process_split(config, items) -> None: ... +def pytest_report_header(config) -> str: ... +def pytest_terminal_summary(terminalreporter) -> None: ... +def pytest_addoption(parser) -> None: ... +def pytest_collection_modifyitems(config, items) -> None: ... +@pytest.fixture(autouse=True, scope="module") +def file_clear_cache() -> None: ... +@pytest.fixture(autouse=True, scope="module") +def check_disabled(request) -> None: ... diff --git a/stubs/sympy-stubs/core/__init__.pyi b/stubs/sympy-stubs/core/__init__.pyi index 17e72e8c..d8eef779 100644 --- a/stubs/sympy-stubs/core/__init__.pyi +++ b/stubs/sympy-stubs/core/__init__.pyi @@ -79,4 +79,104 @@ Catalan = ... EulerGamma = ... GoldenRatio = ... TribonacciConstant = ... -__all__ = ['sympify', 'SympifyError', 'cacheit', 'assumptions', 'check_assumptions', 'failing_assumptions', 'common_assumptions', 'Basic', 'Atom', 'S', 'Expr', 'AtomicExpr', 'UnevaluatedExpr', 'Symbol', 'Wild', 'Dummy', 'symbols', 'var', 'Number', 'Float', 'Rational', 'Integer', 'NumberSymbol', 'RealNumber', 'igcd', 'ilcm', 'seterr', 'E', 'I', 'nan', 'oo', 'pi', 'zoo', 'AlgebraicNumber', 'comp', 'mod_inverse', 'Pow', 'integer_nthroot', 'integer_log', 'Mul', 'prod', 'Add', 'Mod', 'Rel', 'Eq', 'Ne', 'Lt', 'Le', 'Gt', 'Ge', 'Equality', 'GreaterThan', 'LessThan', 'Unequality', 'StrictGreaterThan', 'StrictLessThan', 'vectorize', 'Lambda', 'WildFunction', 'Derivative', 'diff', 'FunctionClass', 'Function', 'Subs', 'expand', 'PoleError', 'count_ops', 'expand_mul', 'expand_log', 'expand_func', 'expand_trig', 'expand_complex', 'expand_multinomial', 'nfloat', 'expand_power_base', 'expand_power_exp', 'arity', 'PrecisionExhausted', 'N', 'evalf', 'Tuple', 'Dict', 'gcd_terms', 'factor_terms', 'factor_nc', 'evaluate', 'Catalan', 'EulerGamma', 'GoldenRatio', 'TribonacciConstant', 'UndefinedKind', 'NumberKind', 'BooleanKind', 'preorder_traversal', 'bottom_up', 'use', 'postorder_traversal', 'default_sort_key', 'ordered'] +__all__ = [ + "sympify", + "SympifyError", + "cacheit", + "assumptions", + "check_assumptions", + "failing_assumptions", + "common_assumptions", + "Basic", + "Atom", + "S", + "Expr", + "AtomicExpr", + "UnevaluatedExpr", + "Symbol", + "Wild", + "Dummy", + "symbols", + "var", + "Number", + "Float", + "Rational", + "Integer", + "NumberSymbol", + "RealNumber", + "igcd", + "ilcm", + "seterr", + "E", + "I", + "nan", + "oo", + "pi", + "zoo", + "AlgebraicNumber", + "comp", + "mod_inverse", + "Pow", + "integer_nthroot", + "integer_log", + "Mul", + "prod", + "Add", + "Mod", + "Rel", + "Eq", + "Ne", + "Lt", + "Le", + "Gt", + "Ge", + "Equality", + "GreaterThan", + "LessThan", + "Unequality", + "StrictGreaterThan", + "StrictLessThan", + "vectorize", + "Lambda", + "WildFunction", + "Derivative", + "diff", + "FunctionClass", + "Function", + "Subs", + "expand", + "PoleError", + "count_ops", + "expand_mul", + "expand_log", + "expand_func", + "expand_trig", + "expand_complex", + "expand_multinomial", + "nfloat", + "expand_power_base", + "expand_power_exp", + "arity", + "PrecisionExhausted", + "N", + "evalf", + "Tuple", + "Dict", + "gcd_terms", + "factor_terms", + "factor_nc", + "evaluate", + "Catalan", + "EulerGamma", + "GoldenRatio", + "TribonacciConstant", + "UndefinedKind", + "NumberKind", + "BooleanKind", + "preorder_traversal", + "bottom_up", + "use", + "postorder_traversal", + "default_sort_key", + "ordered", +] diff --git a/stubs/sympy-stubs/core/add.pyi b/stubs/sympy-stubs/core/add.pyi index 8bf334e4..7afb49b4 100644 --- a/stubs/sympy-stubs/core/add.pyi +++ b/stubs/sympy-stubs/core/add.pyi @@ -9,43 +9,31 @@ from sympy.core.operations import AssocOp from sympy.series.order import Order _args_sortkey = ... + class Add(Expr, AssocOp): __slots__ = ... args: tTuple[Expr, ...] is_Add = ... _args_type = Expr @classmethod - def flatten(cls, seq): - ... - + def flatten(cls, seq): ... @classmethod - def class_key(cls) -> tuple[Literal[3], Literal[1], str]: - ... - + def class_key(cls) -> tuple[Literal[3], Literal[1], str]: ... @property - def kind(self) -> _UndefinedKind | Any: - ... - - def could_extract_minus_sign(self) -> bool: - ... - + def kind(self) -> _UndefinedKind | Any: ... + def could_extract_minus_sign(self) -> bool: ... @cacheit - def as_coeff_add(self, *deps) -> tuple[Any | Self, tuple[Any, ...]] | tuple[Expr, tuple[Expr, ...]] | tuple[Any, tTuple[Expr, ...]]: - ... - - def as_coeff_Add(self, rational=..., deps=...) -> tuple[Expr, Any | Self] | tuple[Any, Self]: - ... - - def matches(self, expr, repl_dict=..., old=...): - ... - + def as_coeff_add( + self, *deps + ) -> tuple[Any | Self, tuple[Any, ...]] | tuple[Expr, tuple[Expr, ...]] | tuple[Any, tTuple[Expr, ...]]: ... + def as_coeff_Add(self, rational=..., deps=...) -> tuple[Expr, Any | Self] | tuple[Any, Self]: ... + def matches(self, expr, repl_dict=..., old=...): ... @cacheit - def as_two_terms(self) -> tuple[Expr, Any | Self]: - ... - - def as_numer_denom(self) -> tuple[Order, Any] | tuple[Self, Any | Add | Order | Mul] | tuple[Any | Add | Order | Mul, Any | Add | Order | Mul]: - ... - + def as_two_terms(self) -> tuple[Expr, Any | Self]: ... + def as_numer_denom( + self, + ) -> tuple[Order, Any] | tuple[Self, Any | Add | Order | Mul] | tuple[Any | Add | Order | Mul, Any | Add | Order | Mul]: ... + _eval_is_real = ... _eval_is_extended_real = ... _eval_is_complex = ... @@ -56,28 +44,15 @@ class Add(Expr, AssocOp): _eval_is_rational = ... _eval_is_algebraic = ... _eval_is_commutative = ... - def removeO(self) -> Self: - ... - - def getO(self) -> Self | None: - ... - + def removeO(self) -> Self: ... + def getO(self) -> Self | None: ... @cacheit - def extract_leading_order(self, symbols, point=...) -> tuple[tuple[Expr, Order], ...]: - ... - - def as_real_imag(self, deep=..., **hints) -> tuple[Self, Self]: - ... - - def primitive(self) -> tuple[Any, Self] | tuple[Rational | Any | Integer, Any | Self]: - ... - - def as_content_primitive(self, radical=..., clear=...) -> tuple[Any | Integer | Rational, Any | Rational | Integer | Self]: - ... - - def __neg__(self) -> Mul | Order: - ... - - + def extract_leading_order(self, symbols, point=...) -> tuple[tuple[Expr, Order], ...]: ... + def as_real_imag(self, deep=..., **hints) -> tuple[Self, Self]: ... + def primitive(self) -> tuple[Any, Self] | tuple[Rational | Any | Integer, Any | Self]: ... + def as_content_primitive( + self, radical=..., clear=... + ) -> tuple[Any | Integer | Rational, Any | Rational | Integer | Self]: ... + def __neg__(self) -> Mul | Order: ... add = ... diff --git a/stubs/sympy-stubs/core/assumptions.pyi b/stubs/sympy-stubs/core/assumptions.pyi index 5d830448..6558a432 100644 --- a/stubs/sympy-stubs/core/assumptions.pyi +++ b/stubs/sympy-stubs/core/assumptions.pyi @@ -5,40 +5,20 @@ from sympy.core.facts import FactKB _assume_rules = ... _assume_defined = ... _assume_defined = ... -def assumptions(expr, _check=...) -> dict[Any, Any]: - ... -def common_assumptions(exprs, check=...) -> dict[Any, Any]: - ... - -def failing_assumptions(expr, **assumptions) -> dict[Any, Any]: - ... - -def check_assumptions(expr, against=..., **assume) -> bool | None: - ... +def assumptions(expr, _check=...) -> dict[Any, Any]: ... +def common_assumptions(exprs, check=...) -> dict[Any, Any]: ... +def failing_assumptions(expr, **assumptions) -> dict[Any, Any]: ... +def check_assumptions(expr, against=..., **assume) -> bool | None: ... class StdFactKB(FactKB): - def __init__(self, facts=...) -> None: - ... - - def copy(self) -> Self: - ... - + def __init__(self, facts=...) -> None: ... + def copy(self) -> Self: ... @property - def generator(self) -> dict[Any, Any]: - ... - - + def generator(self) -> dict[Any, Any]: ... -def as_property(fact): - ... - -def make_property(fact) -> property: - ... +def as_property(fact): ... +def make_property(fact) -> property: ... class ManagedProperties(type): - def __init__(cls, *args, **kwargs) -> None: - ... - - - + def __init__(cls, *args, **kwargs) -> None: ... diff --git a/stubs/sympy-stubs/core/basic.pyi b/stubs/sympy-stubs/core/basic.pyi index 0519d44d..f5ebdfca 100644 --- a/stubs/sympy-stubs/core/basic.pyi +++ b/stubs/sympy-stubs/core/basic.pyi @@ -5,20 +5,16 @@ from sympy.core._print_helpers import Printable from sympy.core.cache import cacheit from sympy.core.kind import Kind -def as_Basic(expr): - ... +def as_Basic(expr): ... class Basic(Printable): __slots__ = ... _args: tuple[Basic, ...] _mhash: int | None @property - def __sympy__(self) -> Literal[True]: - ... - - def __init_subclass__(cls) -> None: - ... - + def __sympy__(self) -> Literal[True]: ... + def __init_subclass__(cls) -> None: ... + is_number = ... is_Atom = ... is_Symbol = ... @@ -55,167 +51,72 @@ class Basic(Printable): is_negative: bool | None is_commutative: bool | None kind: Kind = ... - def __new__(cls, *args) -> Self: - ... - - def copy(self) -> Self: - ... - - def __getnewargs__(self) -> tuple[Basic, ...]: - ... - - def __getstate__(self) -> None: - ... - - def __setstate__(self, state) -> None: - ... - - def __reduce_ex__(self, protocol) -> str | tuple[Any, ...]: - ... - - def __hash__(self) -> int: - ... - + def __new__(cls, *args) -> Self: ... + def copy(self) -> Self: ... + def __getnewargs__(self) -> tuple[Basic, ...]: ... + def __getstate__(self) -> None: ... + def __setstate__(self, state) -> None: ... + def __reduce_ex__(self, protocol) -> str | tuple[Any, ...]: ... + def __hash__(self) -> int: ... @property - def assumptions0(self) -> dict[Any, Any]: - ... - - def compare(self, other) -> int: - ... - + def assumptions0(self) -> dict[Any, Any]: ... + def compare(self, other) -> int: ... @classmethod - def fromiter(cls, args, **assumptions) -> Self: - ... - + def fromiter(cls, args, **assumptions) -> Self: ... @classmethod - def class_key(cls) -> tuple[Literal[5], Literal[0], str]: - ... - + def class_key(cls) -> tuple[Literal[5], Literal[0], str]: ... @cacheit - def sort_key(self, order=...) -> tuple[tuple[Literal[5], Literal[0], str], tuple[int, tuple[Any, ...]], Any, Any]: - ... - - def __eq__(self, other) -> bool: - ... - - def __ne__(self, other) -> bool: - ... - - def dummy_eq(self, other, symbol=...): - ... - - def atoms(self, *types) -> set[Any]: - ... - + def sort_key(self, order=...) -> tuple[tuple[Literal[5], Literal[0], str], tuple[int, tuple[Any, ...]], Any, Any]: ... + def __eq__(self, other) -> bool: ... + def __ne__(self, other) -> bool: ... + def dummy_eq(self, other, symbol=...): ... + def atoms(self, *types) -> set[Any]: ... @property - def free_symbols(self) -> set[Basic]: - ... - + def free_symbols(self) -> set[Basic]: ... @property - def expr_free_symbols(self) -> set[Any]: - ... - - def as_dummy(self) -> Self | tuple[Any, dict[Any, Any]]: - ... - + def expr_free_symbols(self) -> set[Any]: ... + def as_dummy(self) -> Self | tuple[Any, dict[Any, Any]]: ... @property - def canonical_variables(self) -> dict[Any, Any]: - ... - - def rcall(self, *args) -> Symbol | Any: - ... - - def is_hypergeometric(self, k) -> bool | None: - ... - + def canonical_variables(self) -> dict[Any, Any]: ... + def rcall(self, *args) -> Symbol | Any: ... + def is_hypergeometric(self, k) -> bool | None: ... @property - def is_comparable(self) -> Literal[False]: - ... - + def is_comparable(self) -> Literal[False]: ... @property - def func(self) -> type[Self]: - ... - + def func(self) -> type[Self]: ... @property - def args(self) -> tuple[Basic, ...]: - ... - - def as_content_primitive(self, radical=..., clear=...) -> tuple[Any, Self]: - ... - - def subs(self, *args, **kwargs) -> Self | Basic: - ... - - def xreplace(self, rule) -> Self: - ... - + def args(self) -> tuple[Basic, ...]: ... + def as_content_primitive(self, radical=..., clear=...) -> tuple[Any, Self]: ... + def subs(self, *args, **kwargs) -> Self | Basic: ... + def xreplace(self, rule) -> Self: ... @cacheit - def has(self, *patterns) -> bool: - ... - - def has_xfree(self, s: set[Basic]) -> bool: - ... - + def has(self, *patterns) -> bool: ... + def has_xfree(self, s: set[Basic]) -> bool: ... @cacheit - def has_free(self, *patterns) -> bool: - ... - - def replace(self, query, value, map=..., simultaneous=..., exact=...) -> tuple[Any, dict[Any, Any]]: - ... - - def find(self, query, group=...) -> set[Any] | dict[Any, Any]: - ... - - def count(self, query) -> int: - ... - - def matches(self, expr, repl_dict=..., old=...) -> dict[Any, Any] | None: - ... - - def match(self, pattern, old=...): - ... - - def count_ops(self, visual=...): - ... - - def doit(self, **hints) -> Self: - ... - - def simplify(self, **kwargs): - ... - - def refine(self, assumption=...) -> Basic: - ... - - def rewrite(self, *args, deep=..., **hints) -> Self | Any: - ... - - _constructor_postprocessor_mapping = ... - def could_extract_minus_sign(self) -> Literal[False]: - ... - + def has_free(self, *patterns) -> bool: ... + def replace(self, query, value, map=..., simultaneous=..., exact=...) -> tuple[Any, dict[Any, Any]]: ... + def find(self, query, group=...) -> set[Any] | dict[Any, Any]: ... + def count(self, query) -> int: ... + def matches(self, expr, repl_dict=..., old=...) -> dict[Any, Any] | None: ... + def match(self, pattern, old=...): ... + def count_ops(self, visual=...): ... + def doit(self, **hints) -> Self: ... + def simplify(self, **kwargs): ... + def refine(self, assumption=...) -> Basic: ... + def rewrite(self, *args, deep=..., **hints) -> Self | Any: ... + _constructor_postprocessor_mapping = ... + def could_extract_minus_sign(self) -> Literal[False]: ... class Atom(Basic): is_Atom = ... __slots__ = ... - def matches(self, expr, repl_dict=..., old=...) -> dict[Any, Any] | None: - ... - - def xreplace(self, rule, hack2=...): - ... - - def doit(self, **hints) -> Self: - ... - + def matches(self, expr, repl_dict=..., old=...) -> dict[Any, Any] | None: ... + def xreplace(self, rule, hack2=...): ... + def doit(self, **hints) -> Self: ... @classmethod - def class_key(cls) -> tuple[Literal[2], Literal[0], str]: - ... - + def class_key(cls) -> tuple[Literal[2], Literal[0], str]: ... @cacheit - def sort_key(self, order=...) -> tuple[tuple[Literal[2], Literal[0], str], tuple[Literal[1], tuple[str]], Any, Any]: - ... - - + def sort_key(self, order=...) -> tuple[tuple[Literal[2], Literal[0], str], tuple[Literal[1], tuple[str]], Any, Any]: ... preorder_traversal = ... diff --git a/stubs/sympy-stubs/core/cache.pyi b/stubs/sympy-stubs/core/cache.pyi index f9afb695..5921266c 100644 --- a/stubs/sympy-stubs/core/cache.pyi +++ b/stubs/sympy-stubs/core/cache.pyi @@ -1,37 +1,24 @@ from typing import Callable class _cache(list): - def print_cache(self) -> None: - ... - - def clear_cache(self) -> None: - ... - - + def print_cache(self) -> None: ... + def clear_cache(self) -> None: ... CACHE = ... print_cache = ... clear_cache = ... USE_CACHE = ... scs = ... -if scs.lower() == 'none': +if scs.lower() == "none": SYMPY_CACHE_SIZE = ... else: SYMPY_CACHE_SIZE = ... -if USE_CACHE == 'no': +if USE_CACHE == "no": cacheit = ... else: cacheit = ... -def cached_property(func) -> property: - ... +def cached_property(func) -> property: ... def lazy_function(module: str, name: str) -> Callable: - class LazyFunctionMeta(type): - ... - - - class LazyFunction(metaclass=LazyFunctionMeta): - ... - - - + class LazyFunctionMeta(type): ... + class LazyFunction(metaclass=LazyFunctionMeta): ... diff --git a/stubs/sympy-stubs/core/containers.pyi b/stubs/sympy-stubs/core/containers.pyi index dc85c318..066efed5 100644 --- a/stubs/sympy-stubs/core/containers.pyi +++ b/stubs/sympy-stubs/core/containers.pyi @@ -6,143 +6,57 @@ from sympy.core.basic import Basic from sympy.core.kind import Kind class Tuple(Basic): - def __new__(cls, *args, **kwargs) -> Self: - ... - - def __getitem__(self, i) -> Tuple: - ... - - def __len__(self) -> int: - ... - - def __contains__(self, item) -> bool: - ... - - def __iter__(self) -> Iterator[Basic]: - ... - - def __add__(self, other) -> Tuple | NotImplementedType: - ... - - def __radd__(self, other) -> Tuple | NotImplementedType: - ... - - def __mul__(self, other) -> Self: - ... - + def __new__(cls, *args, **kwargs) -> Self: ... + def __getitem__(self, i) -> Tuple: ... + def __len__(self) -> int: ... + def __contains__(self, item) -> bool: ... + def __iter__(self) -> Iterator[Basic]: ... + def __add__(self, other) -> Tuple | NotImplementedType: ... + def __radd__(self, other) -> Tuple | NotImplementedType: ... + def __mul__(self, other) -> Self: ... + __rmul__ = ... - def __eq__(self, other) -> bool: - ... - - def __ne__(self, other) -> bool: - ... - - def __hash__(self) -> int: - ... - - def __lt__(self, other) -> bool: - ... - - def __le__(self, other) -> bool: - ... - - def tuple_count(self, value) -> int: - ... - - def index(self, value, start=..., stop=...) -> int: - ... - + def __eq__(self, other) -> bool: ... + def __ne__(self, other) -> bool: ... + def __hash__(self) -> int: ... + def __lt__(self, other) -> bool: ... + def __le__(self, other) -> bool: ... + def tuple_count(self, value) -> int: ... + def index(self, value, start=..., stop=...) -> int: ... @property - def kind(self) -> TupleKind: - ... - - + def kind(self) -> TupleKind: ... -def tuple_wrapper(method) -> Callable[..., Any]: - ... +def tuple_wrapper(method) -> Callable[..., Any]: ... class Dict(Basic): - def __new__(cls, *args) -> Self: - ... - - def __getitem__(self, key): - ... - - def __setitem__(self, key, value): - ... - - def items(self): - ... - - def keys(self): - ... - - def values(self): - ... - - def __iter__(self): - ... - - def __len__(self): - ... - - def get(self, key, default=...) -> None: - ... - - def __contains__(self, key) -> bool: - ... - - def __lt__(self, other) -> bool: - ... - - def __eq__(self, other) -> bool: - ... - - __hash__: Callable[[Basic], Any] = ... + def __new__(cls, *args) -> Self: ... + def __getitem__(self, key): ... + def __setitem__(self, key, value): ... + def items(self): ... + def keys(self): ... + def values(self): ... + def __iter__(self): ... + def __len__(self): ... + def get(self, key, default=...) -> None: ... + def __contains__(self, key) -> bool: ... + def __lt__(self, other) -> bool: ... + def __eq__(self, other) -> bool: ... + __hash__: Callable[[Basic], Any] = ... class OrderedSet(MutableSet): - def __init__(self, iterable=...) -> None: - ... - - def __len__(self) -> int: - ... - - def __contains__(self, key) -> bool: - ... - - def add(self, key) -> None: - ... - - def discard(self, key) -> None: - ... - - def pop(self, last=...): - ... - - def __iter__(self) -> Generator[Any, Any, None]: - ... - - def __repr__(self) -> str: - ... - - def intersection(self, other) -> Self: - ... - - def difference(self, other) -> Self: - ... - - def update(self, iterable) -> None: - ... - - + def __init__(self, iterable=...) -> None: ... + def __len__(self) -> int: ... + def __contains__(self, key) -> bool: ... + def add(self, key) -> None: ... + def discard(self, key) -> None: ... + def pop(self, last=...): ... + def __iter__(self) -> Generator[Any, Any, None]: ... + def __repr__(self) -> str: ... + def intersection(self, other) -> Self: ... + def difference(self, other) -> Self: ... + def update(self, iterable) -> None: ... class TupleKind(Kind): - def __new__(cls, *args) -> Self: - ... - - def __repr__(self) -> str: - ... - - - + def __new__(cls, *args) -> Self: ... + def __repr__(self) -> str: ... diff --git a/stubs/sympy-stubs/core/core.pyi b/stubs/sympy-stubs/core/core.pyi index 713b3194..435ef869 100644 --- a/stubs/sympy-stubs/core/core.pyi +++ b/stubs/sympy-stubs/core/core.pyi @@ -1,12 +1,6 @@ - ordering_of_classes = ... + class Registry: __slots__ = ... - def __setattr__(self, name, obj) -> None: - ... - - def __delattr__(self, name) -> None: - ... - - - + def __setattr__(self, name, obj) -> None: ... + def __delattr__(self, name) -> None: ... diff --git a/stubs/sympy-stubs/core/decorators.pyi b/stubs/sympy-stubs/core/decorators.pyi index f449e02e..d560a4d1 100644 --- a/stubs/sympy-stubs/core/decorators.pyi +++ b/stubs/sympy-stubs/core/decorators.pyi @@ -1,27 +1,12 @@ from functools import _Wrapped from typing import Any, Callable -def call_highest_priority(method_name) -> Callable[..., _Wrapped[..., Any, ..., Any]]: - ... - -def sympify_method_args(cls): - ... - -def sympify_return(*args) -> Callable[..., _SympifyWrapper]: - ... - -def _sympifyit(arg, retval=None) -> Callable[..., _SympifyWrapper]: - ... - -def __sympifyit(func, arg, retval=None) -> Callable[..., _SympifyWrapper]: - ... +def call_highest_priority(method_name) -> Callable[..., _Wrapped[..., Any, ..., Any]]: ... +def sympify_method_args(cls): ... +def sympify_return(*args) -> Callable[..., _SympifyWrapper]: ... +def _sympifyit(arg, retval=None) -> Callable[..., _SympifyWrapper]: ... +def __sympifyit(func, arg, retval=None) -> Callable[..., _SympifyWrapper]: ... class _SympifyWrapper: - def __init__(self, func, args) -> None: - ... - - def make_wrapped(self, cls) -> _Wrapped[..., Any, ..., Any]: - ... - - - + def __init__(self, func, args) -> None: ... + def make_wrapped(self, cls) -> _Wrapped[..., Any, ..., Any]: ... diff --git a/stubs/sympy-stubs/core/evalf.pyi b/stubs/sympy-stubs/core/evalf.pyi index bf413425..8d0ff322 100644 --- a/stubs/sympy-stubs/core/evalf.pyi +++ b/stubs/sympy-stubs/core/evalf.pyi @@ -31,157 +31,76 @@ if TYPE_CHECKING: ... LG10 = ... rnd = ... -def bitcount(n): - ... + +def bitcount(n): ... INF = ... MINUS_INF = ... DEFAULT_MAXPREC = ... -class PrecisionExhausted(ArithmeticError): - ... +class PrecisionExhausted(ArithmeticError): ... MPF_TUP = tTuple[int, int, int, int] TMP_RES = Any OPT_DICT = tDict[str, Any] -def fastlog(x: Optional[MPF_TUP]) -> tUnion[int, Any]: - ... -def pure_complex(v: Expr, or_real=...) -> tuple[Number, Number] | None: - ... +def fastlog(x: Optional[MPF_TUP]) -> tUnion[int, Any]: ... +def pure_complex(v: Expr, or_real=...) -> tuple[Number, Number] | None: ... SCALED_ZERO_TUP = tTuple[List[int], int, int, int] -@overload -def scaled_zero(mag: SCALED_ZERO_TUP, sign=...) -> MPF_TUP: - ... @overload -def scaled_zero(mag: int, sign=...) -> tTuple[SCALED_ZERO_TUP, int]: - ... - -def scaled_zero(mag: tUnion[SCALED_ZERO_TUP, int], sign=...) -> tUnion[MPF_TUP, tTuple[SCALED_ZERO_TUP, int]]: - ... - -def iszero(mpf: tUnion[MPF_TUP, SCALED_ZERO_TUP, None], scaled=...) -> Optional[bool]: - ... - -def complex_accuracy(result: TMP_RES) -> tUnion[int, Any]: - ... - -def get_abs(expr: Expr, prec: int, options: OPT_DICT) -> TMP_RES: - ... - -def get_complex_part(expr: Expr, no: int, prec: int, options: OPT_DICT) -> TMP_RES: - ... - -def evalf_abs(expr: Abs, prec: int, options: OPT_DICT) -> TMP_RES: - ... - -def evalf_re(expr: re, prec: int, options: OPT_DICT) -> TMP_RES: - ... - -def evalf_im(expr: im, prec: int, options: OPT_DICT) -> TMP_RES: - ... - -def finalize_complex(re: MPF_TUP, im: MPF_TUP, prec: int) -> TMP_RES: - ... - -def chop_parts(value: TMP_RES, prec: int) -> TMP_RES: - ... - -def check_target(expr: Expr, result: TMP_RES, prec: int) -> None: - ... - -def get_integer_part(expr: Expr, no: int, options: OPT_DICT, return_ints=...) -> tUnion[TMP_RES, tTuple[int, int]]: - ... - -def evalf_ceiling(expr: ceiling, prec: int, options: OPT_DICT) -> TMP_RES: - ... - -def evalf_floor(expr: floor, prec: int, options: OPT_DICT) -> TMP_RES: - ... - -def evalf_float(expr: Float, prec: int, options: OPT_DICT) -> TMP_RES: - ... - -def evalf_rational(expr: Rational, prec: int, options: OPT_DICT) -> TMP_RES: - ... - -def evalf_integer(expr: Integer, prec: int, options: OPT_DICT) -> TMP_RES: - ... - -def add_terms(terms: list, prec: int, target_prec: int) -> tTuple[tUnion[MPF_TUP, SCALED_ZERO_TUP, None], Optional[int]]: - ... - -def evalf_add(v: Add, prec: int, options: OPT_DICT) -> TMP_RES: - ... - -def evalf_mul(v: Mul, prec: int, options: OPT_DICT) -> TMP_RES: - ... - -def evalf_pow(v: Pow, prec: int, options) -> TMP_RES: - ... - -def evalf_exp(expr: exp, prec: int, options: OPT_DICT) -> TMP_RES: - ... - -def evalf_trig(v: Expr, prec: int, options: OPT_DICT) -> TMP_RES: - ... - -def evalf_log(expr: log, prec: int, options: OPT_DICT) -> TMP_RES: - ... - -def evalf_atan(v: atan, prec: int, options: OPT_DICT) -> TMP_RES: - ... - -def evalf_subs(prec: int, subs: dict) -> dict: - ... - -def evalf_piecewise(expr: Expr, prec: int, options: OPT_DICT) -> TMP_RES: - ... - -def evalf_alg_num(a: AlgebraicNumber, prec: int, options: OPT_DICT) -> TMP_RES: - ... - -def as_mpmath(x: Any, prec: int, options: OPT_DICT) -> tUnion[mpc, mpf]: - ... - -def do_integral(expr: Integral, prec: int, options: OPT_DICT) -> TMP_RES: - ... - -def evalf_integral(expr: Integral, prec: int, options: OPT_DICT) -> TMP_RES: - ... - -def check_convergence(numer: Expr, denom: Expr, n: Symbol) -> tTuple[int, Any, Any]: - ... - -def hypsum(expr: Expr, n: Symbol, start: int, prec: int) -> mpf: - ... - -def evalf_prod(expr: Product, prec: int, options: OPT_DICT) -> TMP_RES: - ... - -def evalf_sum(expr: Sum, prec: int, options: OPT_DICT) -> TMP_RES: - ... - -def evalf_symbol(x: Expr, prec: int, options: OPT_DICT) -> TMP_RES: - ... +def scaled_zero(mag: SCALED_ZERO_TUP, sign=...) -> MPF_TUP: ... +@overload +def scaled_zero(mag: int, sign=...) -> tTuple[SCALED_ZERO_TUP, int]: ... +def scaled_zero(mag: tUnion[SCALED_ZERO_TUP, int], sign=...) -> tUnion[MPF_TUP, tTuple[SCALED_ZERO_TUP, int]]: ... +def iszero(mpf: tUnion[MPF_TUP, SCALED_ZERO_TUP, None], scaled=...) -> Optional[bool]: ... +def complex_accuracy(result: TMP_RES) -> tUnion[int, Any]: ... +def get_abs(expr: Expr, prec: int, options: OPT_DICT) -> TMP_RES: ... +def get_complex_part(expr: Expr, no: int, prec: int, options: OPT_DICT) -> TMP_RES: ... +def evalf_abs(expr: Abs, prec: int, options: OPT_DICT) -> TMP_RES: ... +def evalf_re(expr: re, prec: int, options: OPT_DICT) -> TMP_RES: ... +def evalf_im(expr: im, prec: int, options: OPT_DICT) -> TMP_RES: ... +def finalize_complex(re: MPF_TUP, im: MPF_TUP, prec: int) -> TMP_RES: ... +def chop_parts(value: TMP_RES, prec: int) -> TMP_RES: ... +def check_target(expr: Expr, result: TMP_RES, prec: int) -> None: ... +def get_integer_part(expr: Expr, no: int, options: OPT_DICT, return_ints=...) -> tUnion[TMP_RES, tTuple[int, int]]: ... +def evalf_ceiling(expr: ceiling, prec: int, options: OPT_DICT) -> TMP_RES: ... +def evalf_floor(expr: floor, prec: int, options: OPT_DICT) -> TMP_RES: ... +def evalf_float(expr: Float, prec: int, options: OPT_DICT) -> TMP_RES: ... +def evalf_rational(expr: Rational, prec: int, options: OPT_DICT) -> TMP_RES: ... +def evalf_integer(expr: Integer, prec: int, options: OPT_DICT) -> TMP_RES: ... +def add_terms(terms: list, prec: int, target_prec: int) -> tTuple[tUnion[MPF_TUP, SCALED_ZERO_TUP, None], Optional[int]]: ... +def evalf_add(v: Add, prec: int, options: OPT_DICT) -> TMP_RES: ... +def evalf_mul(v: Mul, prec: int, options: OPT_DICT) -> TMP_RES: ... +def evalf_pow(v: Pow, prec: int, options) -> TMP_RES: ... +def evalf_exp(expr: exp, prec: int, options: OPT_DICT) -> TMP_RES: ... +def evalf_trig(v: Expr, prec: int, options: OPT_DICT) -> TMP_RES: ... +def evalf_log(expr: log, prec: int, options: OPT_DICT) -> TMP_RES: ... +def evalf_atan(v: atan, prec: int, options: OPT_DICT) -> TMP_RES: ... +def evalf_subs(prec: int, subs: dict) -> dict: ... +def evalf_piecewise(expr: Expr, prec: int, options: OPT_DICT) -> TMP_RES: ... +def evalf_alg_num(a: AlgebraicNumber, prec: int, options: OPT_DICT) -> TMP_RES: ... +def as_mpmath(x: Any, prec: int, options: OPT_DICT) -> tUnion[mpc, mpf]: ... +def do_integral(expr: Integral, prec: int, options: OPT_DICT) -> TMP_RES: ... +def evalf_integral(expr: Integral, prec: int, options: OPT_DICT) -> TMP_RES: ... +def check_convergence(numer: Expr, denom: Expr, n: Symbol) -> tTuple[int, Any, Any]: ... +def hypsum(expr: Expr, n: Symbol, start: int, prec: int) -> mpf: ... +def evalf_prod(expr: Product, prec: int, options: OPT_DICT) -> TMP_RES: ... +def evalf_sum(expr: Sum, prec: int, options: OPT_DICT) -> TMP_RES: ... +def evalf_symbol(x: Expr, prec: int, options: OPT_DICT) -> TMP_RES: ... evalf_table: tDict[Type[Expr], Callable[[Expr, int, OPT_DICT], TMP_RES]] = ... -def evalf(x: Expr, prec: int, options: OPT_DICT) -> TMP_RES: - ... -def quad_to_mpmath(q, ctx=...): - ... +def evalf(x: Expr, prec: int, options: OPT_DICT) -> TMP_RES: ... +def quad_to_mpmath(q, ctx=...): ... class EvalfMixin: __slots__: tTuple[str, ...] = ... - def evalf(self, n=..., subs=..., maxn=..., chop=..., strict=..., quad=..., verbose=...) -> Self | EvalfMixin | TMP_RES | Float: - ... - - n = ... - + def evalf( + self, n=..., subs=..., maxn=..., chop=..., strict=..., quad=..., verbose=... + ) -> Self | EvalfMixin | TMP_RES | Float: ... -def N(x, n=..., **options): - ... + n = ... +def N(x, n=..., **options): ... diff --git a/stubs/sympy-stubs/core/expr.pyi b/stubs/sympy-stubs/core/expr.pyi index a00128da..4aa20709 100644 --- a/stubs/sympy-stubs/core/expr.pyi +++ b/stubs/sympy-stubs/core/expr.pyi @@ -15,396 +15,193 @@ from sympy.tensor.array.array_derivatives import ArrayDerivative if TYPE_CHECKING: ... + @sympify_method_args class Expr(Basic, EvalfMixin): __slots__: tuple[str, ...] = ... is_scalar = ... @cacheit - def sort_key(self, order=...) -> tuple[tuple[Literal[5], Literal[0], str] | Any, tuple[int, tuple[tuple[tuple[Literal[5], Literal[0], str], tuple[int, tuple[Any, ...]], Any, Any] | Any | tuple[tuple[Literal[10, 0], Literal[0], str | Any], tuple[int, tuple[Any, ...]] | tuple[Literal[1], tuple[str]], Any, Any], ...]], tuple[tuple[Literal[5], Literal[0], str], tuple[int, tuple[Any, ...]], Any, Any] | Any, Number]: - ... - + def sort_key(self, order=...) -> tuple[ + tuple[Literal[5], Literal[0], str] | Any, + tuple[ + int, + tuple[ + tuple[tuple[Literal[5], Literal[0], str], tuple[int, tuple[Any, ...]], Any, Any] + | Any + | tuple[ + tuple[Literal[10, 0], Literal[0], str | Any], + tuple[int, tuple[Any, ...]] | tuple[Literal[1], tuple[str]], + Any, + Any, + ], + ..., + ], + ], + tuple[tuple[Literal[5], Literal[0], str], tuple[int, tuple[Any, ...]], Any, Any] | Any, + Number, + ]: ... + _op_priority = ... - def __pos__(self) -> Self: - ... - - def __neg__(self) -> Mul: - ... - - def __abs__(self) -> Expr: - ... - - @sympify_return([('other', 'Expr')], NotImplemented) - @call_highest_priority('__radd__') - def __add__(self, other) -> Order: - ... - - @sympify_return([('other', 'Expr')], NotImplemented) - @call_highest_priority('__add__') - def __radd__(self, other) -> Order: - ... - - @sympify_return([('other', 'Expr')], NotImplemented) - @call_highest_priority('__rsub__') - def __sub__(self, other) -> Order: - ... - - @sympify_return([('other', 'Expr')], NotImplemented) - @call_highest_priority('__sub__') - def __rsub__(self, other) -> Order: - ... - - @sympify_return([('other', 'Expr')], NotImplemented) - @call_highest_priority('__rmul__') - def __mul__(self, other) -> Order: - ... - - @sympify_return([('other', 'Expr')], NotImplemented) - @call_highest_priority('__mul__') - def __rmul__(self, other) -> Order: - ... - - def __pow__(self, other, mod=...) -> Expr: - ... - - @sympify_return([('other', 'Expr')], NotImplemented) - @call_highest_priority('__pow__') - def __rpow__(self, other) -> Pow: - ... - - @sympify_return([('other', 'Expr')], NotImplemented) - @call_highest_priority('__rtruediv__') - def __truediv__(self, other) -> Pow | Order: - ... - - @sympify_return([('other', 'Expr')], NotImplemented) - @call_highest_priority('__truediv__') - def __rtruediv__(self, other) -> Pow | Order: - ... - - @sympify_return([('other', 'Expr')], NotImplemented) - @call_highest_priority('__rmod__') - def __mod__(self, other) -> type[UndefinedFunction]: - ... - - @sympify_return([('other', 'Expr')], NotImplemented) - @call_highest_priority('__mod__') - def __rmod__(self, other) -> type[UndefinedFunction]: - ... - - @sympify_return([('other', 'Expr')], NotImplemented) - @call_highest_priority('__rfloordiv__') - def __floordiv__(self, other) -> type[UndefinedFunction]: - ... - - @sympify_return([('other', 'Expr')], NotImplemented) - @call_highest_priority('__floordiv__') - def __rfloordiv__(self, other) -> type[UndefinedFunction]: - ... - - @sympify_return([('other', 'Expr')], NotImplemented) - @call_highest_priority('__rdivmod__') - def __divmod__(self, other) -> tuple[type[UndefinedFunction] | Any, type[UndefinedFunction] | Any]: - ... - - @sympify_return([('other', 'Expr')], NotImplemented) - @call_highest_priority('__divmod__') - def __rdivmod__(self, other) -> tuple[type[UndefinedFunction] | Any, type[UndefinedFunction] | Any]: - ... - - def __int__(self) -> int: - ... - - def __float__(self) -> float: - ... - - def __complex__(self) -> complex: - ... - - @sympify_return([('other', 'Expr')], NotImplemented) - def __ge__(self, other) -> bool: - ... - - @sympify_return([('other', 'Expr')], NotImplemented) - def __le__(self, other) -> bool: - ... - - @sympify_return([('other', 'Expr')], NotImplemented) - def __gt__(self, other) -> bool: - ... - - @sympify_return([('other', 'Expr')], NotImplemented) - def __lt__(self, other) -> bool: - ... - - def __trunc__(self) -> Integer: - ... - - def __format__(self, format_spec: str) -> str: - ... - + def __pos__(self) -> Self: ... + def __neg__(self) -> Mul: ... + def __abs__(self) -> Expr: ... + @sympify_return([("other", "Expr")], NotImplemented) + @call_highest_priority("__radd__") + def __add__(self, other) -> Order: ... + @sympify_return([("other", "Expr")], NotImplemented) + @call_highest_priority("__add__") + def __radd__(self, other) -> Order: ... + @sympify_return([("other", "Expr")], NotImplemented) + @call_highest_priority("__rsub__") + def __sub__(self, other) -> Order: ... + @sympify_return([("other", "Expr")], NotImplemented) + @call_highest_priority("__sub__") + def __rsub__(self, other) -> Order: ... + @sympify_return([("other", "Expr")], NotImplemented) + @call_highest_priority("__rmul__") + def __mul__(self, other) -> Order: ... + @sympify_return([("other", "Expr")], NotImplemented) + @call_highest_priority("__mul__") + def __rmul__(self, other) -> Order: ... + def __pow__(self, other, mod=...) -> Expr: ... + @sympify_return([("other", "Expr")], NotImplemented) + @call_highest_priority("__pow__") + def __rpow__(self, other) -> Pow: ... + @sympify_return([("other", "Expr")], NotImplemented) + @call_highest_priority("__rtruediv__") + def __truediv__(self, other) -> Pow | Order: ... + @sympify_return([("other", "Expr")], NotImplemented) + @call_highest_priority("__truediv__") + def __rtruediv__(self, other) -> Pow | Order: ... + @sympify_return([("other", "Expr")], NotImplemented) + @call_highest_priority("__rmod__") + def __mod__(self, other) -> type[UndefinedFunction]: ... + @sympify_return([("other", "Expr")], NotImplemented) + @call_highest_priority("__mod__") + def __rmod__(self, other) -> type[UndefinedFunction]: ... + @sympify_return([("other", "Expr")], NotImplemented) + @call_highest_priority("__rfloordiv__") + def __floordiv__(self, other) -> type[UndefinedFunction]: ... + @sympify_return([("other", "Expr")], NotImplemented) + @call_highest_priority("__floordiv__") + def __rfloordiv__(self, other) -> type[UndefinedFunction]: ... + @sympify_return([("other", "Expr")], NotImplemented) + @call_highest_priority("__rdivmod__") + def __divmod__(self, other) -> tuple[type[UndefinedFunction] | Any, type[UndefinedFunction] | Any]: ... + @sympify_return([("other", "Expr")], NotImplemented) + @call_highest_priority("__divmod__") + def __rdivmod__(self, other) -> tuple[type[UndefinedFunction] | Any, type[UndefinedFunction] | Any]: ... + def __int__(self) -> int: ... + def __float__(self) -> float: ... + def __complex__(self) -> complex: ... + @sympify_return([("other", "Expr")], NotImplemented) + def __ge__(self, other) -> bool: ... + @sympify_return([("other", "Expr")], NotImplemented) + def __le__(self, other) -> bool: ... + @sympify_return([("other", "Expr")], NotImplemented) + def __gt__(self, other) -> bool: ... + @sympify_return([("other", "Expr")], NotImplemented) + def __lt__(self, other) -> bool: ... + def __trunc__(self) -> Integer: ... + def __format__(self, format_spec: str) -> str: ... @property - def is_number(self) -> bool: - ... - - def is_constant(self, *wrt, **flags): - ... - - def equals(self, other, failing_expression=...): - ... - - def conjugate(self) -> type[UndefinedFunction]: - ... - - def dir(self, x, cdir): - ... - - def transpose(self) -> type[UndefinedFunction]: - ... - - def adjoint(self) -> type[UndefinedFunction]: - ... - - def as_ordered_factors(self, order=...) -> list[Self]: - ... - - def as_poly(self, *gens, **args) -> Any | None: - ... - - def as_ordered_terms(self, order=..., data=...) -> list[Basic] | tuple[list[Any], list[Any]] | list[Any]: - ... - - def as_terms(self) -> tuple[list[Any], list[Any]]: - ... - - def removeO(self) -> Self: - ... - - def getO(self) -> None: - ... - - def getn(self) -> None: - ... - - def count_ops(self, visual=...): - ... - - def args_cnc(self, cset=..., warn=..., split_1=...) -> list[Any]: - ... - - def coeff(self, x, n=..., right=..., _first=...): - ... - - def as_expr(self, *gens) -> Self: - ... - - def as_coefficient(self, expr) -> None: - ... - - def as_independent(self, *deps, **hint) -> tuple[Expr, Expr]: - ... - - def as_real_imag(self, deep=..., **hints) -> tuple[type[UndefinedFunction] | Any, type[UndefinedFunction] | Any] | None: - ... - - def as_powers_dict(self) -> defaultdict[Any, int]: - ... - - def as_coefficients_dict(self, *syms) -> defaultdict[Any, int]: - ... - - def as_base_exp(self) -> tuple[Expr, Expr]: - ... - - def as_coeff_mul(self, *deps, **kwargs) -> tuple[Expr, tuple[Expr, ...]]: - ... - - def as_coeff_add(self, *deps) -> tuple[Expr, tuple[Expr, ...]]: - ... - - def primitive(self) -> tuple[Any, Any] | tuple[Any | Mul | Number, Any | Mul | Expr]: - ... - - def as_content_primitive(self, radical=..., clear=...) -> tuple[Any, Self]: - ... - - def as_numer_denom(self) -> tuple[Self, Any]: - ... - - def normal(self) -> Self | Mul: - ... - - def extract_multiplicatively(self, c): - ... - - def extract_additively(self, c) -> Self | Order | None: - ... - + def is_number(self) -> bool: ... + def is_constant(self, *wrt, **flags): ... + def equals(self, other, failing_expression=...): ... + def conjugate(self) -> type[UndefinedFunction]: ... + def dir(self, x, cdir): ... + def transpose(self) -> type[UndefinedFunction]: ... + def adjoint(self) -> type[UndefinedFunction]: ... + def as_ordered_factors(self, order=...) -> list[Self]: ... + def as_poly(self, *gens, **args) -> Any | None: ... + def as_ordered_terms(self, order=..., data=...) -> list[Basic] | tuple[list[Any], list[Any]] | list[Any]: ... + def as_terms(self) -> tuple[list[Any], list[Any]]: ... + def removeO(self) -> Self: ... + def getO(self) -> None: ... + def getn(self) -> None: ... + def count_ops(self, visual=...): ... + def args_cnc(self, cset=..., warn=..., split_1=...) -> list[Any]: ... + def coeff(self, x, n=..., right=..., _first=...): ... + def as_expr(self, *gens) -> Self: ... + def as_coefficient(self, expr) -> None: ... + def as_independent(self, *deps, **hint) -> tuple[Expr, Expr]: ... + def as_real_imag(self, deep=..., **hints) -> tuple[type[UndefinedFunction] | Any, type[UndefinedFunction] | Any] | None: ... + def as_powers_dict(self) -> defaultdict[Any, int]: ... + def as_coefficients_dict(self, *syms) -> defaultdict[Any, int]: ... + def as_base_exp(self) -> tuple[Expr, Expr]: ... + def as_coeff_mul(self, *deps, **kwargs) -> tuple[Expr, tuple[Expr, ...]]: ... + def as_coeff_add(self, *deps) -> tuple[Expr, tuple[Expr, ...]]: ... + def primitive(self) -> tuple[Any, Any] | tuple[Any | Mul | Number, Any | Mul | Expr]: ... + def as_content_primitive(self, radical=..., clear=...) -> tuple[Any, Self]: ... + def as_numer_denom(self) -> tuple[Self, Any]: ... + def normal(self) -> Self | Mul: ... + def extract_multiplicatively(self, c): ... + def extract_additively(self, c) -> Self | Order | None: ... @property - def expr_free_symbols(self) -> set[Any]: - ... - - def could_extract_minus_sign(self) -> Literal[False]: - ... - - def extract_branch_factor(self, allow_half=...) -> tuple[Any, Any]: - ... - - def is_polynomial(self, *syms) -> Literal[True] | None: - ... - - def is_rational_function(self, *syms) -> bool | None: - ... - - def is_meromorphic(self, x, a) -> Literal[True] | None: - ... - - def is_algebraic_expr(self, *syms) -> Literal[True] | None: - ... - - def series(self, x=..., x0=..., n=..., dir=..., logx=..., cdir=...): - ... - - def aseries(self, x=..., n=..., bound=..., hir=...) -> Self: - ... - - def taylor_term(self, n, x, *previous_terms): - ... - - def lseries(self, x=..., x0=..., dir=..., logx=..., cdir=...): - ... - - def nseries(self, x=..., x0=..., n=..., dir=..., logx=..., cdir=...) -> Self: - ... - - def limit(self, x, xlim, dir=...): - ... - - def compute_leading_term(self, x, logx=...) -> Self | Order | Any: - ... - + def expr_free_symbols(self) -> set[Any]: ... + def could_extract_minus_sign(self) -> Literal[False]: ... + def extract_branch_factor(self, allow_half=...) -> tuple[Any, Any]: ... + def is_polynomial(self, *syms) -> Literal[True] | None: ... + def is_rational_function(self, *syms) -> bool | None: ... + def is_meromorphic(self, x, a) -> Literal[True] | None: ... + def is_algebraic_expr(self, *syms) -> Literal[True] | None: ... + def series(self, x=..., x0=..., n=..., dir=..., logx=..., cdir=...): ... + def aseries(self, x=..., n=..., bound=..., hir=...) -> Self: ... + def taylor_term(self, n, x, *previous_terms): ... + def lseries(self, x=..., x0=..., dir=..., logx=..., cdir=...): ... + def nseries(self, x=..., x0=..., n=..., dir=..., logx=..., cdir=...) -> Self: ... + def limit(self, x, xlim, dir=...): ... + def compute_leading_term(self, x, logx=...) -> Self | Order | Any: ... @cacheit - def as_leading_term(self, *symbols, logx=..., cdir=...) -> Self: - ... - - def as_coeff_exponent(self, x) -> tuple[Expr, Expr]: - ... - - def leadterm(self, x, logx=..., cdir=...) -> tuple[Any | Expr | Basic, Expr | Any]: - ... - - def as_coeff_Mul(self, rational: bool = ...) -> tuple[Number, Expr]: - ... - - def as_coeff_Add(self, rational=...) -> tuple[Number, Expr]: - ... - - def fps(self, x=..., x0=..., dir=..., hyper=..., order=..., rational=..., full=...) -> FormalPowerSeries: - ... - - def fourier_series(self, limits=...) -> FiniteFourierSeries | FourierSeries: - ... - - def diff(self, *symbols, **assumptions) -> ArrayDerivative | Derivative: - ... - + def as_leading_term(self, *symbols, logx=..., cdir=...) -> Self: ... + def as_coeff_exponent(self, x) -> tuple[Expr, Expr]: ... + def leadterm(self, x, logx=..., cdir=...) -> tuple[Any | Expr | Basic, Expr | Any]: ... + def as_coeff_Mul(self, rational: bool = ...) -> tuple[Number, Expr]: ... + def as_coeff_Add(self, rational=...) -> tuple[Number, Expr]: ... + def fps(self, x=..., x0=..., dir=..., hyper=..., order=..., rational=..., full=...) -> FormalPowerSeries: ... + def fourier_series(self, limits=...) -> FiniteFourierSeries | FourierSeries: ... + def diff(self, *symbols, **assumptions) -> ArrayDerivative | Derivative: ... @cacheit - def expand(self, deep=..., modulus=..., power_base=..., power_exp=..., mul=..., log=..., multinomial=..., basic=..., **hints) -> Order | Any | Self: - ... - - def integrate(self, *args, **kwargs) -> Equality | Relational | Ne: - ... - - def nsimplify(self, constants=..., tolerance=..., full=...): - ... - - def separate(self, deep=..., force=...): - ... - - def collect(self, syms, func=..., evaluate=..., exact=..., distribute_order_term=...): - ... - - def together(self, *args, **kwargs) -> Any: - ... - - def apart(self, x=..., **args) -> Any: - ... - - def ratsimp(self) -> Any: - ... - - def trigsimp(self, **args) -> Any: - ... - - def radsimp(self, **kwargs): - ... - - def powsimp(self, *args, **kwargs): - ... - - def combsimp(self) -> Any: - ... - - def gammasimp(self) -> Self | Any: - ... - - def factor(self, *gens, **args) -> Any: - ... - - def cancel(self, *gens, **args) -> Any: - ... - - def invert(self, g, *gens, **args) -> int | Any: - ... - - def round(self, n=...) -> Self | Integer | Rational | Float: - ... - - __round__ = ... + def expand( + self, deep=..., modulus=..., power_base=..., power_exp=..., mul=..., log=..., multinomial=..., basic=..., **hints + ) -> Order | Any | Self: ... + def integrate(self, *args, **kwargs) -> Equality | Relational | Ne: ... + def nsimplify(self, constants=..., tolerance=..., full=...): ... + def separate(self, deep=..., force=...): ... + def collect(self, syms, func=..., evaluate=..., exact=..., distribute_order_term=...): ... + def together(self, *args, **kwargs) -> Any: ... + def apart(self, x=..., **args) -> Any: ... + def ratsimp(self) -> Any: ... + def trigsimp(self, **args) -> Any: ... + def radsimp(self, **kwargs): ... + def powsimp(self, *args, **kwargs): ... + def combsimp(self) -> Any: ... + def gammasimp(self) -> Self | Any: ... + def factor(self, *gens, **args) -> Any: ... + def cancel(self, *gens, **args) -> Any: ... + def invert(self, g, *gens, **args) -> int | Any: ... + def round(self, n=...) -> Self | Integer | Rational | Float: ... + __round__ = ... class AtomicExpr(Atom, Expr): is_number = ... is_Atom = ... __slots__ = ... @property - def expr_free_symbols(self) -> set[Self]: - ... - - + def expr_free_symbols(self) -> set[Self]: ... class UnevaluatedExpr(Expr): - def __new__(cls, arg, **kwargs) -> Self: - ... - - def doit(self, **hints) -> Basic: - ... - + def __new__(cls, arg, **kwargs) -> Self: ... + def doit(self, **hints) -> Basic: ... - -def unchanged(func, *args): - ... +def unchanged(func, *args): ... class ExprBuilder: - def __init__(self, op, args=..., validator=..., check=...) -> None: - ... - - def validate(self) -> None: - ... - - def build(self, check=...): - ... - - def append_argument(self, arg, check=...) -> None: - ... - - def __getitem__(self, item) -> Any: - ... - - def __repr__(self) -> str: - ... - - def search_element(self, elem) -> tuple[int] | None: - ... - - - + def __init__(self, op, args=..., validator=..., check=...) -> None: ... + def validate(self) -> None: ... + def build(self, check=...): ... + def append_argument(self, arg, check=...) -> None: ... + def __getitem__(self, item) -> Any: ... + def __repr__(self) -> str: ... + def search_element(self, elem) -> tuple[int] | None: ... diff --git a/stubs/sympy-stubs/core/exprtools.pyi b/stubs/sympy-stubs/core/exprtools.pyi index fdcce925..4cc53fd0 100644 --- a/stubs/sympy-stubs/core/exprtools.pyi +++ b/stubs/sympy-stubs/core/exprtools.pyi @@ -9,136 +9,54 @@ from sympy.core.mul import Mul from sympy.core.numbers import Rational _eps = ... -def decompose_power(expr: Expr) -> tTuple[Expr, int]: - ... -def decompose_power_rat(expr: Expr) -> tTuple[Expr, Rational]: - ... +def decompose_power(expr: Expr) -> tTuple[Expr, int]: ... +def decompose_power_rat(expr: Expr) -> tTuple[Expr, Rational]: ... class Factors: __slots__ = ... - def __init__(self, factors=...) -> None: - ... - - def __hash__(self) -> int: - ... - - def __repr__(self) -> LiteralString: - ... - + def __init__(self, factors=...) -> None: ... + def __hash__(self) -> int: ... + def __repr__(self) -> LiteralString: ... @property - def is_zero(self) -> bool: - ... - + def is_zero(self) -> bool: ... @property - def is_one(self) -> bool: - ... - - def as_expr(self) -> Order: - ... - - def mul(self, other) -> Factors: - ... - - def normal(self, other) -> tuple[Factors, Factors]: - ... - - def div(self, other) -> tuple[Factors, Factors]: - ... - - def quo(self, other) -> Factors: - ... - - def rem(self, other) -> Factors: - ... - - def pow(self, other) -> Factors: - ... - - def gcd(self, other) -> Factors: - ... - - def lcm(self, other) -> Factors: - ... - - def __mul__(self, other) -> Factors: - ... - - def __divmod__(self, other) -> tuple[Factors, Factors]: - ... - - def __truediv__(self, other) -> Factors: - ... - - def __mod__(self, other) -> Factors: - ... - - def __pow__(self, other) -> Factors: - ... - - def __eq__(self, other) -> bool: - ... - - def __ne__(self, other) -> bool: - ... - - + def is_one(self) -> bool: ... + def as_expr(self) -> Order: ... + def mul(self, other) -> Factors: ... + def normal(self, other) -> tuple[Factors, Factors]: ... + def div(self, other) -> tuple[Factors, Factors]: ... + def quo(self, other) -> Factors: ... + def rem(self, other) -> Factors: ... + def pow(self, other) -> Factors: ... + def gcd(self, other) -> Factors: ... + def lcm(self, other) -> Factors: ... + def __mul__(self, other) -> Factors: ... + def __divmod__(self, other) -> tuple[Factors, Factors]: ... + def __truediv__(self, other) -> Factors: ... + def __mod__(self, other) -> Factors: ... + def __pow__(self, other) -> Factors: ... + def __eq__(self, other) -> bool: ... + def __ne__(self, other) -> bool: ... class Term: __slots__ = ... - def __init__(self, term, numer=..., denom=...) -> None: - ... - - def __hash__(self) -> int: - ... - - def __repr__(self) -> str: - ... - - def as_expr(self): - ... - - def mul(self, other) -> Term: - ... - - def inv(self) -> Term: - ... - - def quo(self, other) -> Term: - ... - - def pow(self, other) -> Term: - ... - - def gcd(self, other) -> Term: - ... - - def lcm(self, other) -> Term: - ... - - def __mul__(self, other) -> Term | NotImplementedType: - ... - - def __truediv__(self, other) -> Term | NotImplementedType: - ... - - def __pow__(self, other) -> Term | NotImplementedType: - ... - - def __eq__(self, other) -> bool: - ... - - def __ne__(self, other) -> bool: - ... - - - -def gcd_terms(terms, isprimitive=..., clear=..., fraction=...) -> Add | Order | Mul | Basic | Dict: - ... - -def factor_terms(expr, radical=..., clear=..., fraction=..., sign=...) -> Basic | Any | Add | Order | Mul: - ... - -def factor_nc(expr) -> Expr | Any | Add | Order | Mul: - ... - + def __init__(self, term, numer=..., denom=...) -> None: ... + def __hash__(self) -> int: ... + def __repr__(self) -> str: ... + def as_expr(self): ... + def mul(self, other) -> Term: ... + def inv(self) -> Term: ... + def quo(self, other) -> Term: ... + def pow(self, other) -> Term: ... + def gcd(self, other) -> Term: ... + def lcm(self, other) -> Term: ... + def __mul__(self, other) -> Term | NotImplementedType: ... + def __truediv__(self, other) -> Term | NotImplementedType: ... + def __pow__(self, other) -> Term | NotImplementedType: ... + def __eq__(self, other) -> bool: ... + def __ne__(self, other) -> bool: ... + +def gcd_terms(terms, isprimitive=..., clear=..., fraction=...) -> Add | Order | Mul | Basic | Dict: ... +def factor_terms(expr, radical=..., clear=..., fraction=..., sign=...) -> Basic | Any | Add | Order | Mul: ... +def factor_nc(expr) -> Expr | Any | Add | Order | Mul: ... diff --git a/stubs/sympy-stubs/core/facts.pyi b/stubs/sympy-stubs/core/facts.pyi index b73b75c9..3ace116c 100644 --- a/stubs/sympy-stubs/core/facts.pyi +++ b/stubs/sympy-stubs/core/facts.pyi @@ -1,66 +1,30 @@ from collections import defaultdict from typing import Any, Iterator -def transitive_closure(implications) -> set[Any]: - ... - -def deduce_alpha_implications(implications) -> defaultdict[Any, set[Any]]: - ... - -def apply_beta_to_alpha_route(alpha_implications, beta_rules) -> dict[Any, Any]: - ... - -def rules_2prereq(rules) -> defaultdict[Any, set[Any]]: - ... - -class TautologyDetected(Exception): - ... +def transitive_closure(implications) -> set[Any]: ... +def deduce_alpha_implications(implications) -> defaultdict[Any, set[Any]]: ... +def apply_beta_to_alpha_route(alpha_implications, beta_rules) -> dict[Any, Any]: ... +def rules_2prereq(rules) -> defaultdict[Any, set[Any]]: ... +class TautologyDetected(Exception): ... class Prover: - def __init__(self) -> None: - ... - - def split_alpha_beta(self) -> tuple[list[Any], list[Any]]: - ... - + def __init__(self) -> None: ... + def split_alpha_beta(self) -> tuple[list[Any], list[Any]]: ... @property - def rules_alpha(self) -> list[Any]: - ... - + def rules_alpha(self) -> list[Any]: ... @property - def rules_beta(self) -> list[Any]: - ... - - def process_rule(self, a, b) -> None: - ... - - + def rules_beta(self) -> list[Any]: ... + def process_rule(self, a, b) -> None: ... class FactRules: - def __init__(self, rules) -> None: - ... - - def print_rules(self) -> Iterator[str]: - ... - - + def __init__(self, rules) -> None: ... + def print_rules(self) -> Iterator[str]: ... class InconsistentAssumptions(ValueError): - def __str__(self) -> str: - ... - - + def __str__(self) -> str: ... class FactKB(dict): - def __str__(self) -> str: - ... - - def __init__(self, rules) -> None: - ... - - def deduce_all_facts(self, facts) -> None: - ... - - - + def __str__(self) -> str: ... + def __init__(self, rules) -> None: ... + def deduce_all_facts(self, facts) -> None: ... diff --git a/stubs/sympy-stubs/core/function.pyi b/stubs/sympy-stubs/core/function.pyi index 46c0b80e..a033e1a5 100644 --- a/stubs/sympy-stubs/core/function.pyi +++ b/stubs/sympy-stubs/core/function.pyi @@ -13,293 +13,149 @@ from sympy.printing.str import StrPrinter from sympy.sets.sets import FiniteSet from sympy.tensor.array.array_derivatives import ArrayDerivative -class PoleError(Exception): - ... - +class PoleError(Exception): ... class ArgumentIndexError(ValueError): - def __str__(self) -> str: - ... - - - -class BadSignatureError(TypeError): - ... - - -class BadArgumentsError(TypeError): - ... + def __str__(self) -> str: ... +class BadSignatureError(TypeError): ... +class BadArgumentsError(TypeError): ... -def arity(cls) -> int | tuple[int, ...] | None: - ... +def arity(cls) -> int | tuple[int, ...] | None: ... class FunctionClass(type): _new = ... - def __init__(cls, *args, **kwargs) -> None: - ... - + def __init__(cls, *args, **kwargs) -> None: ... @property - def __signature__(self) -> Signature | None: - ... - + def __signature__(self) -> Signature | None: ... @property - def free_symbols(self) -> set[Any]: - ... - + def free_symbols(self) -> set[Any]: ... @property - def xreplace(self) -> Callable[..., Any]: - ... - + def xreplace(self) -> Callable[..., Any]: ... @property - def nargs(self) -> FiniteSet: - ... - - def __repr__(cls) -> str: - ... - - + def nargs(self) -> FiniteSet: ... + def __repr__(cls) -> str: ... class Application(Basic, metaclass=FunctionClass): is_Function = ... @cacheit - def __new__(cls, *args, **options) -> Self: - ... - + def __new__(cls, *args, **options) -> Self: ... @classmethod - def eval(cls, *args) -> None: - ... - + def eval(cls, *args) -> None: ... @property - def func(self) -> type[Self]: - ... - - + def func(self) -> type[Self]: ... class Function(Application, Expr): @cacheit - def __new__(cls, *args, **options) -> type[UndefinedFunction]: - ... - + def __new__(cls, *args, **options) -> type[UndefinedFunction]: ... @classmethod - def class_key(cls) -> tuple[Literal[4], int, str]: - ... - + def class_key(cls) -> tuple[Literal[4], int, str]: ... + _singularities: FuzzyBool | tuple[Expr, ...] = ... @classmethod - def is_singular(cls, a) -> FuzzyBool: - ... - - def as_base_exp(self) -> tuple[Self, Any]: - ... - - def fdiff(self, argindex=...) -> ArrayDerivative | Derivative | Subs: - ... - - + def is_singular(cls, a) -> FuzzyBool: ... + def as_base_exp(self) -> tuple[Self, Any]: ... + def fdiff(self, argindex=...) -> ArrayDerivative | Derivative | Subs: ... class AppliedUndef(Function): is_number = ... - def __new__(cls, *args, **options) -> type[UndefinedFunction]: - ... - - + def __new__(cls, *args, **options) -> type[UndefinedFunction]: ... class UndefSageHelper: - def __get__(self, ins, typ) -> Callable[[], Any]: - ... - - + def __get__(self, ins, typ) -> Callable[[], Any]: ... _undef_sage_helper = ... + class UndefinedFunction(FunctionClass): - def __new__(cls, name, bases=..., __dict__=..., **kwargs) -> Self: # type: ignore + def __new__(cls, name, bases=..., __dict__=..., **kwargs) -> Self: # type: ignore ... - - def __instancecheck__(cls, instance) -> bool: - ... - - _kwargs: dict[str, bool | None] = ... - def __hash__(self) -> int: - ... - - def __eq__(self, other) -> bool: - ... - - def __ne__(self, other) -> bool: - ... - + def __instancecheck__(cls, instance) -> bool: ... + + _kwargs: dict[str, bool | None] = ... + def __hash__(self) -> int: ... + def __eq__(self, other) -> bool: ... + def __ne__(self, other) -> bool: ... class WildFunction(Function, AtomicExpr): include: set[Any] = ... - def __init__(self, name, **assumptions) -> None: - ... - - def matches(self, expr, repl_dict=..., old=...) -> dict[Any, Any] | None: - ... - - + def __init__(self, name, **assumptions) -> None: ... + def matches(self, expr, repl_dict=..., old=...) -> dict[Any, Any] | None: ... class Derivative(Expr): is_Derivative = ... - def __new__(cls, expr, *variables, **kwargs): - ... - + def __new__(cls, expr, *variables, **kwargs): ... @property - def canonical(cls) -> Self: - ... - - def doit(self, **hints) -> Self: - ... - - @_sympifyit('z0', NotImplementedError) - def doit_numerically(self, z0) -> Float: - ... - + def canonical(cls) -> Self: ... + def doit(self, **hints) -> Self: ... + @_sympifyit("z0", NotImplementedError) + def doit_numerically(self, z0) -> Float: ... @property - def expr(self) -> Basic: - ... - + def expr(self) -> Basic: ... @property - def variables(self) -> tuple[Any, ...]: - ... - + def variables(self) -> tuple[Any, ...]: ... @property - def variable_count(self) -> tuple[Basic, ...]: - ... - + def variable_count(self) -> tuple[Basic, ...]: ... @property - def derivative_count(self) -> int: - ... - + def derivative_count(self) -> int: ... @property - def free_symbols(self) -> set[Basic]: - ... - + def free_symbols(self) -> set[Basic]: ... @property - def kind(self) -> Kind: - ... - - def as_finite_difference(self, points=..., x0=..., wrt=...) -> Literal[0]: - ... - - + def kind(self) -> Kind: ... + def as_finite_difference(self, points=..., x0=..., wrt=...) -> Literal[0]: ... class Lambda(Expr): is_Function = ... - def __new__(cls, signature, expr) -> Self: - ... - + def __new__(cls, signature, expr) -> Self: ... @property - def signature(self) -> Basic: - ... - + def signature(self) -> Basic: ... @property - def expr(self) -> Basic: - ... - + def expr(self) -> Basic: ... @property - def variables(self) -> tuple[Any, ...]: - ... - + def variables(self) -> tuple[Any, ...]: ... @property - def nargs(self) -> FiniteSet: - ... - + def nargs(self) -> FiniteSet: ... + bound_symbols = ... @property - def free_symbols(self) -> set[Basic]: - ... - - def __call__(self, *args) -> Basic: - ... - + def free_symbols(self) -> set[Basic]: ... + def __call__(self, *args) -> Basic: ... @property - def is_identity(self) -> NotImplementedType | bool: - ... - - + def is_identity(self) -> NotImplementedType | bool: ... class Subs(Expr): def __new__(cls, expr, variables, point, **assumptions) -> Self: - class CustomStrPrinter(StrPrinter): - ... - - - - def doit(self, **hints) -> Basic: - ... - - def evalf(self, prec=..., **options): - ... - + class CustomStrPrinter(StrPrinter): ... + + def doit(self, **hints) -> Basic: ... + def evalf(self, prec=..., **options): ... + n = ... @property - def variables(self) -> Basic: - ... - + def variables(self) -> Basic: ... + bound_symbols = ... @property - def expr(self) -> Basic: - ... - - @property - def point(self) -> Basic: - ... - - @property - def free_symbols(self) -> set[Basic]: - ... - - @property - def expr_free_symbols(self) -> set[Any]: - ... - - def __eq__(self, other) -> bool: - ... - - def __ne__(self, other) -> bool: - ... - - def __hash__(self) -> int: - ... - - - -def diff(f, *symbols, **kwargs) -> ArrayDerivative | Derivative: - ... - -def expand(e, deep=..., modulus=..., power_base=..., power_exp=..., mul=..., log=..., multinomial=..., basic=..., **hints): - ... - -def expand_mul(expr, deep=...): - ... - -def expand_multinomial(expr, deep=...): - ... - -def expand_log(expr, deep=..., force=..., factor=...): - ... - -def expand_func(expr, deep=...): - ... - -def expand_trig(expr, deep=...): - ... - -def expand_complex(expr, deep=...): - ... - -def expand_power_base(expr, deep=..., force=...): - ... - -def expand_power_exp(expr, deep=...): - ... - -def count_ops(expr, visual=...): - ... - -def nfloat(expr, n=..., exponent=..., dkeys=...) -> dict[Any, Any] | Dict | Basic | Any | Float: - ... - + def expr(self) -> Basic: ... + @property + def point(self) -> Basic: ... + @property + def free_symbols(self) -> set[Basic]: ... + @property + def expr_free_symbols(self) -> set[Any]: ... + def __eq__(self, other) -> bool: ... + def __ne__(self, other) -> bool: ... + def __hash__(self) -> int: ... + +def diff(f, *symbols, **kwargs) -> ArrayDerivative | Derivative: ... +def expand(e, deep=..., modulus=..., power_base=..., power_exp=..., mul=..., log=..., multinomial=..., basic=..., **hints): ... +def expand_mul(expr, deep=...): ... +def expand_multinomial(expr, deep=...): ... +def expand_log(expr, deep=..., force=..., factor=...): ... +def expand_func(expr, deep=...): ... +def expand_trig(expr, deep=...): ... +def expand_complex(expr, deep=...): ... +def expand_power_base(expr, deep=..., force=...): ... +def expand_power_exp(expr, deep=...): ... +def count_ops(expr, visual=...): ... +def nfloat(expr, n=..., exponent=..., dkeys=...) -> dict[Any, Any] | Dict | Basic | Any | Float: ... diff --git a/stubs/sympy-stubs/core/kind.pyi b/stubs/sympy-stubs/core/kind.pyi index 8e4ce9d7..56884753 100644 --- a/stubs/sympy-stubs/core/kind.pyi +++ b/stubs/sympy-stubs/core/kind.pyi @@ -3,67 +3,36 @@ from typing import Callable, Literal, LiteralString, Self from sympy.core.cache import cacheit class KindMeta(type): - def __new__(cls, clsname, bases, dct) -> Self: # type: ignore + def __new__(cls, clsname, bases, dct) -> Self: # type: ignore ... - - class Kind(metaclass=KindMeta): - def __new__(cls, *args) -> Self: - ... - - + def __new__(cls, *args) -> Self: ... class _UndefinedKind(Kind): - def __new__(cls) -> Self: - ... - - def __repr__(self) -> Literal['UndefinedKind']: - ... - - + def __new__(cls) -> Self: ... + def __repr__(self) -> Literal["UndefinedKind"]: ... UndefinedKind = ... -class _NumberKind(Kind): - def __new__(cls) -> Self: - ... - - def __repr__(self) -> Literal['NumberKind']: - ... - +class _NumberKind(Kind): + def __new__(cls) -> Self: ... + def __repr__(self) -> Literal["NumberKind"]: ... NumberKind = ... -class _BooleanKind(Kind): - def __new__(cls) -> Self: - ... - - def __repr__(self) -> Literal['BooleanKind']: - ... - +class _BooleanKind(Kind): + def __new__(cls) -> Self: ... + def __repr__(self) -> Literal["BooleanKind"]: ... BooleanKind = ... + class KindDispatcher: - def __init__(self, name, commutative=..., doc=...) -> None: - ... - - def __repr__(self) -> LiteralString: - ... - - def register(self, *types, **kwargs) -> Callable[..., None]: - ... - - def __call__(self, *args, **kwargs) -> Kind | _UndefinedKind: - ... - + def __init__(self, name, commutative=..., doc=...) -> None: ... + def __repr__(self) -> LiteralString: ... + def register(self, *types, **kwargs) -> Callable[..., None]: ... + def __call__(self, *args, **kwargs) -> Kind | _UndefinedKind: ... @cacheit - def dispatch_kinds(self, kinds, **kwargs) -> Kind | _UndefinedKind: - ... - + def dispatch_kinds(self, kinds, **kwargs) -> Kind | _UndefinedKind: ... @property - def __doc__(self) -> str: - ... - - - + def __doc__(self) -> str: ... diff --git a/stubs/sympy-stubs/core/logic.pyi b/stubs/sympy-stubs/core/logic.pyi index 452e7460..e52b6e5d 100644 --- a/stubs/sympy-stubs/core/logic.pyi +++ b/stubs/sympy-stubs/core/logic.pyi @@ -1,85 +1,42 @@ from typing import Any, Optional, Self FuzzyBool = Optional[bool] -def fuzzy_bool(x) -> bool | None: - ... -def fuzzy_and(args) -> bool | None: - ... - -def fuzzy_not(v) -> bool: - ... - -def fuzzy_or(args) -> bool | None: - ... - -def fuzzy_xor(args) -> bool | None: - ... - -def fuzzy_nand(args) -> bool | None: - ... +def fuzzy_bool(x) -> bool | None: ... +def fuzzy_and(args) -> bool | None: ... +def fuzzy_not(v) -> bool: ... +def fuzzy_or(args) -> bool | None: ... +def fuzzy_xor(args) -> bool | None: ... +def fuzzy_nand(args) -> bool | None: ... class Logic: op_2class: dict[str, type[Logic]] = ... - def __new__(cls, *args) -> Self: - ... - - def __getnewargs__(self): - ... - - def __hash__(self) -> int: - ... - - def __eq__(self, b) -> bool: - ... - - def __ne__(self, b) -> bool: - ... - - def __lt__(self, other) -> bool: - ... - - def __cmp__(self, other) -> int: - ... - - def __str__(self) -> str: - ... - + def __new__(cls, *args) -> Self: ... + def __getnewargs__(self): ... + def __hash__(self) -> int: ... + def __eq__(self, b) -> bool: ... + def __ne__(self, b) -> bool: ... + def __lt__(self, other) -> bool: ... + def __cmp__(self, other) -> int: ... + def __str__(self) -> str: ... + __repr__ = ... @staticmethod - def fromstring(text) -> Not | bool | Logic: - ... - - + def fromstring(text) -> Not | bool | Logic: ... class AndOr_Base(Logic): - def __new__(cls, *args) -> bool | Self: - ... - + def __new__(cls, *args) -> bool | Self: ... @classmethod - def flatten(cls, args) -> tuple[Any, ...]: - ... - - + def flatten(cls, args) -> tuple[Any, ...]: ... class And(AndOr_Base): op_x_notx = ... - def expand(self) -> bool | Or | Self: - ... - - + def expand(self) -> bool | Or | Self: ... class Or(AndOr_Base): op_x_notx = ... - class Not(Logic): - def __new__(cls, arg) -> Self | bool: - ... - + def __new__(cls, arg) -> Self | bool: ... @property - def arg(self): - ... - - - + def arg(self): ... diff --git a/stubs/sympy-stubs/core/mod.pyi b/stubs/sympy-stubs/core/mod.pyi index dddfead5..36672bdc 100644 --- a/stubs/sympy-stubs/core/mod.pyi +++ b/stubs/sympy-stubs/core/mod.pyi @@ -3,8 +3,4 @@ from sympy.core.function import Function class Mod(Function): kind = ... @classmethod - def eval(cls, p, q): - ... - - - + def eval(cls, p, q): ... diff --git a/stubs/sympy-stubs/core/mul.pyi b/stubs/sympy-stubs/core/mul.pyi index bf883079..c53f301b 100644 --- a/stubs/sympy-stubs/core/mul.pyi +++ b/stubs/sympy-stubs/core/mul.pyi @@ -13,8 +13,8 @@ class NC_Marker: is_Poly = ... is_commutative = ... - _args_sortkey = ... + class Mul(Expr, AssocOp): __slots__ = ... args: tTuple[Expr] @@ -22,62 +22,35 @@ class Mul(Expr, AssocOp): _args_type = Expr _kind_dispatcher = ... @property - def kind(self) -> Kind | _UndefinedKind: - ... - - def could_extract_minus_sign(self) -> Literal[False]: - ... - - def __neg__(self) -> Self: - ... - + def kind(self) -> Kind | _UndefinedKind: ... + def could_extract_minus_sign(self) -> Literal[False]: ... + def __neg__(self) -> Self: ... @classmethod - def flatten(cls, seq): - ... - + def flatten(cls, seq): ... @classmethod - def class_key(cls) -> tuple[Literal[3], Literal[0], str]: - ... - + def class_key(cls) -> tuple[Literal[3], Literal[0], str]: ... @cacheit - def as_two_terms(self) -> tuple[Any, Self] | tuple[Any, Any | Self]: - ... - + def as_two_terms(self) -> tuple[Any, Self] | tuple[Any, Any | Self]: ... @cacheit - def as_coeff_mul(self, *deps, rational=..., **kwargs) -> tuple[Any | Self, tuple[Any, ...]] | tuple[Expr, tuple[()]] | tuple[Any, tuple[Any | Mul]] | tuple[Any, tTuple[Expr]]: - ... - - def as_coeff_Mul(self, rational=...) -> tuple[Expr, Any] | tuple[Expr, Any | Self] | tuple[Any, Any | Self] | tuple[Any, Self]: - ... - - def as_real_imag(self, deep=..., **hints) -> tuple[Self, Any] | tuple[Any, Any] | None: - ... - - def matches(self, expr, repl_dict=..., old=...) -> dict[Any, Any] | None: - ... - - def as_powers_dict(self) -> defaultdict[Any, int]: - ... - - def as_numer_denom(self) -> tuple[Self, Self]: - ... - - def as_base_exp(self) -> tuple[Self, Any] | tuple[Self, Expr | None]: - ... - - _eval_is_commutative = ... - def as_content_primitive(self, radical=..., clear=...) -> tuple[Any, Self]: - ... - - def as_ordered_factors(self, order=...): - ... - + def as_coeff_mul( + self, *deps, rational=..., **kwargs + ) -> ( + tuple[Any | Self, tuple[Any, ...]] | tuple[Expr, tuple[()]] | tuple[Any, tuple[Any | Mul]] | tuple[Any, tTuple[Expr]] + ): ... + def as_coeff_Mul( + self, rational=... + ) -> tuple[Expr, Any] | tuple[Expr, Any | Self] | tuple[Any, Any | Self] | tuple[Any, Self]: ... + def as_real_imag(self, deep=..., **hints) -> tuple[Self, Any] | tuple[Any, Any] | None: ... + def matches(self, expr, repl_dict=..., old=...) -> dict[Any, Any] | None: ... + def as_powers_dict(self) -> defaultdict[Any, int]: ... + def as_numer_denom(self) -> tuple[Self, Self]: ... + def as_base_exp(self) -> tuple[Self, Any] | tuple[Self, Expr | None]: ... + _eval_is_commutative = ... + def as_content_primitive(self, radical=..., clear=...) -> tuple[Any, Self]: ... + def as_ordered_factors(self, order=...): ... mul = ... -def prod(a, start=...) -> Any: - ... - -def expand_2arg(e): - ... +def prod(a, start=...) -> Any: ... +def expand_2arg(e): ... diff --git a/stubs/sympy-stubs/core/multidimensional.pyi b/stubs/sympy-stubs/core/multidimensional.pyi index cd876e9f..06c07b9b 100644 --- a/stubs/sympy-stubs/core/multidimensional.pyi +++ b/stubs/sympy-stubs/core/multidimensional.pyi @@ -1,21 +1,10 @@ from functools import _Wrapped from typing import Any, Callable -def apply_on_element(f, args, kwargs, n) -> list[list[Any] | Any]: - ... - -def iter_copy(structure) -> list[Any]: - ... - -def structure_copy(structure) -> list[Any]: - ... +def apply_on_element(f, args, kwargs, n) -> list[list[Any] | Any]: ... +def iter_copy(structure) -> list[Any]: ... +def structure_copy(structure) -> list[Any]: ... class vectorize: - def __init__(self, *mdargs) -> None: - ... - - def __call__(self, f) -> _Wrapped[..., Any, ..., list[list[Any] | Any] | Any]: - ... - - - + def __init__(self, *mdargs) -> None: ... + def __call__(self, f) -> _Wrapped[..., Any, ..., list[list[Any] | Any] | Any]: ... diff --git a/stubs/sympy-stubs/core/numbers.pyi b/stubs/sympy-stubs/core/numbers.pyi index 662edc15..f014f8e4 100644 --- a/stubs/sympy-stubs/core/numbers.pyi +++ b/stubs/sympy-stubs/core/numbers.pyi @@ -12,33 +12,34 @@ from sympy.external.gmpy import gmpy from sympy.series.order import Order _LOG2 = ... -def comp(z1, z2, tol=...) -> bool: - ... -def mpf_norm(mpf, prec) -> tuple[Literal[0], int | Any, Literal[0], Literal[0]] | tuple[Any, Any | Literal[1], Any, Any | Literal[1]]: - ... +def comp(z1, z2, tol=...) -> bool: ... +def mpf_norm( + mpf, prec +) -> tuple[Literal[0], int | Any, Literal[0], Literal[0]] | tuple[Any, Any | Literal[1], Any, Any | Literal[1]]: ... _errdict = ... -def seterr(divide=...) -> None: - ... + +def seterr(divide=...) -> None: ... _floatpat = ... + @lru_cache(1024) -def igcd(*args) -> int: - ... +def igcd(*args) -> int: ... igcd2 = ... -def igcd_lehmer(a, b) -> int: - ... - -def ilcm(*args) -> Literal[0]: - ... - -def igcdex(a, b) -> tuple[Literal[0], Literal[1], Literal[0]] | tuple[Literal[0], Any, Any] | tuple[Any, Literal[0], Any] | tuple[Literal[-1, 1, 0], Literal[0, -1, 1], Any]: - ... -def mod_inverse(a, m) -> int: - ... +def igcd_lehmer(a, b) -> int: ... +def ilcm(*args) -> Literal[0]: ... +def igcdex( + a, b +) -> ( + tuple[Literal[0], Literal[1], Literal[0]] + | tuple[Literal[0], Any, Any] + | tuple[Any, Literal[0], Any] + | tuple[Literal[-1, 1, 0], Literal[0, -1, 1], Any] +): ... +def mod_inverse(a, m) -> int: ... class Number(AtomicExpr): is_commutative = ... @@ -47,106 +48,47 @@ class Number(AtomicExpr): __slots__ = ... _prec = ... kind = ... - def __new__(cls, *obj) -> Number | Integer | Rational | Float: - ... - - def could_extract_minus_sign(self) -> bool: - ... - - def invert(self, other, *gens, **args) -> int | Any: - ... - - def __divmod__(self, other) -> tuple[Any, Any] | NotImplementedType | Tuple: - ... - - def __rdivmod__(self, other) -> NotImplementedType | tuple[Any, Any] | Tuple: - ... - - def __float__(self) -> float: - ... - - def floor(self): - ... - - def ceiling(self): - ... - - def __floor__(self): - ... - - def __ceil__(self): - ... - + def __new__(cls, *obj) -> Number | Integer | Rational | Float: ... + def could_extract_minus_sign(self) -> bool: ... + def invert(self, other, *gens, **args) -> int | Any: ... + def __divmod__(self, other) -> tuple[Any, Any] | NotImplementedType | Tuple: ... + def __rdivmod__(self, other) -> NotImplementedType | tuple[Any, Any] | Tuple: ... + def __float__(self) -> float: ... + def floor(self): ... + def ceiling(self): ... + def __floor__(self): ... + def __ceil__(self): ... @classmethod - def class_key(cls) -> tuple[Literal[1], Literal[0], Literal['Number']]: - ... - + def class_key(cls) -> tuple[Literal[1], Literal[0], Literal["Number"]]: ... @cacheit - def sort_key(self, order=...) -> tuple[tuple[Literal[1], Literal[0], Literal['Number']], tuple[Literal[0], tuple[()]], tuple[()], Self]: - ... - - @_sympifyit('other', NotImplemented) - def __add__(self, other): - ... - - @_sympifyit('other', NotImplemented) - def __sub__(self, other): - ... - - @_sympifyit('other', NotImplemented) - def __mul__(self, other) -> NotImplementedType: - ... - - @_sympifyit('other', NotImplemented) - def __truediv__(self, other): - ... - - def __eq__(self, other) -> bool: - ... - - def __ne__(self, other) -> bool: - ... - - def __lt__(self, other) -> bool: - ... - - def __le__(self, other) -> bool: - ... - - def __gt__(self, other) -> bool: - ... - - def __ge__(self, other) -> bool: - ... - - def __hash__(self) -> int: - ... - - def is_constant(self, *wrt, **flags) -> Literal[True]: - ... - - def as_coeff_mul(self, *deps, rational=..., **kwargs) -> tuple[Self, tuple[()]] | tuple[Any, tuple[Any | Mul]] | tuple[Any, tuple[Self]]: - ... - - def as_coeff_add(self, *deps) -> tuple[Self, tuple[()]] | tuple[Any, tuple[Self]]: - ... - - def as_coeff_Mul(self, rational=...) -> tuple[Any, Self] | tuple[Self, Any] | tuple[Any, Any]: - ... - - def as_coeff_Add(self, rational=...) -> tuple[Self, Any] | tuple[Any, Self]: - ... - - def gcd(self, other) -> Any: - ... - - def lcm(self, other) -> Any: - ... - - def cofactors(self, other) -> Any: - ... - - + def sort_key( + self, order=... + ) -> tuple[tuple[Literal[1], Literal[0], Literal["Number"]], tuple[Literal[0], tuple[()]], tuple[()], Self]: ... + @_sympifyit("other", NotImplemented) + def __add__(self, other): ... + @_sympifyit("other", NotImplemented) + def __sub__(self, other): ... + @_sympifyit("other", NotImplemented) + def __mul__(self, other) -> NotImplementedType: ... + @_sympifyit("other", NotImplemented) + def __truediv__(self, other): ... + def __eq__(self, other) -> bool: ... + def __ne__(self, other) -> bool: ... + def __lt__(self, other) -> bool: ... + def __le__(self, other) -> bool: ... + def __gt__(self, other) -> bool: ... + def __ge__(self, other) -> bool: ... + def __hash__(self) -> int: ... + def is_constant(self, *wrt, **flags) -> Literal[True]: ... + def as_coeff_mul( + self, *deps, rational=..., **kwargs + ) -> tuple[Self, tuple[()]] | tuple[Any, tuple[Any | Mul]] | tuple[Any, tuple[Self]]: ... + def as_coeff_add(self, *deps) -> tuple[Self, tuple[()]] | tuple[Any, tuple[Self]]: ... + def as_coeff_Mul(self, rational=...) -> tuple[Any, Self] | tuple[Self, Any] | tuple[Any, Any]: ... + def as_coeff_Add(self, rational=...) -> tuple[Self, Any] | tuple[Any, Self]: ... + def gcd(self, other) -> Any: ... + def lcm(self, other) -> Any: ... + def cofactors(self, other) -> Any: ... class Float(Number): __slots__ = ... @@ -157,94 +99,42 @@ class Float(Number): is_real = ... is_extended_real = ... is_Float = ... - def __new__(cls, num, dps=..., precision=...): - ... - - def __getnewargs_ex__(self) -> tuple[tuple[tuple[int, str, int, int]], dict[str, Any]]: - ... - - def floor(self) -> Integer: - ... - - def ceiling(self) -> Integer: - ... - - def __floor__(self) -> Integer: - ... - - def __ceil__(self) -> Integer: - ... - + def __new__(cls, num, dps=..., precision=...): ... + def __getnewargs_ex__(self) -> tuple[tuple[tuple[int, str, int, int]], dict[str, Any]]: ... + def floor(self) -> Integer: ... + def ceiling(self) -> Integer: ... + def __floor__(self) -> Integer: ... + def __ceil__(self) -> Integer: ... @property - def num(self): - ... - - def __bool__(self) -> bool: - ... - - def __neg__(self) -> Self | Float: - ... - - @_sympifyit('other', NotImplemented) - def __add__(self, other) -> Float: - ... - - @_sympifyit('other', NotImplemented) - def __sub__(self, other) -> Float: - ... - - @_sympifyit('other', NotImplemented) - def __mul__(self, other) -> Float | NotImplementedType: - ... - - @_sympifyit('other', NotImplemented) - def __truediv__(self, other) -> Float: - ... - - @_sympifyit('other', NotImplemented) - def __mod__(self, other) -> Float: - ... - - @_sympifyit('other', NotImplemented) - def __rmod__(self, other) -> Float: - ... - - def __abs__(self) -> Float: - ... - - def __int__(self) -> int: - ... - - def __eq__(self, other) -> bool: - ... - - def __ne__(self, other) -> bool: - ... - - def __gt__(self, other) -> bool: - ... - - def __ge__(self, other) -> bool: - ... - - def __lt__(self, other) -> bool: - ... - - def __le__(self, other) -> bool: - ... - - def __hash__(self) -> int: - ... - - def epsilon_eq(self, other, epsilon=...): - ... - - def __format__(self, format_spec) -> str: - ... - - + def num(self): ... + def __bool__(self) -> bool: ... + def __neg__(self) -> Self | Float: ... + @_sympifyit("other", NotImplemented) + def __add__(self, other) -> Float: ... + @_sympifyit("other", NotImplemented) + def __sub__(self, other) -> Float: ... + @_sympifyit("other", NotImplemented) + def __mul__(self, other) -> Float | NotImplementedType: ... + @_sympifyit("other", NotImplemented) + def __truediv__(self, other) -> Float: ... + @_sympifyit("other", NotImplemented) + def __mod__(self, other) -> Float: ... + @_sympifyit("other", NotImplemented) + def __rmod__(self, other) -> Float: ... + def __abs__(self) -> Float: ... + def __int__(self) -> int: ... + def __eq__(self, other) -> bool: ... + def __ne__(self, other) -> bool: ... + def __gt__(self, other) -> bool: ... + def __ge__(self, other) -> bool: ... + def __lt__(self, other) -> bool: ... + def __le__(self, other) -> bool: ... + def __hash__(self) -> int: ... + def epsilon_eq(self, other, epsilon=...): ... + def __format__(self, format_spec) -> str: ... RealNumber = Float + class Rational(Number): is_real = ... is_integer = ... @@ -255,123 +145,60 @@ class Rational(Number): q: int is_Rational = ... @cacheit - def __new__(cls, p, q=..., gcd=...) -> Rational | Integer | Self: - ... - - def limit_denominator(self, max_denominator=...) -> Rational: - ... - - def __getnewargs__(self) -> tuple[int, int]: - ... - - def __neg__(self) -> Rational | Integer: - ... - - @_sympifyit('other', NotImplemented) - def __add__(self, other) -> Rational | Integer | Float: - ... - + def __new__(cls, p, q=..., gcd=...) -> Rational | Integer | Self: ... + def limit_denominator(self, max_denominator=...) -> Rational: ... + def __getnewargs__(self) -> tuple[int, int]: ... + def __neg__(self) -> Rational | Integer: ... + @_sympifyit("other", NotImplemented) + def __add__(self, other) -> Rational | Integer | Float: ... + __radd__ = ... - @_sympifyit('other', NotImplemented) - def __sub__(self, other) -> Rational | Integer | Float: - ... - - @_sympifyit('other', NotImplemented) - def __rsub__(self, other) -> Rational | Integer | Float | Order: - ... - - @_sympifyit('other', NotImplemented) - def __mul__(self, other) -> Rational | Integer | Float | NotImplementedType: - ... - + @_sympifyit("other", NotImplemented) + def __sub__(self, other) -> Rational | Integer | Float: ... + @_sympifyit("other", NotImplemented) + def __rsub__(self, other) -> Rational | Integer | Float | Order: ... + @_sympifyit("other", NotImplemented) + def __mul__(self, other) -> Rational | Integer | Float | NotImplementedType: ... + __rmul__ = ... - @_sympifyit('other', NotImplemented) - def __truediv__(self, other) -> Rational | Integer: - ... - - @_sympifyit('other', NotImplemented) - def __rtruediv__(self, other) -> Rational | Integer: - ... - - @_sympifyit('other', NotImplemented) - def __mod__(self, other) -> Rational | Integer | Float: - ... - - @_sympifyit('other', NotImplemented) - def __rmod__(self, other) -> Rational | Integer | Float: - ... - - def __abs__(self) -> Rational | Integer: - ... - - def __int__(self) -> int: - ... - - def floor(self) -> Integer: - ... - - def ceiling(self) -> Integer: - ... - - def __floor__(self) -> Integer: - ... - - def __ceil__(self) -> Integer: - ... - - def __eq__(self, other) -> bool: - ... - - def __ne__(self, other) -> bool: - ... - - def __gt__(self, other) -> bool: - ... - - def __ge__(self, other) -> bool: - ... - - def __lt__(self, other) -> bool: - ... - - def __le__(self, other) -> bool: - ... - - def __hash__(self) -> int: - ... - - def factors(self, limit=..., use_trial=..., use_rho=..., use_pm1=..., verbose=..., visual=...) -> Order | dict[Any, int] | list[Any]: - ... - + @_sympifyit("other", NotImplemented) + def __truediv__(self, other) -> Rational | Integer: ... + @_sympifyit("other", NotImplemented) + def __rtruediv__(self, other) -> Rational | Integer: ... + @_sympifyit("other", NotImplemented) + def __mod__(self, other) -> Rational | Integer | Float: ... + @_sympifyit("other", NotImplemented) + def __rmod__(self, other) -> Rational | Integer | Float: ... + def __abs__(self) -> Rational | Integer: ... + def __int__(self) -> int: ... + def floor(self) -> Integer: ... + def ceiling(self) -> Integer: ... + def __floor__(self) -> Integer: ... + def __ceil__(self) -> Integer: ... + def __eq__(self, other) -> bool: ... + def __ne__(self, other) -> bool: ... + def __gt__(self, other) -> bool: ... + def __ge__(self, other) -> bool: ... + def __lt__(self, other) -> bool: ... + def __le__(self, other) -> bool: ... + def __hash__(self) -> int: ... + def factors( + self, limit=..., use_trial=..., use_rho=..., use_pm1=..., verbose=..., visual=... + ) -> Order | dict[Any, int] | list[Any]: ... @property - def numerator(self) -> int: - ... - + def numerator(self) -> int: ... @property - def denominator(self) -> int: - ... - - @_sympifyit('other', NotImplemented) - def gcd(self, other) -> Rational | Integer | Any: - ... - - @_sympifyit('other', NotImplemented) - def lcm(self, other) -> Rational | Integer | Any: - ... - - def as_numer_denom(self) -> tuple[Any | Integer, Any | Integer]: - ... - - def as_content_primitive(self, radical=..., clear=...) -> tuple[Self, Any] | tuple[Rational | Any | Integer, Any] | tuple[Any, Any]: - ... - - def as_coeff_Mul(self, rational=...) -> tuple[Self, Any]: - ... - - def as_coeff_Add(self, rational=...) -> tuple[Self, Any]: - ... - - + def denominator(self) -> int: ... + @_sympifyit("other", NotImplemented) + def gcd(self, other) -> Rational | Integer | Any: ... + @_sympifyit("other", NotImplemented) + def lcm(self, other) -> Rational | Integer | Any: ... + def as_numer_denom(self) -> tuple[Any | Integer, Any | Integer]: ... + def as_content_primitive( + self, radical=..., clear=... + ) -> tuple[Self, Any] | tuple[Rational | Any | Integer, Any] | tuple[Any, Any]: ... + def as_coeff_Mul(self, rational=...) -> tuple[Self, Any]: ... + def as_coeff_Add(self, rational=...) -> tuple[Self, Any]: ... class Integer(Rational): q = ... @@ -380,131 +207,48 @@ class Integer(Rational): is_Integer = ... __slots__ = ... @cacheit - def __new__(cls, i) -> Self: - ... - - def __getnewargs__(self) -> tuple[int]: - ... - - def __int__(self) -> int: - ... - - def floor(self) -> Integer: - ... - - def ceiling(self) -> Integer: - ... - - def __floor__(self) -> Integer: - ... - - def __ceil__(self) -> Integer: - ... - - def __neg__(self) -> Integer: - ... - - def __abs__(self) -> Self | Integer: - ... - - def __divmod__(self, other) -> Tuple | tuple[Any, Any] | NotImplementedType: - ... - - def __rdivmod__(self, other) -> Tuple | tuple[Any, Any] | NotImplementedType: - ... - - def __add__(self, other) -> Integer | Rational | Float | Order: - ... - - def __radd__(self, other) -> Integer | Rational: - ... - - def __sub__(self, other) -> Integer | Rational | Float: - ... - - def __rsub__(self, other) -> Integer | Rational | Float | Order: - ... - - def __mul__(self, other) -> Integer | Rational | Float | NotImplementedType: - ... - - def __rmul__(self, other) -> Integer | Rational: - ... - - def __mod__(self, other) -> Integer | Rational | Float: - ... - - def __rmod__(self, other) -> Integer | Rational | Float: - ... - - def __eq__(self, other) -> bool: - ... - - def __ne__(self, other) -> bool: - ... - - def __gt__(self, other) -> bool: - ... - - def __lt__(self, other) -> bool: - ... - - def __ge__(self, other) -> bool: - ... - - def __le__(self, other) -> bool: - ... - - def __hash__(self) -> int: - ... - - def __index__(self) -> int: - ... - - def as_numer_denom(self) -> tuple[Self, Any]: - ... - - @_sympifyit('other', NotImplemented) - def __floordiv__(self, other) -> NotImplementedType | Integer | Tuple: - ... - - def __rfloordiv__(self, other) -> Integer: - ... - - def __lshift__(self, other) -> Integer | NotImplementedType: - ... - - def __rlshift__(self, other) -> Integer | NotImplementedType: - ... - - def __rshift__(self, other) -> Integer | NotImplementedType: - ... - - def __rrshift__(self, other) -> Integer | NotImplementedType: - ... - - def __and__(self, other) -> Integer | NotImplementedType: - ... - - def __rand__(self, other) -> Integer | NotImplementedType: - ... - - def __xor__(self, other) -> Integer | NotImplementedType: - ... - - def __rxor__(self, other) -> Integer | NotImplementedType: - ... - - def __or__(self, other) -> Integer | NotImplementedType: - ... - - def __ror__(self, other) -> Integer | NotImplementedType: - ... - - def __invert__(self) -> Integer: - ... - - + def __new__(cls, i) -> Self: ... + def __getnewargs__(self) -> tuple[int]: ... + def __int__(self) -> int: ... + def floor(self) -> Integer: ... + def ceiling(self) -> Integer: ... + def __floor__(self) -> Integer: ... + def __ceil__(self) -> Integer: ... + def __neg__(self) -> Integer: ... + def __abs__(self) -> Self | Integer: ... + def __divmod__(self, other) -> Tuple | tuple[Any, Any] | NotImplementedType: ... + def __rdivmod__(self, other) -> Tuple | tuple[Any, Any] | NotImplementedType: ... + def __add__(self, other) -> Integer | Rational | Float | Order: ... + def __radd__(self, other) -> Integer | Rational: ... + def __sub__(self, other) -> Integer | Rational | Float: ... + def __rsub__(self, other) -> Integer | Rational | Float | Order: ... + def __mul__(self, other) -> Integer | Rational | Float | NotImplementedType: ... + def __rmul__(self, other) -> Integer | Rational: ... + def __mod__(self, other) -> Integer | Rational | Float: ... + def __rmod__(self, other) -> Integer | Rational | Float: ... + def __eq__(self, other) -> bool: ... + def __ne__(self, other) -> bool: ... + def __gt__(self, other) -> bool: ... + def __lt__(self, other) -> bool: ... + def __ge__(self, other) -> bool: ... + def __le__(self, other) -> bool: ... + def __hash__(self) -> int: ... + def __index__(self) -> int: ... + def as_numer_denom(self) -> tuple[Self, Any]: ... + @_sympifyit("other", NotImplemented) + def __floordiv__(self, other) -> NotImplementedType | Integer | Tuple: ... + def __rfloordiv__(self, other) -> Integer: ... + def __lshift__(self, other) -> Integer | NotImplementedType: ... + def __rlshift__(self, other) -> Integer | NotImplementedType: ... + def __rshift__(self, other) -> Integer | NotImplementedType: ... + def __rrshift__(self, other) -> Integer | NotImplementedType: ... + def __and__(self, other) -> Integer | NotImplementedType: ... + def __rand__(self, other) -> Integer | NotImplementedType: ... + def __xor__(self, other) -> Integer | NotImplementedType: ... + def __rxor__(self, other) -> Integer | NotImplementedType: ... + def __or__(self, other) -> Integer | NotImplementedType: ... + def __ror__(self, other) -> Integer | NotImplementedType: ... + def __invert__(self) -> Integer: ... class AlgebraicNumber(Expr): __slots__ = ... @@ -513,65 +257,30 @@ class AlgebraicNumber(Expr): is_number = ... kind = ... free_symbols: set[Basic] = ... - def __new__(cls, expr, coeffs=..., alias=..., **args) -> Self: - ... - - def __hash__(self) -> int: - ... - + def __new__(cls, expr, coeffs=..., alias=..., **args) -> Self: ... + def __hash__(self) -> int: ... @property - def is_aliased(self) -> bool: - ... - - def as_poly(self, x=...): - ... - - def as_expr(self, x=...): - ... - - def coeffs(self) -> list[Any]: - ... - - def native_coeffs(self): - ... - - def to_algebraic_integer(self) -> Self | AlgebraicNumber: - ... - - def field_element(self, coeffs) -> AlgebraicNumber: - ... - + def is_aliased(self) -> bool: ... + def as_poly(self, x=...): ... + def as_expr(self, x=...): ... + def coeffs(self) -> list[Any]: ... + def native_coeffs(self): ... + def to_algebraic_integer(self) -> Self | AlgebraicNumber: ... + def field_element(self, coeffs) -> AlgebraicNumber: ... @property - def is_primitive_element(self) -> bool: - ... - - def primitive_element(self) -> Self | AlgebraicNumber: - ... - - def to_primitive_element(self, radicals=...) -> Self | AlgebraicNumber: - ... - - def minpoly_of_element(self) -> Any: - ... - - def to_root(self, radicals=..., minpoly=...) -> Any | None: - ... - - + def is_primitive_element(self) -> bool: ... + def primitive_element(self) -> Self | AlgebraicNumber: ... + def to_primitive_element(self, radicals=...) -> Self | AlgebraicNumber: ... + def minpoly_of_element(self) -> Any: ... + def to_root(self, radicals=..., minpoly=...) -> Any | None: ... class RationalConstant(Rational): __slots__ = ... - def __new__(cls) -> Self: - ... - - + def __new__(cls) -> Self: ... class IntegerConstant(Integer): __slots__ = ... - def __new__(cls) -> Self: - ... - - + def __new__(cls) -> Self: ... class Zero(IntegerConstant, metaclass=Singleton): p = ... @@ -582,21 +291,12 @@ class Zero(IntegerConstant, metaclass=Singleton): is_number = ... is_comparable = ... __slots__ = ... - def __getnewargs__(self) -> tuple[()]: - ... - + def __getnewargs__(self) -> tuple[()]: ... @staticmethod - def __abs__(): - ... - + def __abs__(): ... @staticmethod - def __neg__(): - ... - - def __bool__(self) -> Literal[False]: - ... - - + def __neg__(): ... + def __bool__(self) -> Literal[False]: ... class One(IntegerConstant, metaclass=Singleton): is_number = ... @@ -604,54 +304,33 @@ class One(IntegerConstant, metaclass=Singleton): p = ... q = ... __slots__ = ... - def __getnewargs__(self) -> tuple[()]: - ... - + def __getnewargs__(self) -> tuple[()]: ... @staticmethod - def __abs__(): - ... - + def __abs__(): ... @staticmethod - def __neg__(): - ... - + def __neg__(): ... @staticmethod - def factors(limit=..., use_trial=..., use_rho=..., use_pm1=..., verbose=..., visual=...) -> dict[Any, Any]: - ... - - + def factors(limit=..., use_trial=..., use_rho=..., use_pm1=..., verbose=..., visual=...) -> dict[Any, Any]: ... class NegativeOne(IntegerConstant, metaclass=Singleton): is_number = ... p = ... q = ... __slots__ = ... - def __getnewargs__(self) -> tuple[()]: - ... - + def __getnewargs__(self) -> tuple[()]: ... @staticmethod - def __abs__(): - ... - + def __abs__(): ... @staticmethod - def __neg__(): - ... - - + def __neg__(): ... class Half(RationalConstant, metaclass=Singleton): is_number = ... p = ... q = ... __slots__ = ... - def __getnewargs__(self) -> tuple[()]: - ... - + def __getnewargs__(self) -> tuple[()]: ... @staticmethod - def __abs__(): - ... - - + def __abs__(): ... class Infinity(Number, metaclass=Singleton): is_commutative = ... @@ -663,67 +342,41 @@ class Infinity(Number, metaclass=Singleton): is_extended_positive = ... is_prime = ... __slots__ = ... - def __new__(cls) -> Self: - ... - - def evalf(self, prec=..., **options) -> Float: - ... - - @_sympifyit('other', NotImplemented) - def __add__(self, other) -> Self: - ... - + def __new__(cls) -> Self: ... + def evalf(self, prec=..., **options) -> Float: ... + @_sympifyit("other", NotImplemented) + def __add__(self, other) -> Self: ... + __radd__ = ... - @_sympifyit('other', NotImplemented) - def __sub__(self, other) -> Self: - ... - - @_sympifyit('other', NotImplemented) - def __rsub__(self, other): - ... - - @_sympifyit('other', NotImplemented) - def __mul__(self, other) -> Self | NotImplementedType: - ... - + @_sympifyit("other", NotImplemented) + def __sub__(self, other) -> Self: ... + @_sympifyit("other", NotImplemented) + def __rsub__(self, other): ... + @_sympifyit("other", NotImplemented) + def __mul__(self, other) -> Self | NotImplementedType: ... + __rmul__ = ... - @_sympifyit('other', NotImplemented) - def __truediv__(self, other) -> Self: - ... - - def __abs__(self): - ... - - def __neg__(self): - ... - - def __hash__(self) -> int: - ... - - def __eq__(self, other) -> bool: - ... - - def __ne__(self, other) -> bool: - ... - + @_sympifyit("other", NotImplemented) + def __truediv__(self, other) -> Self: ... + def __abs__(self): ... + def __neg__(self): ... + def __hash__(self) -> int: ... + def __eq__(self, other) -> bool: ... + def __ne__(self, other) -> bool: ... + __gt__ = ... __ge__ = ... __lt__ = ... __le__ = ... - @_sympifyit('other', NotImplemented) - def __mod__(self, other) -> NotImplementedType: - ... - - __rmod__ = ... - def floor(self) -> Self: - ... - - def ceiling(self) -> Self: - ... - + @_sympifyit("other", NotImplemented) + def __mod__(self, other) -> NotImplementedType: ... + __rmod__ = ... + def floor(self) -> Self: ... + def ceiling(self) -> Self: ... oo = ... + class NegativeInfinity(Number, metaclass=Singleton): is_extended_real = ... is_complex = ... @@ -734,68 +387,39 @@ class NegativeInfinity(Number, metaclass=Singleton): is_number = ... is_prime = ... __slots__ = ... - def __new__(cls) -> Self: - ... - - def evalf(self, prec=..., **options) -> Float: - ... - - @_sympifyit('other', NotImplemented) - def __add__(self, other) -> Self: - ... - + def __new__(cls) -> Self: ... + def evalf(self, prec=..., **options) -> Float: ... + @_sympifyit("other", NotImplemented) + def __add__(self, other) -> Self: ... + __radd__ = ... - @_sympifyit('other', NotImplemented) - def __sub__(self, other) -> Self: - ... - - @_sympifyit('other', NotImplemented) - def __rsub__(self, other): - ... - - @_sympifyit('other', NotImplemented) - def __mul__(self, other) -> Self | NotImplementedType: - ... - + @_sympifyit("other", NotImplemented) + def __sub__(self, other) -> Self: ... + @_sympifyit("other", NotImplemented) + def __rsub__(self, other): ... + @_sympifyit("other", NotImplemented) + def __mul__(self, other) -> Self | NotImplementedType: ... + __rmul__ = ... - @_sympifyit('other', NotImplemented) - def __truediv__(self, other) -> Self: - ... - - def __abs__(self): - ... - - def __neg__(self): - ... - - def __hash__(self) -> int: - ... - - def __eq__(self, other) -> bool: - ... - - def __ne__(self, other) -> bool: - ... - + @_sympifyit("other", NotImplemented) + def __truediv__(self, other) -> Self: ... + def __abs__(self): ... + def __neg__(self): ... + def __hash__(self) -> int: ... + def __eq__(self, other) -> bool: ... + def __ne__(self, other) -> bool: ... + __gt__ = ... __ge__ = ... __lt__ = ... __le__ = ... - @_sympifyit('other', NotImplemented) - def __mod__(self, other) -> NotImplementedType: - ... - - __rmod__ = ... - def floor(self) -> Self: - ... - - def ceiling(self) -> Self: - ... - - def as_powers_dict(self) -> dict[Any, int]: - ... - + @_sympifyit("other", NotImplemented) + def __mod__(self, other) -> NotImplementedType: ... + __rmod__ = ... + def floor(self) -> Self: ... + def ceiling(self) -> Self: ... + def as_powers_dict(self) -> dict[Any, int]: ... class NaN(Number, metaclass=Singleton): is_commutative = ... @@ -813,50 +437,29 @@ class NaN(Number, metaclass=Singleton): is_negative = ... is_number = ... __slots__ = ... - def __new__(cls) -> Self: - ... - - def __neg__(self) -> Self: - ... - - @_sympifyit('other', NotImplemented) - def __add__(self, other) -> Self: - ... - - @_sympifyit('other', NotImplemented) - def __sub__(self, other) -> Self: - ... - - @_sympifyit('other', NotImplemented) - def __mul__(self, other) -> Self: - ... - - @_sympifyit('other', NotImplemented) - def __truediv__(self, other) -> Self: - ... - - def floor(self) -> Self: - ... - - def ceiling(self) -> Self: - ... - - def __hash__(self) -> int: - ... - - def __eq__(self, other) -> bool: - ... - - def __ne__(self, other) -> bool: - ... - + def __new__(cls) -> Self: ... + def __neg__(self) -> Self: ... + @_sympifyit("other", NotImplemented) + def __add__(self, other) -> Self: ... + @_sympifyit("other", NotImplemented) + def __sub__(self, other) -> Self: ... + @_sympifyit("other", NotImplemented) + def __mul__(self, other) -> Self: ... + @_sympifyit("other", NotImplemented) + def __truediv__(self, other) -> Self: ... + def floor(self) -> Self: ... + def ceiling(self) -> Self: ... + def __hash__(self) -> int: ... + def __eq__(self, other) -> bool: ... + def __ne__(self, other) -> bool: ... + __gt__ = ... __ge__ = ... __lt__ = ... __le__ = ... - nan = ... + class ComplexInfinity(AtomicExpr, metaclass=Singleton): is_commutative = ... is_infinite = ... @@ -866,26 +469,16 @@ class ComplexInfinity(AtomicExpr, metaclass=Singleton): is_extended_real = ... kind = ... __slots__ = ... - def __new__(cls) -> Self: - ... - + def __new__(cls) -> Self: ... @staticmethod - def __abs__(): - ... - - def floor(self) -> Self: - ... - - def ceiling(self) -> Self: - ... - + def __abs__(): ... + def floor(self) -> Self: ... + def ceiling(self) -> Self: ... @staticmethod - def __neg__(): - ... - - + def __neg__(): ... zoo = ... + class NumberSymbol(AtomicExpr): is_commutative = ... is_finite = ... @@ -893,31 +486,14 @@ class NumberSymbol(AtomicExpr): __slots__ = ... is_NumberSymbol = ... kind = ... - def __new__(cls) -> Self: - ... - - def approximation(self, number_cls) -> None: - ... - - def __eq__(self, other) -> bool: - ... - - def __ne__(self, other) -> bool: - ... - - def __le__(self, other) -> bool: - ... - - def __ge__(self, other) -> bool: - ... - - def __int__(self) -> int: - ... - - def __hash__(self) -> int: - ... - - + def __new__(cls) -> Self: ... + def approximation(self, number_cls) -> None: ... + def __eq__(self, other) -> bool: ... + def __ne__(self, other) -> bool: ... + def __le__(self, other) -> bool: ... + def __ge__(self, other) -> bool: ... + def __int__(self) -> int: ... + def __hash__(self) -> int: ... class Exp1(NumberSymbol, metaclass=Singleton): is_real = ... @@ -929,18 +505,12 @@ class Exp1(NumberSymbol, metaclass=Singleton): is_transcendental = ... __slots__ = ... @staticmethod - def __abs__(): - ... - - def __int__(self) -> int: - ... - - def approximation_interval(self, number_cls) -> tuple[Any | Integer, Any | Integer] | None: - ... - - + def __abs__(): ... + def __int__(self) -> int: ... + def approximation_interval(self, number_cls) -> tuple[Any | Integer, Any | Integer] | None: ... E = ... + class Pi(NumberSymbol, metaclass=Singleton): is_real = ... is_positive = ... @@ -951,18 +521,14 @@ class Pi(NumberSymbol, metaclass=Singleton): is_transcendental = ... __slots__ = ... @staticmethod - def __abs__(): - ... - - def __int__(self) -> int: - ... - - def approximation_interval(self, number_cls) -> tuple[Any | Integer, Any | Integer] | tuple[Rational | Any | Integer, Rational | Any | Integer] | None: - ... - - + def __abs__(): ... + def __int__(self) -> int: ... + def approximation_interval( + self, number_cls + ) -> tuple[Any | Integer, Any | Integer] | tuple[Rational | Any | Integer, Rational | Any | Integer] | None: ... pi = ... + class GoldenRatio(NumberSymbol, metaclass=Singleton): is_real = ... is_positive = ... @@ -972,14 +538,10 @@ class GoldenRatio(NumberSymbol, metaclass=Singleton): is_algebraic = ... is_transcendental = ... __slots__ = ... - def __int__(self) -> int: - ... - - def approximation_interval(self, number_cls) -> tuple[Any, Rational | Any | Integer] | None: - ... - - _eval_rewrite_as_sqrt = ... + def __int__(self) -> int: ... + def approximation_interval(self, number_cls) -> tuple[Any, Rational | Any | Integer] | None: ... + _eval_rewrite_as_sqrt = ... class TribonacciConstant(NumberSymbol, metaclass=Singleton): is_real = ... @@ -990,14 +552,10 @@ class TribonacciConstant(NumberSymbol, metaclass=Singleton): is_algebraic = ... is_transcendental = ... __slots__ = ... - def __int__(self) -> int: - ... - - def approximation_interval(self, number_cls) -> tuple[Any, Rational | Any | Integer] | None: - ... - - _eval_rewrite_as_sqrt = ... + def __int__(self) -> int: ... + def approximation_interval(self, number_cls) -> tuple[Any, Rational | Any | Integer] | None: ... + _eval_rewrite_as_sqrt = ... class EulerGamma(NumberSymbol, metaclass=Singleton): is_real = ... @@ -1006,13 +564,8 @@ class EulerGamma(NumberSymbol, metaclass=Singleton): is_irrational = ... is_number = ... __slots__ = ... - def __int__(self) -> int: - ... - - def approximation_interval(self, number_cls) -> tuple[Any, Any] | tuple[Any, Rational | Any | Integer] | None: - ... - - + def __int__(self) -> int: ... + def approximation_interval(self, number_cls) -> tuple[Any, Any] | tuple[Any, Rational | Any | Integer] | None: ... class Catalan(NumberSymbol, metaclass=Singleton): is_real = ... @@ -1021,13 +574,8 @@ class Catalan(NumberSymbol, metaclass=Singleton): is_irrational = ... is_number = ... __slots__ = ... - def __int__(self) -> int: - ... - - def approximation_interval(self, number_cls) -> tuple[Any, Any] | tuple[Rational | Any | Integer, Any] | None: - ... - - + def __int__(self) -> int: ... + def approximation_interval(self, number_cls) -> tuple[Any, Any] | tuple[Rational | Any | Integer, Any] | None: ... class ImaginaryUnit(AtomicExpr, metaclass=Singleton): is_commutative = ... @@ -1039,34 +587,17 @@ class ImaginaryUnit(AtomicExpr, metaclass=Singleton): kind = ... __slots__ = ... @staticmethod - def __abs__(): - ... - - def as_base_exp(self) -> tuple[Any, Any]: - ... - - + def __abs__(): ... + def as_base_exp(self) -> tuple[Any, Any]: ... I = ... -def equal_valued(x, y) -> Literal[False]: - ... - -def sympify_fractions(f) -> Rational | Integer: - ... - -def sympify_mpz(x) -> Integer: - ... - -def sympify_mpq(x) -> Rational | Integer: - ... - -def sympify_mpmath_mpq(x) -> Rational | Integer: - ... - -def sympify_mpmath(x) -> Float: - ... -def sympify_complex(a): - ... +def equal_valued(x, y) -> Literal[False]: ... +def sympify_fractions(f) -> Rational | Integer: ... +def sympify_mpz(x) -> Integer: ... +def sympify_mpq(x) -> Rational | Integer: ... +def sympify_mpmath_mpq(x) -> Rational | Integer: ... +def sympify_mpmath(x) -> Float: ... +def sympify_complex(a): ... _illegal = ... diff --git a/stubs/sympy-stubs/core/operations.pyi b/stubs/sympy-stubs/core/operations.pyi index 2ecc1880..a45f4021 100644 --- a/stubs/sympy-stubs/core/operations.pyi +++ b/stubs/sympy-stubs/core/operations.pyi @@ -8,58 +8,28 @@ class AssocOp(Basic): __slots__: tuple[str, ...] = ... _args_type: type[Basic] | None = ... @cacheit - def __new__(cls, *args, evaluate=..., _sympify=...) -> Order: - ... - + def __new__(cls, *args, evaluate=..., _sympify=...) -> Order: ... @classmethod - def flatten(cls, seq) -> tuple[list[Any], list[Any], None]: - ... - + def flatten(cls, seq) -> tuple[list[Any], list[Any], None]: ... @classmethod - def make_args(cls, expr) -> tuple[Basic, ...] | tuple[Any]: - ... - - def doit(self, **hints) -> Self: - ... - - - -class ShortCircuit(Exception): - ... + def make_args(cls, expr) -> tuple[Basic, ...] | tuple[Any]: ... + def doit(self, **hints) -> Self: ... +class ShortCircuit(Exception): ... class LatticeOp(AssocOp): is_commutative = ... - def __new__(cls, *args, **options) -> Self: - ... - + def __new__(cls, *args, **options) -> Self: ... @classmethod - def make_args(cls, expr) -> frozenset[Any]: - ... - - + def make_args(cls, expr) -> frozenset[Any]: ... class AssocOpDispatcher: - def __init__(self, name, doc=...) -> None: - ... - - def __repr__(self) -> LiteralString: - ... - - def register_handlerclass(self, classes, typ, on_ambiguity=...) -> None: - ... - + def __init__(self, name, doc=...) -> None: ... + def __repr__(self) -> LiteralString: ... + def register_handlerclass(self, classes, typ, on_ambiguity=...) -> None: ... @cacheit - def __call__(self, *args, _sympify=..., **kwargs) -> Any: - ... - + def __call__(self, *args, _sympify=..., **kwargs) -> Any: ... @cacheit - def dispatch(self, handlers) -> type: - ... - + def dispatch(self, handlers) -> type: ... @property - def __doc__(self) -> str: - ... - - - + def __doc__(self) -> str: ... diff --git a/stubs/sympy-stubs/core/parameters.pyi b/stubs/sympy-stubs/core/parameters.pyi index f0b2aa23..888d0725 100644 --- a/stubs/sympy-stubs/core/parameters.pyi +++ b/stubs/sympy-stubs/core/parameters.pyi @@ -3,20 +3,12 @@ from threading import local from typing import Any, Generator class _global_parameters(local): - def __init__(self, **kwargs) -> None: - ... - - def __setattr__(self, name, value) -> None: - ... - - + def __init__(self, **kwargs) -> None: ... + def __setattr__(self, name, value) -> None: ... global_parameters = ... -@contextmanager -def evaluate(x) -> Generator[None, Any, None]: - ... @contextmanager -def distribute(x) -> Generator[None, Any, None]: - ... - +def evaluate(x) -> Generator[None, Any, None]: ... +@contextmanager +def distribute(x) -> Generator[None, Any, None]: ... diff --git a/stubs/sympy-stubs/core/power.pyi b/stubs/sympy-stubs/core/power.pyi index bca1e4fc..86e7e922 100644 --- a/stubs/sympy-stubs/core/power.pyi +++ b/stubs/sympy-stubs/core/power.pyi @@ -10,14 +10,11 @@ from sympy.core.numbers import Number from sympy.functions.elementary.exponential import log from sympy.series.order import Order -def isqrt(n) -> int: - ... - -def integer_nthroot(y, n) -> tuple[int, bool] | tuple[Any, Literal[True]] | tuple[Literal[1], Literal[False]] | tuple[int, Any]: - ... - -def integer_log(y, x) -> tuple[int, Any] | tuple[Any, Any | bool] | tuple[int, bool]: - ... +def isqrt(n) -> int: ... +def integer_nthroot( + y, n +) -> tuple[int, bool] | tuple[Any, Literal[True]] | tuple[Literal[1], Literal[False]] | tuple[int, Any]: ... +def integer_log(y, x) -> tuple[int, Any] | tuple[Any, Any | bool] | tuple[int, bool]: ... class Pow(Expr): is_Pow = ... @@ -25,49 +22,33 @@ class Pow(Expr): args: tuple[Expr, Expr] _args: tuple[Expr, Expr] @cacheit - def __new__(cls, b, e, evaluate=...): - ... - - def inverse(self, argindex=...) -> type[log] | None: - ... - + def __new__(cls, b, e, evaluate=...): ... + def inverse(self, argindex=...) -> type[log] | None: ... @property - def base(self) -> Expr: - ... - + def base(self) -> Expr: ... @property - def exp(self) -> Expr: - ... - + def exp(self) -> Expr: ... @property - def kind(self) -> Kind | _UndefinedKind: - ... - + def kind(self) -> Kind | _UndefinedKind: ... @classmethod - def class_key(cls) -> tuple[Literal[3], Literal[2], str]: - ... - - def as_base_exp(self) -> tuple[Any, Any | Mul] | tuple[Expr, Expr]: - ... - - def as_real_imag(self, deep=..., **hints) -> tuple[Self, Any] | tuple[Any | Order | Basic, Any] | tuple[Any, Any | Expr] | tuple[Any, Any] | tuple[type[UndefinedFunction] | Any, type[UndefinedFunction] | Any] | None: - ... - - def as_numer_denom(self) -> tuple[Self, Any] | tuple[Any | Mul | Expr, Self] | tuple[Self, Any | Mul | Expr] | tuple[Self, Self]: - ... - - def matches(self, expr, repl_dict=..., old=...) -> dict[Any, Any] | None: - ... - - def taylor_term(self, n, x, *previous_terms): - ... - - def as_content_primitive(self, radical=..., clear=...) -> tuple[Self, Self] | tuple[Number, Self] | tuple[Any, Self]: - ... - - def is_constant(self, *wrt, **flags) -> bool | None: - ... - - + def class_key(cls) -> tuple[Literal[3], Literal[2], str]: ... + def as_base_exp(self) -> tuple[Any, Any | Mul] | tuple[Expr, Expr]: ... + def as_real_imag( + self, deep=..., **hints + ) -> ( + tuple[Self, Any] + | tuple[Any | Order | Basic, Any] + | tuple[Any, Any | Expr] + | tuple[Any, Any] + | tuple[type[UndefinedFunction] | Any, type[UndefinedFunction] | Any] + | None + ): ... + def as_numer_denom( + self, + ) -> tuple[Self, Any] | tuple[Any | Mul | Expr, Self] | tuple[Self, Any | Mul | Expr] | tuple[Self, Self]: ... + def matches(self, expr, repl_dict=..., old=...) -> dict[Any, Any] | None: ... + def taylor_term(self, n, x, *previous_terms): ... + def as_content_primitive(self, radical=..., clear=...) -> tuple[Self, Self] | tuple[Number, Self] | tuple[Any, Self]: ... + def is_constant(self, *wrt, **flags) -> bool | None: ... power = ... diff --git a/stubs/sympy-stubs/core/random.pyi b/stubs/sympy-stubs/core/random.pyi index 5b9a9708..0994bf82 100644 --- a/stubs/sympy-stubs/core/random.pyi +++ b/stubs/sympy-stubs/core/random.pyi @@ -1,4 +1,3 @@ - rng = ... choice = ... random = ... @@ -9,15 +8,8 @@ shuffle = ... uniform = ... _assumptions_rng = ... _assumptions_shuffle = ... -def seed(a=..., version=...) -> None: - ... - -def random_complex_number(a=..., b=..., c=..., d=..., rational=..., tolerance=...): - ... - -def verify_numerically(f, g, z=..., tol=..., a=..., b=..., c=..., d=...) -> bool: - ... - -def test_derivative_numerically(f, z, tol=..., a=..., b=..., c=..., d=...) -> bool: - ... +def seed(a=..., version=...) -> None: ... +def random_complex_number(a=..., b=..., c=..., d=..., rational=..., tolerance=...): ... +def verify_numerically(f, g, z=..., tol=..., a=..., b=..., c=..., d=...) -> bool: ... +def test_derivative_numerically(f, z, tol=..., a=..., b=..., c=..., d=...) -> bool: ... diff --git a/stubs/sympy-stubs/core/relational.pyi b/stubs/sympy-stubs/core/relational.pyi index 48a43966..55c3c58d 100644 --- a/stubs/sympy-stubs/core/relational.pyi +++ b/stubs/sympy-stubs/core/relational.pyi @@ -5,184 +5,129 @@ from sympy.core.basic import Basic from sympy.core.evalf import EvalfMixin from sympy.logic.boolalg import Boolean -__all__ = ('Rel', 'Eq', 'Ne', 'Lt', 'Le', 'Gt', 'Ge', 'Relational', 'Equality', 'Unequality', 'StrictLessThan', 'LessThan', 'StrictGreaterThan', 'GreaterThan') +__all__ = ( + "Rel", + "Eq", + "Ne", + "Lt", + "Le", + "Gt", + "Ge", + "Relational", + "Equality", + "Unequality", + "StrictLessThan", + "LessThan", + "StrictGreaterThan", + "GreaterThan", +) + class Relational(Boolean, EvalfMixin): __slots__ = ... ValidRelationOperator: dict[str | None, type[Relational]] = ... is_Relational = ... - def __new__(cls, lhs, rhs, rop=..., **assumptions) -> Self | Eq | Relational | Ne: - ... - - @property - def lhs(self) -> Basic: - ... - - @property - def rhs(self) -> Basic: - ... - - @property - def reversed(self) -> Eq | Relational | Ne: - ... - - @property - def reversedsign(self) -> Eq | Relational | Ne | Self: - ... - - @property - def negated(self) -> Self | Eq | Relational | Ne: - ... - - @property - def weak(self) -> Self: - ... - - @property - def strict(self) -> Self: - ... - - @property - def canonical(self) -> Eq | Relational | Ne | Self: - ... - - def equals(self, other, failing_expression=...) -> bool | None: - ... - - def expand(self, **kwargs) -> Self: - ... - - def __bool__(self): - ... - - @property - def binary_symbols(self) -> set[Any]: - ... - - + def __new__(cls, lhs, rhs, rop=..., **assumptions) -> Self | Eq | Relational | Ne: ... + @property + def lhs(self) -> Basic: ... + @property + def rhs(self) -> Basic: ... + @property + def reversed(self) -> Eq | Relational | Ne: ... + @property + def reversedsign(self) -> Eq | Relational | Ne | Self: ... + @property + def negated(self) -> Self | Eq | Relational | Ne: ... + @property + def weak(self) -> Self: ... + @property + def strict(self) -> Self: ... + @property + def canonical(self) -> Eq | Relational | Ne | Self: ... + def equals(self, other, failing_expression=...) -> bool | None: ... + def expand(self, **kwargs) -> Self: ... + def __bool__(self): ... + @property + def binary_symbols(self) -> set[Any]: ... Rel = Relational + class Equality(Relational): rel_op = ... __slots__ = ... is_Equality = ... - def __new__(cls, lhs, rhs, **options) -> Self | Eq | Relational | Ne: - ... - + def __new__(cls, lhs, rhs, **options) -> Self | Eq | Relational | Ne: ... @property - def binary_symbols(self) -> set[Basic] | set[Any]: - ... - - def integrate(self, *args, **kwargs) -> Equality | Relational | Ne: - ... - - def as_poly(self, *gens, **kwargs): - ... - - + def binary_symbols(self) -> set[Basic] | set[Any]: ... + def integrate(self, *args, **kwargs) -> Equality | Relational | Ne: ... + def as_poly(self, *gens, **kwargs): ... Eq = Equality + class Unequality(Relational): rel_op = ... __slots__ = ... - def __new__(cls, lhs, rhs, **options) -> Self: - ... - + def __new__(cls, lhs, rhs, **options) -> Self: ... @property - def binary_symbols(self) -> set[Basic] | set[Any]: - ... - - + def binary_symbols(self) -> set[Basic] | set[Any]: ... Ne = Unequality + class _Inequality(Relational): __slots__ = ... - def __new__(cls, lhs, rhs, **options) -> NotImplementedType | Self | Eq | Relational | Ne: - ... - - + def __new__(cls, lhs, rhs, **options) -> NotImplementedType | Self | Eq | Relational | Ne: ... class _Greater(_Inequality): __slots__ = ... @property - def gts(self) -> Basic: - ... - + def gts(self) -> Basic: ... @property - def lts(self) -> Basic: - ... - - + def lts(self) -> Basic: ... class _Less(_Inequality): __slots__ = ... @property - def gts(self) -> Basic: - ... - + def gts(self) -> Basic: ... @property - def lts(self) -> Basic: - ... - - + def lts(self) -> Basic: ... class GreaterThan(_Greater): __slots__ = ... rel_op = ... @property - def strict(self) -> NotImplementedType | Gt | Eq | Relational | Ne: - ... - - + def strict(self) -> NotImplementedType | Gt | Eq | Relational | Ne: ... Ge = GreaterThan + class LessThan(_Less): __doc__ = ... __slots__ = ... rel_op = ... @property - def strict(self) -> NotImplementedType | Lt | Eq | Relational | Ne: - ... - - + def strict(self) -> NotImplementedType | Lt | Eq | Relational | Ne: ... Le = LessThan + class StrictGreaterThan(_Greater): __doc__ = ... __slots__ = ... rel_op = ... @property - def weak(self) -> NotImplementedType | Ge | Eq | Relational | Ne: - ... - - + def weak(self) -> NotImplementedType | Ge | Eq | Relational | Ne: ... Gt = StrictGreaterThan + class StrictLessThan(_Less): __doc__ = ... __slots__ = ... rel_op = ... @property - def weak(self) -> NotImplementedType | Le | Eq | Relational | Ne: - ... - - + def weak(self) -> NotImplementedType | Le | Eq | Relational | Ne: ... Lt = StrictLessThan -def is_lt(lhs, rhs, assumptions=...) -> bool | None: - ... - -def is_gt(lhs, rhs, assumptions=...) -> bool | None: - ... - -def is_le(lhs, rhs, assumptions=...) -> bool | None: - ... - -def is_ge(lhs, rhs, assumptions=...) -> bool | None: - ... - -def is_neq(lhs, rhs, assumptions=...) -> bool: - ... - -def is_eq(lhs, rhs, assumptions=...): - ... +def is_lt(lhs, rhs, assumptions=...) -> bool | None: ... +def is_gt(lhs, rhs, assumptions=...) -> bool | None: ... +def is_le(lhs, rhs, assumptions=...) -> bool | None: ... +def is_ge(lhs, rhs, assumptions=...) -> bool | None: ... +def is_neq(lhs, rhs, assumptions=...) -> bool: ... +def is_eq(lhs, rhs, assumptions=...): ... diff --git a/stubs/sympy-stubs/core/rules.pyi b/stubs/sympy-stubs/core/rules.pyi index 25d61016..b984ff8e 100644 --- a/stubs/sympy-stubs/core/rules.pyi +++ b/stubs/sympy-stubs/core/rules.pyi @@ -1,16 +1,5 @@ - class Transform: - def __init__(self, transform, filter=...) -> None: - ... - - def __contains__(self, item): - ... - - def __getitem__(self, key): - ... - - def get(self, item, default=...) -> None: - ... - - - + def __init__(self, transform, filter=...) -> None: ... + def __contains__(self, item): ... + def __getitem__(self, key): ... + def get(self, item, default=...) -> None: ... diff --git a/stubs/sympy-stubs/core/singleton.pyi b/stubs/sympy-stubs/core/singleton.pyi index b6134532..30ac823a 100644 --- a/stubs/sympy-stubs/core/singleton.pyi +++ b/stubs/sympy-stubs/core/singleton.pyi @@ -5,24 +5,12 @@ from sympy.core.core import Registry class SingletonRegistry(Registry): __slots__ = ... __call__ = ... - def __init__(self) -> None: - ... - - def register(self, cls) -> None: - ... - - def __getattr__(self, name): - ... - - def __repr__(self) -> Literal['S']: - ... - - + def __init__(self) -> None: ... + def register(self, cls) -> None: ... + def __getattr__(self, name): ... + def __repr__(self) -> Literal["S"]: ... S = ... -class Singleton(type): - def __init__(cls, *args, **kwargs) -> None: - ... - - +class Singleton(type): + def __init__(cls, *args, **kwargs) -> None: ... diff --git a/stubs/sympy-stubs/core/sorting.pyi b/stubs/sympy-stubs/core/sorting.pyi index 69dfe991..8c375e7c 100644 --- a/stubs/sympy-stubs/core/sorting.pyi +++ b/stubs/sympy-stubs/core/sorting.pyi @@ -1,9 +1,11 @@ from typing import Any, Generator, Literal -__all__ = ['default_sort_key', 'ordered'] -def default_sort_key(item, order=...) -> tuple[tuple[Literal[5], Literal[0], str], tuple[int, tuple[Any, ...]], Any, Any] | tuple[tuple[Literal[10, 0], Literal[0], str | Any], tuple[int, tuple[Any, ...]] | tuple[Literal[1], tuple[str]], Any, Any]: - ... - -def ordered(seq, keys=..., default=..., warn=...) -> Generator[Any, Any, None]: - ... +__all__ = ["default_sort_key", "ordered"] +def default_sort_key( + item, order=... +) -> ( + tuple[tuple[Literal[5], Literal[0], str], tuple[int, tuple[Any, ...]], Any, Any] + | tuple[tuple[Literal[10, 0], Literal[0], str | Any], tuple[int, tuple[Any, ...]] | tuple[Literal[1], tuple[str]], Any, Any] +): ... +def ordered(seq, keys=..., default=..., warn=...) -> Generator[Any, Any, None]: ... diff --git a/stubs/sympy-stubs/core/symbol.pyi b/stubs/sympy-stubs/core/symbol.pyi index 4f80cb79..11bbbdc4 100644 --- a/stubs/sympy-stubs/core/symbol.pyi +++ b/stubs/sympy-stubs/core/symbol.pyi @@ -9,18 +9,13 @@ from sympy.logic.boolalg import Boolean class Str(Atom): __slots__ = ... - def __new__(cls, name, **kwargs) -> Self: - ... - - def __getnewargs__(self) -> tuple[Any]: - ... - + def __new__(cls, name, **kwargs) -> Self: ... + def __getnewargs__(self) -> tuple[Any]: ... - -def uniquely_named_symbol(xname, exprs=..., compare=..., modify=..., **assumptions) -> Symbol: - ... +def uniquely_named_symbol(xname, exprs=..., compare=..., modify=..., **assumptions) -> Symbol: ... _uniquely_named_symbol = ... + class Symbol(AtomicExpr, Boolean): is_comparable = ... __slots__ = ... @@ -28,48 +23,24 @@ class Symbol(AtomicExpr, Boolean): is_Symbol = ... is_symbol = ... @property - def kind(self) -> _NumberKind | _UndefinedKind: - ... - - def __new__(cls, name, **assumptions): - ... - + def kind(self) -> _NumberKind | _UndefinedKind: ... + def __new__(cls, name, **assumptions): ... @staticmethod - def __xnew__(cls, name, **assumptions): - ... - - def __getnewargs_ex__(self) -> tuple[tuple[str], Any]: - ... - - def __setstate__(self, state) -> None: - ... - + def __xnew__(cls, name, **assumptions): ... + def __getnewargs_ex__(self) -> tuple[tuple[str], Any]: ... + def __setstate__(self, state) -> None: ... @property - def assumptions0(self): - ... - + def assumptions0(self): ... @cacheit - def sort_key(self, order=...) -> tuple[tuple[Literal[2], Literal[0], str], tuple[Literal[1], tuple[str]], Any, Any]: - ... - - def as_dummy(self) -> Dummy: - ... - - def as_real_imag(self, deep=..., **hints) -> tuple[type[UndefinedFunction] | Any, type[UndefinedFunction] | Any] | None: - ... - - def is_constant(self, *wrt, **flags) -> bool: - ... - + def sort_key(self, order=...) -> tuple[tuple[Literal[2], Literal[0], str], tuple[Literal[1], tuple[str]], Any, Any]: ... + def as_dummy(self) -> Dummy: ... + def as_real_imag(self, deep=..., **hints) -> tuple[type[UndefinedFunction] | Any, type[UndefinedFunction] | Any] | None: ... + def is_constant(self, *wrt, **flags) -> bool: ... @property - def free_symbols(self) -> set[Self]: - ... - - binary_symbols = ... - def as_set(self): - ... - + def free_symbols(self) -> set[Self]: ... + binary_symbols = ... + def as_set(self): ... class Dummy(Symbol): _count = ... @@ -77,44 +48,23 @@ class Dummy(Symbol): _base_dummy_index = ... __slots__ = ... is_Dummy = ... - def __new__(cls, name=..., dummy_index=..., **assumptions): - ... - - def __getnewargs_ex__(self) -> tuple[tuple[str, Any], Any]: - ... - + def __new__(cls, name=..., dummy_index=..., **assumptions): ... + def __getnewargs_ex__(self) -> tuple[tuple[str, Any], Any]: ... @cacheit - def sort_key(self, order=...) -> tuple[tuple[Literal[2], Literal[0], str], tuple[Literal[2], tuple[str, Any]], Any, Any]: - ... - - + def sort_key(self, order=...) -> tuple[tuple[Literal[2], Literal[0], str], tuple[Literal[2], tuple[str, Any]], Any, Any]: ... class Wild(Symbol): is_Wild = ... __slots__ = ... - def __new__(cls, name, exclude=..., properties=..., **assumptions): - ... - - def __getnewargs__(self) -> tuple[str, Any, Any]: - ... - + def __new__(cls, name, exclude=..., properties=..., **assumptions): ... + def __getnewargs__(self) -> tuple[str, Any, Any]: ... @staticmethod @cacheit - def __xnew__(cls, name, exclude, properties, **assumptions): - ... - - def matches(self, expr, repl_dict=..., old=...) -> dict[Any, Any] | None: - ... - - + def __xnew__(cls, name, exclude, properties, **assumptions): ... + def matches(self, expr, repl_dict=..., old=...) -> dict[Any, Any] | None: ... _range = ... -def symbols(names, *, cls=..., **args) -> Any: - ... - -def var(names, **args) -> Basic | FunctionClass | Any: - ... - -def disambiguate(*iter) -> Tuple: - ... +def symbols(names, *, cls=..., **args) -> Any: ... +def var(names, **args) -> Basic | FunctionClass | Any: ... +def disambiguate(*iter) -> Tuple: ... diff --git a/stubs/sympy-stubs/core/sympify.pyi b/stubs/sympy-stubs/core/sympify.pyi index a08d2f81..1be13db6 100644 --- a/stubs/sympy-stubs/core/sympify.pyi +++ b/stubs/sympy-stubs/core/sympify.pyi @@ -3,24 +3,15 @@ from typing import Any, Callable from sympy.core.basic import Basic class SympifyError(ValueError): - def __init__(self, expr, base_exc=...) -> None: - ... - - def __str__(self) -> str: - ... - - + def __init__(self, expr, base_exc=...) -> None: ... + def __str__(self) -> str: ... converter: dict[type[Any], Callable[[Any], Basic]] = ... _sympy_converter: dict[type[Any], Callable[[Any], Basic]] = ... _external_converter = ... + class CantSympify: __slots__ = ... - -def sympify(a, locals=..., convert_xor=..., strict=..., rational=..., evaluate=...): - ... - -def kernS(s) -> list[Any] | set[Any] | tuple[Any, ...]: - ... - +def sympify(a, locals=..., convert_xor=..., strict=..., rational=..., evaluate=...): ... +def kernS(s) -> list[Any] | set[Any] | tuple[Any, ...]: ... diff --git a/stubs/sympy-stubs/core/traversal.pyi b/stubs/sympy-stubs/core/traversal.pyi index 89aba143..4717e93b 100644 --- a/stubs/sympy-stubs/core/traversal.pyi +++ b/stubs/sympy-stubs/core/traversal.pyi @@ -2,36 +2,16 @@ from typing import Any, Generator, Self from sympy.core.basic import Basic -def iterargs(expr) -> Generator[Any, Any, None]: - ... - -def iterfreeargs(expr, _first=...) -> Generator[Any, Any, None]: - ... +def iterargs(expr) -> Generator[Any, Any, None]: ... +def iterfreeargs(expr, _first=...) -> Generator[Any, Any, None]: ... class preorder_traversal: - def __init__(self, node, keys=...) -> None: - ... - - def skip(self) -> None: - ... - - def __next__(self): - ... - - def __iter__(self) -> Self: - ... - - - -def use(expr, func, level=..., args=..., kwargs=...): - ... - -def walk(e, *target) -> Generator[Any, Any, None]: - ... - -def bottom_up(rv, F, atoms=..., nonbasic=...): - ... - -def postorder_traversal(node, keys=...) -> Generator[Any | Basic, Any, None]: - ... - + def __init__(self, node, keys=...) -> None: ... + def skip(self) -> None: ... + def __next__(self): ... + def __iter__(self) -> Self: ... + +def use(expr, func, level=..., args=..., kwargs=...): ... +def walk(e, *target) -> Generator[Any, Any, None]: ... +def bottom_up(rv, F, atoms=..., nonbasic=...): ... +def postorder_traversal(node, keys=...) -> Generator[Any | Basic, Any, None]: ... diff --git a/stubs/sympy-stubs/crypto/crypto.pyi b/stubs/sympy-stubs/crypto/crypto.pyi index 5219ad73..4c20da4d 100644 --- a/stubs/sympy-stubs/crypto/crypto.pyi +++ b/stubs/sympy-stubs/crypto/crypto.pyi @@ -6,187 +6,72 @@ from sympy.matrices import Matrix from sympy.utilities.decorator import doctest_depends_on class NonInvertibleCipherWarning(RuntimeWarning): - def __init__(self, msg) -> None: - ... - - def __str__(self) -> str: - ... - - def warn(self, stacklevel=...) -> None: - ... - + def __init__(self, msg) -> None: ... + def __str__(self) -> str: ... + def warn(self, stacklevel=...) -> None: ... - -def AZ(s=...) -> LiteralString | str | list[Any | str]: - ... +def AZ(s=...) -> LiteralString | str | list[Any | str]: ... bifid5 = ... bifid6 = ... bifid10 = ... -def padded_key(key, symbols) -> str: - ... - -def check_and_join(phrase, symbols=..., filter=...) -> str: - ... - -def cycle_list(k, n) -> list[int]: - ... - -def encipher_shift(msg, key, symbols=...) -> str: - ... - -def decipher_shift(msg, key, symbols=...) -> str: - ... - -def encipher_rot13(msg, symbols=...) -> str: - ... - -def decipher_rot13(msg, symbols=...) -> str: - ... - -def encipher_affine(msg, key, symbols=..., _inverse=...) -> str: - ... - -def decipher_affine(msg, key, symbols=...) -> str: - ... - -def encipher_atbash(msg, symbols=...) -> str: - ... - -def decipher_atbash(msg, symbols=...) -> str: - ... - -def encipher_substitution(msg, old, new=...) -> str: - ... - -def encipher_vigenere(msg, key, symbols=...) -> LiteralString: - ... - -def decipher_vigenere(msg, key, symbols=...) -> str: - ... - -def encipher_hill(msg, key, symbols=..., pad=...) -> str: - ... - -def decipher_hill(msg, key, symbols=...) -> str: - ... - -def encipher_bifid(msg, key, symbols=...) -> str: - ... - -def decipher_bifid(msg, key, symbols=...) -> str: - ... - -def bifid_square(key) -> Matrix: - ... - -def encipher_bifid5(msg, key) -> str: - ... - -def decipher_bifid5(msg, key) -> str: - ... - -def bifid5_square(key=...) -> Matrix: - ... - -def encipher_bifid6(msg, key) -> str: - ... - -def decipher_bifid6(msg, key) -> str: - ... - -def bifid6_square(key=...) -> Matrix: - ... - -def rsa_public_key(*args, **kwargs) -> tuple[Any, Any] | tuple[Any, Any | int] | Literal[False]: - ... - -def rsa_private_key(*args, **kwargs) -> tuple[Any, Any] | tuple[Any, Any | int] | Literal[False]: - ... -def encipher_rsa(i, key, factors=...): - ... - -def decipher_rsa(i, key, factors=...): - ... - -def kid_rsa_public_key(a, b, A, B) -> tuple[Any, Any]: - ... - -def kid_rsa_private_key(a, b, A, B) -> tuple[Any, Any]: - ... - -def encipher_kid_rsa(msg, key): - ... - -def decipher_kid_rsa(msg, key): - ... +def padded_key(key, symbols) -> str: ... +def check_and_join(phrase, symbols=..., filter=...) -> str: ... +def cycle_list(k, n) -> list[int]: ... +def encipher_shift(msg, key, symbols=...) -> str: ... +def decipher_shift(msg, key, symbols=...) -> str: ... +def encipher_rot13(msg, symbols=...) -> str: ... +def decipher_rot13(msg, symbols=...) -> str: ... +def encipher_affine(msg, key, symbols=..., _inverse=...) -> str: ... +def decipher_affine(msg, key, symbols=...) -> str: ... +def encipher_atbash(msg, symbols=...) -> str: ... +def decipher_atbash(msg, symbols=...) -> str: ... +def encipher_substitution(msg, old, new=...) -> str: ... +def encipher_vigenere(msg, key, symbols=...) -> LiteralString: ... +def decipher_vigenere(msg, key, symbols=...) -> str: ... +def encipher_hill(msg, key, symbols=..., pad=...) -> str: ... +def decipher_hill(msg, key, symbols=...) -> str: ... +def encipher_bifid(msg, key, symbols=...) -> str: ... +def decipher_bifid(msg, key, symbols=...) -> str: ... +def bifid_square(key) -> Matrix: ... +def encipher_bifid5(msg, key) -> str: ... +def decipher_bifid5(msg, key) -> str: ... +def bifid5_square(key=...) -> Matrix: ... +def encipher_bifid6(msg, key) -> str: ... +def decipher_bifid6(msg, key) -> str: ... +def bifid6_square(key=...) -> Matrix: ... +def rsa_public_key(*args, **kwargs) -> tuple[Any, Any] | tuple[Any, Any | int] | Literal[False]: ... +def rsa_private_key(*args, **kwargs) -> tuple[Any, Any] | tuple[Any, Any | int] | Literal[False]: ... +def encipher_rsa(i, key, factors=...): ... +def decipher_rsa(i, key, factors=...): ... +def kid_rsa_public_key(a, b, A, B) -> tuple[Any, Any]: ... +def kid_rsa_private_key(a, b, A, B) -> tuple[Any, Any]: ... +def encipher_kid_rsa(msg, key): ... +def decipher_kid_rsa(msg, key): ... morse_char = ... char_morse = ... -def encode_morse(msg, sep=..., mapping=...) -> str: - ... - -def decode_morse(msg, sep=..., mapping=...) -> LiteralString: - ... - -def lfsr_sequence(key, fill, n) -> list[Any]: - ... - -def lfsr_autocorrelation(L, P, k) -> Rational | Integer: - ... - -def lfsr_connection_polynomial(s) -> int: - ... - -def elgamal_private_key(digit=..., seed=...) -> tuple[Any | int | array[int] | None, int | Any | None, int | Any]: - ... - -def elgamal_public_key(key) -> tuple[Any, Any, Any]: - ... - -def encipher_elgamal(i, key, seed=...) -> tuple[Any, Any]: - ... - -def decipher_elgamal(msg, key): - ... - -def dh_private_key(digit=..., seed=...) -> tuple[Any | int | array[int] | None, int | Any | None, int | Any]: - ... - -def dh_public_key(key) -> tuple[Any, Any, Any]: - ... - -def dh_shared_key(key, b): - ... - -def gm_private_key(p, q, a=...) -> tuple[Any, Any]: - ... - -def gm_public_key(p, q, a=..., seed=...) -> tuple[int | Any, Any] | Literal[False]: - ... - -def encipher_gm(i, key, seed=...) -> list[Any]: - ... - -def decipher_gm(message, key) -> int: - ... - -def encipher_railfence(message, rails) -> LiteralString: - ... - -def decipher_railfence(ciphertext, rails) -> str: - ... - -def bg_private_key(p, q) -> tuple[Any, Any]: - ... - -def bg_public_key(p, q): - ... - -def encipher_bg(i, key, seed=...) -> tuple[list[Any], int]: - ... - -def decipher_bg(message, key) -> Literal[0]: - ... +def encode_morse(msg, sep=..., mapping=...) -> str: ... +def decode_morse(msg, sep=..., mapping=...) -> LiteralString: ... +def lfsr_sequence(key, fill, n) -> list[Any]: ... +def lfsr_autocorrelation(L, P, k) -> Rational | Integer: ... +def lfsr_connection_polynomial(s) -> int: ... +def elgamal_private_key(digit=..., seed=...) -> tuple[Any | int | array[int] | None, int | Any | None, int | Any]: ... +def elgamal_public_key(key) -> tuple[Any, Any, Any]: ... +def encipher_elgamal(i, key, seed=...) -> tuple[Any, Any]: ... +def decipher_elgamal(msg, key): ... +def dh_private_key(digit=..., seed=...) -> tuple[Any | int | array[int] | None, int | Any | None, int | Any]: ... +def dh_public_key(key) -> tuple[Any, Any, Any]: ... +def dh_shared_key(key, b): ... +def gm_private_key(p, q, a=...) -> tuple[Any, Any]: ... +def gm_public_key(p, q, a=..., seed=...) -> tuple[int | Any, Any] | Literal[False]: ... +def encipher_gm(i, key, seed=...) -> list[Any]: ... +def decipher_gm(message, key) -> int: ... +def encipher_railfence(message, rails) -> LiteralString: ... +def decipher_railfence(ciphertext, rails) -> str: ... +def bg_private_key(p, q) -> tuple[Any, Any]: ... +def bg_public_key(p, q): ... +def encipher_bg(i, key, seed=...) -> tuple[list[Any], int]: ... +def decipher_bg(message, key) -> Literal[0]: ... diff --git a/stubs/sympy-stubs/diffgeom/__init__.pyi b/stubs/sympy-stubs/diffgeom/__init__.pyi index 6f7a08fe..f26b5f7b 100644 --- a/stubs/sympy-stubs/diffgeom/__init__.pyi +++ b/stubs/sympy-stubs/diffgeom/__init__.pyi @@ -25,4 +25,29 @@ from sympy.diffgeom.diffgeom import ( vectors_in_basis, ) -__all__ = ['BaseCovarDerivativeOp', 'BaseScalarField', 'BaseVectorField', 'Commutator', 'contravariant_order', 'CoordSystem', 'CoordinateSymbol', 'CovarDerivativeOp', 'covariant_order', 'Differential', 'intcurve_diffequ', 'intcurve_series', 'LieDerivative', 'Manifold', 'metric_to_Christoffel_1st', 'metric_to_Christoffel_2nd', 'metric_to_Ricci_components', 'metric_to_Riemann_components', 'Patch', 'Point', 'TensorProduct', 'twoform_to_matrix', 'vectors_in_basis', 'WedgeProduct'] +__all__ = [ + "BaseCovarDerivativeOp", + "BaseScalarField", + "BaseVectorField", + "Commutator", + "contravariant_order", + "CoordSystem", + "CoordinateSymbol", + "CovarDerivativeOp", + "covariant_order", + "Differential", + "intcurve_diffequ", + "intcurve_series", + "LieDerivative", + "Manifold", + "metric_to_Christoffel_1st", + "metric_to_Christoffel_2nd", + "metric_to_Ricci_components", + "metric_to_Riemann_components", + "Patch", + "Point", + "TensorProduct", + "twoform_to_matrix", + "vectors_in_basis", + "WedgeProduct", +] diff --git a/stubs/sympy-stubs/diffgeom/diffgeom.pyi b/stubs/sympy-stubs/diffgeom/diffgeom.pyi index 221b129d..a8824815 100644 --- a/stubs/sympy-stubs/diffgeom/diffgeom.pyi +++ b/stubs/sympy-stubs/diffgeom/diffgeom.pyi @@ -8,364 +8,172 @@ from sympy.series.order import Order from sympy.tensor.array.dense_ndim_array import ImmutableDenseNDimArray class Manifold(Basic): - def __new__(cls, name, dim, **kwargs) -> Self: - ... - + def __new__(cls, name, dim, **kwargs) -> Self: ... @property - def name(self) -> Basic: - ... - + def name(self) -> Basic: ... @property - def dim(self) -> Basic: - ... - - + def dim(self) -> Basic: ... class Patch(Basic): - def __new__(cls, name, manifold, **kwargs) -> Self: - ... - + def __new__(cls, name, manifold, **kwargs) -> Self: ... @property - def name(self) -> Basic: - ... - + def name(self) -> Basic: ... @property - def manifold(self) -> Basic: - ... - + def manifold(self) -> Basic: ... @property - def dim(self): - ... - - + def dim(self): ... class CoordSystem(Basic): - def __new__(cls, name, patch, symbols=..., relations=..., **kwargs) -> Self: - ... - - @property - def name(self) -> Basic: - ... - - @property - def patch(self) -> Basic: - ... - - @property - def manifold(self): - ... - - @property - def symbols(self) -> tuple[CoordinateSymbol, ...]: - ... - - @property - def relations(self) -> Basic: - ... - - @property - def dim(self): - ... - - def transformation(self, sys) -> Lambda: - ... - - def connect_to(self, to_sys, from_coords, to_exprs, inverse=..., fill_in_gaps=...) -> None: - ... - - def transform(self, sys, coordinates=...) -> Basic | ImmutableDenseMatrix: - ... - - def coord_tuple_transform_to(self, to_sys, coords) -> ImmutableDenseMatrix: - ... - - def jacobian(self, sys, coordinates=...): - ... - + def __new__(cls, name, patch, symbols=..., relations=..., **kwargs) -> Self: ... + @property + def name(self) -> Basic: ... + @property + def patch(self) -> Basic: ... + @property + def manifold(self): ... + @property + def symbols(self) -> tuple[CoordinateSymbol, ...]: ... + @property + def relations(self) -> Basic: ... + @property + def dim(self): ... + def transformation(self, sys) -> Lambda: ... + def connect_to(self, to_sys, from_coords, to_exprs, inverse=..., fill_in_gaps=...) -> None: ... + def transform(self, sys, coordinates=...) -> Basic | ImmutableDenseMatrix: ... + def coord_tuple_transform_to(self, to_sys, coords) -> ImmutableDenseMatrix: ... + def jacobian(self, sys, coordinates=...): ... + jacobian_matrix = ... - def jacobian_determinant(self, sys, coordinates=...): - ... - - def point(self, coords) -> Point: - ... - - def point_to_coords(self, point): - ... - - def base_scalar(self, coord_index) -> BaseScalarField: - ... - + def jacobian_determinant(self, sys, coordinates=...): ... + def point(self, coords) -> Point: ... + def point_to_coords(self, point): ... + def base_scalar(self, coord_index) -> BaseScalarField: ... + coord_function = ... - def base_scalars(self) -> list[BaseScalarField]: - ... - - coord_functions = ... - def base_vector(self, coord_index) -> BaseVectorField: - ... - - def base_vectors(self) -> list[BaseVectorField]: - ... - - def base_oneform(self, coord_index) -> Differential: - ... - - def base_oneforms(self) -> list[Any | Differential]: - ... - + def base_scalars(self) -> list[BaseScalarField]: ... + coord_functions = ... + def base_vector(self, coord_index) -> BaseVectorField: ... + def base_vectors(self) -> list[BaseVectorField]: ... + def base_oneform(self, coord_index) -> Differential: ... + def base_oneforms(self) -> list[Any | Differential]: ... class CoordinateSymbol(Symbol): - def __new__(cls, coord_sys, index, **assumptions): - ... - - def __getnewargs__(self) -> tuple[Any, Any]: - ... - - + def __new__(cls, coord_sys, index, **assumptions): ... + def __getnewargs__(self) -> tuple[Any, Any]: ... class Point(Basic): - def __new__(cls, coord_sys, coords, **kwargs) -> Self: - ... - - @property - def patch(self): - ... - - @property - def manifold(self): - ... - - @property - def dim(self): - ... - - def coords(self, sys=...): - ... - - @property - def free_symbols(self): - ... - - + def __new__(cls, coord_sys, coords, **kwargs) -> Self: ... + @property + def patch(self): ... + @property + def manifold(self): ... + @property + def dim(self): ... + def coords(self, sys=...): ... + @property + def free_symbols(self): ... class BaseScalarField(Expr): is_commutative = ... - def __new__(cls, coord_sys, index, **kwargs) -> Self: - ... - - @property - def coord_sys(self) -> Basic: - ... - - @property - def index(self) -> Basic: - ... - - @property - def patch(self): - ... - - @property - def manifold(self): - ... - - @property - def dim(self): - ... - - def __call__(self, *args) -> Self: - ... - - free_symbols: set[Any] = ... + def __new__(cls, coord_sys, index, **kwargs) -> Self: ... + @property + def coord_sys(self) -> Basic: ... + @property + def index(self) -> Basic: ... + @property + def patch(self): ... + @property + def manifold(self): ... + @property + def dim(self): ... + def __call__(self, *args) -> Self: ... + free_symbols: set[Any] = ... class BaseVectorField(Expr): is_commutative = ... - def __new__(cls, coord_sys, index, **kwargs) -> Self: - ... - - @property - def coord_sys(self) -> Basic: - ... - - @property - def index(self) -> Basic: - ... - - @property - def patch(self): - ... - - @property - def manifold(self): - ... - - @property - def dim(self): - ... - - def __call__(self, scalar_field) -> Self: - ... - - + def __new__(cls, coord_sys, index, **kwargs) -> Self: ... + @property + def coord_sys(self) -> Basic: ... + @property + def index(self) -> Basic: ... + @property + def patch(self): ... + @property + def manifold(self): ... + @property + def dim(self): ... + def __call__(self, scalar_field) -> Self: ... class Commutator(Expr): - def __new__(cls, v1, v2) -> Self | Literal[0]: - ... - - @property - def v1(self) -> Basic: - ... - - @property - def v2(self) -> Basic: - ... - - def __call__(self, scalar_field): - ... - - + def __new__(cls, v1, v2) -> Self | Literal[0]: ... + @property + def v1(self) -> Basic: ... + @property + def v2(self) -> Basic: ... + def __call__(self, scalar_field): ... class Differential(Expr): is_commutative = ... - def __new__(cls, form_field) -> Self: - ... - - @property - def form_field(self) -> Basic: - ... - - def __call__(self, *vector_fields) -> Self | Literal[0]: - ... - - + def __new__(cls, form_field) -> Self: ... + @property + def form_field(self) -> Basic: ... + def __call__(self, *vector_fields) -> Self | Literal[0]: ... class TensorProduct(Expr): - def __new__(cls, *args) -> Order: - ... - - def __call__(self, *fields) -> Order: - ... - - + def __new__(cls, *args) -> Order: ... + def __call__(self, *fields) -> Order: ... class WedgeProduct(TensorProduct): - def __call__(self, *fields): - ... - - + def __call__(self, *fields): ... class LieDerivative(Expr): - def __new__(cls, v_field, expr) -> Self | Commutator | Literal[0]: - ... - - @property - def v_field(self) -> Basic: - ... - - @property - def expr(self) -> Basic: - ... - - def __call__(self, *args): - ... - - + def __new__(cls, v_field, expr) -> Self | Commutator | Literal[0]: ... + @property + def v_field(self) -> Basic: ... + @property + def expr(self) -> Basic: ... + def __call__(self, *args): ... class BaseCovarDerivativeOp(Expr): - def __new__(cls, coord_sys, index, christoffel) -> Self: - ... - - @property - def coord_sys(self) -> Basic: - ... - - @property - def index(self) -> Basic: - ... - - @property - def christoffel(self) -> Basic: - ... - - def __call__(self, field): - ... - - + def __new__(cls, coord_sys, index, christoffel) -> Self: ... + @property + def coord_sys(self) -> Basic: ... + @property + def index(self) -> Basic: ... + @property + def christoffel(self) -> Basic: ... + def __call__(self, field): ... class CovarDerivativeOp(Expr): - def __new__(cls, wrt, christoffel) -> Self: - ... - - @property - def wrt(self) -> Basic: - ... - - @property - def christoffel(self) -> Basic: - ... - - def __call__(self, field): - ... - - - -def intcurve_series(vector_field, param, start_point, n=..., coord_sys=..., coeffs=...) -> list[ImmutableDenseMatrix] | ImmutableDenseMatrix: - ... - -def intcurve_diffequ(vector_field, param, start_point, coord_sys=...) -> tuple[list[Any], list[Any]]: - ... - -def dummyfy(args, exprs) -> tuple[ImmutableDenseMatrix, ImmutableDenseMatrix]: - ... - -def contravariant_order(expr, _strict=...) -> int: - ... - -def covariant_order(expr, _strict=...) -> int: - ... - -def vectors_in_basis(expr, to_sys): - ... - -def twoform_to_matrix(expr) -> ImmutableDenseMatrix: - ... - -def metric_to_Christoffel_1st(expr) -> ImmutableDenseNDimArray: - ... - -def metric_to_Christoffel_2nd(expr) -> ImmutableDenseNDimArray: - ... - -def metric_to_Riemann_components(expr) -> ImmutableDenseNDimArray: - ... - -def metric_to_Ricci_components(expr) -> ImmutableDenseNDimArray: - ... + def __new__(cls, wrt, christoffel) -> Self: ... + @property + def wrt(self) -> Basic: ... + @property + def christoffel(self) -> Basic: ... + def __call__(self, field): ... + +def intcurve_series( + vector_field, param, start_point, n=..., coord_sys=..., coeffs=... +) -> list[ImmutableDenseMatrix] | ImmutableDenseMatrix: ... +def intcurve_diffequ(vector_field, param, start_point, coord_sys=...) -> tuple[list[Any], list[Any]]: ... +def dummyfy(args, exprs) -> tuple[ImmutableDenseMatrix, ImmutableDenseMatrix]: ... +def contravariant_order(expr, _strict=...) -> int: ... +def covariant_order(expr, _strict=...) -> int: ... +def vectors_in_basis(expr, to_sys): ... +def twoform_to_matrix(expr) -> ImmutableDenseMatrix: ... +def metric_to_Christoffel_1st(expr) -> ImmutableDenseNDimArray: ... +def metric_to_Christoffel_2nd(expr) -> ImmutableDenseNDimArray: ... +def metric_to_Riemann_components(expr) -> ImmutableDenseNDimArray: ... +def metric_to_Ricci_components(expr) -> ImmutableDenseNDimArray: ... class _deprecated_container: - def __init__(self, message, data) -> None: - ... - - def warn(self) -> None: - ... - - def __iter__(self): - ... - - def __getitem__(self, key): - ... - - def __contains__(self, key): - ... - - - -class _deprecated_list(_deprecated_container, list): - ... - - -class _deprecated_dict(_deprecated_container, dict): - ... - - + def __init__(self, message, data) -> None: ... + def warn(self) -> None: ... + def __iter__(self): ... + def __getitem__(self, key): ... + def __contains__(self, key): ... + +class _deprecated_list(_deprecated_container, list): ... +class _deprecated_dict(_deprecated_container, dict): ... diff --git a/stubs/sympy-stubs/discrete/__init__.pyi b/stubs/sympy-stubs/discrete/__init__.pyi index 2bb1e0c9..53bed9b7 100644 --- a/stubs/sympy-stubs/discrete/__init__.pyi +++ b/stubs/sympy-stubs/discrete/__init__.pyi @@ -1,4 +1,16 @@ from sympy.discrete.convolutions import convolution, covering_product, intersecting_product from sympy.discrete.transforms import fft, fwht, ifft, ifwht, intt, inverse_mobius_transform, mobius_transform, ntt -__all__ = ['fft', 'ifft', 'ntt', 'intt', 'fwht', 'ifwht', 'mobius_transform', 'inverse_mobius_transform', 'convolution', 'covering_product', 'intersecting_product'] +__all__ = [ + "fft", + "ifft", + "ntt", + "intt", + "fwht", + "ifwht", + "mobius_transform", + "inverse_mobius_transform", + "convolution", + "covering_product", + "intersecting_product", +] diff --git a/stubs/sympy-stubs/discrete/convolutions.pyi b/stubs/sympy-stubs/discrete/convolutions.pyi index 1724126b..5dcd4d31 100644 --- a/stubs/sympy-stubs/discrete/convolutions.pyi +++ b/stubs/sympy-stubs/discrete/convolutions.pyi @@ -2,24 +2,10 @@ from typing import Any from sympy.core.numbers import Integer, Rational -def convolution(a, b, cycle=..., dps=..., prime=..., dyadic=..., subset=...) -> list[int] | list[Any | int] | Any | list[Any]: - ... - -def convolution_fft(a, b, dps=...) -> list[Any] | Any: - ... - -def convolution_ntt(a, b, prime) -> list[int] | list[Any | int] | Any: - ... - -def convolution_fwht(a, b) -> list[Any] | Any: - ... - -def convolution_subset(a, b) -> list[Any] | Any: - ... - -def covering_product(a, b) -> list[Any] | Any: - ... - -def intersecting_product(a, b) -> list[Any] | Any: - ... - +def convolution(a, b, cycle=..., dps=..., prime=..., dyadic=..., subset=...) -> list[int] | list[Any | int] | Any | list[Any]: ... +def convolution_fft(a, b, dps=...) -> list[Any] | Any: ... +def convolution_ntt(a, b, prime) -> list[int] | list[Any | int] | Any: ... +def convolution_fwht(a, b) -> list[Any] | Any: ... +def convolution_subset(a, b) -> list[Any] | Any: ... +def covering_product(a, b) -> list[Any] | Any: ... +def intersecting_product(a, b) -> list[Any] | Any: ... diff --git a/stubs/sympy-stubs/discrete/recurrences.pyi b/stubs/sympy-stubs/discrete/recurrences.pyi index 11e6bb38..4824e313 100644 --- a/stubs/sympy-stubs/discrete/recurrences.pyi +++ b/stubs/sympy-stubs/discrete/recurrences.pyi @@ -1,7 +1,2 @@ - -def linrec(coeffs, init, n) -> int: - ... - -def linrec_coeffs(c, n): - ... - +def linrec(coeffs, init, n) -> int: ... +def linrec_coeffs(c, n): ... diff --git a/stubs/sympy-stubs/discrete/transforms.pyi b/stubs/sympy-stubs/discrete/transforms.pyi index ca1e0b6d..4a948f1f 100644 --- a/stubs/sympy-stubs/discrete/transforms.pyi +++ b/stubs/sympy-stubs/discrete/transforms.pyi @@ -1,26 +1,10 @@ from typing import Any -def fft(seq, dps=...) -> list[Any] | Any: - ... - -def ifft(seq, dps=...) -> list[Any] | Any: - ... - -def ntt(seq, prime) -> list[int] | list[Any | int] | Any: - ... - -def intt(seq, prime) -> list[int] | list[Any | int] | Any: - ... - -def fwht(seq) -> list[Any] | Any: - ... - -def ifwht(seq) -> list[Any] | Any: - ... - -def mobius_transform(seq, subset=...) -> list[Any] | Any: - ... - -def inverse_mobius_transform(seq, subset=...) -> list[Any] | Any: - ... - +def fft(seq, dps=...) -> list[Any] | Any: ... +def ifft(seq, dps=...) -> list[Any] | Any: ... +def ntt(seq, prime) -> list[int] | list[Any | int] | Any: ... +def intt(seq, prime) -> list[int] | list[Any | int] | Any: ... +def fwht(seq) -> list[Any] | Any: ... +def ifwht(seq) -> list[Any] | Any: ... +def mobius_transform(seq, subset=...) -> list[Any] | Any: ... +def inverse_mobius_transform(seq, subset=...) -> list[Any] | Any: ... diff --git a/stubs/sympy-stubs/external/importtools.pyi b/stubs/sympy-stubs/external/importtools.pyi index fc141599..a988436b 100644 --- a/stubs/sympy-stubs/external/importtools.pyi +++ b/stubs/sympy-stubs/external/importtools.pyi @@ -3,9 +3,16 @@ from typing import Any WARN_NOT_INSTALLED = ... WARN_OLD_VERSION = ... _component_re = ... -def version_tuple(vstring) -> tuple[Any, ...]: - ... - -def import_module(module, min_module_version=..., min_python_version=..., warn_not_installed=..., warn_old_version=..., module_version_attr=..., module_version_attr_call_args=..., import_kwargs=..., catch=...): - ... +def version_tuple(vstring) -> tuple[Any, ...]: ... +def import_module( + module, + min_module_version=..., + min_python_version=..., + warn_not_installed=..., + warn_old_version=..., + module_version_attr=..., + module_version_attr_call_args=..., + import_kwargs=..., + catch=..., +): ... diff --git a/stubs/sympy-stubs/external/pythonmpq.pyi b/stubs/sympy-stubs/external/pythonmpq.pyi index 193dea47..e8f64759 100644 --- a/stubs/sympy-stubs/external/pythonmpq.pyi +++ b/stubs/sympy-stubs/external/pythonmpq.pyi @@ -3,83 +3,33 @@ from typing import Any, Self, Tuple as tTuple, Type _PyHASH_MODULUS = ... _PyHASH_INF = ... + class PythonMPQ: __slots__ = ... - def __new__(cls, numerator, denominator=...) -> Self: - ... - - def __int__(self) -> int: - ... - - def __float__(self): - ... - - def __bool__(self) -> bool: - ... - - def __eq__(self, other) -> bool: - ... - - def __hash__(self) -> int: - ... - - def __reduce__(self) -> tuple[type[Self], tuple[Any, Any]]: - ... - - def __str__(self) -> str: - ... - - def __repr__(self) -> str: - ... - - def __lt__(self, other) -> bool: - ... - - def __le__(self, other) -> bool: - ... - - def __gt__(self, other) -> bool: - ... - - def __ge__(self, other) -> bool: - ... - - def __abs__(self) -> Self: - ... - - def __pos__(self) -> Self: - ... - - def __neg__(self) -> Self: - ... - - def __add__(self, other) -> NotImplementedType | Self: - ... - - def __radd__(self, other) -> Self | NotImplementedType: - ... - - def __sub__(self, other) -> NotImplementedType | Self: - ... - - def __rsub__(self, other) -> Self | NotImplementedType: - ... - - def __mul__(self, other) -> NotImplementedType | Self: - ... - - def __rmul__(self, other) -> Self | NotImplementedType: - ... - - def __pow__(self, exp) -> Self: - ... - - def __truediv__(self, other) -> NotImplementedType | Self: - ... - - def __rtruediv__(self, other) -> Self | NotImplementedType: - ... - - _compatible_types: tTuple[Type, ...] = ... - + def __new__(cls, numerator, denominator=...) -> Self: ... + def __int__(self) -> int: ... + def __float__(self): ... + def __bool__(self) -> bool: ... + def __eq__(self, other) -> bool: ... + def __hash__(self) -> int: ... + def __reduce__(self) -> tuple[type[Self], tuple[Any, Any]]: ... + def __str__(self) -> str: ... + def __repr__(self) -> str: ... + def __lt__(self, other) -> bool: ... + def __le__(self, other) -> bool: ... + def __gt__(self, other) -> bool: ... + def __ge__(self, other) -> bool: ... + def __abs__(self) -> Self: ... + def __pos__(self) -> Self: ... + def __neg__(self) -> Self: ... + def __add__(self, other) -> NotImplementedType | Self: ... + def __radd__(self, other) -> Self | NotImplementedType: ... + def __sub__(self, other) -> NotImplementedType | Self: ... + def __rsub__(self, other) -> Self | NotImplementedType: ... + def __mul__(self, other) -> NotImplementedType | Self: ... + def __rmul__(self, other) -> Self | NotImplementedType: ... + def __pow__(self, exp) -> Self: ... + def __truediv__(self, other) -> NotImplementedType | Self: ... + def __rtruediv__(self, other) -> Self | NotImplementedType: ... + _compatible_types: tTuple[Type, ...] = ... diff --git a/stubs/sympy-stubs/functions/combinatorial/factorials.pyi b/stubs/sympy-stubs/functions/combinatorial/factorials.pyi index 79d3d7fc..9bef581e 100644 --- a/stubs/sympy-stubs/functions/combinatorial/factorials.pyi +++ b/stubs/sympy-stubs/functions/combinatorial/factorials.pyi @@ -4,63 +4,38 @@ from sympy.core.function import Function, UndefinedFunction from sympy.core.numbers import Integer from sympy.series.order import Order -class CombinatorialFunction(Function): - ... - +class CombinatorialFunction(Function): ... class factorial(CombinatorialFunction): - def fdiff(self, argindex=...): - ... - + def fdiff(self, argindex=...): ... + _small_swing = ... _small_factorials: list[int] = ... @classmethod - def eval(cls, n) -> Integer | None: - ... - - - -class MultiFactorial(CombinatorialFunction): - ... + def eval(cls, n) -> Integer | None: ... +class MultiFactorial(CombinatorialFunction): ... class subfactorial(CombinatorialFunction): @classmethod - def eval(cls, arg) -> int | None: - ... - - + def eval(cls, arg) -> int | None: ... class factorial2(CombinatorialFunction): @classmethod - def eval(cls, arg) -> None: - ... - - + def eval(cls, arg) -> None: ... class RisingFactorial(CombinatorialFunction): @classmethod - def eval(cls, x, k) -> type[UndefinedFunction] | int | float | None: - ... - - + def eval(cls, x, k) -> type[UndefinedFunction] | int | float | None: ... class FallingFactorial(CombinatorialFunction): @classmethod - def eval(cls, x, k) -> type[UndefinedFunction] | int | float | None: - ... - - + def eval(cls, x, k) -> type[UndefinedFunction] | int | float | None: ... rf = RisingFactorial ff = FallingFactorial + class binomial(CombinatorialFunction): - def fdiff(self, argindex=...): - ... - + def fdiff(self, argindex=...): ... @classmethod - def eval(cls, n, k) -> Order | Any | Integer | float | None: - ... - - - + def eval(cls, n, k) -> Order | Any | Integer | float | None: ... diff --git a/stubs/sympy-stubs/functions/combinatorial/numbers.pyi b/stubs/sympy-stubs/functions/combinatorial/numbers.pyi index 4e5da493..660db8be 100644 --- a/stubs/sympy-stubs/functions/combinatorial/numbers.pyi +++ b/stubs/sympy-stubs/functions/combinatorial/numbers.pyi @@ -5,158 +5,91 @@ from sympy.core.numbers import Float, Integer, Rational from sympy.series.order import Order _sym = ... + class carmichael(Function): @staticmethod - def is_perfect_square(n) -> bool: - ... - + def is_perfect_square(n) -> bool: ... @staticmethod - def divides(p, n): - ... - + def divides(p, n): ... @staticmethod - def is_prime(n) -> bool: - ... - + def is_prime(n) -> bool: ... @staticmethod - def is_carmichael(n) -> bool: - ... - + def is_carmichael(n) -> bool: ... @staticmethod - def find_carmichael_numbers_in_range(x, y) -> list[int]: - ... - + def find_carmichael_numbers_in_range(x, y) -> list[int]: ... @staticmethod - def find_first_n_carmichaels(n) -> list[Any]: - ... - - + def find_first_n_carmichaels(n) -> list[Any]: ... class fibonacci(Function): @classmethod - def eval(cls, n, sym=...) -> Integer | None: - ... - - + def eval(cls, n, sym=...) -> Integer | None: ... class lucas(Function): @classmethod - def eval(cls, n) -> None: - ... - - + def eval(cls, n) -> None: ... class tribonacci(Function): @classmethod - def eval(cls, n, sym=...) -> Integer | None: - ... - - + def eval(cls, n, sym=...) -> Integer | None: ... class bernoulli(Function): args: tTuple[Integer] _cache = ... _highest = ... @classmethod - def eval(cls, n, x=...) -> Self | Rational | Integer | Float | Any | None: - ... - - + def eval(cls, n, x=...) -> Self | Rational | Integer | Float | Any | None: ... class bell(Function): @classmethod - def eval(cls, n, k_sym=..., symbols=...) -> Integer | None: - ... - - + def eval(cls, n, k_sym=..., symbols=...) -> Integer | None: ... class harmonic(Function): @classmethod - def eval(cls, n, m=...) -> Self | type[UndefinedFunction] | Order | None: - ... - - def fdiff(self, argindex=...): - ... - - + def eval(cls, n, m=...) -> Self | type[UndefinedFunction] | Order | None: ... + def fdiff(self, argindex=...): ... class euler(Function): @classmethod - def eval(cls, n, x=...) -> Integer | Any | None: - ... - - + def eval(cls, n, x=...) -> Integer | Any | None: ... class catalan(Function): @classmethod - def eval(cls, n) -> Rational | Integer | None: - ... - - def fdiff(self, argindex=...): - ... - - + def eval(cls, n) -> Rational | Integer | None: ... + def fdiff(self, argindex=...): ... class genocchi(Function): @classmethod - def eval(cls, n, x=...) -> Self | Any | None: - ... - - + def eval(cls, n, x=...) -> Self | Any | None: ... class andre(Function): @classmethod - def eval(cls, n) -> None: - ... - - + def eval(cls, n) -> None: ... _npartition = ... + class partition(Function): @classmethod - def eval(cls, n) -> Integer | None: - ... - - - -class _MultisetHistogram(tuple): - ... + def eval(cls, n) -> Integer | None: ... +class _MultisetHistogram(tuple): ... _N = ... _ITEMS = ... _M = ... -def nP(n, k=..., replacement=...) -> Integer: - ... -def nC(n, k=..., replacement=...) -> int | type[UndefinedFunction]: - ... - -def stirling(n, k, d=..., kind=..., signed=...) -> type[UndefinedFunction] | Integer: - ... - -def nT(n, k=...): - ... +def nP(n, k=..., replacement=...) -> Integer: ... +def nC(n, k=..., replacement=...) -> int | type[UndefinedFunction]: ... +def stirling(n, k, d=..., kind=..., signed=...) -> type[UndefinedFunction] | Integer: ... +def nT(n, k=...): ... class motzkin(Function): @staticmethod - def is_motzkin(n) -> bool: - ... - + def is_motzkin(n) -> bool: ... @staticmethod - def find_motzkin_numbers_in_range(x, y) -> list[Any]: - ... - + def find_motzkin_numbers_in_range(x, y) -> list[Any]: ... @staticmethod - def find_first_n_motzkins(n) -> list[int]: - ... - + def find_first_n_motzkins(n) -> list[int]: ... @classmethod - def eval(cls, n) -> Integer: - ... - - - -def nD(i=..., brute=..., *, n=..., m=...): - ... + def eval(cls, n) -> Integer: ... +def nD(i=..., brute=..., *, n=..., m=...): ... diff --git a/stubs/sympy-stubs/functions/elementary/complexes.pyi b/stubs/sympy-stubs/functions/elementary/complexes.pyi index e10ffce7..e8bde77e 100644 --- a/stubs/sympy-stubs/functions/elementary/complexes.pyi +++ b/stubs/sympy-stubs/functions/elementary/complexes.pyi @@ -14,13 +14,8 @@ class re(Function): unbranched = ... _singularities = ... @classmethod - def eval(cls, arg) -> type[UndefinedFunction] | None: - ... - - def as_real_imag(self, deep=..., **hints) -> tuple[Self, Any]: - ... - - + def eval(cls, arg) -> type[UndefinedFunction] | None: ... + def as_real_imag(self, deep=..., **hints) -> tuple[Self, Any]: ... class im(Function): args: tTuple[Expr] @@ -28,25 +23,15 @@ class im(Function): unbranched = ... _singularities = ... @classmethod - def eval(cls, arg) -> None: - ... - - def as_real_imag(self, deep=..., **hints) -> tuple[Self, Any]: - ... - - + def eval(cls, arg) -> None: ... + def as_real_imag(self, deep=..., **hints) -> tuple[Self, Any]: ... class sign(Function): is_complex = ... _singularities = ... - def doit(self, **hints) -> Self: - ... - + def doit(self, **hints) -> Self: ... @classmethod - def eval(cls, arg) -> sign | None: - ... - - + def eval(cls, arg) -> sign | None: ... class Abs(Function): args: tTuple[Expr] @@ -55,14 +40,9 @@ class Abs(Function): is_extended_nonnegative = ... unbranched = ... _singularities = ... - def fdiff(self, argindex=...) -> type[UndefinedFunction]: - ... - + def fdiff(self, argindex=...) -> type[UndefinedFunction]: ... @classmethod - def eval(cls, arg): - ... - - + def eval(cls, arg): ... class arg(Function): is_extended_real = ... @@ -70,67 +50,49 @@ class arg(Function): is_finite = ... _singularities = ... @classmethod - def eval(cls, arg) -> type[UndefinedFunction] | Self | None: - ... - - + def eval(cls, arg) -> type[UndefinedFunction] | Self | None: ... class conjugate(Function): _singularities = ... @classmethod - def eval(cls, arg) -> None: - ... - - def inverse(self) -> type[conjugate]: - ... - - + def eval(cls, arg) -> None: ... + def inverse(self) -> type[conjugate]: ... class transpose(Function): @classmethod - def eval(cls, arg) -> None: - ... - - + def eval(cls, arg) -> None: ... class adjoint(Function): @classmethod - def eval(cls, arg) -> type[UndefinedFunction] | None: - ... - - + def eval(cls, arg) -> type[UndefinedFunction] | None: ... class polar_lift(Function): is_polar = ... is_comparable = ... @classmethod - def eval(cls, arg) -> Order | None: - ... - - + def eval(cls, arg) -> Order | None: ... class periodic_argument(Function): @classmethod - def eval(cls, ar, period) -> type[UndefinedFunction] | Literal[0] | None: - ... - + def eval(cls, ar, period) -> type[UndefinedFunction] | Literal[0] | None: ... - -def unbranched_argument(arg) -> type[UndefinedFunction]: - ... +def unbranched_argument(arg) -> type[UndefinedFunction]: ... class principal_branch(Function): is_polar = ... is_comparable = ... @classmethod - def eval(cls, x, period) -> type[UndefinedFunction] | None: - ... - - - -def polarify(eq, subs=..., lift=...) -> type[UndefinedFunction] | Symbol | Equality | Relational | Ne | Integral | tuple[Any | Symbol | Basic | Equality | Relational | Ne | Integral, dict[Dummy, Any | Symbol | Basic]]: - ... - -def unpolarify(eq, subs=..., exponents_only=...) -> bool | Basic: - ... - + def eval(cls, x, period) -> type[UndefinedFunction] | None: ... + +def polarify( + eq, subs=..., lift=... +) -> ( + type[UndefinedFunction] + | Symbol + | Equality + | Relational + | Ne + | Integral + | tuple[Any | Symbol | Basic | Equality | Relational | Ne | Integral, dict[Dummy, Any | Symbol | Basic]] +): ... +def unpolarify(eq, subs=..., exponents_only=...) -> bool | Basic: ... diff --git a/stubs/sympy-stubs/functions/elementary/exponential.pyi b/stubs/sympy-stubs/functions/elementary/exponential.pyi index a11031a4..02dd5037 100644 --- a/stubs/sympy-stubs/functions/elementary/exponential.pyi +++ b/stubs/sympy-stubs/functions/elementary/exponential.pyi @@ -12,97 +12,55 @@ class ExpBase(Function): unbranched = ... _singularities = ... @property - def kind(self) -> Kind: - ... - - def inverse(self, argindex=...) -> type[log]: - ... - - def as_numer_denom(self) -> tuple[Any, Self] | tuple[Self, Any]: - ... - + def kind(self) -> Kind: ... + def inverse(self, argindex=...) -> type[log]: ... + def as_numer_denom(self) -> tuple[Any, Self] | tuple[Self, Any]: ... @property - def exp(self) -> Basic: - ... - - def as_base_exp(self) -> tuple[Self, Any | Order]: - ... - - + def exp(self) -> Basic: ... + def as_base_exp(self) -> tuple[Self, Any | Order]: ... class exp_polar(ExpBase): is_polar = ... is_comparable = ... - def as_base_exp(self) -> tuple[Self, Any] | tuple[ExpBase, Any | Order]: - ... - - + def as_base_exp(self) -> tuple[Self, Any] | tuple[ExpBase, Any | Order]: ... class ExpMeta(FunctionClass): - def __instancecheck__(cls, instance) -> bool: - ... - - + def __instancecheck__(cls, instance) -> bool: ... class exp(ExpBase, metaclass=ExpMeta): - def fdiff(self, argindex=...) -> Self: - ... - + def fdiff(self, argindex=...) -> Self: ... @classmethod - def eval(cls, arg): - ... - + def eval(cls, arg): ... @property - def base(self): - ... - + def base(self): ... @staticmethod @cacheit - def taylor_term(n, x, *previous_terms): - ... - - def as_real_imag(self, deep=..., **hints) -> tuple[Any, Any]: - ... - - + def taylor_term(n, x, *previous_terms): ... + def as_real_imag(self, deep=..., **hints) -> tuple[Any, Any]: ... -def match_real_imag(expr) -> tuple[Any, Literal[0]] | tuple[Any, Any] | tuple[None, None]: - ... +def match_real_imag(expr) -> tuple[Any, Literal[0]] | tuple[Any, Any] | tuple[None, None]: ... class log(Function): args: tTuple[Expr] _singularities = ... - def fdiff(self, argindex=...): - ... - - def inverse(self, argindex=...) -> type[exp]: - ... - + def fdiff(self, argindex=...): ... + def inverse(self, argindex=...) -> type[exp]: ... @classmethod - def eval(cls, arg, base=...): - ... - - def as_base_exp(self) -> tuple[Self, Any]: - ... - + def eval(cls, arg, base=...): ... + def as_base_exp(self) -> tuple[Self, Any]: ... @staticmethod @cacheit - def taylor_term(n, x, *previous_terms): - ... - - def as_real_imag(self, deep=..., **hints) -> tuple[Self, Any] | tuple[Any, type[UndefinedFunction] | Any] | tuple[type[UndefinedFunction] | Any, type[UndefinedFunction] | Any]: - ... - - + def taylor_term(n, x, *previous_terms): ... + def as_real_imag( + self, deep=..., **hints + ) -> ( + tuple[Self, Any] + | tuple[Any, type[UndefinedFunction] | Any] + | tuple[type[UndefinedFunction] | Any, type[UndefinedFunction] | Any] + ): ... class LambertW(Function): _singularities = ... @classmethod - def eval(cls, x, k=...) -> Self | type[UndefinedFunction] | Integer | None: - ... - - def fdiff(self, argindex=...): - ... - - - + def eval(cls, x, k=...) -> Self | type[UndefinedFunction] | Integer | None: ... + def fdiff(self, argindex=...): ... diff --git a/stubs/sympy-stubs/functions/elementary/hyperbolic.pyi b/stubs/sympy-stubs/functions/elementary/hyperbolic.pyi index b785951e..2166f693 100644 --- a/stubs/sympy-stubs/functions/elementary/hyperbolic.pyi +++ b/stubs/sympy-stubs/functions/elementary/hyperbolic.pyi @@ -12,242 +12,133 @@ from sympy.series.order import Order class HyperbolicFunction(Function): unbranched = ... - class sinh(HyperbolicFunction): - def fdiff(self, argindex=...) -> type[UndefinedFunction]: - ... - - def inverse(self, argindex=...) -> type[asinh]: - ... - + def fdiff(self, argindex=...) -> type[UndefinedFunction]: ... + def inverse(self, argindex=...) -> type[asinh]: ... @classmethod - def eval(cls, arg) -> Mul | None: - ... - + def eval(cls, arg) -> Mul | None: ... @staticmethod @cacheit - def taylor_term(n, x, *previous_terms): - ... - - def as_real_imag(self, deep=..., **hints) -> tuple[Any | Order | Self, Any] | tuple[Self, Any] | tuple[Any, Any]: - ... - - + def taylor_term(n, x, *previous_terms): ... + def as_real_imag(self, deep=..., **hints) -> tuple[Any | Order | Self, Any] | tuple[Self, Any] | tuple[Any, Any]: ... class cosh(HyperbolicFunction): - def fdiff(self, argindex=...) -> type[UndefinedFunction]: - ... - + def fdiff(self, argindex=...) -> type[UndefinedFunction]: ... @classmethod - def eval(cls, arg) -> Self | type[UndefinedFunction] | Pow | None: - ... - + def eval(cls, arg) -> Self | type[UndefinedFunction] | Pow | None: ... @staticmethod @cacheit - def taylor_term(n, x, *previous_terms): - ... - - def as_real_imag(self, deep=..., **hints) -> tuple[Any | Order | Self, Any] | tuple[Self, Any] | tuple[Any, Any]: - ... - - + def taylor_term(n, x, *previous_terms): ... + def as_real_imag(self, deep=..., **hints) -> tuple[Any | Order | Self, Any] | tuple[Self, Any] | tuple[Any, Any]: ... class tanh(HyperbolicFunction): - def fdiff(self, argindex=...): - ... - - def inverse(self, argindex=...) -> type[atanh]: - ... - + def fdiff(self, argindex=...): ... + def inverse(self, argindex=...) -> type[atanh]: ... @classmethod - def eval(cls, arg) -> Mul | type[UndefinedFunction] | None: - ... - + def eval(cls, arg) -> Mul | type[UndefinedFunction] | None: ... @staticmethod @cacheit - def taylor_term(n, x, *previous_terms): - ... - - def as_real_imag(self, deep=..., **hints) -> tuple[Any | Order | Self, Any] | tuple[Self, Any] | tuple[Any, Any]: - ... - - + def taylor_term(n, x, *previous_terms): ... + def as_real_imag(self, deep=..., **hints) -> tuple[Any | Order | Self, Any] | tuple[Self, Any] | tuple[Any, Any]: ... class coth(HyperbolicFunction): - def fdiff(self, argindex=...): - ... - - def inverse(self, argindex=...) -> type[acoth]: - ... - + def fdiff(self, argindex=...): ... + def inverse(self, argindex=...) -> type[acoth]: ... @classmethod - def eval(cls, arg) -> Mul | type[UndefinedFunction] | None: - ... - + def eval(cls, arg) -> Mul | type[UndefinedFunction] | None: ... @staticmethod @cacheit - def taylor_term(n, x, *previous_terms): - ... - - def as_real_imag(self, deep=..., **hints) -> tuple[Any | Order | Self, Any] | tuple[Self, Any] | tuple[Any, Any]: - ... - - + def taylor_term(n, x, *previous_terms): ... + def as_real_imag(self, deep=..., **hints) -> tuple[Any | Order | Self, Any] | tuple[Self, Any] | tuple[Any, Any]: ... class ReciprocalHyperbolicFunction(HyperbolicFunction): _reciprocal_of = ... _is_even: FuzzyBool = ... _is_odd: FuzzyBool = ... @classmethod - def eval(cls, arg) -> Self | Mul: - ... - - def as_real_imag(self, deep=..., **hints): - ... - - + def eval(cls, arg) -> Self | Mul: ... + def as_real_imag(self, deep=..., **hints): ... class csch(ReciprocalHyperbolicFunction): _reciprocal_of = sinh _is_odd = ... - def fdiff(self, argindex=...): - ... - + def fdiff(self, argindex=...): ... @staticmethod @cacheit - def taylor_term(n, x, *previous_terms): - ... - - + def taylor_term(n, x, *previous_terms): ... class sech(ReciprocalHyperbolicFunction): _reciprocal_of = cosh _is_even = ... - def fdiff(self, argindex=...): - ... - + def fdiff(self, argindex=...): ... @staticmethod @cacheit - def taylor_term(n, x, *previous_terms): - ... - - - -class InverseHyperbolicFunction(Function): - ... + def taylor_term(n, x, *previous_terms): ... +class InverseHyperbolicFunction(Function): ... class asinh(InverseHyperbolicFunction): - def fdiff(self, argindex=...): - ... - + def fdiff(self, argindex=...): ... @classmethod - def eval(cls, arg) -> log | Mul | Basic | None: - ... - + def eval(cls, arg) -> log | Mul | Basic | None: ... @staticmethod @cacheit - def taylor_term(n, x, *previous_terms): - ... - - _eval_rewrite_as_tractable = ... - def inverse(self, argindex=...) -> type[sinh]: - ... - + def taylor_term(n, x, *previous_terms): ... + _eval_rewrite_as_tractable = ... + def inverse(self, argindex=...) -> type[sinh]: ... class acosh(InverseHyperbolicFunction): - def fdiff(self, argindex=...): - ... - + def fdiff(self, argindex=...): ... @classmethod - def eval(cls, arg): - ... - + def eval(cls, arg): ... @staticmethod @cacheit - def taylor_term(n, x, *previous_terms): - ... - - _eval_rewrite_as_tractable = ... - def inverse(self, argindex=...) -> type[cosh]: - ... - + def taylor_term(n, x, *previous_terms): ... + _eval_rewrite_as_tractable = ... + def inverse(self, argindex=...) -> type[cosh]: ... class atanh(InverseHyperbolicFunction): - def fdiff(self, argindex=...): - ... - + def fdiff(self, argindex=...): ... @classmethod - def eval(cls, arg) -> Mul | Basic | None: - ... - + def eval(cls, arg) -> Mul | Basic | None: ... @staticmethod @cacheit - def taylor_term(n, x, *previous_terms): - ... - - _eval_rewrite_as_tractable = ... - def inverse(self, argindex=...) -> type[tanh]: - ... - + def taylor_term(n, x, *previous_terms): ... + _eval_rewrite_as_tractable = ... + def inverse(self, argindex=...) -> type[tanh]: ... class acoth(InverseHyperbolicFunction): - def fdiff(self, argindex=...): - ... - + def fdiff(self, argindex=...): ... @classmethod - def eval(cls, arg) -> Mul | None: - ... - + def eval(cls, arg) -> Mul | None: ... @staticmethod @cacheit - def taylor_term(n, x, *previous_terms): - ... - - _eval_rewrite_as_tractable = ... - def inverse(self, argindex=...) -> type[coth]: - ... - + def taylor_term(n, x, *previous_terms): ... + _eval_rewrite_as_tractable = ... + def inverse(self, argindex=...) -> type[coth]: ... class asech(InverseHyperbolicFunction): - def fdiff(self, argindex=...): - ... - + def fdiff(self, argindex=...): ... @classmethod - def eval(cls, arg) -> None: - ... - + def eval(cls, arg) -> None: ... @staticmethod @cacheit - def taylor_term(n, x, *previous_terms) -> type[UndefinedFunction]: - ... - - def inverse(self, argindex=...) -> type[sech]: - ... - - _eval_rewrite_as_tractable = ... + def taylor_term(n, x, *previous_terms) -> type[UndefinedFunction]: ... + def inverse(self, argindex=...) -> type[sech]: ... + _eval_rewrite_as_tractable = ... class acsch(InverseHyperbolicFunction): - def fdiff(self, argindex=...): - ... - + def fdiff(self, argindex=...): ... @classmethod - def eval(cls, arg) -> log | Mul | None: - ... - + def eval(cls, arg) -> log | Mul | None: ... @staticmethod @cacheit - def taylor_term(n, x, *previous_terms) -> type[UndefinedFunction]: - ... - - def inverse(self, argindex=...) -> type[csch]: - ... - - _eval_rewrite_as_tractable = ... - + def taylor_term(n, x, *previous_terms) -> type[UndefinedFunction]: ... + def inverse(self, argindex=...) -> type[csch]: ... + _eval_rewrite_as_tractable = ... diff --git a/stubs/sympy-stubs/functions/elementary/miscellaneous.pyi b/stubs/sympy-stubs/functions/elementary/miscellaneous.pyi index 04d1d991..a1bdd974 100644 --- a/stubs/sympy-stubs/functions/elementary/miscellaneous.pyi +++ b/stubs/sympy-stubs/functions/elementary/miscellaneous.pyi @@ -14,38 +14,22 @@ from sympy.series.order import Order class IdentityFunction(Lambda, metaclass=Singleton): _symbol = ... @property - def signature(self) -> Tuple: - ... - + def signature(self) -> Tuple: ... @property - def expr(self) -> Dummy: - ... - - + def expr(self) -> Dummy: ... Id = ... -def sqrt(arg, evaluate=...) -> Pow: - ... - -def cbrt(arg, evaluate=...) -> Pow: - ... - -def root(arg, n, k=..., evaluate=...) -> Order | Pow: - ... -def real_root(arg, n=..., evaluate=...) -> Piecewise: - ... +def sqrt(arg, evaluate=...) -> Pow: ... +def cbrt(arg, evaluate=...) -> Pow: ... +def root(arg, n, k=..., evaluate=...) -> Order | Pow: ... +def real_root(arg, n=..., evaluate=...) -> Piecewise: ... class MinMaxBase(Expr, LatticeOp): - def __new__(cls, *args, **assumptions) -> Self: - ... - - def evalf(self, n=..., **options) -> Self: - ... - - def n(self, *args, **kwargs) -> Self: - ... - + def __new__(cls, *args, **assumptions) -> Self: ... + def evalf(self, n=..., **options) -> Self: ... + def n(self, *args, **kwargs) -> Self: ... + _eval_is_algebraic = ... _eval_is_antihermitian = ... _eval_is_commutative = ... @@ -73,28 +57,17 @@ class MinMaxBase(Expr, LatticeOp): _eval_is_transcendental = ... _eval_is_zero = ... - class Max(MinMaxBase, Application): zero = ... identity = ... - def fdiff(self, argindex) -> Heaviside: - ... - - + def fdiff(self, argindex) -> Heaviside: ... class Min(MinMaxBase, Application): zero = ... identity = ... - def fdiff(self, argindex) -> Heaviside: - ... - - + def fdiff(self, argindex) -> Heaviside: ... class Rem(Function): kind = ... @classmethod - def eval(cls, p, q) -> None: - ... - - - + def eval(cls, p, q) -> None: ... diff --git a/stubs/sympy-stubs/functions/elementary/piecewise.pyi b/stubs/sympy-stubs/functions/elementary/piecewise.pyi index 4a949750..17725ce6 100644 --- a/stubs/sympy-stubs/functions/elementary/piecewise.pyi +++ b/stubs/sympy-stubs/functions/elementary/piecewise.pyi @@ -4,43 +4,26 @@ from sympy.core import Function, Tuple from sympy.core.basic import Basic Undefined = ... + class ExprCondPair(Tuple): - def __new__(cls, expr, cond) -> Self: - ... - + def __new__(cls, expr, cond) -> Self: ... @property - def expr(self) -> Basic: - ... - + def expr(self) -> Basic: ... @property - def cond(self) -> Basic: - ... - + def cond(self) -> Basic: ... @property - def is_commutative(self) -> bool | None: - ... - - def __iter__(self) -> Generator[Basic, Any, None]: - ... - - + def is_commutative(self) -> bool | None: ... + def __iter__(self) -> Generator[Basic, Any, None]: ... class Piecewise(Function): nargs = ... is_Piecewise = ... - def __new__(cls, *args, **options) -> Self: - ... - + def __new__(cls, *args, **options) -> Self: ... @classmethod - def eval(cls, *_args) -> Self | None: - ... - - def doit(self, **hints) -> Self: - ... - - def piecewise_integrate(self, x, **kwargs) -> Self: - ... - + def eval(cls, *_args) -> Self | None: ... + def doit(self, **hints) -> Self: ... + def piecewise_integrate(self, x, **kwargs) -> Self: ... + _eval_is_finite = ... _eval_is_complex = ... _eval_is_even = ... @@ -62,21 +45,12 @@ class Piecewise(Function): _eval_is_extended_nonnegative = ... _eval_is_real = ... _eval_is_zero = ... - def as_expr_set_pairs(self, domain=...) -> list[Any]: - ... - + def as_expr_set_pairs(self, domain=...) -> list[Any]: ... - -def piecewise_fold(expr, evaluate=...) -> Basic | Piecewise: - ... - -def piecewise_simplify_arguments(expr, **kwargs): - ... +def piecewise_fold(expr, evaluate=...) -> Basic | Piecewise: ... +def piecewise_simplify_arguments(expr, **kwargs): ... _blessed = ... -def piecewise_simplify(expr, **kwargs) -> Piecewise: - ... - -def piecewise_exclusive(expr, *, skip_nan=..., deep=...) -> Piecewise: - ... +def piecewise_simplify(expr, **kwargs) -> Piecewise: ... +def piecewise_exclusive(expr, *, skip_nan=..., deep=...) -> Piecewise: ... diff --git a/stubs/sympy-stubs/functions/elementary/trigonometric.pyi b/stubs/sympy-stubs/functions/elementary/trigonometric.pyi index 8578ceb3..38c6d583 100644 --- a/stubs/sympy-stubs/functions/elementary/trigonometric.pyi +++ b/stubs/sympy-stubs/functions/elementary/trigonometric.pyi @@ -12,96 +12,47 @@ class TrigonometricFunction(Function): unbranched = ... _singularities = ... - class sin(TrigonometricFunction): - def period(self, symbol=...): - ... - - def fdiff(self, argindex=...) -> type[UndefinedFunction]: - ... - + def period(self, symbol=...): ... + def fdiff(self, argindex=...) -> type[UndefinedFunction]: ... @classmethod - def eval(cls, arg): - ... - + def eval(cls, arg): ... @staticmethod @cacheit - def taylor_term(n, x, *previous_terms): - ... - - def as_real_imag(self, deep=..., **hints) -> tuple[Any, Any]: - ... - - + def taylor_term(n, x, *previous_terms): ... + def as_real_imag(self, deep=..., **hints) -> tuple[Any, Any]: ... class cos(TrigonometricFunction): - def period(self, symbol=...): - ... - - def fdiff(self, argindex=...): - ... - + def period(self, symbol=...): ... + def fdiff(self, argindex=...): ... @classmethod - def eval(cls, arg): - ... - + def eval(cls, arg): ... @staticmethod @cacheit - def taylor_term(n, x, *previous_terms): - ... - - def as_real_imag(self, deep=..., **hints) -> tuple[Any, Any]: - ... - - + def taylor_term(n, x, *previous_terms): ... + def as_real_imag(self, deep=..., **hints) -> tuple[Any, Any]: ... class tan(TrigonometricFunction): - def period(self, symbol=...): - ... - - def fdiff(self, argindex=...): - ... - - def inverse(self, argindex=...) -> type[atan]: - ... - + def period(self, symbol=...): ... + def fdiff(self, argindex=...): ... + def inverse(self, argindex=...) -> type[atan]: ... @classmethod - def eval(cls, arg): - ... - + def eval(cls, arg): ... @staticmethod @cacheit - def taylor_term(n, x, *previous_terms): - ... - - def as_real_imag(self, deep=..., **hints) -> tuple[Any, Any] | tuple[Self, Any]: - ... - - + def taylor_term(n, x, *previous_terms): ... + def as_real_imag(self, deep=..., **hints) -> tuple[Any, Any] | tuple[Self, Any]: ... class cot(TrigonometricFunction): - def period(self, symbol=...): - ... - - def fdiff(self, argindex=...): - ... - - def inverse(self, argindex=...) -> type[acot]: - ... - + def period(self, symbol=...): ... + def fdiff(self, argindex=...): ... + def inverse(self, argindex=...) -> type[acot]: ... @classmethod - def eval(cls, arg): - ... - + def eval(cls, arg): ... @staticmethod @cacheit - def taylor_term(n, x, *previous_terms): - ... - - def as_real_imag(self, deep=..., **hints) -> tuple[Any, Any] | tuple[Self, Any]: - ... - - + def taylor_term(n, x, *previous_terms): ... + def as_real_imag(self, deep=..., **hints) -> tuple[Any, Any] | tuple[Self, Any]: ... class ReciprocalTrigonometricFunction(TrigonometricFunction): _reciprocal_of = ... @@ -109,189 +60,109 @@ class ReciprocalTrigonometricFunction(TrigonometricFunction): _is_even: FuzzyBool = ... _is_odd: FuzzyBool = ... @classmethod - def eval(cls, arg) -> Self | Mul: - ... - - def fdiff(self, argindex=...) -> Any: - ... - - def as_real_imag(self, deep=..., **hints): - ... - - + def eval(cls, arg) -> Self | Mul: ... + def fdiff(self, argindex=...) -> Any: ... + def as_real_imag(self, deep=..., **hints): ... class sec(ReciprocalTrigonometricFunction): _reciprocal_of = cos _is_even = ... - def period(self, symbol=...): - ... - - def fdiff(self, argindex=...): - ... - + def period(self, symbol=...): ... + def fdiff(self, argindex=...): ... @staticmethod @cacheit - def taylor_term(n, x, *previous_terms): - ... - - + def taylor_term(n, x, *previous_terms): ... class csc(ReciprocalTrigonometricFunction): _reciprocal_of = sin _is_odd = ... - def period(self, symbol=...): - ... - - def fdiff(self, argindex=...): - ... - + def period(self, symbol=...): ... + def fdiff(self, argindex=...): ... @staticmethod @cacheit - def taylor_term(n, x, *previous_terms): - ... - - + def taylor_term(n, x, *previous_terms): ... class sinc(Function): _singularities = ... - def fdiff(self, argindex=...): - ... - + def fdiff(self, argindex=...): ... @classmethod - def eval(cls, arg) -> Self | None: - ... - - _eval_is_finite = ... + def eval(cls, arg) -> Self | None: ... + _eval_is_finite = ... class InverseTrigonometricFunction(Function): _singularities: tTuple[Expr, ...] = ... - class asin(InverseTrigonometricFunction): - def fdiff(self, argindex=...): - ... - + def fdiff(self, argindex=...): ... @classmethod - def eval(cls, arg) -> Mul | None: - ... - + def eval(cls, arg) -> Mul | None: ... @staticmethod @cacheit - def taylor_term(n, x, *previous_terms): - ... - - _eval_rewrite_as_tractable = ... - def inverse(self, argindex=...) -> type[sin]: - ... - + def taylor_term(n, x, *previous_terms): ... + _eval_rewrite_as_tractable = ... + def inverse(self, argindex=...) -> type[sin]: ... class acos(InverseTrigonometricFunction): - def fdiff(self, argindex=...): - ... - + def fdiff(self, argindex=...): ... @classmethod - def eval(cls, arg) -> None: - ... - + def eval(cls, arg) -> None: ... @staticmethod @cacheit - def taylor_term(n, x, *previous_terms): - ... - - _eval_rewrite_as_tractable = ... - def inverse(self, argindex=...) -> type[cos]: - ... - + def taylor_term(n, x, *previous_terms): ... + _eval_rewrite_as_tractable = ... + def inverse(self, argindex=...) -> type[cos]: ... class atan(InverseTrigonometricFunction): args: tTuple[Expr] _singularities = ... - def fdiff(self, argindex=...): - ... - + def fdiff(self, argindex=...): ... @classmethod - def eval(cls, arg) -> AccumBounds | Mul | None: - ... - + def eval(cls, arg) -> AccumBounds | Mul | None: ... @staticmethod @cacheit - def taylor_term(n, x, *previous_terms): - ... - - _eval_rewrite_as_tractable = ... - def inverse(self, argindex=...) -> type[tan]: - ... - + def taylor_term(n, x, *previous_terms): ... + _eval_rewrite_as_tractable = ... + def inverse(self, argindex=...) -> type[tan]: ... class acot(InverseTrigonometricFunction): _singularities = ... - def fdiff(self, argindex=...): - ... - + def fdiff(self, argindex=...): ... @classmethod - def eval(cls, arg) -> Mul | None: - ... - + def eval(cls, arg) -> Mul | None: ... @staticmethod @cacheit - def taylor_term(n, x, *previous_terms): - ... - - _eval_rewrite_as_tractable = ... - def inverse(self, argindex=...) -> type[cot]: - ... - + def taylor_term(n, x, *previous_terms): ... + _eval_rewrite_as_tractable = ... + def inverse(self, argindex=...) -> type[cot]: ... class asec(InverseTrigonometricFunction): @classmethod - def eval(cls, arg) -> None: - ... - - def fdiff(self, argindex=...): - ... - - def inverse(self, argindex=...) -> type[sec]: - ... - + def eval(cls, arg) -> None: ... + def fdiff(self, argindex=...): ... + def inverse(self, argindex=...) -> type[sec]: ... @staticmethod @cacheit - def taylor_term(n, x, *previous_terms): - ... - - _eval_rewrite_as_tractable = ... + def taylor_term(n, x, *previous_terms): ... + _eval_rewrite_as_tractable = ... class acsc(InverseTrigonometricFunction): @classmethod - def eval(cls, arg) -> Mul | None: - ... - - def fdiff(self, argindex=...): - ... - - def inverse(self, argindex=...) -> type[csc]: - ... - + def eval(cls, arg) -> Mul | None: ... + def fdiff(self, argindex=...): ... + def inverse(self, argindex=...) -> type[csc]: ... @staticmethod @cacheit - def taylor_term(n, x, *previous_terms): - ... - - _eval_rewrite_as_tractable = ... + def taylor_term(n, x, *previous_terms): ... + _eval_rewrite_as_tractable = ... class atan2(InverseTrigonometricFunction): @classmethod - def eval(cls, y, x) -> atan | Piecewise | None: - ... - - def fdiff(self, argindex): - ... - - - + def eval(cls, y, x) -> atan | Piecewise | None: ... + def fdiff(self, argindex): ... diff --git a/stubs/sympy-stubs/functions/special/bessel.pyi b/stubs/sympy-stubs/functions/special/bessel.pyi index 385b3f02..3fe6968e 100644 --- a/stubs/sympy-stubs/functions/special/bessel.pyi +++ b/stubs/sympy-stubs/functions/special/bessel.pyi @@ -9,174 +9,105 @@ from sympy.core.numbers import Float class BesselBase(Function): @property - def order(self) -> Basic: - ... - + def order(self) -> Basic: ... @property - def argument(self) -> Basic: - ... - + def argument(self) -> Basic: ... @classmethod - def eval(cls, nu, z) -> None: - ... - - def fdiff(self, argindex=...): - ... - - + def eval(cls, nu, z) -> None: ... + def fdiff(self, argindex=...): ... class besselj(BesselBase): _a = ... _b = ... @classmethod - def eval(cls, nu, z) -> type[UndefinedFunction] | None: - ... - - + def eval(cls, nu, z) -> type[UndefinedFunction] | None: ... class bessely(BesselBase): _a = ... _b = ... @classmethod - def eval(cls, nu, z) -> None: - ... - - + def eval(cls, nu, z) -> None: ... class besseli(BesselBase): _a = ... _b = ... @classmethod - def eval(cls, nu, z) -> type[UndefinedFunction] | None: - ... - - + def eval(cls, nu, z) -> type[UndefinedFunction] | None: ... class besselk(BesselBase): _a = ... _b = ... @classmethod - def eval(cls, nu, z) -> type[UndefinedFunction] | None: - ... - - + def eval(cls, nu, z) -> type[UndefinedFunction] | None: ... class hankel1(BesselBase): _a = ... _b = ... - class hankel2(BesselBase): _a = ... _b = ... - -def assume_integer_order(fn) -> _Wrapped[..., Any, ..., Any | None]: - ... +def assume_integer_order(fn) -> _Wrapped[..., Any, ..., Any | None]: ... class SphericalBesselBase(BesselBase): - def fdiff(self, argindex=...): - ... - - + def fdiff(self, argindex=...): ... class jn(SphericalBesselBase): @classmethod - def eval(cls, nu, z) -> None: - ... - - - -class yn(SphericalBesselBase): - ... - - -class SphericalHankelBase(SphericalBesselBase): - ... + def eval(cls, nu, z) -> None: ... +class yn(SphericalBesselBase): ... +class SphericalHankelBase(SphericalBesselBase): ... class hn1(SphericalHankelBase): _hankel_kind_sign = ... - class hn2(SphericalHankelBase): _hankel_kind_sign = ... - -def jn_zeros(n, k, method=..., dps=...) -> list[Any | Float] | list[Any | NDArray[Any, Any] | NDArray[floating[Any], Any] | tuple[Any, Any] | Any]: - ... +def jn_zeros( + n, k, method=..., dps=... +) -> list[Any | Float] | list[Any | NDArray[Any, Any] | NDArray[floating[Any], Any] | tuple[Any, Any] | Any]: ... class AiryBase(Function): - def as_real_imag(self, deep=..., **hints) -> tuple[Any, Any]: - ... - - + def as_real_imag(self, deep=..., **hints) -> tuple[Any, Any]: ... class airyai(AiryBase): nargs = ... unbranched = ... @classmethod - def eval(cls, arg) -> None: - ... - - def fdiff(self, argindex=...) -> type[UndefinedFunction]: - ... - + def eval(cls, arg) -> None: ... + def fdiff(self, argindex=...) -> type[UndefinedFunction]: ... @staticmethod @cacheit - def taylor_term(n, x, *previous_terms): - ... - - + def taylor_term(n, x, *previous_terms): ... class airybi(AiryBase): nargs = ... unbranched = ... @classmethod - def eval(cls, arg) -> None: - ... - - def fdiff(self, argindex=...) -> type[UndefinedFunction]: - ... - + def eval(cls, arg) -> None: ... + def fdiff(self, argindex=...) -> type[UndefinedFunction]: ... @staticmethod @cacheit - def taylor_term(n, x, *previous_terms): - ... - - + def taylor_term(n, x, *previous_terms): ... class airyaiprime(AiryBase): nargs = ... unbranched = ... @classmethod - def eval(cls, arg) -> None: - ... - - def fdiff(self, argindex=...): - ... - - + def eval(cls, arg) -> None: ... + def fdiff(self, argindex=...): ... class airybiprime(AiryBase): nargs = ... unbranched = ... @classmethod - def eval(cls, arg) -> None: - ... - - def fdiff(self, argindex=...): - ... - - + def eval(cls, arg) -> None: ... + def fdiff(self, argindex=...): ... class marcumq(Function): @classmethod - def eval(cls, m, a, b) -> None: - ... - - def fdiff(self, argindex=...): - ... - - - + def eval(cls, m, a, b) -> None: ... + def fdiff(self, argindex=...): ... diff --git a/stubs/sympy-stubs/functions/special/beta_functions.pyi b/stubs/sympy-stubs/functions/special/beta_functions.pyi index 3da1fd9b..60512fff 100644 --- a/stubs/sympy-stubs/functions/special/beta_functions.pyi +++ b/stubs/sympy-stubs/functions/special/beta_functions.pyi @@ -2,39 +2,22 @@ from typing import Self from sympy.core.function import Function, UndefinedFunction -def betainc_mpmath_fix(a, b, x1, x2, reg=...): - ... +def betainc_mpmath_fix(a, b, x1, x2, reg=...): ... class beta(Function): unbranched = ... - def fdiff(self, argindex): - ... - + def fdiff(self, argindex): ... @classmethod - def eval(cls, x, y=...) -> type[UndefinedFunction] | None: - ... - - def doit(self, **hints) -> Self | type[UndefinedFunction]: - ... - - + def eval(cls, x, y=...) -> type[UndefinedFunction] | None: ... + def doit(self, **hints) -> Self | type[UndefinedFunction]: ... class betainc(Function): nargs = ... unbranched = ... - def fdiff(self, argindex): - ... - - + def fdiff(self, argindex): ... class betainc_regularized(Function): nargs = ... unbranched = ... - def __new__(cls, a, b, x1, x2) -> type[UndefinedFunction]: - ... - - def fdiff(self, argindex): - ... - - - + def __new__(cls, a, b, x1, x2) -> type[UndefinedFunction]: ... + def fdiff(self, argindex): ... diff --git a/stubs/sympy-stubs/functions/special/bsplines.pyi b/stubs/sympy-stubs/functions/special/bsplines.pyi index ed57c438..4d632a6e 100644 --- a/stubs/sympy-stubs/functions/special/bsplines.pyi +++ b/stubs/sympy-stubs/functions/special/bsplines.pyi @@ -5,12 +5,6 @@ from sympy.functions.elementary.piecewise import Piecewise from sympy.series.order import Order @lru_cache(maxsize=128) -def bspline_basis(d, knots, n, x) -> Piecewise | Order | Any: - ... - -def bspline_basis_set(d, knots, x) -> list[Any | Piecewise | Order]: - ... - -def interpolating_spline(d, x, X, Y) -> Piecewise: - ... - +def bspline_basis(d, knots, n, x) -> Piecewise | Order | Any: ... +def bspline_basis_set(d, knots, x) -> list[Any | Piecewise | Order]: ... +def interpolating_spline(d, x, X, Y) -> Piecewise: ... diff --git a/stubs/sympy-stubs/functions/special/delta_functions.pyi b/stubs/sympy-stubs/functions/special/delta_functions.pyi index 884eef82..378258ca 100644 --- a/stubs/sympy-stubs/functions/special/delta_functions.pyi +++ b/stubs/sympy-stubs/functions/special/delta_functions.pyi @@ -6,33 +6,16 @@ from sympy.core.mul import Mul class DiracDelta(Function): is_real = ... - def fdiff(self, argindex=...) -> Self: - ... - + def fdiff(self, argindex=...) -> Self: ... @classmethod - def eval(cls, arg, k=...) -> Mul | Self | None: - ... - - def is_simple(self, x) -> Literal[False]: - ... - - + def eval(cls, arg, k=...) -> Mul | Self | None: ... + def is_simple(self, x) -> Literal[False]: ... class Heaviside(Function): is_real = ... - def fdiff(self, argindex=...) -> type[UndefinedFunction]: - ... - - def __new__(cls, arg, H0=..., **options): - ... - + def fdiff(self, argindex=...) -> type[UndefinedFunction]: ... + def __new__(cls, arg, H0=..., **options): ... @property - def pargs(self) -> tuple[Basic, ...]: - ... - + def pargs(self) -> tuple[Basic, ...]: ... @classmethod - def eval(cls, arg, H0=...) -> None: - ... - - - + def eval(cls, arg, H0=...) -> None: ... diff --git a/stubs/sympy-stubs/functions/special/elliptic_integrals.pyi b/stubs/sympy-stubs/functions/special/elliptic_integrals.pyi index 76beb857..e8632ad2 100644 --- a/stubs/sympy-stubs/functions/special/elliptic_integrals.pyi +++ b/stubs/sympy-stubs/functions/special/elliptic_integrals.pyi @@ -3,41 +3,20 @@ from sympy.core.power import Pow class elliptic_k(Function): @classmethod - def eval(cls, m) -> None: - ... - - def fdiff(self, argindex=...): - ... - - + def eval(cls, m) -> None: ... + def fdiff(self, argindex=...): ... class elliptic_f(Function): @classmethod - def eval(cls, z, m) -> None: - ... - - def fdiff(self, argindex=...): - ... - - + def eval(cls, z, m) -> None: ... + def fdiff(self, argindex=...): ... class elliptic_e(Function): @classmethod - def eval(cls, m, z=...) -> None: - ... - - def fdiff(self, argindex=...) -> Pow: - ... - - + def eval(cls, m, z=...) -> None: ... + def fdiff(self, argindex=...) -> Pow: ... class elliptic_pi(Function): @classmethod - def eval(cls, n, m, z=...): - ... - - def fdiff(self, argindex=...): - ... - - - + def eval(cls, n, m, z=...): ... + def fdiff(self, argindex=...): ... diff --git a/stubs/sympy-stubs/functions/special/error_functions.pyi b/stubs/sympy-stubs/functions/special/error_functions.pyi index 52cc6faa..2254cb6f 100644 --- a/stubs/sympy-stubs/functions/special/error_functions.pyi +++ b/stubs/sympy-stubs/functions/special/error_functions.pyi @@ -7,239 +7,146 @@ from sympy.core.mul import Mul from sympy.functions.elementary.hyperbolic import cosh, sinh from sympy.functions.elementary.trigonometric import cos, sin -def real_to_real_as_real_imag(self, deep=..., **hints) -> tuple[Any, Any]: - ... +def real_to_real_as_real_imag(self, deep=..., **hints) -> tuple[Any, Any]: ... class erf(Function): unbranched = ... - def fdiff(self, argindex=...): - ... - - def inverse(self, argindex=...) -> type[erfinv]: - ... - + def fdiff(self, argindex=...): ... + def inverse(self, argindex=...) -> type[erfinv]: ... @classmethod - def eval(cls, arg) -> Basic | erf2inv | Mul | None: - ... - + def eval(cls, arg) -> Basic | erf2inv | Mul | None: ... @staticmethod @cacheit - def taylor_term(n, x, *previous_terms): - ... - - as_real_imag = ... + def taylor_term(n, x, *previous_terms): ... + as_real_imag = ... class erfc(Function): unbranched = ... - def fdiff(self, argindex=...): - ... - - def inverse(self, argindex=...) -> type[erfcinv]: - ... - + def fdiff(self, argindex=...): ... + def inverse(self, argindex=...) -> type[erfcinv]: ... @classmethod - def eval(cls, arg) -> Basic | None: - ... - + def eval(cls, arg) -> Basic | None: ... @staticmethod @cacheit - def taylor_term(n, x, *previous_terms): - ... - - as_real_imag = ... + def taylor_term(n, x, *previous_terms): ... + as_real_imag = ... class erfi(Function): unbranched = ... - def fdiff(self, argindex=...): - ... - + def fdiff(self, argindex=...): ... @classmethod - def eval(cls, z) -> Mul | None: - ... - + def eval(cls, z) -> Mul | None: ... @staticmethod @cacheit - def taylor_term(n, x, *previous_terms): - ... - - as_real_imag = ... + def taylor_term(n, x, *previous_terms): ... + as_real_imag = ... class erf2(Function): - def fdiff(self, argindex): - ... - + def fdiff(self, argindex): ... @classmethod - def eval(cls, x, y) -> Basic | Mul | None: - ... - - + def eval(cls, x, y) -> Basic | Mul | None: ... class erfinv(Function): - def fdiff(self, argindex=...): - ... - - def inverse(self, argindex=...) -> type[erf]: - ... - + def fdiff(self, argindex=...): ... + def inverse(self, argindex=...) -> type[erf]: ... @classmethod - def eval(cls, z) -> Basic | None: - ... - - + def eval(cls, z) -> Basic | None: ... class erfcinv(Function): - def fdiff(self, argindex=...): - ... - - def inverse(self, argindex=...) -> type[erfc]: - ... - + def fdiff(self, argindex=...): ... + def inverse(self, argindex=...) -> type[erfc]: ... @classmethod - def eval(cls, z) -> None: - ... - - + def eval(cls, z) -> None: ... class erf2inv(Function): - def fdiff(self, argindex) -> type[UndefinedFunction]: - ... - + def fdiff(self, argindex) -> type[UndefinedFunction]: ... @classmethod - def eval(cls, x, y) -> type[UndefinedFunction] | None: - ... - - + def eval(cls, x, y) -> type[UndefinedFunction] | None: ... class Ei(Function): @classmethod - def eval(cls, z) -> None: - ... - - def fdiff(self, argindex=...): - ... - + def eval(cls, z) -> None: ... + def fdiff(self, argindex=...): ... + _eval_rewrite_as_Ci = ... _eval_rewrite_as_Chi = ... _eval_rewrite_as_Shi = ... - class expint(Function): @classmethod - def eval(cls, nu, z) -> type[UndefinedFunction] | bool | Basic | None: - ... - - def fdiff(self, argindex) -> Mul: - ... - + def eval(cls, nu, z) -> type[UndefinedFunction] | bool | Basic | None: ... + def fdiff(self, argindex) -> Mul: ... + _eval_rewrite_as_Ci = ... _eval_rewrite_as_Chi = ... _eval_rewrite_as_Shi = ... - -def E1(z) -> type[UndefinedFunction]: - ... +def E1(z) -> type[UndefinedFunction]: ... class li(Function): @classmethod - def eval(cls, z) -> None: - ... - - def fdiff(self, argindex=...): - ... - + def eval(cls, z) -> None: ... + def fdiff(self, argindex=...): ... + _eval_rewrite_as_Ci = ... _eval_rewrite_as_Chi = ... - class Li(Function): @classmethod - def eval(cls, z) -> None: - ... - - def fdiff(self, argindex=...): - ... - - + def eval(cls, z) -> None: ... + def fdiff(self, argindex=...): ... class TrigonometricIntegral(Function): @classmethod - def eval(cls, z) -> None: - ... - - def fdiff(self, argindex=...): - ... - - + def eval(cls, z) -> None: ... + def fdiff(self, argindex=...): ... class Si(TrigonometricIntegral): _trigfunc = sin _atzero = ... - class Ci(TrigonometricIntegral): _trigfunc = cos _atzero = ... - class Shi(TrigonometricIntegral): _trigfunc = sinh _atzero = ... - class Chi(TrigonometricIntegral): _trigfunc = cosh _atzero = ... - class FresnelIntegral(Function): unbranched = ... @classmethod - def eval(cls, z) -> None: - ... - - def fdiff(self, argindex=...): - ... - + def eval(cls, z) -> None: ... + def fdiff(self, argindex=...): ... + _eval_is_finite = ... as_real_imag = ... - class fresnels(FresnelIntegral): _trigfunc = sin _sign = ... @staticmethod @cacheit - def taylor_term(n, x, *previous_terms): - ... - - + def taylor_term(n, x, *previous_terms): ... class fresnelc(FresnelIntegral): _trigfunc = cos _sign = ... @staticmethod @cacheit - def taylor_term(n, x, *previous_terms): - ... - - + def taylor_term(n, x, *previous_terms): ... class _erfs(Function): @classmethod - def eval(cls, arg) -> None: - ... - - def fdiff(self, argindex=...): - ... - - + def eval(cls, arg) -> None: ... + def fdiff(self, argindex=...): ... class _eis(Function): - def fdiff(self, argindex=...): - ... - - - + def fdiff(self, argindex=...): ... diff --git a/stubs/sympy-stubs/functions/special/gamma_functions.pyi b/stubs/sympy-stubs/functions/special/gamma_functions.pyi index 2e20e266..50f86f07 100644 --- a/stubs/sympy-stubs/functions/special/gamma_functions.pyi +++ b/stubs/sympy-stubs/functions/special/gamma_functions.pyi @@ -1,88 +1,46 @@ from sympy.core.function import Function, UndefinedFunction -def intlike(n) -> bool: - ... +def intlike(n) -> bool: ... class gamma(Function): unbranched = ... _singularities = ... - def fdiff(self, argindex=...): - ... - + def fdiff(self, argindex=...): ... @classmethod - def eval(cls, arg) -> type[UndefinedFunction] | None: - ... - - + def eval(cls, arg) -> type[UndefinedFunction] | None: ... class lowergamma(Function): - def fdiff(self, argindex=...): - ... - + def fdiff(self, argindex=...): ... @classmethod - def eval(cls, a, x) -> type[UndefinedFunction] | None: - ... - - + def eval(cls, a, x) -> type[UndefinedFunction] | None: ... class uppergamma(Function): - def fdiff(self, argindex=...): - ... - + def fdiff(self, argindex=...): ... @classmethod - def eval(cls, a, z): - ... - - + def eval(cls, a, z): ... class polygamma(Function): @classmethod - def eval(cls, n, z) -> type[UndefinedFunction] | None: - ... - - def fdiff(self, argindex=...) -> polygamma: - ... - - + def eval(cls, n, z) -> type[UndefinedFunction] | None: ... + def fdiff(self, argindex=...) -> polygamma: ... class loggamma(Function): @classmethod - def eval(cls, z) -> type[UndefinedFunction] | None: - ... - - def fdiff(self, argindex=...) -> type[UndefinedFunction]: - ... - - + def eval(cls, z) -> type[UndefinedFunction] | None: ... + def fdiff(self, argindex=...) -> type[UndefinedFunction]: ... class digamma(Function): - def fdiff(self, argindex=...): - ... - + def fdiff(self, argindex=...): ... @classmethod - def eval(cls, z) -> type[UndefinedFunction]: - ... - - + def eval(cls, z) -> type[UndefinedFunction]: ... class trigamma(Function): - def fdiff(self, argindex=...): - ... - + def fdiff(self, argindex=...): ... @classmethod - def eval(cls, z) -> type[UndefinedFunction]: - ... - - + def eval(cls, z) -> type[UndefinedFunction]: ... class multigamma(Function): unbranched = ... - def fdiff(self, argindex=...): - ... - + def fdiff(self, argindex=...): ... @classmethod - def eval(cls, x, p): - ... - - - + def eval(cls, x, p): ... diff --git a/stubs/sympy-stubs/functions/special/hyper.pyi b/stubs/sympy-stubs/functions/special/hyper.pyi index dd5b483b..3e3af77b 100644 --- a/stubs/sympy-stubs/functions/special/hyper.pyi +++ b/stubs/sympy-stubs/functions/special/hyper.pyi @@ -6,165 +6,72 @@ from sympy.core.function import Derivative, Function, UndefinedFunction from sympy.core.logic import Or class TupleArg(Tuple): - def limit(self, x, xlim, dir=...) -> TupleArg: - ... - - + def limit(self, x, xlim, dir=...) -> TupleArg: ... class TupleParametersBase(Function): is_commutative = ... - class hyper(TupleParametersBase): - def __new__(cls, ap, bq, z, **kwargs) -> type[UndefinedFunction]: - ... - + def __new__(cls, ap, bq, z, **kwargs) -> type[UndefinedFunction]: ... @classmethod - def eval(cls, ap, bq, z) -> type[UndefinedFunction] | None: - ... - - def fdiff(self, argindex=...): - ... - - @property - def argument(self) -> Basic: - ... - - @property - def ap(self) -> Tuple: - ... - - @property - def bq(self) -> Tuple: - ... - - @property - def eta(self): - ... - - @property - def radius_of_convergence(self): - ... - - @property - def convergence_statement(self) -> Or | bool: - ... - - + def eval(cls, ap, bq, z) -> type[UndefinedFunction] | None: ... + def fdiff(self, argindex=...): ... + @property + def argument(self) -> Basic: ... + @property + def ap(self) -> Tuple: ... + @property + def bq(self) -> Tuple: ... + @property + def eta(self): ... + @property + def radius_of_convergence(self): ... + @property + def convergence_statement(self) -> Or | bool: ... class meijerg(TupleParametersBase): - def __new__(cls, *args, **kwargs) -> type[UndefinedFunction]: - ... - - def fdiff(self, argindex=...): - ... - - def get_period(self): - ... - - def integrand(self, s): - ... - - @property - def argument(self) -> Basic: - ... - - @property - def an(self) -> Tuple: - ... - - @property - def ap(self) -> Tuple: - ... - - @property - def aother(self) -> Tuple: - ... - - @property - def bm(self) -> Tuple: - ... - - @property - def bq(self) -> Tuple: - ... - - @property - def bother(self) -> Tuple: - ... - - @property - def nu(self): - ... - - @property - def delta(self): - ... - - @property - def is_number(self) -> bool: - ... - - + def __new__(cls, *args, **kwargs) -> type[UndefinedFunction]: ... + def fdiff(self, argindex=...): ... + def get_period(self): ... + def integrand(self, s): ... + @property + def argument(self) -> Basic: ... + @property + def an(self) -> Tuple: ... + @property + def ap(self) -> Tuple: ... + @property + def aother(self) -> Tuple: ... + @property + def bm(self) -> Tuple: ... + @property + def bq(self) -> Tuple: ... + @property + def bother(self) -> Tuple: ... + @property + def nu(self): ... + @property + def delta(self): ... + @property + def is_number(self) -> bool: ... class HyperRep(Function): @classmethod - def eval(cls, *args) -> Self | None: - ... - - - -class HyperRep_power1(HyperRep): - ... - - -class HyperRep_power2(HyperRep): - ... - - -class HyperRep_log1(HyperRep): - ... - - -class HyperRep_atanh(HyperRep): - ... - - -class HyperRep_asin1(HyperRep): - ... - - -class HyperRep_asin2(HyperRep): - ... - - -class HyperRep_sqrts1(HyperRep): - ... - - -class HyperRep_sqrts2(HyperRep): - ... - - -class HyperRep_log2(HyperRep): - ... - - -class HyperRep_cosasin(HyperRep): - ... - - -class HyperRep_sinasin(HyperRep): - ... - + def eval(cls, *args) -> Self | None: ... + +class HyperRep_power1(HyperRep): ... +class HyperRep_power2(HyperRep): ... +class HyperRep_log1(HyperRep): ... +class HyperRep_atanh(HyperRep): ... +class HyperRep_asin1(HyperRep): ... +class HyperRep_asin2(HyperRep): ... +class HyperRep_sqrts1(HyperRep): ... +class HyperRep_sqrts2(HyperRep): ... +class HyperRep_log2(HyperRep): ... +class HyperRep_cosasin(HyperRep): ... +class HyperRep_sinasin(HyperRep): ... class appellf1(Function): @classmethod - def eval(cls, a, b1, b2, c, x, y) -> Self | None: - ... - - def fdiff(self, argindex=...) -> Derivative: - ... - - - + def eval(cls, a, b1, b2, c, x, y) -> Self | None: ... + def fdiff(self, argindex=...) -> Derivative: ... diff --git a/stubs/sympy-stubs/functions/special/mathieu_functions.pyi b/stubs/sympy-stubs/functions/special/mathieu_functions.pyi index 88cccf90..fe024fcf 100644 --- a/stubs/sympy-stubs/functions/special/mathieu_functions.pyi +++ b/stubs/sympy-stubs/functions/special/mathieu_functions.pyi @@ -6,44 +6,22 @@ from sympy.core.mul import Mul class MathieuBase(Function): unbranched = ... - class mathieus(MathieuBase): - def fdiff(self, argindex=...) -> type[UndefinedFunction]: - ... - + def fdiff(self, argindex=...) -> type[UndefinedFunction]: ... @classmethod - def eval(cls, a, q, z) -> type[UndefinedFunction] | Mul | None: - ... - - + def eval(cls, a, q, z) -> type[UndefinedFunction] | Mul | None: ... class mathieuc(MathieuBase): - def fdiff(self, argindex=...) -> type[UndefinedFunction]: - ... - + def fdiff(self, argindex=...) -> type[UndefinedFunction]: ... @classmethod - def eval(cls, a, q, z) -> type[UndefinedFunction] | Self | None: - ... - - + def eval(cls, a, q, z) -> type[UndefinedFunction] | Self | None: ... class mathieusprime(MathieuBase): - def fdiff(self, argindex=...): - ... - + def fdiff(self, argindex=...): ... @classmethod - def eval(cls, a, q, z) -> Self | None: - ... - - + def eval(cls, a, q, z) -> Self | None: ... class mathieucprime(MathieuBase): - def fdiff(self, argindex=...): - ... - + def fdiff(self, argindex=...): ... @classmethod - def eval(cls, a, q, z) -> Mul | None: - ... - - - + def eval(cls, a, q, z) -> Mul | None: ... diff --git a/stubs/sympy-stubs/functions/special/polynomials.pyi b/stubs/sympy-stubs/functions/special/polynomials.pyi index dfca6dbd..19600b71 100644 --- a/stubs/sympy-stubs/functions/special/polynomials.pyi +++ b/stubs/sympy-stubs/functions/special/polynomials.pyi @@ -6,130 +6,71 @@ from sympy.core.mul import Mul from sympy.core.relational import Equality, Ne, Relational _x = ... -class OrthogonalPolynomial(Function): - ... +class OrthogonalPolynomial(Function): ... class jacobi(OrthogonalPolynomial): @classmethod - def eval(cls, n, a, b, x) -> type[UndefinedFunction] | Any | None: - ... - - def fdiff(self, argindex=...) -> Equality | Relational | Ne | Sum: - ... - + def eval(cls, n, a, b, x) -> type[UndefinedFunction] | Any | None: ... + def fdiff(self, argindex=...) -> Equality | Relational | Ne | Sum: ... - -def jacobi_normalized(n, a, b, x): - ... +def jacobi_normalized(n, a, b, x): ... class gegenbauer(OrthogonalPolynomial): @classmethod - def eval(cls, n, a, x) -> type[UndefinedFunction] | None: - ... - - def fdiff(self, argindex=...) -> Equality | Relational | Ne | Sum: - ... - - + def eval(cls, n, a, x) -> type[UndefinedFunction] | None: ... + def fdiff(self, argindex=...) -> Equality | Relational | Ne | Sum: ... class chebyshevt(OrthogonalPolynomial): _ortho_poly = ... @classmethod - def eval(cls, n, x) -> type[UndefinedFunction] | None: - ... - - def fdiff(self, argindex=...): - ... - - + def eval(cls, n, x) -> type[UndefinedFunction] | None: ... + def fdiff(self, argindex=...): ... class chebyshevu(OrthogonalPolynomial): _ortho_poly = ... @classmethod - def eval(cls, n, x) -> type[UndefinedFunction] | None: - ... - - def fdiff(self, argindex=...): - ... - - + def eval(cls, n, x) -> type[UndefinedFunction] | None: ... + def fdiff(self, argindex=...): ... class chebyshevt_root(Function): @classmethod - def eval(cls, n, k) -> type[UndefinedFunction]: - ... - - + def eval(cls, n, k) -> type[UndefinedFunction]: ... class chebyshevu_root(Function): @classmethod - def eval(cls, n, k) -> type[UndefinedFunction]: - ... - - + def eval(cls, n, k) -> type[UndefinedFunction]: ... class legendre(OrthogonalPolynomial): _ortho_poly = ... @classmethod - def eval(cls, n, x) -> type[UndefinedFunction] | None: - ... - - def fdiff(self, argindex=...): - ... - - + def eval(cls, n, x) -> type[UndefinedFunction] | None: ... + def fdiff(self, argindex=...): ... class assoc_legendre(Function): @classmethod - def eval(cls, n, m, x) -> type[UndefinedFunction] | None: - ... - - def fdiff(self, argindex=...): - ... - - + def eval(cls, n, m, x) -> type[UndefinedFunction] | None: ... + def fdiff(self, argindex=...): ... class hermite(OrthogonalPolynomial): _ortho_poly = ... @classmethod - def eval(cls, n, x) -> None: - ... - - def fdiff(self, argindex=...): - ... - - + def eval(cls, n, x) -> None: ... + def fdiff(self, argindex=...): ... class hermite_prob(OrthogonalPolynomial): _ortho_poly = ... @classmethod - def eval(cls, n, x) -> None: - ... - - def fdiff(self, argindex=...): - ... - - + def eval(cls, n, x) -> None: ... + def fdiff(self, argindex=...): ... class laguerre(OrthogonalPolynomial): _ortho_poly = ... @classmethod - def eval(cls, n, x) -> None: - ... - - def fdiff(self, argindex=...) -> Mul: - ... - - + def eval(cls, n, x) -> None: ... + def fdiff(self, argindex=...) -> Mul: ... class assoc_laguerre(OrthogonalPolynomial): @classmethod - def eval(cls, n, alpha, x) -> type[UndefinedFunction] | Any | None: - ... - - def fdiff(self, argindex=...) -> Equality | Relational | Ne | Sum | Mul: - ... - - - + def eval(cls, n, alpha, x) -> type[UndefinedFunction] | Any | None: ... + def fdiff(self, argindex=...) -> Equality | Relational | Ne | Sum | Mul: ... diff --git a/stubs/sympy-stubs/functions/special/singularity_functions.pyi b/stubs/sympy-stubs/functions/special/singularity_functions.pyi index 63768bfc..2b2bcaca 100644 --- a/stubs/sympy-stubs/functions/special/singularity_functions.pyi +++ b/stubs/sympy-stubs/functions/special/singularity_functions.pyi @@ -4,14 +4,9 @@ from sympy.core.function import Function class SingularityFunction(Function): is_real = ... - def fdiff(self, argindex=...) -> Self | None: - ... - + def fdiff(self, argindex=...) -> Self | None: ... @classmethod - def eval(cls, variable, offset, exponent) -> None: - ... - + def eval(cls, variable, offset, exponent) -> None: ... + _eval_rewrite_as_DiracDelta = ... _eval_rewrite_as_HeavisideDiracDelta = ... - - diff --git a/stubs/sympy-stubs/functions/special/spherical_harmonics.pyi b/stubs/sympy-stubs/functions/special/spherical_harmonics.pyi index 0fa42504..9e978a87 100644 --- a/stubs/sympy-stubs/functions/special/spherical_harmonics.pyi +++ b/stubs/sympy-stubs/functions/special/spherical_harmonics.pyi @@ -3,26 +3,15 @@ from typing import Any from sympy.core.function import Function, UndefinedFunction _x = ... + class Ynm(Function): @classmethod - def eval(cls, n, m, theta, phi) -> type[UndefinedFunction] | None: - ... - - def fdiff(self, argindex=...): - ... - - def as_real_imag(self, deep=..., **hints) -> tuple[Any, Any]: - ... - - + def eval(cls, n, m, theta, phi) -> type[UndefinedFunction] | None: ... + def fdiff(self, argindex=...): ... + def as_real_imag(self, deep=..., **hints) -> tuple[Any, Any]: ... -def Ynm_c(n, m, theta, phi) -> type[UndefinedFunction]: - ... +def Ynm_c(n, m, theta, phi) -> type[UndefinedFunction]: ... class Znm(Function): @classmethod - def eval(cls, n, m, theta, phi) -> type[UndefinedFunction] | None: - ... - - - + def eval(cls, n, m, theta, phi) -> type[UndefinedFunction] | None: ... diff --git a/stubs/sympy-stubs/functions/special/tensor_functions.pyi b/stubs/sympy-stubs/functions/special/tensor_functions.pyi index f14bed12..dc871073 100644 --- a/stubs/sympy-stubs/functions/special/tensor_functions.pyi +++ b/stubs/sympy-stubs/functions/special/tensor_functions.pyi @@ -3,64 +3,34 @@ from typing import Literal, Self from sympy.core.basic import Basic from sympy.core.function import Function, UndefinedFunction -def Eijk(*args, **kwargs) -> type[UndefinedFunction]: - ... - -def eval_levicivita(*args): - ... +def Eijk(*args, **kwargs) -> type[UndefinedFunction]: ... +def eval_levicivita(*args): ... class LeviCivita(Function): is_integer = ... @classmethod - def eval(cls, *args) -> None: - ... - - def doit(self, **hints): - ... - - + def eval(cls, *args) -> None: ... + def doit(self, **hints): ... class KroneckerDelta(Function): is_integer = ... @classmethod - def eval(cls, i, j, delta_range=...) -> Self | None: - ... - + def eval(cls, i, j, delta_range=...) -> Self | None: ... @property - def delta_range(self) -> Basic | None: - ... - + def delta_range(self) -> Basic | None: ... @property - def is_above_fermi(self) -> bool: - ... - + def is_above_fermi(self) -> bool: ... @property - def is_below_fermi(self) -> bool: - ... - + def is_below_fermi(self) -> bool: ... @property - def is_only_above_fermi(self) -> Literal[False]: - ... - + def is_only_above_fermi(self) -> Literal[False]: ... @property - def is_only_below_fermi(self) -> Literal[False]: - ... - + def is_only_below_fermi(self) -> Literal[False]: ... @property - def indices_contain_equal_information(self) -> bool: - ... - + def indices_contain_equal_information(self) -> bool: ... @property - def preferred_index(self) -> Basic: - ... - + def preferred_index(self) -> Basic: ... @property - def killable_index(self) -> Basic: - ... - + def killable_index(self) -> Basic: ... @property - def indices(self) -> tuple[Basic, ...]: - ... - - - + def indices(self) -> tuple[Basic, ...]: ... diff --git a/stubs/sympy-stubs/functions/special/zeta_functions.pyi b/stubs/sympy-stubs/functions/special/zeta_functions.pyi index d31b55b0..f4efc436 100644 --- a/stubs/sympy-stubs/functions/special/zeta_functions.pyi +++ b/stubs/sympy-stubs/functions/special/zeta_functions.pyi @@ -3,49 +3,26 @@ from typing import Self from sympy.core.function import Function, UndefinedFunction class lerchphi(Function): - def fdiff(self, argindex=...): - ... - - + def fdiff(self, argindex=...): ... class polylog(Function): @classmethod - def eval(cls, s, z) -> type[UndefinedFunction] | Self | None: - ... - - def fdiff(self, argindex=...): - ... - - + def eval(cls, s, z) -> type[UndefinedFunction] | Self | None: ... + def fdiff(self, argindex=...): ... class zeta(Function): @classmethod - def eval(cls, s, a=...) -> Self | None: - ... - - def fdiff(self, argindex=...): - ... - - + def eval(cls, s, a=...) -> Self | None: ... + def fdiff(self, argindex=...): ... class dirichlet_eta(Function): @classmethod - def eval(cls, s, a=...) -> Self | type[UndefinedFunction] | None: - ... - - + def eval(cls, s, a=...) -> Self | type[UndefinedFunction] | None: ... class riemann_xi(Function): @classmethod - def eval(cls, s) -> None: - ... - - + def eval(cls, s) -> None: ... class stieltjes(Function): @classmethod - def eval(cls, n, a=...) -> None: - ... - - - + def eval(cls, n, a=...) -> None: ... diff --git a/stubs/sympy-stubs/geometry/curve.pyi b/stubs/sympy-stubs/geometry/curve.pyi index 059a2c1a..ab9a172e 100644 --- a/stubs/sympy-stubs/geometry/curve.pyi +++ b/stubs/sympy-stubs/geometry/curve.pyi @@ -7,50 +7,22 @@ from sympy.geometry.entity import GeometrySet from sympy.geometry.point import Point, Point2D, Point3D class Curve(GeometrySet): - def __new__(cls, function, limits) -> Self: - ... - - def __call__(self, f) -> Self | Basic: - ... - - def arbitrary_point(self, parameter=...) -> Point | Point2D | Point3D: - ... - + def __new__(cls, function, limits) -> Self: ... + def __call__(self, f) -> Self | Basic: ... + def arbitrary_point(self, parameter=...) -> Point | Point2D | Point3D: ... @property - def free_symbols(self) -> set[Any]: - ... - + def free_symbols(self) -> set[Any]: ... @property - def ambient_dimension(self) -> int: - ... - + def ambient_dimension(self) -> int: ... @property - def functions(self) -> Basic: - ... - + def functions(self) -> Basic: ... @property - def limits(self) -> Basic: - ... - + def limits(self) -> Basic: ... @property - def parameter(self): - ... - + def parameter(self): ... @property - def length(self) -> Equality | Relational | Ne: - ... - - def plot_interval(self, parameter=...) -> list[Any | Symbol]: - ... - - def rotate(self, angle=..., pt=...) -> Self: - ... - - def scale(self, x=..., y=..., pt=...) -> Self: - ... - - def translate(self, x=..., y=...) -> Self: - ... - - - + def length(self) -> Equality | Relational | Ne: ... + def plot_interval(self, parameter=...) -> list[Any | Symbol]: ... + def rotate(self, angle=..., pt=...) -> Self: ... + def scale(self, x=..., y=..., pt=...) -> Self: ... + def translate(self, x=..., y=...) -> Self: ... diff --git a/stubs/sympy-stubs/geometry/ellipse.pyi b/stubs/sympy-stubs/geometry/ellipse.pyi index 8e2bf99a..2070a5c7 100644 --- a/stubs/sympy-stubs/geometry/ellipse.pyi +++ b/stubs/sympy-stubs/geometry/ellipse.pyi @@ -8,161 +8,70 @@ from sympy.geometry.line import Line, Line2D, Line3D, Segment, Segment2D, Segmen from sympy.geometry.point import Point, Point2D, Point3D class Ellipse(GeometrySet): - def __contains__(self, o) -> bool | NotImplementedType: - ... - - def __eq__(self, o) -> bool: - ... - - def __hash__(self) -> int: - ... - - def __new__(cls, center=..., hradius=..., vradius=..., eccentricity=..., **kwargs) -> Circle | Point | Point2D | Point3D | Segment2D | Segment3D | Segment | Self | None: - ... - - @property - def ambient_dimension(self) -> Literal[2]: - ... - - @property - def apoapsis(self): - ... - - def arbitrary_point(self, parameter=...) -> Point | Point2D | Point3D: - ... - - @property - def area(self): - ... - - @property - def bounds(self) -> tuple[Any, Any, Any, Any]: - ... - - @property - def center(self) -> Basic: - ... - - @property - def circumference(self): - ... - - @property - def eccentricity(self): - ... - - def encloses_point(self, p) -> bool | None: - ... - - def equation(self, x=..., y=..., _slope=...): - ... - - def evolute(self, x=..., y=...): - ... - - @property - def foci(self) -> tuple[Basic, Basic] | tuple[Any, Any] | None: - ... - - @property - def focus_distance(self) -> Pow | Any: - ... - - @property - def hradius(self) -> Basic: - ... - - def intersection(self, o) -> list[Point] | list[Any] | Self: - ... - - def is_tangent(self, o) -> bool: - ... - - @property - def major(self) -> Basic: - ... - - @property - def minor(self) -> Basic: - ... - - def normal_lines(self, p, prec=...) -> list[Any] | list[Line | Line2D | Line3D | None]: - ... - - @property - def periapsis(self): - ... - - @property - def semilatus_rectum(self): - ... - - def auxiliary_circle(self) -> Circle | Point | Point2D | Point3D | Segment2D | Segment3D | Segment | None: - ... - - def director_circle(self) -> Circle | Point | Point2D | Point3D | Segment2D | Segment3D | Segment | None: - ... - - def plot_interval(self, parameter=...) -> list[Any]: - ... - - def random_point(self, seed=...) -> Point | Point2D | Point3D: - ... - - def reflect(self, line) -> Self: - ... - - def rotate(self, angle=..., pt=...) -> Self: - ... - - def scale(self, x=..., y=..., pt=...) -> Self: - ... - - def tangent_lines(self, p) -> list[Any] | list[Line | Line2D | Line3D | None]: - ... - - @property - def vradius(self) -> Basic: - ... - - def second_moment_of_area(self, point=...) -> tuple[Any, Any, Literal[0]] | tuple[Any, Any, Any]: - ... - - def polar_second_moment_of_area(self): - ... - - def section_modulus(self, point=...) -> tuple[Any, Any]: - ... - - + def __contains__(self, o) -> bool | NotImplementedType: ... + def __eq__(self, o) -> bool: ... + def __hash__(self) -> int: ... + def __new__( + cls, center=..., hradius=..., vradius=..., eccentricity=..., **kwargs + ) -> Circle | Point | Point2D | Point3D | Segment2D | Segment3D | Segment | Self | None: ... + @property + def ambient_dimension(self) -> Literal[2]: ... + @property + def apoapsis(self): ... + def arbitrary_point(self, parameter=...) -> Point | Point2D | Point3D: ... + @property + def area(self): ... + @property + def bounds(self) -> tuple[Any, Any, Any, Any]: ... + @property + def center(self) -> Basic: ... + @property + def circumference(self): ... + @property + def eccentricity(self): ... + def encloses_point(self, p) -> bool | None: ... + def equation(self, x=..., y=..., _slope=...): ... + def evolute(self, x=..., y=...): ... + @property + def foci(self) -> tuple[Basic, Basic] | tuple[Any, Any] | None: ... + @property + def focus_distance(self) -> Pow | Any: ... + @property + def hradius(self) -> Basic: ... + def intersection(self, o) -> list[Point] | list[Any] | Self: ... + def is_tangent(self, o) -> bool: ... + @property + def major(self) -> Basic: ... + @property + def minor(self) -> Basic: ... + def normal_lines(self, p, prec=...) -> list[Any] | list[Line | Line2D | Line3D | None]: ... + @property + def periapsis(self): ... + @property + def semilatus_rectum(self): ... + def auxiliary_circle(self) -> Circle | Point | Point2D | Point3D | Segment2D | Segment3D | Segment | None: ... + def director_circle(self) -> Circle | Point | Point2D | Point3D | Segment2D | Segment3D | Segment | None: ... + def plot_interval(self, parameter=...) -> list[Any]: ... + def random_point(self, seed=...) -> Point | Point2D | Point3D: ... + def reflect(self, line) -> Self: ... + def rotate(self, angle=..., pt=...) -> Self: ... + def scale(self, x=..., y=..., pt=...) -> Self: ... + def tangent_lines(self, p) -> list[Any] | list[Line | Line2D | Line3D | None]: ... + @property + def vradius(self) -> Basic: ... + def second_moment_of_area(self, point=...) -> tuple[Any, Any, Literal[0]] | tuple[Any, Any, Any]: ... + def polar_second_moment_of_area(self): ... + def section_modulus(self, point=...) -> tuple[Any, Any]: ... class Circle(Ellipse): - def __new__(cls, *args, **kwargs) -> Circle | Point | Point2D | Point3D | Segment2D | Segment3D | Segment | Self | None: - ... - - @property - def circumference(self): - ... - - def equation(self, x=..., y=...): - ... - - def intersection(self, o) -> list[Point] | list[Any] | Ellipse: - ... - - @property - def radius(self) -> Basic: - ... - - def reflect(self, line) -> Self: - ... - - def scale(self, x=..., y=..., pt=...) -> Self | Ellipse: - ... - - @property - def vradius(self): - ... - - - + def __new__(cls, *args, **kwargs) -> Circle | Point | Point2D | Point3D | Segment2D | Segment3D | Segment | Self | None: ... + @property + def circumference(self): ... + def equation(self, x=..., y=...): ... + def intersection(self, o) -> list[Point] | list[Any] | Ellipse: ... + @property + def radius(self) -> Basic: ... + def reflect(self, line) -> Self: ... + def scale(self, x=..., y=..., pt=...) -> Self | Ellipse: ... + @property + def vradius(self): ... diff --git a/stubs/sympy-stubs/geometry/entity.pyi b/stubs/sympy-stubs/geometry/entity.pyi index 8d065de3..2416945f 100644 --- a/stubs/sympy-stubs/geometry/entity.pyi +++ b/stubs/sympy-stubs/geometry/entity.pyi @@ -8,96 +8,41 @@ from sympy.sets.sets import FiniteSet, Union ordering_of_classes = ... T = ... + class GeometryEntity(Basic, EvalfMixin): __slots__: tuple[str, ...] = ... - def __cmp__(self, other) -> int: - ... - - def __contains__(self, other): - ... - - def __getnewargs__(self) -> tuple[Basic, ...]: - ... - - def __ne__(self, o) -> bool: - ... - - def __new__(cls, *args, **kwargs) -> Self: - ... - - def __radd__(self, a): - ... - - def __rtruediv__(self, a): - ... - - def __repr__(self) -> str: - ... - - def __rmul__(self, a): - ... - - def __rsub__(self, a): - ... - - def __str__(self) -> str: - ... - + def __cmp__(self, other) -> int: ... + def __contains__(self, other): ... + def __getnewargs__(self) -> tuple[Basic, ...]: ... + def __ne__(self, o) -> bool: ... + def __new__(cls, *args, **kwargs) -> Self: ... + def __radd__(self, a): ... + def __rtruediv__(self, a): ... + def __repr__(self) -> str: ... + def __rmul__(self, a): ... + def __rsub__(self, a): ... + def __str__(self) -> str: ... @property - def ambient_dimension(self): - ... - + def ambient_dimension(self): ... @property - def bounds(self): - ... - - def encloses(self, o) -> bool: - ... - - def equals(self, o): - ... - - def intersection(self, o): - ... - - def is_similar(self, other): - ... - - def reflect(self, line) -> Self: - ... - - def rotate(self, angle, pt=...) -> Self: - ... - - def scale(self, x=..., y=..., pt=...) -> Self: - ... - - def translate(self, x=..., y=...) -> Self: - ... - - def parameter_value(self, other, t) -> dict[Any, Any]: - ... - - + def bounds(self): ... + def encloses(self, o) -> bool: ... + def equals(self, o): ... + def intersection(self, o): ... + def is_similar(self, other): ... + def reflect(self, line) -> Self: ... + def rotate(self, angle, pt=...) -> Self: ... + def scale(self, x=..., y=..., pt=...) -> Self: ... + def translate(self, x=..., y=...) -> Self: ... + def parameter_value(self, other, t) -> dict[Any, Any]: ... class GeometrySet(GeometryEntity, Set): __slots__ = ... - @dispatch(GeometrySet, Set) -def union_sets(self, o) -> FiniteSet | Union | None: - ... - +def union_sets(self, o) -> FiniteSet | Union | None: ... @dispatch(GeometrySet, Set) -def intersection_sets(self, o) -> FiniteSet | Union | None: - ... - -def translate(x, y): - ... - -def scale(x, y, pt=...): - ... - -def rotate(th): - ... - +def intersection_sets(self, o) -> FiniteSet | Union | None: ... +def translate(x, y): ... +def scale(x, y, pt=...): ... +def rotate(th): ... diff --git a/stubs/sympy-stubs/geometry/line.pyi b/stubs/sympy-stubs/geometry/line.pyi index e698387a..4b3a2965 100644 --- a/stubs/sympy-stubs/geometry/line.pyi +++ b/stubs/sympy-stubs/geometry/line.pyi @@ -11,248 +11,112 @@ from sympy.geometry.point import Point, Point2D, Point3D from sympy.sets.sets import Complement, FiniteSet, Intersection, Union class LinearEntity(GeometrySet): - def __new__(cls, p1, p2=..., **kwargs) -> Self: - ... - - def __contains__(self, other): - ... - + def __new__(cls, p1, p2=..., **kwargs) -> Self: ... + def __contains__(self, other): ... @property - def ambient_dimension(self) -> int: - ... - - def angle_between(self, l2) -> type[UndefinedFunction]: - ... - - def smallest_angle_between(self, l2) -> type[UndefinedFunction]: - ... - - def arbitrary_point(self, parameter=...): - ... - + def ambient_dimension(self) -> int: ... + def angle_between(self, l2) -> type[UndefinedFunction]: ... + def smallest_angle_between(self, l2) -> type[UndefinedFunction]: ... + def arbitrary_point(self, parameter=...): ... @staticmethod - def are_concurrent(*lines) -> bool: - ... - - def contains(self, other): - ... - + def are_concurrent(*lines) -> bool: ... + def contains(self, other): ... @property - def direction(self): - ... - - def intersection(self, other): - ... - - def is_parallel(self, l2): - ... - - def is_perpendicular(self, l2): - ... - - def is_similar(self, other) -> bool: - ... - + def direction(self): ... + def intersection(self, other): ... + def is_parallel(self, l2): ... + def is_perpendicular(self, l2): ... + def is_similar(self, other) -> bool: ... @property - def length(self): - ... - + def length(self): ... @property - def p1(self) -> Basic: - ... - + def p1(self) -> Basic: ... @property - def p2(self) -> Basic: - ... - - def parallel_line(self, p) -> Line | Line2D | Line3D | None: - ... - - def perpendicular_line(self, p) -> Line | Line2D | Line3D | None: - ... - - def perpendicular_segment(self, p) -> Point | Point2D | Point3D | Segment2D | Segment3D | Segment: - ... - + def p2(self) -> Basic: ... + def parallel_line(self, p) -> Line | Line2D | Line3D | None: ... + def perpendicular_line(self, p) -> Line | Line2D | Line3D | None: ... + def perpendicular_segment(self, p) -> Point | Point2D | Point3D | Segment2D | Segment3D | Segment: ... @property - def points(self) -> tuple[Basic, Basic]: - ... - - def projection(self, other) -> FiniteSet | Intersection | Union | Complement | Basic: - ... - - def random_point(self, seed=...): - ... - - def bisectors(self, other) -> list[Self] | list[Line | Line2D | Line3D | None]: - ... - - + def points(self) -> tuple[Basic, Basic]: ... + def projection(self, other) -> FiniteSet | Intersection | Union | Complement | Basic: ... + def random_point(self, seed=...): ... + def bisectors(self, other) -> list[Self] | list[Line | Line2D | Line3D | None]: ... class Line(LinearEntity): - def __new__(cls, *args, **kwargs) -> Line | Line2D | Line3D | Self | None: - ... - - def contains(self, other) -> bool: - ... - - def distance(self, other) -> Pow | Any: - ... - - def equals(self, other) -> bool: - ... - - def plot_interval(self, parameter=...) -> list[Any]: - ... - - + def __new__(cls, *args, **kwargs) -> Line | Line2D | Line3D | Self | None: ... + def contains(self, other) -> bool: ... + def distance(self, other) -> Pow | Any: ... + def equals(self, other) -> bool: ... + def plot_interval(self, parameter=...) -> list[Any]: ... class Ray(LinearEntity): - def __new__(cls, p1, p2=..., **kwargs) -> Ray2D | Ray3D | Self: - ... - - def contains(self, other) -> bool: - ... - - def distance(self, other): - ... - - def equals(self, other) -> bool | NotImplementedType: - ... - - def plot_interval(self, parameter=...) -> list[Any]: - ... - + def __new__(cls, p1, p2=..., **kwargs) -> Ray2D | Ray3D | Self: ... + def contains(self, other) -> bool: ... + def distance(self, other): ... + def equals(self, other) -> bool | NotImplementedType: ... + def plot_interval(self, parameter=...) -> list[Any]: ... @property - def source(self) -> Basic: - ... - - + def source(self) -> Basic: ... class Segment(LinearEntity): - def __new__(cls, p1, p2, **kwargs) -> Point | Point2D | Point3D | Segment2D | Segment3D | Self: - ... - - def contains(self, other) -> bool: - ... - - def equals(self, other) -> bool: - ... - - def distance(self, other) -> Pow | Any: - ... - + def __new__(cls, p1, p2, **kwargs) -> Point | Point2D | Point3D | Segment2D | Segment3D | Self: ... + def contains(self, other) -> bool: ... + def equals(self, other) -> bool: ... + def distance(self, other) -> Pow | Any: ... @property - def length(self) -> Pow | Any: - ... - + def length(self) -> Pow | Any: ... @property - def midpoint(self) -> Point | Point2D | Point3D: - ... - - def perpendicular_bisector(self, p=...) -> Point | Point2D | Point3D | Segment2D | Segment3D | Segment | Line | Line2D | Line3D | None: - ... - - def plot_interval(self, parameter=...) -> list[Any]: - ... - - + def midpoint(self) -> Point | Point2D | Point3D: ... + def perpendicular_bisector( + self, p=... + ) -> Point | Point2D | Point3D | Segment2D | Segment3D | Segment | Line | Line2D | Line3D | None: ... + def plot_interval(self, parameter=...) -> list[Any]: ... class LinearEntity2D(LinearEntity): @property - def bounds(self) -> tuple[Any, Any, Any, Any]: - ... - - def perpendicular_line(self, p) -> Line | Line2D | Line3D | None: - ... - + def bounds(self) -> tuple[Any, Any, Any, Any]: ... + def perpendicular_line(self, p) -> Line | Line2D | Line3D | None: ... @property - def slope(self): - ... - - + def slope(self): ... class Line2D(LinearEntity2D, Line): - def __new__(cls, p1, pt=..., slope=..., **kwargs) -> Self: - ... - + def __new__(cls, p1, pt=..., slope=..., **kwargs) -> Self: ... @property - def coefficients(self) -> tuple[Any, Any, Any] | tuple[Any, ...]: - ... - - def equation(self, x=..., y=...): - ... - - + def coefficients(self) -> tuple[Any, Any, Any] | tuple[Any, ...]: ... + def equation(self, x=..., y=...): ... class Ray2D(LinearEntity2D, Ray): - def __new__(cls, p1, pt=..., angle=..., **kwargs) -> Self: - ... - + def __new__(cls, p1, pt=..., angle=..., **kwargs) -> Self: ... @property - def xdirection(self): - ... - + def xdirection(self): ... @property - def ydirection(self): - ... - - def closing_angle(self, r2): - ... - - + def ydirection(self): ... + def closing_angle(self, r2): ... class Segment2D(LinearEntity2D, Segment): - def __new__(cls, p1, p2, **kwargs) -> Point | Point2D | Point3D | Self: - ... - - + def __new__(cls, p1, p2, **kwargs) -> Point | Point2D | Point3D | Self: ... class LinearEntity3D(LinearEntity): - def __new__(cls, p1, p2, **kwargs) -> Self: - ... - + def __new__(cls, p1, p2, **kwargs) -> Self: ... + ambient_dimension = ... @property - def direction_ratio(self): - ... - + def direction_ratio(self): ... @property - def direction_cosine(self): - ... - - + def direction_cosine(self): ... class Line3D(LinearEntity3D, Line): - def __new__(cls, p1, pt=..., direction_ratio=..., **kwargs) -> Self: - ... - - def equation(self, x=..., y=..., z=...) -> Tuple: - ... - - + def __new__(cls, p1, pt=..., direction_ratio=..., **kwargs) -> Self: ... + def equation(self, x=..., y=..., z=...) -> Tuple: ... class Ray3D(LinearEntity3D, Ray): - def __new__(cls, p1, pt=..., direction_ratio=..., **kwargs) -> Self: - ... - + def __new__(cls, p1, pt=..., direction_ratio=..., **kwargs) -> Self: ... @property - def xdirection(self): - ... - + def xdirection(self): ... @property - def ydirection(self): - ... - + def ydirection(self): ... @property - def zdirection(self): - ... - - + def zdirection(self): ... class Segment3D(LinearEntity3D, Segment): - def __new__(cls, p1, p2, **kwargs) -> Point | Point2D | Point3D | Self: - ... - - - + def __new__(cls, p1, p2, **kwargs) -> Point | Point2D | Point3D | Self: ... diff --git a/stubs/sympy-stubs/geometry/parabola.pyi b/stubs/sympy-stubs/geometry/parabola.pyi index 7c7b64e4..256f4ef0 100644 --- a/stubs/sympy-stubs/geometry/parabola.pyi +++ b/stubs/sympy-stubs/geometry/parabola.pyi @@ -5,46 +5,22 @@ from sympy.geometry.entity import GeometrySet from sympy.geometry.point import Point, Point2D, Point3D class Parabola(GeometrySet): - def __new__(cls, focus=..., directrix=..., **kwargs) -> Self: - ... - - @property - def ambient_dimension(self) -> Literal[2]: - ... - - @property - def axis_of_symmetry(self): - ... - - @property - def directrix(self) -> Basic: - ... - - @property - def eccentricity(self): - ... - - def equation(self, x=..., y=...): - ... - - @property - def focal_length(self): - ... - - @property - def focus(self) -> Basic: - ... - - def intersection(self, o) -> list[Parabola] | list[Any] | list[Point2D]: - ... - - @property - def p_parameter(self): - ... - - @property - def vertex(self) -> Point | Point2D | Point3D: - ... - - - + def __new__(cls, focus=..., directrix=..., **kwargs) -> Self: ... + @property + def ambient_dimension(self) -> Literal[2]: ... + @property + def axis_of_symmetry(self): ... + @property + def directrix(self) -> Basic: ... + @property + def eccentricity(self): ... + def equation(self, x=..., y=...): ... + @property + def focal_length(self): ... + @property + def focus(self) -> Basic: ... + def intersection(self, o) -> list[Parabola] | list[Any] | list[Point2D]: ... + @property + def p_parameter(self): ... + @property + def vertex(self) -> Point | Point2D | Point3D: ... diff --git a/stubs/sympy-stubs/geometry/plane.pyi b/stubs/sympy-stubs/geometry/plane.pyi index 2a6b92d0..5b7b4833 100644 --- a/stubs/sympy-stubs/geometry/plane.pyi +++ b/stubs/sympy-stubs/geometry/plane.pyi @@ -8,75 +8,39 @@ from sympy.geometry.line import Line3D, Ray3D, Segment3D from sympy.geometry.point import Point, Point2D, Point3D class Plane(GeometryEntity): - def __new__(cls, p1, a=..., b=..., **kwargs) -> Self: - ... - - def __contains__(self, o) -> Literal[False]: - ... - - def angle_between(self, o) -> type[UndefinedFunction] | None: - ... - - def arbitrary_point(self, u=..., v=...) -> Point3D: - ... - + def __new__(cls, p1, a=..., b=..., **kwargs) -> Self: ... + def __contains__(self, o) -> Literal[False]: ... + def angle_between(self, o) -> type[UndefinedFunction] | None: ... + def arbitrary_point(self, u=..., v=...) -> Point3D: ... @staticmethod - def are_concurrent(*planes) -> bool: - ... - - def distance(self, o) -> Expr: - ... - - def equals(self, o) -> Any | Literal[False]: - ... - - def equation(self, x=..., y=..., z=...) -> int: - ... - - def intersection(self, o) -> list[Point | Point2D | Point3D] | list[Any] | list[Point | Point2D | Point3D | Segment3D | Ray3D | Line3D] | list[Any | Point3D | Basic] | list[Self] | list[Line3D] | None: - ... - - def is_coplanar(self, o) -> bool | None: - ... - - def is_parallel(self, l) -> bool | None: - ... - - def is_perpendicular(self, l) -> bool: - ... - + def are_concurrent(*planes) -> bool: ... + def distance(self, o) -> Expr: ... + def equals(self, o) -> Any | Literal[False]: ... + def equation(self, x=..., y=..., z=...) -> int: ... + def intersection( + self, o + ) -> ( + list[Point | Point2D | Point3D] + | list[Any] + | list[Point | Point2D | Point3D | Segment3D | Ray3D | Line3D] + | list[Any | Point3D | Basic] + | list[Self] + | list[Line3D] + | None + ): ... + def is_coplanar(self, o) -> bool | None: ... + def is_parallel(self, l) -> bool | None: ... + def is_perpendicular(self, l) -> bool: ... @property - def normal_vector(self) -> Basic: - ... - + def normal_vector(self) -> Basic: ... @property - def p1(self) -> Basic: - ... - - def parallel_plane(self, pt) -> Plane: - ... - - def perpendicular_line(self, pt) -> Line3D: - ... - - def perpendicular_plane(self, *pts) -> Plane: - ... - - def projection_line(self, line) -> Point | Point2D | Point3D | Segment3D | Ray3D | Line3D | Basic | Self | None: - ... - - def projection(self, pt) -> Point | Point2D | Point3D | Segment3D | Ray3D | Line3D | Basic | Self: - ... - - def random_point(self, seed=...) -> Point3D | Basic: - ... - - def parameter_value(self, other, u, v=...) -> Point | Point2D | Point3D: - ... - + def p1(self) -> Basic: ... + def parallel_plane(self, pt) -> Plane: ... + def perpendicular_line(self, pt) -> Line3D: ... + def perpendicular_plane(self, *pts) -> Plane: ... + def projection_line(self, line) -> Point | Point2D | Point3D | Segment3D | Ray3D | Line3D | Basic | Self | None: ... + def projection(self, pt) -> Point | Point2D | Point3D | Segment3D | Ray3D | Line3D | Basic | Self: ... + def random_point(self, seed=...) -> Point3D | Basic: ... + def parameter_value(self, other, u, v=...) -> Point | Point2D | Point3D: ... @property - def ambient_dimension(self): - ... - - - + def ambient_dimension(self): ... diff --git a/stubs/sympy-stubs/geometry/point.pyi b/stubs/sympy-stubs/geometry/point.pyi index dc873e6e..a7015140 100644 --- a/stubs/sympy-stubs/geometry/point.pyi +++ b/stubs/sympy-stubs/geometry/point.pyi @@ -7,203 +7,85 @@ from sympy.series.order import Order class Point(GeometryEntity): is_Point = ... - def __new__(cls, *args, **kwargs) -> Point | Point2D | Point3D | Self: - ... - - def __abs__(self) -> Pow | Any: - ... - - def __add__(self, other) -> Point | Point2D | Point3D: - ... - - def __contains__(self, item) -> bool: - ... - - def __truediv__(self, divisor) -> Point | Point2D | Point3D: - ... - - def __eq__(self, other) -> bool: - ... - - def __getitem__(self, key): - ... - - def __hash__(self) -> int: - ... - - def __iter__(self) -> Iterator[Basic]: - ... - - def __len__(self) -> int: - ... - - def __mul__(self, factor) -> Point | Point2D | Point3D: - ... - - def __rmul__(self, factor) -> Point | Point2D | Point3D: - ... - - def __neg__(self) -> Point | Point2D | Point3D: - ... - - def __sub__(self, other) -> Point | Point2D | Point3D: - ... - + def __new__(cls, *args, **kwargs) -> Point | Point2D | Point3D | Self: ... + def __abs__(self) -> Pow | Any: ... + def __add__(self, other) -> Point | Point2D | Point3D: ... + def __contains__(self, item) -> bool: ... + def __truediv__(self, divisor) -> Point | Point2D | Point3D: ... + def __eq__(self, other) -> bool: ... + def __getitem__(self, key): ... + def __hash__(self) -> int: ... + def __iter__(self) -> Iterator[Basic]: ... + def __len__(self) -> int: ... + def __mul__(self, factor) -> Point | Point2D | Point3D: ... + def __rmul__(self, factor) -> Point | Point2D | Point3D: ... + def __neg__(self) -> Point | Point2D | Point3D: ... + def __sub__(self, other) -> Point | Point2D | Point3D: ... @staticmethod - def affine_rank(*args) -> int: - ... - + def affine_rank(*args) -> int: ... @property - def ambient_dimension(self) -> Any | int: - ... - + def ambient_dimension(self) -> Any | int: ... @classmethod - def are_coplanar(cls, *points) -> bool: - ... - - def distance(self, other) -> Pow | Any: - ... - - def dot(self, p) -> Order: - ... - - def equals(self, other) -> bool: - ... - - def intersection(self, other) -> list[Self] | list[Any]: - ... - - def is_collinear(self, *args) -> bool: - ... - - def is_concyclic(self, *args) -> bool: - ... - + def are_coplanar(cls, *points) -> bool: ... + def distance(self, other) -> Pow | Any: ... + def dot(self, p) -> Order: ... + def equals(self, other) -> bool: ... + def intersection(self, other) -> list[Self] | list[Any]: ... + def is_collinear(self, *args) -> bool: ... + def is_concyclic(self, *args) -> bool: ... @property - def is_nonzero(self) -> bool | None: - ... - - def is_scalar_multiple(self, p) -> bool: - ... - + def is_nonzero(self) -> bool | None: ... + def is_scalar_multiple(self, p) -> bool: ... @property - def is_zero(self) -> bool | None: - ... - + def is_zero(self) -> bool | None: ... @property - def length(self): - ... - - def midpoint(self, p) -> Point | Point2D | Point3D: - ... - + def length(self): ... + def midpoint(self, p) -> Point | Point2D | Point3D: ... @property - def origin(self) -> Point | Point2D | Point3D: - ... - + def origin(self) -> Point | Point2D | Point3D: ... @property - def orthogonal_direction(self) -> Point | Point2D | Point3D: - ... - + def orthogonal_direction(self) -> Point | Point2D | Point3D: ... @staticmethod - def project(a, b): - ... - - def taxicab_distance(self, p) -> Order: - ... - - def canberra_distance(self, p) -> Order: - ... - + def project(a, b): ... + def taxicab_distance(self, p) -> Order: ... + def canberra_distance(self, p) -> Order: ... @property - def unit(self) -> Point | Point2D | Point3D | Any: - ... - - + def unit(self) -> Point | Point2D | Point3D | Any: ... class Point2D(Point): _ambient_dimension = ... - def __new__(cls, *args, _nocheck=..., **kwargs) -> Self: - ... - - def __contains__(self, item): - ... - + def __new__(cls, *args, _nocheck=..., **kwargs) -> Self: ... + def __contains__(self, item): ... @property - def bounds(self) -> tuple[Basic, Basic, Basic, Basic]: - ... - - def rotate(self, angle, pt=...) -> Point | Point2D | Point3D: - ... - - def scale(self, x=..., y=..., pt=...) -> Point: - ... - - def transform(self, matrix) -> Point | Point2D | Point3D: - ... - - def translate(self, x=..., y=...) -> Point: - ... - + def bounds(self) -> tuple[Basic, Basic, Basic, Basic]: ... + def rotate(self, angle, pt=...) -> Point | Point2D | Point3D: ... + def scale(self, x=..., y=..., pt=...) -> Point: ... + def transform(self, matrix) -> Point | Point2D | Point3D: ... + def translate(self, x=..., y=...) -> Point: ... @property - def coordinates(self) -> tuple[Basic, ...]: - ... - + def coordinates(self) -> tuple[Basic, ...]: ... @property - def x(self) -> Basic: - ... - + def x(self) -> Basic: ... @property - def y(self) -> Basic: - ... - - + def y(self) -> Basic: ... class Point3D(Point): _ambient_dimension = ... - def __new__(cls, *args, _nocheck=..., **kwargs) -> Self: - ... - - def __contains__(self, item): - ... - + def __new__(cls, *args, _nocheck=..., **kwargs) -> Self: ... + def __contains__(self, item): ... @staticmethod - def are_collinear(*points) -> bool: - ... - - def direction_cosine(self, point) -> list[Any]: - ... - - def direction_ratio(self, point) -> list[Any]: - ... - - def intersection(self, other) -> list[Self] | list[Any] | list[Point] | list[Point2D]: - ... - - def scale(self, x=..., y=..., z=..., pt=...) -> Point3D: - ... - - def transform(self, matrix) -> Point3D: - ... - - def translate(self, x=..., y=..., z=...) -> Point3D: - ... - + def are_collinear(*points) -> bool: ... + def direction_cosine(self, point) -> list[Any]: ... + def direction_ratio(self, point) -> list[Any]: ... + def intersection(self, other) -> list[Self] | list[Any] | list[Point] | list[Point2D]: ... + def scale(self, x=..., y=..., z=..., pt=...) -> Point3D: ... + def transform(self, matrix) -> Point3D: ... + def translate(self, x=..., y=..., z=...) -> Point3D: ... @property - def coordinates(self) -> tuple[Basic, ...]: - ... - + def coordinates(self) -> tuple[Basic, ...]: ... @property - def x(self) -> Basic: - ... - + def x(self) -> Basic: ... @property - def y(self) -> Basic: - ... - + def y(self) -> Basic: ... @property - def z(self) -> Basic: - ... - - - + def z(self) -> Basic: ... diff --git a/stubs/sympy-stubs/geometry/polygon.pyi b/stubs/sympy-stubs/geometry/polygon.pyi index 622a1d43..3676b1d3 100644 --- a/stubs/sympy-stubs/geometry/polygon.pyi +++ b/stubs/sympy-stubs/geometry/polygon.pyi @@ -11,271 +11,128 @@ from sympy.geometry.point import Point, Point2D, Point3D class Polygon(GeometrySet): __slots__ = ... - def __new__(cls, *args, n=..., **kwargs) -> RegularPolygon | Self | Triangle | Point | Point2D | Point3D | Segment2D | Segment3D | Segment | None: - ... - - @property - def area(self): - ... - - @property - def angles(self) -> dict[Any, Any]: - ... - - @property - def ambient_dimension(self): - ... - - @property - def perimeter(self): - ... - - @property - def vertices(self) -> list[Basic]: - ... - - @property - def centroid(self) -> Point | Point2D | Point3D: - ... - - def second_moment_of_area(self, point=...) -> tuple[Any, Any, Any]: - ... - - def first_moment_of_area(self, point=...) -> tuple[Any, Any]: - ... - - def polar_second_moment_of_area(self): - ... - - def section_modulus(self, point=...) -> tuple[Any, Any]: - ... - - @property - def sides(self) -> list[Any]: - ... - - @property - def bounds(self) -> tuple[Any, Any, Any, Any]: - ... - - def is_convex(self) -> bool: - ... - - def encloses_point(self, p) -> bool | None: - ... - - def arbitrary_point(self, parameter=...) -> Piecewise: - ... - - def parameter_value(self, other, t) -> dict[Any, Any]: - ... - - def plot_interval(self, parameter=...) -> list[Any]: - ... - - def intersection(self, o) -> list[Any]: - ... - - def cut_section(self, line) -> tuple[RegularPolygon | Polygon | Triangle | Point | Point2D | Point3D | Segment2D | Segment3D | Segment | None, RegularPolygon | Polygon | Triangle | Point | Point2D | Point3D | Segment2D | Segment3D | Segment | None]: - ... - - def distance(self, o): - ... - - def __contains__(self, o) -> NotImplementedType | bool: - ... - - def bisectors(self, prec=...) -> dict[Any, Any]: - ... - - + def __new__( + cls, *args, n=..., **kwargs + ) -> RegularPolygon | Self | Triangle | Point | Point2D | Point3D | Segment2D | Segment3D | Segment | None: ... + @property + def area(self): ... + @property + def angles(self) -> dict[Any, Any]: ... + @property + def ambient_dimension(self): ... + @property + def perimeter(self): ... + @property + def vertices(self) -> list[Basic]: ... + @property + def centroid(self) -> Point | Point2D | Point3D: ... + def second_moment_of_area(self, point=...) -> tuple[Any, Any, Any]: ... + def first_moment_of_area(self, point=...) -> tuple[Any, Any]: ... + def polar_second_moment_of_area(self): ... + def section_modulus(self, point=...) -> tuple[Any, Any]: ... + @property + def sides(self) -> list[Any]: ... + @property + def bounds(self) -> tuple[Any, Any, Any, Any]: ... + def is_convex(self) -> bool: ... + def encloses_point(self, p) -> bool | None: ... + def arbitrary_point(self, parameter=...) -> Piecewise: ... + def parameter_value(self, other, t) -> dict[Any, Any]: ... + def plot_interval(self, parameter=...) -> list[Any]: ... + def intersection(self, o) -> list[Any]: ... + def cut_section(self, line) -> tuple[ + RegularPolygon | Polygon | Triangle | Point | Point2D | Point3D | Segment2D | Segment3D | Segment | None, + RegularPolygon | Polygon | Triangle | Point | Point2D | Point3D | Segment2D | Segment3D | Segment | None, + ]: ... + def distance(self, o): ... + def __contains__(self, o) -> NotImplementedType | bool: ... + def bisectors(self, prec=...) -> dict[Any, Any]: ... class RegularPolygon(Polygon): __slots__ = ... - def __new__(cls, c, r, n, rot=..., **kwargs) -> Self: - ... - - @property - def args(self) -> tuple[Any, Any, Any, Any]: - ... - - def __str__(self) -> str: - ... - - def __repr__(self) -> LiteralString: - ... - - @property - def area(self): - ... - - @property - def length(self): - ... - - @property - def center(self): - ... - - centroid = ... + def __new__(cls, c, r, n, rot=..., **kwargs) -> Self: ... + @property + def args(self) -> tuple[Any, Any, Any, Any]: ... + def __str__(self) -> str: ... + def __repr__(self) -> LiteralString: ... + @property + def area(self): ... + @property + def length(self): ... @property - def circumcenter(self): - ... - - @property - def radius(self): - ... - - @property - def circumradius(self): - ... - - @property - def rotation(self): - ... - - @property - def apothem(self): - ... - - @property - def inradius(self): - ... - - @property - def interior_angle(self): - ... - - @property - def exterior_angle(self): - ... - - @property - def circumcircle(self) -> Circle | Point | Point2D | Point3D | Segment2D | Segment3D | Segment | None: - ... - - @property - def incircle(self) -> Circle | Point | Point2D | Point3D | Segment2D | Segment3D | Segment | None: - ... - - @property - def angles(self) -> dict[Any, Any]: - ... - - def encloses_point(self, p) -> bool | None: - ... - - def spin(self, angle) -> None: - ... - - def rotate(self, angle, pt=...) -> GeometryEntity: - ... - - def scale(self, x=..., y=..., pt=...) -> Point3D | Polygon | Triangle | Point | Segment2D | Segment3D | Segment | Self: - ... - - def reflect(self, line) -> Self: - ... - - @property - def vertices(self) -> list[Point | Point2D | Point3D]: - ... - - def __eq__(self, o) -> bool: - ... - - def __hash__(self) -> int: - ... - + def center(self): ... + centroid = ... + @property + def circumcenter(self): ... + @property + def radius(self): ... + @property + def circumradius(self): ... + @property + def rotation(self): ... + @property + def apothem(self): ... + @property + def inradius(self): ... + @property + def interior_angle(self): ... + @property + def exterior_angle(self): ... + @property + def circumcircle(self) -> Circle | Point | Point2D | Point3D | Segment2D | Segment3D | Segment | None: ... + @property + def incircle(self) -> Circle | Point | Point2D | Point3D | Segment2D | Segment3D | Segment | None: ... + @property + def angles(self) -> dict[Any, Any]: ... + def encloses_point(self, p) -> bool | None: ... + def spin(self, angle) -> None: ... + def rotate(self, angle, pt=...) -> GeometryEntity: ... + def scale(self, x=..., y=..., pt=...) -> Point3D | Polygon | Triangle | Point | Segment2D | Segment3D | Segment | Self: ... + def reflect(self, line) -> Self: ... + @property + def vertices(self) -> list[Point | Point2D | Point3D]: ... + def __eq__(self, o) -> bool: ... + def __hash__(self) -> int: ... class Triangle(Polygon): - def __new__(cls, *args, **kwargs) -> Triangle | Self | Point | Point2D | Point3D | Segment2D | Segment3D | Segment | None: - ... - - @property - def vertices(self) -> tuple[Basic, ...]: - ... - - def is_similar(self, t2) -> bool: - ... - - def is_equilateral(self) -> bool: - ... - - def is_isosceles(self) -> bool: - ... - - def is_scalene(self) -> bool: - ... - - def is_right(self): - ... - - @property - def altitudes(self) -> dict[Basic, Any]: - ... - - @property - def orthocenter(self): - ... - - @property - def circumcenter(self): - ... - - @property - def circumradius(self) -> Pow | Any: - ... - - @property - def circumcircle(self) -> Circle | Point | Point2D | Point3D | Segment2D | Segment3D | Segment | None: - ... - - def bisectors(self) -> dict[Basic, Point | Point2D | Point3D | Segment2D | Segment3D | Segment]: - ... - - @property - def incenter(self) -> Point | Point2D | Point3D: - ... - - @property - def inradius(self): - ... - - @property - def incircle(self) -> Circle | Point | Point2D | Point3D | Segment2D | Segment3D | Segment | None: - ... - - @property - def exradii(self) -> dict[Any, Any]: - ... - - @property - def excenters(self) -> dict[Any, Point | Point2D | Point3D]: - ... - - @property - def medians(self) -> dict[Basic, Point | Point2D | Point3D | Segment2D | Segment3D | Segment]: - ... - - @property - def medial(self) -> Triangle | Point | Point2D | Point3D | Segment2D | Segment3D | Segment | None: - ... - - @property - def nine_point_circle(self) -> Circle | Point | Point2D | Point3D | Segment2D | Segment3D | Segment | None: - ... - - @property - def eulerline(self) -> Line | Line2D | Line3D | None: - ... - - - -def rad(d): - ... - -def deg(r): - ... + def __new__(cls, *args, **kwargs) -> Triangle | Self | Point | Point2D | Point3D | Segment2D | Segment3D | Segment | None: ... + @property + def vertices(self) -> tuple[Basic, ...]: ... + def is_similar(self, t2) -> bool: ... + def is_equilateral(self) -> bool: ... + def is_isosceles(self) -> bool: ... + def is_scalene(self) -> bool: ... + def is_right(self): ... + @property + def altitudes(self) -> dict[Basic, Any]: ... + @property + def orthocenter(self): ... + @property + def circumcenter(self): ... + @property + def circumradius(self) -> Pow | Any: ... + @property + def circumcircle(self) -> Circle | Point | Point2D | Point3D | Segment2D | Segment3D | Segment | None: ... + def bisectors(self) -> dict[Basic, Point | Point2D | Point3D | Segment2D | Segment3D | Segment]: ... + @property + def incenter(self) -> Point | Point2D | Point3D: ... + @property + def inradius(self): ... + @property + def incircle(self) -> Circle | Point | Point2D | Point3D | Segment2D | Segment3D | Segment | None: ... + @property + def exradii(self) -> dict[Any, Any]: ... + @property + def excenters(self) -> dict[Any, Point | Point2D | Point3D]: ... + @property + def medians(self) -> dict[Basic, Point | Point2D | Point3D | Segment2D | Segment3D | Segment]: ... + @property + def medial(self) -> Triangle | Point | Point2D | Point3D | Segment2D | Segment3D | Segment | None: ... + @property + def nine_point_circle(self) -> Circle | Point | Point2D | Point3D | Segment2D | Segment3D | Segment | None: ... + @property + def eulerline(self) -> Line | Line2D | Line3D | None: ... +def rad(d): ... +def deg(r): ... diff --git a/stubs/sympy-stubs/geometry/util.pyi b/stubs/sympy-stubs/geometry/util.pyi index 964d5bcc..55e61886 100644 --- a/stubs/sympy-stubs/geometry/util.pyi +++ b/stubs/sympy-stubs/geometry/util.pyi @@ -8,30 +8,28 @@ from sympy.geometry.point import Point, Point2D, Point3D from sympy.geometry.polygon import Polygon, RegularPolygon, Triangle from sympy.series.order import Order -def find(x, equation): - ... - -def are_coplanar(*e) -> bool: - ... - -def are_similar(e1, e2) -> Any | Literal[True]: - ... - -def centroid(*args) -> None: - ... - -def closest_points(*args) -> set[tuple[Point2D, ...]]: - ... - -def convex_hull(*args, polygon=...) -> tuple[Any, None] | Point | Point2D | Point3D | Segment2D | Segment3D | Segment | tuple[Point | Point2D | Point3D | Segment2D | Segment3D | Segment, None] | RegularPolygon | Polygon | Triangle | tuple[list[Any], list[Any]] | None: - ... - -def farthest_points(*args) -> set[tuple[Any, Any]]: - ... - -def idiff(eq, y, x, n=...) -> Basic | Add | Order | Mul | Any | None: - ... - -def intersection(*entities, pairwise=..., **kwargs) -> list[Any]: - ... - +def find(x, equation): ... +def are_coplanar(*e) -> bool: ... +def are_similar(e1, e2) -> Any | Literal[True]: ... +def centroid(*args) -> None: ... +def closest_points(*args) -> set[tuple[Point2D, ...]]: ... +def convex_hull( + *args, polygon=... +) -> ( + tuple[Any, None] + | Point + | Point2D + | Point3D + | Segment2D + | Segment3D + | Segment + | tuple[Point | Point2D | Point3D | Segment2D | Segment3D | Segment, None] + | RegularPolygon + | Polygon + | Triangle + | tuple[list[Any], list[Any]] + | None +): ... +def farthest_points(*args) -> set[tuple[Any, Any]]: ... +def idiff(eq, y, x, n=...) -> Basic | Add | Order | Mul | Any | None: ... +def intersection(*entities, pairwise=..., **kwargs) -> list[Any]: ... diff --git a/stubs/sympy-stubs/holonomic/__init__.pyi b/stubs/sympy-stubs/holonomic/__init__.pyi index 5314a918..97a3244e 100644 --- a/stubs/sympy-stubs/holonomic/__init__.pyi +++ b/stubs/sympy-stubs/holonomic/__init__.pyi @@ -8,4 +8,14 @@ from sympy.holonomic.holonomic import ( ) from sympy.holonomic.recurrence import HolonomicSequence, RecurrenceOperator, RecurrenceOperators -__all__ = ['DifferentialOperator', 'HolonomicFunction', 'DifferentialOperators', 'from_hyper', 'from_meijerg', 'expr_to_holonomic', 'RecurrenceOperators', 'RecurrenceOperator', 'HolonomicSequence'] +__all__ = [ + "DifferentialOperator", + "HolonomicFunction", + "DifferentialOperators", + "from_hyper", + "from_meijerg", + "expr_to_holonomic", + "RecurrenceOperators", + "RecurrenceOperator", + "HolonomicSequence", +] diff --git a/stubs/sympy-stubs/holonomic/holonomic.pyi b/stubs/sympy-stubs/holonomic/holonomic.pyi index d0846687..fcde2962 100644 --- a/stubs/sympy-stubs/holonomic/holonomic.pyi +++ b/stubs/sympy-stubs/holonomic/holonomic.pyi @@ -2,160 +2,73 @@ from typing import Any, Self from sympy.holonomic.recurrence import HolonomicSequence -def DifferentialOperators(base, generator) -> tuple[DifferentialOperatorAlgebra, DifferentialOperator]: - ... +def DifferentialOperators(base, generator) -> tuple[DifferentialOperatorAlgebra, DifferentialOperator]: ... class DifferentialOperatorAlgebra: - def __init__(self, base, generator) -> None: - ... - - def __str__(self) -> str: - ... - - __repr__ = ... - def __eq__(self, other) -> bool: - ... - + def __init__(self, base, generator) -> None: ... + def __str__(self) -> str: ... + __repr__ = ... + def __eq__(self, other) -> bool: ... class DifferentialOperator: _op_priority = ... - def __init__(self, list_of_poly, parent) -> None: - ... - - def __mul__(self, other) -> DifferentialOperator: - ... - - def __rmul__(self, other) -> DifferentialOperator | None: - ... - - def __add__(self, other) -> DifferentialOperator: - ... - + def __init__(self, list_of_poly, parent) -> None: ... + def __mul__(self, other) -> DifferentialOperator: ... + def __rmul__(self, other) -> DifferentialOperator | None: ... + def __add__(self, other) -> DifferentialOperator: ... + __radd__ = ... - def __sub__(self, other): - ... - - def __rsub__(self, other): - ... - - def __neg__(self) -> DifferentialOperator | None: - ... - - def __truediv__(self, other): - ... - - def __pow__(self, n) -> Self | DifferentialOperator | None: - ... - - def __str__(self) -> str: - ... - - __repr__ = ... - def __eq__(self, other) -> bool: - ... - - def is_singular(self, x0) -> bool: - ... - + def __sub__(self, other): ... + def __rsub__(self, other): ... + def __neg__(self) -> DifferentialOperator | None: ... + def __truediv__(self, other): ... + def __pow__(self, n) -> Self | DifferentialOperator | None: ... + def __str__(self) -> str: ... + __repr__ = ... + def __eq__(self, other) -> bool: ... + def is_singular(self, x0) -> bool: ... class HolonomicFunction: _op_priority = ... - def __init__(self, annihilator, x, x0=..., y0=...) -> None: - ... - - def __str__(self) -> str: - ... - - __repr__ = ... - def unify(self, other) -> tuple[Self, Any] | tuple[HolonomicFunction, HolonomicFunction]: - ... - - def is_singularics(self) -> bool | None: - ... - - def __add__(self, other): - ... - - def integrate(self, limits, initcond=...): - ... - - def diff(self, *args, **kwargs) -> Self | HolonomicFunction: - ... - - def __eq__(self, other) -> bool: - ... - - def __mul__(self, other): - ... - - __rmul__ = ... - def __sub__(self, other): - ... - - def __rsub__(self, other): - ... - - def __neg__(self): - ... - - def __truediv__(self, other): - ... - - def __pow__(self, n) -> HolonomicFunction | Self | None: - ... - - def degree(self): - ... - - def composition(self, expr, *args, **kwargs) -> HolonomicFunction: - ... - - def to_sequence(self, lb=...) -> list[tuple[HolonomicSequence, Any]] | list[HolonomicSequence]: - ... - - def series(self, n=..., coefficient=..., order=..., _recur=...) -> list[Any]: - ... - - def evalf(self, points, method=..., h=..., derivatives=...) -> list[Any]: - ... - - def change_x(self, z) -> HolonomicFunction: - ... - - def shift_x(self, a) -> HolonomicFunction: - ... - - def to_hyper(self, as_list=..., _recur=...): - ... - - def to_expr(self): - ... - - def change_ics(self, b, lenics=...) -> HolonomicFunction: - ... - - def to_meijerg(self): - ... - + def __init__(self, annihilator, x, x0=..., y0=...) -> None: ... + def __str__(self) -> str: ... + __repr__ = ... + def unify(self, other) -> tuple[Self, Any] | tuple[HolonomicFunction, HolonomicFunction]: ... + def is_singularics(self) -> bool | None: ... + def __add__(self, other): ... + def integrate(self, limits, initcond=...): ... + def diff(self, *args, **kwargs) -> Self | HolonomicFunction: ... + def __eq__(self, other) -> bool: ... + def __mul__(self, other): ... -def from_hyper(func, x0=..., evalf=...) -> HolonomicFunction: - ... + __rmul__ = ... + def __sub__(self, other): ... + def __rsub__(self, other): ... + def __neg__(self): ... + def __truediv__(self, other): ... + def __pow__(self, n) -> HolonomicFunction | Self | None: ... + def degree(self): ... + def composition(self, expr, *args, **kwargs) -> HolonomicFunction: ... + def to_sequence(self, lb=...) -> list[tuple[HolonomicSequence, Any]] | list[HolonomicSequence]: ... + def series(self, n=..., coefficient=..., order=..., _recur=...) -> list[Any]: ... + def evalf(self, points, method=..., h=..., derivatives=...) -> list[Any]: ... + def change_x(self, z) -> HolonomicFunction: ... + def shift_x(self, a) -> HolonomicFunction: ... + def to_hyper(self, as_list=..., _recur=...): ... + def to_expr(self): ... + def change_ics(self, b, lenics=...) -> HolonomicFunction: ... + def to_meijerg(self): ... -def from_meijerg(func, x0=..., evalf=..., initcond=..., domain=...) -> HolonomicFunction: - ... +def from_hyper(func, x0=..., evalf=...) -> HolonomicFunction: ... +def from_meijerg(func, x0=..., evalf=..., initcond=..., domain=...) -> HolonomicFunction: ... x_1 = ... _lookup_table = ... domain_for_table = ... -def expr_to_holonomic(func, x=..., x0=..., y0=..., lenics=..., domain=..., initcond=...): - ... - -def DMFdiff(frac): - ... - -def DMFsubs(frac, x0, mpm=...): - ... +def expr_to_holonomic(func, x=..., x0=..., y0=..., lenics=..., domain=..., initcond=...): ... +def DMFdiff(frac): ... +def DMFsubs(frac, x0, mpm=...): ... diff --git a/stubs/sympy-stubs/holonomic/recurrence.pyi b/stubs/sympy-stubs/holonomic/recurrence.pyi index 8b2f2cae..eec89e11 100644 --- a/stubs/sympy-stubs/holonomic/recurrence.pyi +++ b/stubs/sympy-stubs/holonomic/recurrence.pyi @@ -1,64 +1,33 @@ from typing import LiteralString, Self -def RecurrenceOperators(base, generator) -> tuple[RecurrenceOperatorAlgebra, RecurrenceOperator]: - ... +def RecurrenceOperators(base, generator) -> tuple[RecurrenceOperatorAlgebra, RecurrenceOperator]: ... class RecurrenceOperatorAlgebra: - def __init__(self, base, generator) -> None: - ... - - def __str__(self) -> str: - ... - - __repr__ = ... - def __eq__(self, other) -> bool: - ... - + def __init__(self, base, generator) -> None: ... + def __str__(self) -> str: ... + __repr__ = ... + def __eq__(self, other) -> bool: ... class RecurrenceOperator: _op_priority = ... - def __init__(self, list_of_poly, parent) -> None: - ... - - def __mul__(self, other) -> RecurrenceOperator: - ... - - def __rmul__(self, other) -> RecurrenceOperator | None: - ... - - def __add__(self, other) -> RecurrenceOperator: - ... - + def __init__(self, list_of_poly, parent) -> None: ... + def __mul__(self, other) -> RecurrenceOperator: ... + def __rmul__(self, other) -> RecurrenceOperator | None: ... + def __add__(self, other) -> RecurrenceOperator: ... + __radd__ = ... - def __sub__(self, other): - ... - - def __rsub__(self, other): - ... - - def __pow__(self, n) -> Self | RecurrenceOperator | None: - ... - - def __str__(self) -> str: - ... - - __repr__ = ... - def __eq__(self, other) -> bool: - ... - + def __sub__(self, other): ... + def __rsub__(self, other): ... + def __pow__(self, n) -> Self | RecurrenceOperator | None: ... + def __str__(self) -> str: ... + __repr__ = ... + def __eq__(self, other) -> bool: ... class HolonomicSequence: - def __init__(self, recurrence, u0=...) -> None: - ... - - def __repr__(self) -> LiteralString: - ... - - __str__ = ... - def __eq__(self, other) -> bool: - ... - - + def __init__(self, recurrence, u0=...) -> None: ... + def __repr__(self) -> LiteralString: ... + __str__ = ... + def __eq__(self, other) -> bool: ... diff --git a/stubs/sympy-stubs/integrals/__init__.pyi b/stubs/sympy-stubs/integrals/__init__.pyi index 1aee8f82..b67fe878 100644 --- a/stubs/sympy-stubs/integrals/__init__.pyi +++ b/stubs/sympy-stubs/integrals/__init__.pyi @@ -27,4 +27,33 @@ from sympy.integrals.transforms import ( sine_transform, ) -__all__ = ['integrate', 'Integral', 'line_integrate', 'mellin_transform', 'inverse_mellin_transform', 'MellinTransform', 'InverseMellinTransform', 'laplace_transform', 'inverse_laplace_transform', 'LaplaceTransform', 'InverseLaplaceTransform', 'fourier_transform', 'inverse_fourier_transform', 'FourierTransform', 'InverseFourierTransform', 'sine_transform', 'inverse_sine_transform', 'SineTransform', 'InverseSineTransform', 'cosine_transform', 'inverse_cosine_transform', 'CosineTransform', 'InverseCosineTransform', 'hankel_transform', 'inverse_hankel_transform', 'HankelTransform', 'InverseHankelTransform', 'singularityintegrate'] +__all__ = [ + "integrate", + "Integral", + "line_integrate", + "mellin_transform", + "inverse_mellin_transform", + "MellinTransform", + "InverseMellinTransform", + "laplace_transform", + "inverse_laplace_transform", + "LaplaceTransform", + "InverseLaplaceTransform", + "fourier_transform", + "inverse_fourier_transform", + "FourierTransform", + "InverseFourierTransform", + "sine_transform", + "inverse_sine_transform", + "SineTransform", + "InverseSineTransform", + "cosine_transform", + "inverse_cosine_transform", + "CosineTransform", + "InverseCosineTransform", + "hankel_transform", + "inverse_hankel_transform", + "HankelTransform", + "InverseHankelTransform", + "singularityintegrate", +] diff --git a/stubs/sympy-stubs/integrals/deltafunctions.pyi b/stubs/sympy-stubs/integrals/deltafunctions.pyi index 568b5f1e..0c7b499e 100644 --- a/stubs/sympy-stubs/integrals/deltafunctions.pyi +++ b/stubs/sympy-stubs/integrals/deltafunctions.pyi @@ -4,9 +4,5 @@ from sympy.core.relational import Equality, Ne, Relational from sympy.functions.special.delta_functions import DiracDelta, Heaviside from sympy.series.order import Order -def change_mul(node, x) -> tuple[None, Any | Order | None] | tuple[DiracDelta, Any | Order]: - ... - -def deltaintegrate(f, x) -> Heaviside | Equality | Relational | Ne | None: - ... - +def change_mul(node, x) -> tuple[None, Any | Order | None] | tuple[DiracDelta, Any | Order]: ... +def deltaintegrate(f, x) -> Heaviside | Equality | Relational | Ne | None: ... diff --git a/stubs/sympy-stubs/integrals/heurisch.pyi b/stubs/sympy-stubs/integrals/heurisch.pyi index da612399..c1e5cf2b 100644 --- a/stubs/sympy-stubs/integrals/heurisch.pyi +++ b/stubs/sympy-stubs/integrals/heurisch.pyi @@ -4,35 +4,25 @@ from sympy.core.basic import Basic from sympy.core.symbol import Dummy from sympy.functions.elementary.piecewise import Piecewise -def components(f, x) -> set[Any]: - ... +def components(f, x) -> set[Any]: ... _symbols_cache: dict[str, list[Dummy]] = ... -def heurisch_wrapper(f, x, rewrite=..., hints=..., mappings=..., retries=..., degree_offset=..., unnecessary_permutations=..., _try_heurisch=...) -> Basic | Piecewise: - ... -class BesselTable: - def __init__(self) -> None: - ... - - def diffs(self, f, n, z) -> tuple[Any, Any] | None: - ... - - def has(self, f) -> bool: - ... - +def heurisch_wrapper( + f, x, rewrite=..., hints=..., mappings=..., retries=..., degree_offset=..., unnecessary_permutations=..., _try_heurisch=... +) -> Basic | Piecewise: ... +class BesselTable: + def __init__(self) -> None: ... + def diffs(self, f, n, z) -> tuple[Any, Any] | None: ... + def has(self, f) -> bool: ... _bessel_table = ... -class DiffCache: - def __init__(self, x) -> None: - ... - - def get_diff(self, f): - ... - +class DiffCache: + def __init__(self, x) -> None: ... + def get_diff(self, f): ... -def heurisch(f, x, rewrite=..., hints=..., mappings=..., retries=..., degree_offset=..., unnecessary_permutations=..., _try_heurisch=...): - ... - +def heurisch( + f, x, rewrite=..., hints=..., mappings=..., retries=..., degree_offset=..., unnecessary_permutations=..., _try_heurisch=... +): ... diff --git a/stubs/sympy-stubs/integrals/integrals.pyi b/stubs/sympy-stubs/integrals/integrals.pyi index 4a86f3f5..983f300c 100644 --- a/stubs/sympy-stubs/integrals/integrals.pyi +++ b/stubs/sympy-stubs/integrals/integrals.pyi @@ -10,37 +10,16 @@ from sympy.tensor.functions import shape class Integral(AddWithLimits): __slots__ = ... args: tTuple[Expr, Tuple] - def __new__(cls, function, *symbols, **assumptions) -> Equality | Relational | Ne | Self: - ... - - def __getnewargs__(self) -> tuple[Basic, *tuple[tuple[Any], ...]]: - ... - + def __new__(cls, function, *symbols, **assumptions) -> Equality | Relational | Ne | Self: ... + def __getnewargs__(self) -> tuple[Basic, *tuple[tuple[Any], ...]]: ... @property - def free_symbols(self) -> set[Any]: - ... - - def transform(self, x, u) -> Self: - ... - - def doit(self, **hints): - ... - - def as_sum(self, n=..., method=..., evaluate=...): - ... - - def principal_value(self, **kwargs) -> Self: - ... - - - -def integrate(*args, meijerg=..., conds=..., risch=..., heurisch=..., manual=..., **kwargs) -> Equality | Relational | Ne: - ... - -def line_integrate(field, curve, vars) -> Equality | Relational | Ne: - ... + def free_symbols(self) -> set[Any]: ... + def transform(self, x, u) -> Self: ... + def doit(self, **hints): ... + def as_sum(self, n=..., method=..., evaluate=...): ... + def principal_value(self, **kwargs) -> Self: ... +def integrate(*args, meijerg=..., conds=..., risch=..., heurisch=..., manual=..., **kwargs) -> Equality | Relational | Ne: ... +def line_integrate(field, curve, vars) -> Equality | Relational | Ne: ... @shape.register(Integral) -def _(expr): - ... - +def _(expr): ... diff --git a/stubs/sympy-stubs/integrals/laplace.pyi b/stubs/sympy-stubs/integrals/laplace.pyi index e48cdaa6..e9a371ce 100644 --- a/stubs/sympy-stubs/integrals/laplace.pyi +++ b/stubs/sympy-stubs/integrals/laplace.pyi @@ -10,35 +10,23 @@ from sympy.functions.elementary.miscellaneous import Max from sympy.integrals.transforms import IntegralTransform from sympy.series.order import Order -def expand_dirac_delta(expr) -> tuple[Any, dict[Any, Any]] | tuple[Any | Order, dict[Any, Any | Order]] | tuple[Any | Mul, dict[Any, Any]]: - ... +def expand_dirac_delta( + expr, +) -> tuple[Any, dict[Any, Any]] | tuple[Any | Order, dict[Any, Any | Order]] | tuple[Any | Mul, dict[Any, Any]]: ... class LaplaceTransform(IntegralTransform): _name = ... - def doit(self, **hints) -> Order | tuple[Any | Order, Any | Max, Any | And]: - ... - + def doit(self, **hints) -> Order | tuple[Any | Order, Any | Max, Any | And]: ... - -def laplace_transform(f, t, s, legacy_matrix=..., **hints) -> tuple[MatrixBase, Any | Max, Any | And] | MatrixBase: - ... +def laplace_transform(f, t, s, legacy_matrix=..., **hints) -> tuple[MatrixBase, Any | Max, Any | And] | MatrixBase: ... class InverseLaplaceTransform(IntegralTransform): _name = ... _none_sentinel = ... _c = ... - def __new__(cls, F, s, x, plane, **opts) -> type[UndefinedFunction]: - ... - + def __new__(cls, F, s, x, plane, **opts) -> type[UndefinedFunction]: ... @property - def fundamental_plane(self) -> Basic | None: - ... - - def doit(self, **hints) -> Order | tuple[Any | Order, Any | And]: - ... - - - -def inverse_laplace_transform(F, s, t, plane=..., **hints): - ... + def fundamental_plane(self) -> Basic | None: ... + def doit(self, **hints) -> Order | tuple[Any | Order, Any | And]: ... +def inverse_laplace_transform(F, s, t, plane=..., **hints): ... diff --git a/stubs/sympy-stubs/integrals/manualintegrate.pyi b/stubs/sympy-stubs/integrals/manualintegrate.pyi index 9f1b5e4c..c73fb174 100644 --- a/stubs/sympy-stubs/integrals/manualintegrate.pyi +++ b/stubs/sympy-stubs/integrals/manualintegrate.pyi @@ -16,83 +16,51 @@ class Rule(ABC): integrand: Expr variable: Symbol @abstractmethod - def eval(self) -> Expr: - ... - + def eval(self) -> Expr: ... @abstractmethod - def contains_dont_know(self) -> bool: - ... - - + def contains_dont_know(self) -> bool: ... @dataclass class AtomicRule(Rule, ABC): - def contains_dont_know(self) -> bool: - ... - - + def contains_dont_know(self) -> bool: ... @dataclass class ConstantRule(AtomicRule): - def eval(self) -> Expr: - ... - - + def eval(self) -> Expr: ... @dataclass class ConstantTimesRule(Rule): constant: Expr other: Expr substep: Rule - def eval(self) -> Expr: - ... - - def contains_dont_know(self) -> bool: - ... - - + def eval(self) -> Expr: ... + def contains_dont_know(self) -> bool: ... @dataclass class PowerRule(AtomicRule): base: Expr exp: Expr - def eval(self) -> Expr: - ... - - + def eval(self) -> Expr: ... @dataclass class NestedPowRule(AtomicRule): base: Expr exp: Expr - def eval(self) -> Expr: - ... - - + def eval(self) -> Expr: ... @dataclass class AddRule(Rule): substeps: list[Rule] - def eval(self) -> Expr: - ... - - def contains_dont_know(self) -> bool: - ... - - + def eval(self) -> Expr: ... + def contains_dont_know(self) -> bool: ... @dataclass class URule(Rule): u_var: Symbol u_func: Expr substep: Rule - def eval(self) -> Expr: - ... - - def contains_dont_know(self) -> bool: - ... - - + def eval(self) -> Expr: ... + def contains_dont_know(self) -> bool: ... @dataclass class PartsRule(Rule): @@ -100,132 +68,79 @@ class PartsRule(Rule): dv: Expr v_step: Rule second_step: Rule | None - def eval(self) -> Expr: - ... - - def contains_dont_know(self) -> bool: - ... - - + def eval(self) -> Expr: ... + def contains_dont_know(self) -> bool: ... @dataclass class CyclicPartsRule(Rule): parts_rules: list[PartsRule] coefficient: Expr - def eval(self) -> Expr: - ... - - def contains_dont_know(self) -> bool: - ... - - + def eval(self) -> Expr: ... + def contains_dont_know(self) -> bool: ... @dataclass -class TrigRule(AtomicRule, ABC): - ... - +class TrigRule(AtomicRule, ABC): ... @dataclass class SinRule(TrigRule): - def eval(self) -> Expr: - ... - - + def eval(self) -> Expr: ... @dataclass class CosRule(TrigRule): - def eval(self) -> Expr: - ... - - + def eval(self) -> Expr: ... @dataclass class SecTanRule(TrigRule): - def eval(self) -> Expr: - ... - - + def eval(self) -> Expr: ... @dataclass class CscCotRule(TrigRule): - def eval(self) -> Expr: - ... - - + def eval(self) -> Expr: ... @dataclass class Sec2Rule(TrigRule): - def eval(self) -> Expr: - ... - - + def eval(self) -> Expr: ... @dataclass class Csc2Rule(TrigRule): - def eval(self) -> Expr: - ... - - + def eval(self) -> Expr: ... @dataclass -class HyperbolicRule(AtomicRule, ABC): - ... - +class HyperbolicRule(AtomicRule, ABC): ... @dataclass class SinhRule(HyperbolicRule): - def eval(self) -> Expr: - ... - - + def eval(self) -> Expr: ... @dataclass class CoshRule(HyperbolicRule): - def eval(self) -> type[UndefinedFunction]: - ... - - + def eval(self) -> type[UndefinedFunction]: ... @dataclass class ExpRule(AtomicRule): base: Expr exp: Expr - def eval(self) -> Expr: - ... - - + def eval(self) -> Expr: ... @dataclass class ReciprocalRule(AtomicRule): base: Expr - def eval(self) -> Expr: - ... - - + def eval(self) -> Expr: ... @dataclass class ArcsinRule(AtomicRule): - def eval(self) -> Expr: - ... - - + def eval(self) -> Expr: ... @dataclass class ArcsinhRule(AtomicRule): - def eval(self) -> Expr: - ... - - + def eval(self) -> Expr: ... @dataclass class ReciprocalSqrtQuadraticRule(AtomicRule): a: Expr b: Expr c: Expr - def eval(self) -> Expr: - ... - - + def eval(self) -> Expr: ... @dataclass class SqrtQuadraticDenomRule(AtomicRule): @@ -233,99 +148,60 @@ class SqrtQuadraticDenomRule(AtomicRule): b: Expr c: Expr coeffs: list[Expr] - def eval(self) -> Expr: - ... - - + def eval(self) -> Expr: ... @dataclass class SqrtQuadraticRule(AtomicRule): a: Expr b: Expr c: Expr - def eval(self) -> Expr: - ... - - + def eval(self) -> Expr: ... @dataclass class AlternativeRule(Rule): alternatives: list[Rule] - def eval(self) -> Expr: - ... - - def contains_dont_know(self) -> bool: - ... - - + def eval(self) -> Expr: ... + def contains_dont_know(self) -> bool: ... @dataclass class DontKnowRule(Rule): - def eval(self) -> Expr: - ... - - def contains_dont_know(self) -> bool: - ... - - + def eval(self) -> Expr: ... + def contains_dont_know(self) -> bool: ... @dataclass class DerivativeRule(AtomicRule): - def eval(self) -> Expr: - ... - - + def eval(self) -> Expr: ... @dataclass class RewriteRule(Rule): rewritten: Expr substep: Rule - def eval(self) -> Expr: - ... - - def contains_dont_know(self) -> bool: - ... - - + def eval(self) -> Expr: ... + def contains_dont_know(self) -> bool: ... @dataclass -class CompleteSquareRule(RewriteRule): - ... - +class CompleteSquareRule(RewriteRule): ... @dataclass class PiecewiseRule(Rule): subfunctions: Sequence[tuple[Rule, bool | Boolean]] - def eval(self) -> Expr: - ... - - def contains_dont_know(self) -> bool: - ... - - + def eval(self) -> Expr: ... + def contains_dont_know(self) -> bool: ... @dataclass class HeavisideRule(Rule): harg: Expr ibnd: Expr substep: Rule - def eval(self) -> Expr: - ... - - def contains_dont_know(self) -> bool: - ... - - + def eval(self) -> Expr: ... + def contains_dont_know(self) -> bool: ... @dataclass class DiracDeltaRule(AtomicRule): n: Expr a: Expr b: Expr - def eval(self) -> Expr: - ... - - + def eval(self) -> Expr: ... @dataclass class TrigSubstitutionRule(Rule): @@ -334,89 +210,56 @@ class TrigSubstitutionRule(Rule): rewritten: Expr substep: Rule restriction: bool | Boolean - def eval(self) -> Expr: - ... - - def contains_dont_know(self) -> bool: - ... - - + def eval(self) -> Expr: ... + def contains_dont_know(self) -> bool: ... @dataclass class ArctanRule(AtomicRule): a: Expr b: Expr c: Expr - def eval(self) -> Expr: - ... - - + def eval(self) -> Expr: ... @dataclass class OrthogonalPolyRule(AtomicRule, ABC): n: Expr ... - @dataclass class JacobiRule(OrthogonalPolyRule): a: Expr b: Expr - def eval(self) -> Expr: - ... - - + def eval(self) -> Expr: ... @dataclass class GegenbauerRule(OrthogonalPolyRule): a: Expr - def eval(self) -> Expr: - ... - - + def eval(self) -> Expr: ... @dataclass class ChebyshevTRule(OrthogonalPolyRule): - def eval(self) -> Expr: - ... - - + def eval(self) -> Expr: ... @dataclass class ChebyshevURule(OrthogonalPolyRule): - def eval(self) -> Expr: - ... - - + def eval(self) -> Expr: ... @dataclass class LegendreRule(OrthogonalPolyRule): - def eval(self) -> Expr: - ... - - + def eval(self) -> Expr: ... @dataclass class HermiteRule(OrthogonalPolyRule): - def eval(self) -> Expr: - ... - - + def eval(self) -> Expr: ... @dataclass class LaguerreRule(OrthogonalPolyRule): - def eval(self) -> Expr: - ... - - + def eval(self) -> Expr: ... @dataclass class AssocLaguerreRule(OrthogonalPolyRule): a: Expr - def eval(self) -> Expr: - ... - - + def eval(self) -> Expr: ... @dataclass class IRule(AtomicRule, ABC): @@ -424,222 +267,125 @@ class IRule(AtomicRule, ABC): b: Expr ... - @dataclass class CiRule(IRule): - def eval(self) -> Expr: - ... - - + def eval(self) -> Expr: ... @dataclass class ChiRule(IRule): - def eval(self) -> Expr: - ... - - + def eval(self) -> Expr: ... @dataclass class EiRule(IRule): - def eval(self) -> Expr: - ... - - + def eval(self) -> Expr: ... @dataclass class SiRule(IRule): - def eval(self) -> Expr: - ... - - + def eval(self) -> Expr: ... @dataclass class ShiRule(IRule): - def eval(self) -> Expr: - ... - - + def eval(self) -> Expr: ... @dataclass class LiRule(IRule): - def eval(self) -> Expr: - ... - - + def eval(self) -> Expr: ... @dataclass class ErfRule(AtomicRule): a: Expr b: Expr c: Expr - def eval(self) -> Expr: - ... - - + def eval(self) -> Expr: ... @dataclass class FresnelCRule(AtomicRule): a: Expr b: Expr c: Expr - def eval(self) -> Expr: - ... - - + def eval(self) -> Expr: ... @dataclass class FresnelSRule(AtomicRule): a: Expr b: Expr c: Expr - def eval(self) -> Expr: - ... - - + def eval(self) -> Expr: ... @dataclass class PolylogRule(AtomicRule): a: Expr b: Expr - def eval(self) -> Expr: - ... - - + def eval(self) -> Expr: ... @dataclass class UpperGammaRule(AtomicRule): a: Expr e: Expr - def eval(self) -> Expr: - ... - - + def eval(self) -> Expr: ... @dataclass class EllipticFRule(AtomicRule): a: Expr d: Expr - def eval(self) -> Expr: - ... - - + def eval(self) -> Expr: ... @dataclass class EllipticERule(AtomicRule): a: Expr d: Expr - def eval(self) -> Expr: - ... - - + def eval(self) -> Expr: ... class IntegralInfo(NamedTuple): integrand: Expr symbol: Symbol ... - -def manual_diff(f, symbol) -> int | ArrayDerivative | Derivative: - ... - -def manual_subs(expr, *args): - ... +def manual_diff(f, symbol) -> int | ArrayDerivative | Derivative: ... +def manual_subs(expr, *args): ... inverse_trig_functions = ... -def find_substitutions(integrand, symbol, u_var) -> list[Any]: - ... - -def rewriter(condition, rewrite) -> Callable[..., RewriteRule | None]: - ... -def proxy_rewriter(condition, rewrite) -> Callable[..., RewriteRule | None]: - ... - -def multiplexer(conditions) -> Callable[..., Any | None]: - ... - -def alternatives(*rules) -> Callable[..., Any | AlternativeRule | None]: - ... - -def constant_rule(integral) -> ConstantRule: - ... - -def power_rule(integral) -> ReciprocalRule | PowerRule | ExpRule | ConstantRule | PiecewiseRule | None: - ... - -def exp_rule(integral) -> ExpRule | None: - ... - -def orthogonal_poly_rule(integral) -> None: - ... +def find_substitutions(integrand, symbol, u_var) -> list[Any]: ... +def rewriter(condition, rewrite) -> Callable[..., RewriteRule | None]: ... +def proxy_rewriter(condition, rewrite) -> Callable[..., RewriteRule | None]: ... +def multiplexer(conditions) -> Callable[..., Any | None]: ... +def alternatives(*rules) -> Callable[..., Any | AlternativeRule | None]: ... +def constant_rule(integral) -> ConstantRule: ... +def power_rule(integral) -> ReciprocalRule | PowerRule | ExpRule | ConstantRule | PiecewiseRule | None: ... +def exp_rule(integral) -> ExpRule | None: ... +def orthogonal_poly_rule(integral) -> None: ... _special_function_patterns: list[tuple[Type, Expr, Callable | None, tuple]] = ... _wilds = ... _symbol = ... -def special_function_rule(integral) -> None: - ... +def special_function_rule(integral) -> None: ... def nested_pow_rule(integral: IntegralInfo) -> Rule | None: - class NoMatch(Exception): - ... - - - -def inverse_trig_rule(integral: IntegralInfo, degenerate=...) -> NestedPowRule | Rule | None: - ... - -def add_rule(integral) -> AddRule | None: - ... - -def mul_rule(integral: IntegralInfo) -> ConstantTimesRule | None: - ... - -def parts_rule(integral) -> ConstantTimesRule | CyclicPartsRule | PartsRule | None: - ... - -def trig_rule(integral) -> SinRule | CosRule | Sec2Rule | Csc2Rule | RewriteRule | None: - ... - -def trig_product_rule(integral: IntegralInfo) -> SecTanRule | CscCotRule | None: - ... - -def quadratic_denom_rule(integral) -> ArctanRule | RewriteRule | PiecewiseRule | URule | ConstantTimesRule | None: - ... - -def sqrt_linear_rule(integral: IntegralInfo) -> PiecewiseRule | URule | None: - ... - -def sqrt_quadratic_rule(integral: IntegralInfo, degenerate=...) -> Rule | None: - ... - -def hyperbolic_rule(integral: tuple[Expr, Symbol]) -> SinhRule | CoshRule | RewriteRule | None: - ... - + class NoMatch(Exception): ... + +def inverse_trig_rule(integral: IntegralInfo, degenerate=...) -> NestedPowRule | Rule | None: ... +def add_rule(integral) -> AddRule | None: ... +def mul_rule(integral: IntegralInfo) -> ConstantTimesRule | None: ... +def parts_rule(integral) -> ConstantTimesRule | CyclicPartsRule | PartsRule | None: ... +def trig_rule(integral) -> SinRule | CosRule | Sec2Rule | Csc2Rule | RewriteRule | None: ... +def trig_product_rule(integral: IntegralInfo) -> SecTanRule | CscCotRule | None: ... +def quadratic_denom_rule(integral) -> ArctanRule | RewriteRule | PiecewiseRule | URule | ConstantTimesRule | None: ... +def sqrt_linear_rule(integral: IntegralInfo) -> PiecewiseRule | URule | None: ... +def sqrt_quadratic_rule(integral: IntegralInfo, degenerate=...) -> Rule | None: ... +def hyperbolic_rule(integral: tuple[Expr, Symbol]) -> SinhRule | CoshRule | RewriteRule | None: ... @cacheit -def make_wilds(symbol) -> tuple[Wild, Wild, Wild, Wild]: - ... - +def make_wilds(symbol) -> tuple[Wild, Wild, Wild, Wild]: ... @cacheit -def sincos_pattern(symbol) -> tuple[Any, Wild, Wild, Wild, Wild]: - ... - +def sincos_pattern(symbol) -> tuple[Any, Wild, Wild, Wild, Wild]: ... @cacheit -def tansec_pattern(symbol) -> tuple[Any, Wild, Wild, Wild, Wild]: - ... - +def tansec_pattern(symbol) -> tuple[Any, Wild, Wild, Wild, Wild]: ... @cacheit -def cotcsc_pattern(symbol) -> tuple[Any, Wild, Wild, Wild, Wild]: - ... - +def cotcsc_pattern(symbol) -> tuple[Any, Wild, Wild, Wild, Wild]: ... @cacheit -def heaviside_pattern(symbol) -> tuple[Any, Wild, Wild, Wild]: - ... - -def uncurry(func) -> Callable[..., Any]: - ... - -def trig_rewriter(rewrite) -> Callable[..., RewriteRule | None]: - ... +def heaviside_pattern(symbol) -> tuple[Any, Wild, Wild, Wild]: ... +def uncurry(func) -> Callable[..., Any]: ... +def trig_rewriter(rewrite) -> Callable[..., RewriteRule | None]: ... sincos_botheven_condition = ... sincos_botheven = ... @@ -657,52 +403,29 @@ cotcsc_csceven_condition = ... cotcsc_csceven = ... cotcsc_cotodd_condition = ... cotcsc_cotodd = ... -def trig_sincos_rule(integral) -> None: - ... -def trig_tansec_rule(integral) -> None: - ... - -def trig_cotcsc_rule(integral) -> None: - ... - -def trig_sindouble_rule(integral) -> DontKnowRule | tuple[Any, Any] | Rule | None: - ... - -def trig_powers_products_rule(integral) -> DontKnowRule | Rule | tuple[Any, Any]: - ... - -def trig_substitution_rule(integral) -> TrigSubstitutionRule | None: - ... - -def heaviside_rule(integral) -> HeavisideRule | None: - ... - -def dirac_delta_rule(integral: IntegralInfo) -> Rule | None: - ... - -def substitution_rule(integral) -> AlternativeRule | None: - ... +def trig_sincos_rule(integral) -> None: ... +def trig_tansec_rule(integral) -> None: ... +def trig_cotcsc_rule(integral) -> None: ... +def trig_sindouble_rule(integral) -> DontKnowRule | tuple[Any, Any] | Rule | None: ... +def trig_powers_products_rule(integral) -> DontKnowRule | Rule | tuple[Any, Any]: ... +def trig_substitution_rule(integral) -> TrigSubstitutionRule | None: ... +def heaviside_rule(integral) -> HeavisideRule | None: ... +def dirac_delta_rule(integral: IntegralInfo) -> Rule | None: ... +def substitution_rule(integral) -> AlternativeRule | None: ... partial_fractions_rule = ... cancel_rule = ... distribute_expand_rule = ... trig_expand_rule = ... -def derivative_rule(integral) -> DerivativeRule | DontKnowRule | ConstantRule: - ... - -def rewrites_rule(integral) -> RewriteRule | None: - ... -def fallback_rule(integral) -> DontKnowRule: - ... +def derivative_rule(integral) -> DerivativeRule | DontKnowRule | ConstantRule: ... +def rewrites_rule(integral) -> RewriteRule | None: ... +def fallback_rule(integral) -> DontKnowRule: ... _integral_cache: dict[Expr, Expr | None] = ... _parts_u_cache: dict[Expr, int] = ... _cache_dummy = ... -def integral_steps(integrand, symbol, **options) -> DontKnowRule | tuple[Any, Any] | Rule: - ... - -def manualintegrate(f, var) -> Piecewise | Expr: - ... +def integral_steps(integrand, symbol, **options) -> DontKnowRule | tuple[Any, Any] | Rule: ... +def manualintegrate(f, var) -> Piecewise | Expr: ... diff --git a/stubs/sympy-stubs/integrals/meijerint.pyi b/stubs/sympy-stubs/integrals/meijerint.pyi index a2ca1743..8f971d6f 100644 --- a/stubs/sympy-stubs/integrals/meijerint.pyi +++ b/stubs/sympy-stubs/integrals/meijerint.pyi @@ -4,19 +4,13 @@ from sympy.functions.elementary.piecewise import Piecewise z = ... timeit = ... -class _CoeffExpValueError(ValueError): - ... +class _CoeffExpValueError(ValueError): ... _dummies: dict[tuple[str, str], Dummy] = ... _lookup_table = ... -def meijerint_indefinite(f, x) -> Piecewise | Basic | None: - ... +def meijerint_indefinite(f, x) -> Piecewise | Basic | None: ... @timeit -def meijerint_definite(f, x, a, b): - ... - -def meijerint_inversion(f, x, t) -> Piecewise | None: - ... - +def meijerint_definite(f, x, a, b): ... +def meijerint_inversion(f, x, t) -> Piecewise | None: ... diff --git a/stubs/sympy-stubs/integrals/prde.pyi b/stubs/sympy-stubs/integrals/prde.pyi index ca0be820..30248f5d 100644 --- a/stubs/sympy-stubs/integrals/prde.pyi +++ b/stubs/sympy-stubs/integrals/prde.pyi @@ -5,60 +5,27 @@ from sympy.series.order import Order zeros = ... eye = ... -def prde_normal_denom(fa, fd, G, DE) -> tuple[Any, tuple[Any, Any], list[Any], Any]: - ... - -def real_imag(ba, bd, gen) -> tuple[Any, Any, Any]: - ... - -def prde_special_denom(a, ba, bd, G, DE, case=...) -> tuple[Any, Any, Any, Any] | tuple[Any, Any, list[Any], Any]: - ... - -def prde_linear_constraints(a, b, G, DE) -> tuple[Any, PolyMatrix]: - ... - -def poly_linear_constraints(p, d) -> tuple[Any, PolyMatrix]: - ... - -def constant_system(A, u, DE) -> tuple[Any, Any]: - ... - -def prde_spde(a, b, Q, n, DE) -> tuple[Any, Any, list[Any], list[Any], Any]: - ... - -def prde_no_cancel_b_large(b, Q, n, DE) -> tuple[list[Any], Any]: - ... - -def prde_no_cancel_b_small(b, Q, n, DE) -> tuple[list[Any], Any] | tuple[list[Any], PolyMatrix | Any]: - ... - -def prde_cancel_liouvillian(b, Q, n, DE) -> tuple[list[Any], Any]: - ... - -def param_poly_rischDE(a, b, q, n, DE) -> tuple[list[Any], PolyMatrix] | tuple[list[Any], Any] | tuple[list[Any], PolyMatrix | Any]: - ... - -def param_rischDE(fa, fd, G, DE) -> tuple[list[Any], PolyMatrix]: - ... - -def limited_integrate_reduce(fa, fd, G, DE) -> tuple[Any, Any, Any, Any, Any, list[Any]]: - ... - -def limited_integrate(fa, fd, G, DE) -> tuple[tuple[Any, Any], list[Any]] | None: - ... - -def parametric_log_deriv_heu(fa, fd, wa, wd, DE, c1=...) -> tuple[Any, Any, Any | Order] | None: - ... - -def parametric_log_deriv(fa, fd, wa, wd, DE) -> tuple[Any, Any, Any | Order] | None: - ... - -def is_deriv_k(fa, fd, DE) -> tuple[list[tuple[Any, Any]], Any | Order, Any] | None: - ... - -def is_log_deriv_k_t_radical(fa, fd, DE, Df=...) -> tuple[list[tuple[Any, Any]], Any | Order, Any | Literal[0], Any] | None: - ... - -def is_log_deriv_k_t_radical_in_field(fa, fd, DE, case=..., z=...) -> tuple[Any | int, Any | Order] | tuple[Any | int, Any] | None: - ... +def prde_normal_denom(fa, fd, G, DE) -> tuple[Any, tuple[Any, Any], list[Any], Any]: ... +def real_imag(ba, bd, gen) -> tuple[Any, Any, Any]: ... +def prde_special_denom(a, ba, bd, G, DE, case=...) -> tuple[Any, Any, Any, Any] | tuple[Any, Any, list[Any], Any]: ... +def prde_linear_constraints(a, b, G, DE) -> tuple[Any, PolyMatrix]: ... +def poly_linear_constraints(p, d) -> tuple[Any, PolyMatrix]: ... +def constant_system(A, u, DE) -> tuple[Any, Any]: ... +def prde_spde(a, b, Q, n, DE) -> tuple[Any, Any, list[Any], list[Any], Any]: ... +def prde_no_cancel_b_large(b, Q, n, DE) -> tuple[list[Any], Any]: ... +def prde_no_cancel_b_small(b, Q, n, DE) -> tuple[list[Any], Any] | tuple[list[Any], PolyMatrix | Any]: ... +def prde_cancel_liouvillian(b, Q, n, DE) -> tuple[list[Any], Any]: ... +def param_poly_rischDE( + a, b, q, n, DE +) -> tuple[list[Any], PolyMatrix] | tuple[list[Any], Any] | tuple[list[Any], PolyMatrix | Any]: ... +def param_rischDE(fa, fd, G, DE) -> tuple[list[Any], PolyMatrix]: ... +def limited_integrate_reduce(fa, fd, G, DE) -> tuple[Any, Any, Any, Any, Any, list[Any]]: ... +def limited_integrate(fa, fd, G, DE) -> tuple[tuple[Any, Any], list[Any]] | None: ... +def parametric_log_deriv_heu(fa, fd, wa, wd, DE, c1=...) -> tuple[Any, Any, Any | Order] | None: ... +def parametric_log_deriv(fa, fd, wa, wd, DE) -> tuple[Any, Any, Any | Order] | None: ... +def is_deriv_k(fa, fd, DE) -> tuple[list[tuple[Any, Any]], Any | Order, Any] | None: ... +def is_log_deriv_k_t_radical(fa, fd, DE, Df=...) -> tuple[list[tuple[Any, Any]], Any | Order, Any | Literal[0], Any] | None: ... +def is_log_deriv_k_t_radical_in_field( + fa, fd, DE, case=..., z=... +) -> tuple[Any | int, Any | Order] | tuple[Any | int, Any] | None: ... diff --git a/stubs/sympy-stubs/integrals/rationaltools.pyi b/stubs/sympy-stubs/integrals/rationaltools.pyi index e71fc3e8..482e928a 100644 --- a/stubs/sympy-stubs/integrals/rationaltools.pyi +++ b/stubs/sympy-stubs/integrals/rationaltools.pyi @@ -1,17 +1,7 @@ from typing import Any -def ratint(f, x, **flags) -> Any: - ... - -def ratint_ratpart(f, g, x) -> tuple[Any, Any]: - ... - -def ratint_logpart(f, g, x, t=...) -> list[Any]: - ... - -def log_to_atan(f, g): - ... - -def log_to_real(h, q, x, t) -> None: - ... - +def ratint(f, x, **flags) -> Any: ... +def ratint_ratpart(f, g, x) -> tuple[Any, Any]: ... +def ratint_logpart(f, g, x, t=...) -> list[Any]: ... +def log_to_atan(f, g): ... +def log_to_real(h, q, x, t) -> None: ... diff --git a/stubs/sympy-stubs/integrals/rde.pyi b/stubs/sympy-stubs/integrals/rde.pyi index 0746bd6b..6a9d8835 100644 --- a/stubs/sympy-stubs/integrals/rde.pyi +++ b/stubs/sympy-stubs/integrals/rde.pyi @@ -2,45 +2,19 @@ from typing import Any, Literal from sympy.polys.polymatrix import PolyMatrix -def order_at(a, p, t) -> Literal[0]: - ... - -def order_at_oo(a, d, t): - ... - -def weak_normalizer(a, d, DE, z=...) -> tuple[Any, tuple[Any, Any]]: - ... - -def normal_denom(fa, fd, ga, gd, DE) -> tuple[Any, tuple[Any, Any], tuple[Any, Any], Any]: - ... - -def special_denom(a, ba, bd, ca, cd, DE, case=...) -> tuple[Any, Any, Any, Any]: - ... - -def bound_degree(a, b, cQ, DE, case=..., parametric=...): - ... - -def spde(a, b, c, n, DE) -> tuple[Any, Any, Literal[0], Any, Any] | tuple[Any, Any, Any, Any, Any]: - ... - -def no_cancel_b_large(b, c, n, DE) -> Any: - ... - -def no_cancel_b_small(b, c, n, DE) -> tuple[Any, Any, Any] | Any: - ... - -def no_cancel_equal(b, c, n, DE) -> tuple[Any, Any | int, Any] | Any: - ... - -def cancel_primitive(b, c, n, DE) -> Any: - ... - -def cancel_exp(b, c, n, DE) -> Any: - ... - -def solve_poly_rde(b, cQ, n, DE, parametric=...) -> tuple[list[Any], Any] | Any | tuple[list[Any], PolyMatrix | Any] | tuple[Any, Any, Any] | tuple[Any, Any | int, Any]: - ... - -def rischDE(fa, fd, ga, gd, DE) -> tuple[Any, Any]: - ... - +def order_at(a, p, t) -> Literal[0]: ... +def order_at_oo(a, d, t): ... +def weak_normalizer(a, d, DE, z=...) -> tuple[Any, tuple[Any, Any]]: ... +def normal_denom(fa, fd, ga, gd, DE) -> tuple[Any, tuple[Any, Any], tuple[Any, Any], Any]: ... +def special_denom(a, ba, bd, ca, cd, DE, case=...) -> tuple[Any, Any, Any, Any]: ... +def bound_degree(a, b, cQ, DE, case=..., parametric=...): ... +def spde(a, b, c, n, DE) -> tuple[Any, Any, Literal[0], Any, Any] | tuple[Any, Any, Any, Any, Any]: ... +def no_cancel_b_large(b, c, n, DE) -> Any: ... +def no_cancel_b_small(b, c, n, DE) -> tuple[Any, Any, Any] | Any: ... +def no_cancel_equal(b, c, n, DE) -> tuple[Any, Any | int, Any] | Any: ... +def cancel_primitive(b, c, n, DE) -> Any: ... +def cancel_exp(b, c, n, DE) -> Any: ... +def solve_poly_rde( + b, cQ, n, DE, parametric=... +) -> tuple[list[Any], Any] | Any | tuple[list[Any], PolyMatrix | Any] | tuple[Any, Any, Any] | tuple[Any, Any | int, Any]: ... +def rischDE(fa, fd, ga, gd, DE) -> tuple[Any, Any]: ... diff --git a/stubs/sympy-stubs/integrals/risch.pyi b/stubs/sympy-stubs/integrals/risch.pyi index 2d5db103..331c5707 100644 --- a/stubs/sympy-stubs/integrals/risch.pyi +++ b/stubs/sympy-stubs/integrals/risch.pyi @@ -3,130 +3,67 @@ from typing import Any, Literal from sympy.core.relational import Equality, Ne, Relational from sympy.integrals.integrals import Integral -def integer_powers(exprs) -> list[tuple[Any, Any]]: - ... +def integer_powers(exprs) -> list[tuple[Any, Any]]: ... class DifferentialExtension: __slots__ = ... - def __init__(self, f=..., x=..., handle_first=..., dummy=..., extension=..., rewrite_complex=...) -> None: - ... - - def __getattr__(self, attr) -> None: - ... - - def __repr__(self) -> str: - ... - - def __str__(self) -> str: - ... - - def __eq__(self, other) -> bool: - ... - - def reset(self) -> None: - ... - - def indices(self, extension) -> list[int]: - ... - - def increment_level(self) -> None: - ... - - def decrement_level(self) -> None: - ... - - - -def update_sets(seq, atoms, func) -> list[Any]: - ... + def __init__(self, f=..., x=..., handle_first=..., dummy=..., extension=..., rewrite_complex=...) -> None: ... + def __getattr__(self, attr) -> None: ... + def __repr__(self) -> str: ... + def __str__(self) -> str: ... + def __eq__(self, other) -> bool: ... + def reset(self) -> None: ... + def indices(self, extension) -> list[int]: ... + def increment_level(self) -> None: ... + def decrement_level(self) -> None: ... + +def update_sets(seq, atoms, func) -> list[Any]: ... class DecrementLevel: __slots__ = ... - def __init__(self, DE) -> None: - ... - - def __enter__(self) -> None: - ... - - def __exit__(self, exc_type, exc_value, traceback) -> None: - ... - - - -class NonElementaryIntegralException(Exception): - ... - - -def gcdex_diophantine(a, b, c) -> tuple[Any, Any]: - ... - -def frac_in(f, t, *, cancel=..., **kwargs) -> tuple[Any, Any]: - ... - -def as_poly_1t(p, t, z): - ... - -def derivation(p, DE, coefficientD=..., basic=...) -> Any | Literal[0]: - ... - -def get_case(d, t) -> Literal['base', 'primitive', 'exp', 'tan', 'other_nonlinear', 'other_linear']: - ... - -def splitfactor(p, DE, coefficientD=..., z=...) -> tuple[Any, Any]: - ... - -def splitfactor_sqf(p, DE, coefficientD=..., z=..., basic=...) -> tuple[tuple[tuple[Any, Literal[1]]], tuple[()]] | tuple[tuple[Any, ...], tuple[Any, ...]]: - ... - -def canonical_representation(a, d, DE) -> tuple[Any, tuple[Any, Any], tuple[Any, Any]]: - ... - -def hermite_reduce(a, d, DE) -> tuple[tuple[Any, Any], tuple[Any, Any], tuple[Any, Any]]: - ... - -def polynomial_reduce(p, DE) -> tuple[Any, Any]: - ... - -def laurent_series(a, d, F, n, DE) -> tuple[Any, Any, list[Any]] | Literal[0]: - ... - -def recognize_derivative(a, d, DE, z=...) -> bool: - ... - -def recognize_log_derivative(a, d, DE, z=...) -> bool: - ... - -def residue_reduce(a, d, DE, z=..., invert=...) -> tuple[list[Any], Literal[True]] | tuple[list[Any], bool]: - ... - -def residue_reduce_to_basic(H, DE, z) -> int: - ... - -def residue_reduce_derivation(H, DE, z): - ... - -def integrate_primitive_polynomial(p, DE) -> tuple[Any, Any, Literal[True]] | tuple[Any, Any, Literal[False]]: - ... - -def integrate_primitive(a, d, DE, z=...) -> tuple[Any, Any | Equality | Relational | Ne | NonElementaryIntegral, Literal[False]] | tuple[Any, Any | Equality | Relational | Ne | NonElementaryIntegral, bool]: - ... - -def integrate_hyperexponential_polynomial(p, DE, z) -> tuple[Any, Any, Literal[True]] | tuple[Any, Any, bool]: - ... - -def integrate_hyperexponential(a, d, DE, z=..., conds=...) -> tuple[Any, Any | Equality | Relational | Ne | NonElementaryIntegral, Literal[False]] | tuple[Any, Any | Equality | Relational | Ne | NonElementaryIntegral, bool]: - ... - -def integrate_hypertangent_polynomial(p, DE) -> tuple[Any, Any]: - ... - -def integrate_nonlinear_no_specials(a, d, DE, z=...) -> tuple[Any, Literal[False]] | tuple[Any, bool]: - ... - -class NonElementaryIntegral(Integral): - ... - - -def risch_integrate(f, x, extension=..., handle_first=..., separate_integral=..., rewrite_complex=..., conds=...) -> tuple[Any, NonElementaryIntegral] | tuple[Any, Literal[0]] | None: - ... - + def __init__(self, DE) -> None: ... + def __enter__(self) -> None: ... + def __exit__(self, exc_type, exc_value, traceback) -> None: ... + +class NonElementaryIntegralException(Exception): ... + +def gcdex_diophantine(a, b, c) -> tuple[Any, Any]: ... +def frac_in(f, t, *, cancel=..., **kwargs) -> tuple[Any, Any]: ... +def as_poly_1t(p, t, z): ... +def derivation(p, DE, coefficientD=..., basic=...) -> Any | Literal[0]: ... +def get_case(d, t) -> Literal["base", "primitive", "exp", "tan", "other_nonlinear", "other_linear"]: ... +def splitfactor(p, DE, coefficientD=..., z=...) -> tuple[Any, Any]: ... +def splitfactor_sqf( + p, DE, coefficientD=..., z=..., basic=... +) -> tuple[tuple[tuple[Any, Literal[1]]], tuple[()]] | tuple[tuple[Any, ...], tuple[Any, ...]]: ... +def canonical_representation(a, d, DE) -> tuple[Any, tuple[Any, Any], tuple[Any, Any]]: ... +def hermite_reduce(a, d, DE) -> tuple[tuple[Any, Any], tuple[Any, Any], tuple[Any, Any]]: ... +def polynomial_reduce(p, DE) -> tuple[Any, Any]: ... +def laurent_series(a, d, F, n, DE) -> tuple[Any, Any, list[Any]] | Literal[0]: ... +def recognize_derivative(a, d, DE, z=...) -> bool: ... +def recognize_log_derivative(a, d, DE, z=...) -> bool: ... +def residue_reduce(a, d, DE, z=..., invert=...) -> tuple[list[Any], Literal[True]] | tuple[list[Any], bool]: ... +def residue_reduce_to_basic(H, DE, z) -> int: ... +def residue_reduce_derivation(H, DE, z): ... +def integrate_primitive_polynomial(p, DE) -> tuple[Any, Any, Literal[True]] | tuple[Any, Any, Literal[False]]: ... +def integrate_primitive( + a, d, DE, z=... +) -> ( + tuple[Any, Any | Equality | Relational | Ne | NonElementaryIntegral, Literal[False]] + | tuple[Any, Any | Equality | Relational | Ne | NonElementaryIntegral, bool] +): ... +def integrate_hyperexponential_polynomial(p, DE, z) -> tuple[Any, Any, Literal[True]] | tuple[Any, Any, bool]: ... +def integrate_hyperexponential( + a, d, DE, z=..., conds=... +) -> ( + tuple[Any, Any | Equality | Relational | Ne | NonElementaryIntegral, Literal[False]] + | tuple[Any, Any | Equality | Relational | Ne | NonElementaryIntegral, bool] +): ... +def integrate_hypertangent_polynomial(p, DE) -> tuple[Any, Any]: ... +def integrate_nonlinear_no_specials(a, d, DE, z=...) -> tuple[Any, Literal[False]] | tuple[Any, bool]: ... + +class NonElementaryIntegral(Integral): ... + +def risch_integrate( + f, x, extension=..., handle_first=..., separate_integral=..., rewrite_complex=..., conds=... +) -> tuple[Any, NonElementaryIntegral] | tuple[Any, Literal[0]] | None: ... diff --git a/stubs/sympy-stubs/integrals/singularityfunctions.pyi b/stubs/sympy-stubs/integrals/singularityfunctions.pyi index e3f64c04..d057134d 100644 --- a/stubs/sympy-stubs/integrals/singularityfunctions.pyi +++ b/stubs/sympy-stubs/integrals/singularityfunctions.pyi @@ -3,6 +3,4 @@ from typing import Any from sympy.core.function import UndefinedFunction from sympy.core.relational import Equality, Ne, Relational -def singularityintegrate(f, x) -> type[UndefinedFunction] | Equality | Any | Relational | Ne | None: - ... - +def singularityintegrate(f, x) -> type[UndefinedFunction] | Equality | Any | Relational | Ne | None: ... diff --git a/stubs/sympy-stubs/integrals/transforms.pyi b/stubs/sympy-stubs/integrals/transforms.pyi index 9cade647..39d6e962 100644 --- a/stubs/sympy-stubs/integrals/transforms.pyi +++ b/stubs/sympy-stubs/integrals/transforms.pyi @@ -10,189 +10,110 @@ from sympy.integrals.integrals import Integral from sympy.series.order import Order class IntegralTransformError(NotImplementedError): - def __init__(self, transform, function, msg) -> None: - ... - - + def __init__(self, transform, function, msg) -> None: ... class IntegralTransform(Function): @property - def function(self) -> Basic: - ... - + def function(self) -> Basic: ... @property - def function_variable(self) -> Basic: - ... - + def function_variable(self) -> Basic: ... @property - def transform_variable(self) -> Basic: - ... - + def transform_variable(self) -> Basic: ... @property - def free_symbols(self) -> set[Basic]: - ... - - def doit(self, **hints) -> Order | tuple[Any | Order, *tuple[Any, ...]] | tuple[Any | Order, Any | And]: - ... - + def free_symbols(self) -> set[Basic]: ... + def doit(self, **hints) -> Order | tuple[Any | Order, *tuple[Any, ...]] | tuple[Any | Order, Any | And]: ... @property - def as_integral(self): - ... - - + def as_integral(self): ... _noconds = ... + class MellinTransform(IntegralTransform): _name = ... +def mellin_transform(f, x, s, **hints): ... -def mellin_transform(f, x, s, **hints): - ... - -class MellinTransformStripError(ValueError): - ... - +class MellinTransformStripError(ValueError): ... _allowed = ... + class InverseMellinTransform(IntegralTransform): _name = ... _none_sentinel = ... _c = ... - def __new__(cls, F, s, x, a, b, **opts) -> type[UndefinedFunction]: - ... - + def __new__(cls, F, s, x, a, b, **opts) -> type[UndefinedFunction]: ... @property - def fundamental_strip(self) -> tuple[Basic | None, Basic | None]: - ... - - + def fundamental_strip(self) -> tuple[Basic | None, Basic | None]: ... -def inverse_mellin_transform(F, s, x, strip, **hints): - ... +def inverse_mellin_transform(F, s, x, strip, **hints): ... class FourierTypeTransform(IntegralTransform): - def a(self): - ... - - def b(self): - ... - - + def a(self): ... + def b(self): ... class FourierTransform(FourierTypeTransform): _name = ... - def a(self) -> Literal[1]: - ... - - def b(self): - ... - - + def a(self) -> Literal[1]: ... + def b(self): ... -def fourier_transform(f, x, k, **hints): - ... +def fourier_transform(f, x, k, **hints): ... class InverseFourierTransform(FourierTypeTransform): _name = ... - def a(self) -> Literal[1]: - ... - - def b(self): - ... - + def a(self) -> Literal[1]: ... + def b(self): ... - -def inverse_fourier_transform(F, k, x, **hints): - ... +def inverse_fourier_transform(F, k, x, **hints): ... class SineCosineTypeTransform(IntegralTransform): - def a(self): - ... - - def b(self): - ... - - + def a(self): ... + def b(self): ... class SineTransform(SineCosineTypeTransform): _name = ... _kern = sin - def a(self): - ... - - def b(self): - ... - - + def a(self): ... + def b(self): ... -def sine_transform(f, x, k, **hints): - ... +def sine_transform(f, x, k, **hints): ... class InverseSineTransform(SineCosineTypeTransform): _name = ... _kern = sin - def a(self): - ... - - def b(self): - ... - + def a(self): ... + def b(self): ... - -def inverse_sine_transform(F, k, x, **hints): - ... +def inverse_sine_transform(F, k, x, **hints): ... class CosineTransform(SineCosineTypeTransform): _name = ... _kern = cos - def a(self): - ... - - def b(self): - ... - - + def a(self): ... + def b(self): ... -def cosine_transform(f, x, k, **hints): - ... +def cosine_transform(f, x, k, **hints): ... class InverseCosineTransform(SineCosineTypeTransform): _name = ... _kern = cos - def a(self): - ... - - def b(self): - ... - + def a(self): ... + def b(self): ... - -def inverse_cosine_transform(F, k, x, **hints): - ... +def inverse_cosine_transform(F, k, x, **hints): ... class HankelTypeTransform(IntegralTransform): - def doit(self, **hints) -> tuple[Any | Equality | Relational | Ne, Any] | tuple[Any, Any]: - ... - + def doit(self, **hints) -> tuple[Any | Equality | Relational | Ne, Any] | tuple[Any, Any]: ... @property - def as_integral(self) -> Equality | Relational | Ne | Integral: - ... - - + def as_integral(self) -> Equality | Relational | Ne | Integral: ... class HankelTransform(HankelTypeTransform): _name = ... - -def hankel_transform(f, r, k, nu, **hints): - ... +def hankel_transform(f, r, k, nu, **hints): ... class InverseHankelTransform(HankelTypeTransform): _name = ... - -def inverse_hankel_transform(F, k, r, nu, **hints): - ... +def inverse_hankel_transform(F, k, r, nu, **hints): ... LaplaceTransform = _laplace.LaplaceTransform laplace_transform = ... diff --git a/stubs/sympy-stubs/interactive/__init__.pyi b/stubs/sympy-stubs/interactive/__init__.pyi index af3a784c..301b689f 100644 --- a/stubs/sympy-stubs/interactive/__init__.pyi +++ b/stubs/sympy-stubs/interactive/__init__.pyi @@ -2,4 +2,4 @@ from sympy.interactive.printing import init_printing from sympy.interactive.session import init_session from sympy.interactive.traversal import interactive_traversal -__all__ = ['init_printing', 'init_session', 'interactive_traversal'] +__all__ = ["init_printing", "init_session", "interactive_traversal"] diff --git a/stubs/sympy-stubs/interactive/printing.pyi b/stubs/sympy-stubs/interactive/printing.pyi index 8ce8350c..9a08d192 100644 --- a/stubs/sympy-stubs/interactive/printing.pyi +++ b/stubs/sympy-stubs/interactive/printing.pyi @@ -1,5 +1,23 @@ - NO_GLOBAL = ... -def init_printing(pretty_print=..., order=..., use_unicode=..., use_latex=..., wrap_line=..., num_columns=..., no_global=..., ip=..., euler=..., forecolor=..., backcolor=..., fontsize=..., latex_mode=..., print_builtin=..., str_printer=..., pretty_printer=..., latex_printer=..., scale=..., **settings) -> None: - ... +def init_printing( + pretty_print=..., + order=..., + use_unicode=..., + use_latex=..., + wrap_line=..., + num_columns=..., + no_global=..., + ip=..., + euler=..., + forecolor=..., + backcolor=..., + fontsize=..., + latex_mode=..., + print_builtin=..., + str_printer=..., + pretty_printer=..., + latex_printer=..., + scale=..., + **settings, +) -> None: ... diff --git a/stubs/sympy-stubs/interactive/session.pyi b/stubs/sympy-stubs/interactive/session.pyi index 72ec2dee..34dce9c8 100644 --- a/stubs/sympy-stubs/interactive/session.pyi +++ b/stubs/sympy-stubs/interactive/session.pyi @@ -4,24 +4,25 @@ from typing import Any preexec_source = ... verbose_message = ... no_ipython = ... -def int_to_Integer(s) -> Any: - ... - -def enable_automatic_int_sympification(shell) -> None: - ... - -def enable_automatic_symbols(shell) -> None: - ... - -def init_ipython_session(shell=..., argv=..., auto_symbols=..., auto_int_to_Integer=...) -> Any: - ... +def int_to_Integer(s) -> Any: ... +def enable_automatic_int_sympification(shell) -> None: ... +def enable_automatic_symbols(shell) -> None: ... +def init_ipython_session(shell=..., argv=..., auto_symbols=..., auto_int_to_Integer=...) -> Any: ... def init_python_session() -> InteractiveConsole: - class SymPyConsole(InteractiveConsole): - ... - - - -def init_session(ipython=..., pretty_print=..., order=..., use_unicode=..., use_latex=..., quiet=..., auto_symbols=..., auto_int_to_Integer=..., str_printer=..., pretty_printer=..., latex_printer=..., argv=...) -> None: - ... + class SymPyConsole(InteractiveConsole): ... +def init_session( + ipython=..., + pretty_print=..., + order=..., + use_unicode=..., + use_latex=..., + quiet=..., + auto_symbols=..., + auto_int_to_Integer=..., + str_printer=..., + pretty_printer=..., + latex_printer=..., + argv=..., +) -> None: ... diff --git a/stubs/sympy-stubs/interactive/traversal.pyi b/stubs/sympy-stubs/interactive/traversal.pyi index 625aa27a..c8244b7d 100644 --- a/stubs/sympy-stubs/interactive/traversal.pyi +++ b/stubs/sympy-stubs/interactive/traversal.pyi @@ -1,5 +1,3 @@ from sympy.core.basic import Basic -def interactive_traversal(expr) -> Basic: - ... - +def interactive_traversal(expr) -> Basic: ... diff --git a/stubs/sympy-stubs/liealgebras/cartan_type.pyi b/stubs/sympy-stubs/liealgebras/cartan_type.pyi index 065d0432..a86042d3 100644 --- a/stubs/sympy-stubs/liealgebras/cartan_type.pyi +++ b/stubs/sympy-stubs/liealgebras/cartan_type.pyi @@ -10,21 +10,11 @@ from sympy.liealgebras.type_f import TypeF from sympy.liealgebras.type_g import TypeG class CartanType_generator: - def __call__(self, *args) -> TypeA | TypeB | TypeC | TypeD | TypeE | TypeF | TypeG | None: - ... - - + def __call__(self, *args) -> TypeA | TypeB | TypeC | TypeD | TypeE | TypeF | TypeG | None: ... CartanType = ... -class Standard_Cartan(Atom): - def __new__(cls, series, n) -> Self: - ... - - def rank(self): - ... - - def series(self) -> Callable[[], Any]: - ... - - +class Standard_Cartan(Atom): + def __new__(cls, series, n) -> Self: ... + def rank(self): ... + def series(self) -> Callable[[], Any]: ... diff --git a/stubs/sympy-stubs/liealgebras/type_a.pyi b/stubs/sympy-stubs/liealgebras/type_a.pyi index 4f82196f..b98d9f6c 100644 --- a/stubs/sympy-stubs/liealgebras/type_a.pyi +++ b/stubs/sympy-stubs/liealgebras/type_a.pyi @@ -3,38 +3,14 @@ from typing import Any, Self from sympy.liealgebras.cartan_type import Standard_Cartan class TypeA(Standard_Cartan): - def __new__(cls, n) -> Self: - ... - - def dimension(self): - ... - - def basic_root(self, i, j): - ... - - def simple_root(self, i): - ... - - def positive_roots(self) -> dict[Any, Any]: - ... - - def highest_root(self): - ... - - def roots(self): - ... - - def cartan_matrix(self): - ... - - def basis(self): - ... - - def lie_algebra(self) -> str: - ... - - def dynkin_diagram(self) -> str: - ... - - - + def __new__(cls, n) -> Self: ... + def dimension(self): ... + def basic_root(self, i, j): ... + def simple_root(self, i): ... + def positive_roots(self) -> dict[Any, Any]: ... + def highest_root(self): ... + def roots(self): ... + def cartan_matrix(self): ... + def basis(self): ... + def lie_algebra(self) -> str: ... + def dynkin_diagram(self) -> str: ... diff --git a/stubs/sympy-stubs/liealgebras/type_b.pyi b/stubs/sympy-stubs/liealgebras/type_b.pyi index fbee4e5e..37c34a29 100644 --- a/stubs/sympy-stubs/liealgebras/type_b.pyi +++ b/stubs/sympy-stubs/liealgebras/type_b.pyi @@ -3,35 +3,13 @@ from typing import Any, Self from sympy.liealgebras.cartan_type import Standard_Cartan class TypeB(Standard_Cartan): - def __new__(cls, n) -> Self: - ... - - def dimension(self): - ... - - def basic_root(self, i, j): - ... - - def simple_root(self, i): - ... - - def positive_roots(self) -> dict[Any, Any]: - ... - - def roots(self): - ... - - def cartan_matrix(self): - ... - - def basis(self): - ... - - def lie_algebra(self) -> str: - ... - - def dynkin_diagram(self) -> str: - ... - - - + def __new__(cls, n) -> Self: ... + def dimension(self): ... + def basic_root(self, i, j): ... + def simple_root(self, i): ... + def positive_roots(self) -> dict[Any, Any]: ... + def roots(self): ... + def cartan_matrix(self): ... + def basis(self): ... + def lie_algebra(self) -> str: ... + def dynkin_diagram(self) -> str: ... diff --git a/stubs/sympy-stubs/liealgebras/type_c.pyi b/stubs/sympy-stubs/liealgebras/type_c.pyi index 23d55529..a0e8b2af 100644 --- a/stubs/sympy-stubs/liealgebras/type_c.pyi +++ b/stubs/sympy-stubs/liealgebras/type_c.pyi @@ -3,35 +3,13 @@ from typing import Any, Self from sympy.liealgebras.cartan_type import Standard_Cartan class TypeC(Standard_Cartan): - def __new__(cls, n) -> Self: - ... - - def dimension(self): - ... - - def basic_root(self, i, j): - ... - - def simple_root(self, i): - ... - - def positive_roots(self) -> dict[Any, Any]: - ... - - def roots(self): - ... - - def cartan_matrix(self): - ... - - def basis(self): - ... - - def lie_algebra(self) -> str: - ... - - def dynkin_diagram(self) -> str: - ... - - - + def __new__(cls, n) -> Self: ... + def dimension(self): ... + def basic_root(self, i, j): ... + def simple_root(self, i): ... + def positive_roots(self) -> dict[Any, Any]: ... + def roots(self): ... + def cartan_matrix(self): ... + def basis(self): ... + def lie_algebra(self) -> str: ... + def dynkin_diagram(self) -> str: ... diff --git a/stubs/sympy-stubs/liealgebras/type_d.pyi b/stubs/sympy-stubs/liealgebras/type_d.pyi index b6945532..e0c6d2ef 100644 --- a/stubs/sympy-stubs/liealgebras/type_d.pyi +++ b/stubs/sympy-stubs/liealgebras/type_d.pyi @@ -3,35 +3,13 @@ from typing import Any, Self from sympy.liealgebras.cartan_type import Standard_Cartan class TypeD(Standard_Cartan): - def __new__(cls, n) -> Self: - ... - - def dimension(self): - ... - - def basic_root(self, i, j): - ... - - def simple_root(self, i): - ... - - def positive_roots(self) -> dict[Any, Any]: - ... - - def roots(self): - ... - - def cartan_matrix(self): - ... - - def basis(self): - ... - - def lie_algebra(self) -> str: - ... - - def dynkin_diagram(self): - ... - - - + def __new__(cls, n) -> Self: ... + def dimension(self): ... + def basic_root(self, i, j): ... + def simple_root(self, i): ... + def positive_roots(self) -> dict[Any, Any]: ... + def roots(self): ... + def cartan_matrix(self): ... + def basis(self): ... + def lie_algebra(self) -> str: ... + def dynkin_diagram(self): ... diff --git a/stubs/sympy-stubs/liealgebras/type_e.pyi b/stubs/sympy-stubs/liealgebras/type_e.pyi index 25336be7..8f6bde7d 100644 --- a/stubs/sympy-stubs/liealgebras/type_e.pyi +++ b/stubs/sympy-stubs/liealgebras/type_e.pyi @@ -3,32 +3,12 @@ from typing import Any, Literal, Self from sympy.liealgebras.cartan_type import Standard_Cartan class TypeE(Standard_Cartan): - def __new__(cls, n) -> Self: - ... - - def dimension(self) -> Literal[8]: - ... - - def basic_root(self, i, j) -> list[int]: - ... - - def simple_root(self, i) -> list[float] | list[int]: - ... - - def positive_roots(self) -> dict[Any, Any] | None: - ... - - def roots(self) -> Literal[72, 126, 240] | None: - ... - - def cartan_matrix(self): - ... - - def basis(self) -> Literal[78, 133, 248] | None: - ... - - def dynkin_diagram(self) -> str: - ... - - - + def __new__(cls, n) -> Self: ... + def dimension(self) -> Literal[8]: ... + def basic_root(self, i, j) -> list[int]: ... + def simple_root(self, i) -> list[float] | list[int]: ... + def positive_roots(self) -> dict[Any, Any] | None: ... + def roots(self) -> Literal[72, 126, 240] | None: ... + def cartan_matrix(self): ... + def basis(self) -> Literal[78, 133, 248] | None: ... + def dynkin_diagram(self) -> str: ... diff --git a/stubs/sympy-stubs/liealgebras/type_f.pyi b/stubs/sympy-stubs/liealgebras/type_f.pyi index 096e2dea..4a205d02 100644 --- a/stubs/sympy-stubs/liealgebras/type_f.pyi +++ b/stubs/sympy-stubs/liealgebras/type_f.pyi @@ -5,32 +5,12 @@ from sympy.liealgebras.cartan_type import Standard_Cartan from sympy.matrices import Matrix class TypeF(Standard_Cartan): - def __new__(cls, n) -> Self: - ... - - def dimension(self) -> Literal[4]: - ... - - def basic_root(self, i, j): - ... - - def simple_root(self, i) -> list[int] | list[Rational | Any | Integer] | None: - ... - - def positive_roots(self) -> dict[Any, Any]: - ... - - def roots(self) -> Literal[48]: - ... - - def cartan_matrix(self) -> Matrix: - ... - - def basis(self) -> Literal[52]: - ... - - def dynkin_diagram(self) -> str: - ... - - - + def __new__(cls, n) -> Self: ... + def dimension(self) -> Literal[4]: ... + def basic_root(self, i, j): ... + def simple_root(self, i) -> list[int] | list[Rational | Any | Integer] | None: ... + def positive_roots(self) -> dict[Any, Any]: ... + def roots(self) -> Literal[48]: ... + def cartan_matrix(self) -> Matrix: ... + def basis(self) -> Literal[52]: ... + def dynkin_diagram(self) -> str: ... diff --git a/stubs/sympy-stubs/liealgebras/type_g.pyi b/stubs/sympy-stubs/liealgebras/type_g.pyi index 61e01245..0f6cfabe 100644 --- a/stubs/sympy-stubs/liealgebras/type_g.pyi +++ b/stubs/sympy-stubs/liealgebras/type_g.pyi @@ -4,29 +4,11 @@ from sympy.liealgebras.cartan_type import Standard_Cartan from sympy.matrices import Matrix class TypeG(Standard_Cartan): - def __new__(cls, n) -> Self: - ... - - def dimension(self) -> Literal[3]: - ... - - def simple_root(self, i) -> list[int]: - ... - - def positive_roots(self) -> dict[int, list[int]]: - ... - - def roots(self) -> Literal[12]: - ... - - def cartan_matrix(self) -> Matrix: - ... - - def basis(self) -> Literal[14]: - ... - - def dynkin_diagram(self) -> Literal['0≡<≡0\n1 2']: - ... - - - + def __new__(cls, n) -> Self: ... + def dimension(self) -> Literal[3]: ... + def simple_root(self, i) -> list[int]: ... + def positive_roots(self) -> dict[int, list[int]]: ... + def roots(self) -> Literal[12]: ... + def cartan_matrix(self) -> Matrix: ... + def basis(self) -> Literal[14]: ... + def dynkin_diagram(self) -> Literal["0≡<≡0\n1 2"]: ... diff --git a/stubs/sympy-stubs/logic/__init__.pyi b/stubs/sympy-stubs/logic/__init__.pyi index c6ec5394..dbddda2a 100644 --- a/stubs/sympy-stubs/logic/__init__.pyi +++ b/stubs/sympy-stubs/logic/__init__.pyi @@ -21,4 +21,25 @@ from sympy.logic.boolalg import ( ) from sympy.logic.inference import satisfiable -__all__ = ['to_cnf', 'to_dnf', 'to_nnf', 'And', 'Or', 'Not', 'Xor', 'Nand', 'Nor', 'Implies', 'Equivalent', 'ITE', 'POSform', 'SOPform', 'simplify_logic', 'bool_map', 'true', 'false', 'gateinputcount', 'satisfiable'] +__all__ = [ + "to_cnf", + "to_dnf", + "to_nnf", + "And", + "Or", + "Not", + "Xor", + "Nand", + "Nor", + "Implies", + "Equivalent", + "ITE", + "POSform", + "SOPform", + "simplify_logic", + "bool_map", + "true", + "false", + "gateinputcount", + "satisfiable", +] diff --git a/stubs/sympy-stubs/logic/algorithms/dpll.pyi b/stubs/sympy-stubs/logic/algorithms/dpll.pyi index b70edf32..2ba5211a 100644 --- a/stubs/sympy-stubs/logic/algorithms/dpll.pyi +++ b/stubs/sympy-stubs/logic/algorithms/dpll.pyi @@ -1,32 +1,14 @@ from typing import Any, Literal -def dpll_satisfiable(expr) -> dict[Any, Any] | Literal[False]: - ... - -def dpll(clauses, symbols, model) -> Literal[False]: - ... - -def dpll_int_repr(clauses, symbols, model) -> Literal[False]: - ... - -def pl_true_int_repr(clause, model=...) -> bool | None: - ... - -def unit_propagate(clauses, symbol) -> list[Any]: - ... - -def unit_propagate_int_repr(clauses, s) -> list[Any]: - ... - -def find_pure_symbol(symbols, unknown_clauses) -> tuple[Any, bool] | tuple[None, None]: - ... - -def find_pure_symbol_int_repr(symbols, unknown_clauses) -> tuple[Any, Literal[True]] | tuple[Any, Literal[False]] | tuple[None, None]: - ... - -def find_unit_clause(clauses, model) -> tuple[Any | bool, Any | bool] | tuple[None, None]: - ... - -def find_unit_clause_int_repr(clauses, model) -> tuple[Any, Literal[False]] | tuple[Any, Literal[True]] | tuple[None, None]: - ... - +def dpll_satisfiable(expr) -> dict[Any, Any] | Literal[False]: ... +def dpll(clauses, symbols, model) -> Literal[False]: ... +def dpll_int_repr(clauses, symbols, model) -> Literal[False]: ... +def pl_true_int_repr(clause, model=...) -> bool | None: ... +def unit_propagate(clauses, symbol) -> list[Any]: ... +def unit_propagate_int_repr(clauses, s) -> list[Any]: ... +def find_pure_symbol(symbols, unknown_clauses) -> tuple[Any, bool] | tuple[None, None]: ... +def find_pure_symbol_int_repr( + symbols, unknown_clauses +) -> tuple[Any, Literal[True]] | tuple[Any, Literal[False]] | tuple[None, None]: ... +def find_unit_clause(clauses, model) -> tuple[Any | bool, Any | bool] | tuple[None, None]: ... +def find_unit_clause_int_repr(clauses, model) -> tuple[Any, Literal[False]] | tuple[Any, Literal[True]] | tuple[None, None]: ... diff --git a/stubs/sympy-stubs/logic/algorithms/dpll2.pyi b/stubs/sympy-stubs/logic/algorithms/dpll2.pyi index cd80e7fa..86da4429 100644 --- a/stubs/sympy-stubs/logic/algorithms/dpll2.pyi +++ b/stubs/sympy-stubs/logic/algorithms/dpll2.pyi @@ -1,17 +1,13 @@ from typing import Any, Generator, Literal -def dpll_satisfiable(expr, all_models=...) -> Generator[bool, None, None] | Generator[Any | Literal[False], Any, None] | dict[Any, Any] | Literal[False]: - ... +def dpll_satisfiable( + expr, all_models=... +) -> Generator[bool, None, None] | Generator[Any | Literal[False], Any, None] | dict[Any, Any] | Literal[False]: ... class SATSolver: - def __init__(self, clauses, variables, var_settings, symbols=..., heuristic=..., clause_learning=..., INTERVAL=...) -> None: - ... - - + def __init__( + self, clauses, variables, var_settings, symbols=..., heuristic=..., clause_learning=..., INTERVAL=... + ) -> None: ... class Level: - def __init__(self, decision, flipped=...) -> None: - ... - - - + def __init__(self, decision, flipped=...) -> None: ... diff --git a/stubs/sympy-stubs/logic/algorithms/minisat22_wrapper.pyi b/stubs/sympy-stubs/logic/algorithms/minisat22_wrapper.pyi index 9e87433d..d9228ec5 100644 --- a/stubs/sympy-stubs/logic/algorithms/minisat22_wrapper.pyi +++ b/stubs/sympy-stubs/logic/algorithms/minisat22_wrapper.pyi @@ -1,5 +1,7 @@ from typing import Any, Generator, Literal, NoReturn -def minisat22_satisfiable(expr, all_models=..., minimal=...) -> Generator[bool, None, None] | dict[Any, Any] | Generator[dict[Any, Any] | Literal[False], Any, NoReturn] | Literal[False]: - ... - +def minisat22_satisfiable( + expr, all_models=..., minimal=... +) -> ( + Generator[bool, None, None] | dict[Any, Any] | Generator[dict[Any, Any] | Literal[False], Any, NoReturn] | Literal[False] +): ... diff --git a/stubs/sympy-stubs/logic/algorithms/pycosat_wrapper.pyi b/stubs/sympy-stubs/logic/algorithms/pycosat_wrapper.pyi index 17ec16d7..f4cf17f1 100644 --- a/stubs/sympy-stubs/logic/algorithms/pycosat_wrapper.pyi +++ b/stubs/sympy-stubs/logic/algorithms/pycosat_wrapper.pyi @@ -1,5 +1,5 @@ from typing import Any, Generator, Literal -def pycosat_satisfiable(expr, all_models=...) -> Generator[bool, None, None] | dict[Any, Any] | Generator[dict[Any, Any] | Literal[False], Any, None] | Literal[False]: - ... - +def pycosat_satisfiable( + expr, all_models=... +) -> Generator[bool, None, None] | dict[Any, Any] | Generator[dict[Any, Any] | Literal[False], Any, None] | Literal[False]: ... diff --git a/stubs/sympy-stubs/logic/boolalg.pyi b/stubs/sympy-stubs/logic/boolalg.pyi index 8e236fde..17f1b377 100644 --- a/stubs/sympy-stubs/logic/boolalg.pyi +++ b/stubs/sympy-stubs/logic/boolalg.pyi @@ -9,70 +9,46 @@ from sympy.core.relational import Eq, Ne from sympy.core.singleton import Singleton from sympy.core.symbol import Symbol -def as_Boolean(e) -> BooleanTrue | BooleanFalse | Symbol | Boolean: - ... - +def as_Boolean(e) -> BooleanTrue | BooleanFalse | Symbol | Boolean: ... @sympify_method_args class Boolean(Basic): __slots__ = ... kind = ... - @sympify_return([('other', 'Boolean')], NotImplemented) - def __and__(self, other) -> And: - ... - + @sympify_return([("other", "Boolean")], NotImplemented) + def __and__(self, other) -> And: ... + __rand__ = ... - @sympify_return([('other', 'Boolean')], NotImplemented) - def __or__(self, other) -> Or: - ... - + @sympify_return([("other", "Boolean")], NotImplemented) + def __or__(self, other) -> Or: ... + __ror__ = ... - def __invert__(self) -> Not: - ... - - @sympify_return([('other', 'Boolean')], NotImplemented) - def __rshift__(self, other) -> Implies: - ... - - @sympify_return([('other', 'Boolean')], NotImplemented) - def __lshift__(self, other) -> Implies: - ... - + def __invert__(self) -> Not: ... + @sympify_return([("other", "Boolean")], NotImplemented) + def __rshift__(self, other) -> Implies: ... + @sympify_return([("other", "Boolean")], NotImplemented) + def __lshift__(self, other) -> Implies: ... + __rrshift__ = ... __rlshift__ = ... - @sympify_return([('other', 'Boolean')], NotImplemented) - def __xor__(self, other) -> BooleanFalse | Not | Xor: - ... - + @sympify_return([("other", "Boolean")], NotImplemented) + def __xor__(self, other) -> BooleanFalse | Not | Xor: ... + __rxor__ = ... - def equals(self, other) -> bool: - ... - - def to_nnf(self, simplify=...) -> Self: - ... - - def as_set(self): - ... - + def equals(self, other) -> bool: ... + def to_nnf(self, simplify=...) -> Self: ... + def as_set(self): ... @property - def binary_symbols(self) -> set[Any | Basic]: - ... - - + def binary_symbols(self) -> set[Any | Basic]: ... class BooleanAtom(Boolean): is_Boolean = ... is_Atom = ... _op_priority = ... - def simplify(self, *a, **kw) -> Self: - ... - - def expand(self, *a, **kw) -> Self: - ... - + def simplify(self, *a, **kw) -> Self: ... + def expand(self, *a, **kw) -> Self: ... @property - def canonical(self) -> Self: - ... - + def canonical(self) -> Self: ... + __add__ = ... __radd__ = ... __sub__ = ... @@ -86,282 +62,140 @@ class BooleanAtom(Boolean): __mod__ = ... __rmod__ = ... _eval_power = ... - def __lt__(self, other) -> bool: - ... - + def __lt__(self, other) -> bool: ... + __le__ = ... __gt__ = ... __ge__ = ... - class BooleanTrue(BooleanAtom, metaclass=Singleton): - def __bool__(self) -> Literal[True]: - ... - - def __hash__(self) -> int: - ... - - def __eq__(self, other) -> bool: - ... - + def __bool__(self) -> Literal[True]: ... + def __hash__(self) -> int: ... + def __eq__(self, other) -> bool: ... @property - def negated(self) -> BooleanFalse: - ... - - def as_set(self): - ... - - + def negated(self) -> BooleanFalse: ... + def as_set(self): ... class BooleanFalse(BooleanAtom, metaclass=Singleton): - def __bool__(self) -> Literal[False]: - ... - - def __hash__(self) -> int: - ... - - def __eq__(self, other) -> bool: - ... - + def __bool__(self) -> Literal[False]: ... + def __hash__(self) -> int: ... + def __eq__(self, other) -> bool: ... @property - def negated(self) -> BooleanTrue: - ... - - def as_set(self): - ... - - + def negated(self) -> BooleanTrue: ... + def as_set(self): ... true = ... false = ... + class BooleanFunction(Application, Boolean): is_Boolean = ... - def simplify(self, **kwargs): - ... - - def __lt__(self, other) -> bool: - ... - + def simplify(self, **kwargs): ... + def __lt__(self, other) -> bool: ... + __le__ = ... __ge__ = ... __gt__ = ... @classmethod - def binary_check_and_simplify(cls, *args) -> list[Any | BooleanTrue | Basic | BooleanFalse | Symbol | Boolean]: - ... - - def to_nnf(self, simplify=...) -> Self: - ... - - def to_anf(self, deep=...) -> Self: - ... - - def diff(self, *symbols, **assumptions) -> Derivative: - ... - - + def binary_check_and_simplify(cls, *args) -> list[Any | BooleanTrue | Basic | BooleanFalse | Symbol | Boolean]: ... + def to_nnf(self, simplify=...) -> Self: ... + def to_anf(self, deep=...) -> Self: ... + def diff(self, *symbols, **assumptions) -> Derivative: ... class And(LatticeOp, BooleanFunction): zero = ... identity = ... nargs = ... - def to_anf(self, deep=...) -> Self: - ... - - + def to_anf(self, deep=...) -> Self: ... class Or(LatticeOp, BooleanFunction): zero = ... identity = ... - def to_anf(self, deep=...) -> BooleanFalse | Not | Xor: - ... - - + def to_anf(self, deep=...) -> BooleanFalse | Not | Xor: ... class Not(BooleanFunction): is_Not = ... @classmethod - def eval(cls, arg) -> BooleanFalse | BooleanTrue | None: - ... - - def to_nnf(self, simplify=...) -> Self | Or | And: - ... - - def to_anf(self, deep=...) -> Xor: - ... - - + def eval(cls, arg) -> BooleanFalse | BooleanTrue | None: ... + def to_nnf(self, simplify=...) -> Self | Or | And: ... + def to_anf(self, deep=...) -> Xor: ... class Xor(BooleanFunction): - def __new__(cls, *args, remove_true=..., **kwargs) -> BooleanFalse | Not | Self: - ... - + def __new__(cls, *args, remove_true=..., **kwargs) -> BooleanFalse | Not | Self: ... @property @cacheit - def args(self) -> tuple[Any, ...]: - ... - - def to_nnf(self, simplify=...) -> And: - ... - - + def args(self) -> tuple[Any, ...]: ... + def to_nnf(self, simplify=...) -> And: ... class Nand(BooleanFunction): @classmethod - def eval(cls, *args) -> Not: - ... - - + def eval(cls, *args) -> Not: ... class Nor(BooleanFunction): @classmethod - def eval(cls, *args) -> Not: - ... - - + def eval(cls, *args) -> Not: ... class Xnor(BooleanFunction): @classmethod - def eval(cls, *args) -> Not: - ... - - + def eval(cls, *args) -> Not: ... class Implies(BooleanFunction): @classmethod - def eval(cls, *args) -> Or | BooleanTrue | Self | None: - ... - - def to_nnf(self, simplify=...) -> Or: - ... - - def to_anf(self, deep=...) -> Xor: - ... - - + def eval(cls, *args) -> Or | BooleanTrue | Self | None: ... + def to_nnf(self, simplify=...) -> Or: ... + def to_anf(self, deep=...) -> Xor: ... class Equivalent(BooleanFunction): - def __new__(cls, *args, **options) -> BooleanFalse | BooleanTrue | And | Self: - ... - + def __new__(cls, *args, **options) -> BooleanFalse | BooleanTrue | And | Self: ... @property @cacheit - def args(self) -> tuple[Any, ...]: - ... - - def to_nnf(self, simplify=...) -> And: - ... - - def to_anf(self, deep=...) -> Xor: - ... - - + def args(self) -> tuple[Any, ...]: ... + def to_nnf(self, simplify=...) -> And: ... + def to_anf(self, deep=...) -> Xor: ... class ITE(BooleanFunction): - def __new__(cls, *args, **kwargs) -> Self | Not | Basic | Ne | Eq: - ... - + def __new__(cls, *args, **kwargs) -> Self | Not | Basic | Ne | Eq: ... @classmethod - def eval(cls, *args) -> Not | Basic | Ne | Eq | Self | None: - ... - - def to_nnf(self, simplify=...) -> And: - ... - - + def eval(cls, *args) -> Not | Basic | Ne | Eq | Self | None: ... + def to_nnf(self, simplify=...) -> And: ... class Exclusive(BooleanFunction): @classmethod - def eval(cls, *args) -> And: - ... - - - -def conjuncts(expr) -> frozenset[Any]: - ... - -def disjuncts(expr) -> frozenset[Any]: - ... - -def distribute_and_over_or(expr): - ... - -def distribute_or_over_and(expr): - ... - -def distribute_xor_over_and(expr): - ... - -def to_anf(expr, deep=...): - ... - -def to_nnf(expr, simplify=...): - ... - -def to_cnf(expr, simplify=..., force=...) -> BooleanFunction: - ... - -def to_dnf(expr, simplify=..., force=...) -> BooleanFunction: - ... - -def is_anf(expr) -> bool: - ... - -def is_nnf(expr, simplified=...) -> bool: - ... - -def is_cnf(expr) -> bool: - ... - -def is_dnf(expr) -> bool: - ... - -def eliminate_implications(expr): - ... - -def is_literal(expr) -> bool: - ... - -def to_int_repr(clauses, symbols) -> list[set[Any]]: - ... - -def term_to_integer(term) -> int: - ... + def eval(cls, *args) -> And: ... + +def conjuncts(expr) -> frozenset[Any]: ... +def disjuncts(expr) -> frozenset[Any]: ... +def distribute_and_over_or(expr): ... +def distribute_or_over_and(expr): ... +def distribute_xor_over_and(expr): ... +def to_anf(expr, deep=...): ... +def to_nnf(expr, simplify=...): ... +def to_cnf(expr, simplify=..., force=...) -> BooleanFunction: ... +def to_dnf(expr, simplify=..., force=...) -> BooleanFunction: ... +def is_anf(expr) -> bool: ... +def is_nnf(expr, simplified=...) -> bool: ... +def is_cnf(expr) -> bool: ... +def is_dnf(expr) -> bool: ... +def eliminate_implications(expr): ... +def is_literal(expr) -> bool: ... +def to_int_repr(clauses, symbols) -> list[set[Any]]: ... +def term_to_integer(term) -> int: ... integer_to_term = ... -def truth_table(expr, variables, input=...) -> Generator[tuple[list[Literal[0, 1]], Any | BooleanFunction] | Any | BooleanFunction, Any, None]: - ... - -def SOPform(variables, minterms, dontcares=...) -> BooleanFalse | Or: - ... - -def POSform(variables, minterms, dontcares=...) -> BooleanFalse | And: - ... - -def ANFform(variables, truthvalues) -> BooleanFalse | Not | Xor: - ... - -def anf_coeffs(truthvalues) -> list[Any]: - ... - -def bool_minterm(k, variables) -> And: - ... - -def bool_maxterm(k, variables) -> Or: - ... - -def bool_monomial(k, variables) -> BooleanTrue | And: - ... - -def simplify_logic(expr, form=..., deep=..., force=..., dontcare=...): - ... - -def bool_map(bool1, bool2) -> tuple[Any, dict[Any, Any]] | dict[Any, Any] | Literal[False] | None: - ... -def simplify_univariate(expr) -> BooleanFunction | BooleanFalse | Or: - ... +def truth_table( + expr, variables, input=... +) -> Generator[tuple[list[Literal[0, 1]], Any | BooleanFunction] | Any | BooleanFunction, Any, None]: ... +def SOPform(variables, minterms, dontcares=...) -> BooleanFalse | Or: ... +def POSform(variables, minterms, dontcares=...) -> BooleanFalse | And: ... +def ANFform(variables, truthvalues) -> BooleanFalse | Not | Xor: ... +def anf_coeffs(truthvalues) -> list[Any]: ... +def bool_minterm(k, variables) -> And: ... +def bool_maxterm(k, variables) -> Or: ... +def bool_monomial(k, variables) -> BooleanTrue | And: ... +def simplify_logic(expr, form=..., deep=..., force=..., dontcare=...): ... +def bool_map(bool1, bool2) -> tuple[Any, dict[Any, Any]] | dict[Any, Any] | Literal[False] | None: ... +def simplify_univariate(expr) -> BooleanFunction | BooleanFalse | Or: ... BooleanGates = ... -def gateinputcount(expr) -> int: - ... +def gateinputcount(expr) -> int: ... diff --git a/stubs/sympy-stubs/logic/inference.pyi b/stubs/sympy-stubs/logic/inference.pyi index 789c7c65..70cb6a87 100644 --- a/stubs/sympy-stubs/logic/inference.pyi +++ b/stubs/sympy-stubs/logic/inference.pyi @@ -1,48 +1,29 @@ from typing import Any, Generator, Literal, NoReturn -def literal_symbol(literal) -> bool: - ... - -def satisfiable(expr, algorithm=..., all_models=..., minimal=...) -> dict[Any, Any] | Generator[bool, None, None] | Generator[Any | Literal[False], Any, None] | Generator[dict[Any, Any] | Literal[False], Any, None] | Generator[dict[Any, Any] | Literal[False], Any, NoReturn] | Literal[False]: - ... - -def valid(expr) -> bool: - ... - -def pl_true(expr, model=..., deep=...) -> bool | None: - ... - -def entails(expr, formula_set=...) -> bool: - ... +def literal_symbol(literal) -> bool: ... +def satisfiable( + expr, algorithm=..., all_models=..., minimal=... +) -> ( + dict[Any, Any] + | Generator[bool, None, None] + | Generator[Any | Literal[False], Any, None] + | Generator[dict[Any, Any] | Literal[False], Any, None] + | Generator[dict[Any, Any] | Literal[False], Any, NoReturn] + | Literal[False] +): ... +def valid(expr) -> bool: ... +def pl_true(expr, model=..., deep=...) -> bool | None: ... +def entails(expr, formula_set=...) -> bool: ... class KB: - def __init__(self, sentence=...) -> None: - ... - - def tell(self, sentence): - ... - - def ask(self, query): - ... - - def retract(self, sentence): - ... - + def __init__(self, sentence=...) -> None: ... + def tell(self, sentence): ... + def ask(self, query): ... + def retract(self, sentence): ... @property - def clauses(self) -> list[Any]: - ... - - + def clauses(self) -> list[Any]: ... class PropKB(KB): - def tell(self, sentence) -> None: - ... - - def ask(self, query) -> bool: - ... - - def retract(self, sentence) -> None: - ... - - - + def tell(self, sentence) -> None: ... + def ask(self, query) -> bool: ... + def retract(self, sentence) -> None: ... diff --git a/stubs/sympy-stubs/matrices/__init__.pyi b/stubs/sympy-stubs/matrices/__init__.pyi index 0623ce4f..609d9421 100644 --- a/stubs/sympy-stubs/matrices/__init__.pyi +++ b/stubs/sympy-stubs/matrices/__init__.pyi @@ -72,4 +72,78 @@ MutableMatrix = MutableDenseMatrix Matrix = MutableMatrix ImmutableMatrix = ImmutableDenseMatrix SparseMatrix = MutableSparseMatrix -__all__ = ['ShapeError', 'NonSquareMatrixError', 'MatrixKind', 'GramSchmidt', 'casoratian', 'diag', 'eye', 'hessian', 'jordan_cell', 'list2numpy', 'matrix2numpy', 'matrix_multiply_elementwise', 'ones', 'randMatrix', 'rot_axis1', 'rot_axis2', 'rot_axis3', 'symarray', 'wronskian', 'zeros', 'rot_ccw_axis1', 'rot_ccw_axis2', 'rot_ccw_axis3', 'rot_givens', 'MutableDenseMatrix', 'DeferredVector', 'MatrixBase', 'Matrix', 'MutableMatrix', 'MutableSparseMatrix', 'banded', 'ImmutableDenseMatrix', 'ImmutableSparseMatrix', 'ImmutableMatrix', 'SparseMatrix', 'MatrixSlice', 'BlockDiagMatrix', 'BlockMatrix', 'FunctionMatrix', 'Identity', 'Inverse', 'MatAdd', 'MatMul', 'MatPow', 'MatrixExpr', 'MatrixSymbol', 'Trace', 'Transpose', 'ZeroMatrix', 'OneMatrix', 'blockcut', 'block_collapse', 'matrix_symbols', 'Adjoint', 'hadamard_product', 'HadamardProduct', 'HadamardPower', 'Determinant', 'det', 'diagonalize_vector', 'DiagMatrix', 'DiagonalMatrix', 'DiagonalOf', 'trace', 'DotProduct', 'kronecker_product', 'KroneckerProduct', 'PermutationMatrix', 'MatrixPermute', 'MatrixSet', 'Permanent', 'per', 'dotprodsimp'] +__all__ = [ + "ShapeError", + "NonSquareMatrixError", + "MatrixKind", + "GramSchmidt", + "casoratian", + "diag", + "eye", + "hessian", + "jordan_cell", + "list2numpy", + "matrix2numpy", + "matrix_multiply_elementwise", + "ones", + "randMatrix", + "rot_axis1", + "rot_axis2", + "rot_axis3", + "symarray", + "wronskian", + "zeros", + "rot_ccw_axis1", + "rot_ccw_axis2", + "rot_ccw_axis3", + "rot_givens", + "MutableDenseMatrix", + "DeferredVector", + "MatrixBase", + "Matrix", + "MutableMatrix", + "MutableSparseMatrix", + "banded", + "ImmutableDenseMatrix", + "ImmutableSparseMatrix", + "ImmutableMatrix", + "SparseMatrix", + "MatrixSlice", + "BlockDiagMatrix", + "BlockMatrix", + "FunctionMatrix", + "Identity", + "Inverse", + "MatAdd", + "MatMul", + "MatPow", + "MatrixExpr", + "MatrixSymbol", + "Trace", + "Transpose", + "ZeroMatrix", + "OneMatrix", + "blockcut", + "block_collapse", + "matrix_symbols", + "Adjoint", + "hadamard_product", + "HadamardProduct", + "HadamardPower", + "Determinant", + "det", + "diagonalize_vector", + "DiagMatrix", + "DiagonalMatrix", + "DiagonalOf", + "trace", + "DotProduct", + "kronecker_product", + "KroneckerProduct", + "PermutationMatrix", + "MatrixPermute", + "MatrixSet", + "Permanent", + "per", + "dotprodsimp", +] diff --git a/stubs/sympy-stubs/matrices/dense.pyi b/stubs/sympy-stubs/matrices/dense.pyi index eee4d7ea..5162e0d5 100644 --- a/stubs/sympy-stubs/matrices/dense.pyi +++ b/stubs/sympy-stubs/matrices/dense.pyi @@ -11,94 +11,37 @@ class DenseMatrix(RepMatrix): is_MatrixExpr: bool = ... _op_priority = ... _class_priority = ... - def as_immutable(self) -> ImmutableDenseMatrix: - ... - - def as_mutable(self) -> Matrix: - ... - - def cholesky(self, hermitian=...): - ... - - def LDLdecomposition(self, hermitian=...) -> tuple[Any, Any]: - ... - - def lower_triangular_solve(self, rhs): - ... - - def upper_triangular_solve(self, rhs): - ... - - + def as_immutable(self) -> ImmutableDenseMatrix: ... + def as_mutable(self) -> Matrix: ... + def cholesky(self, hermitian=...): ... + def LDLdecomposition(self, hermitian=...) -> tuple[Any, Any]: ... + def lower_triangular_solve(self, rhs): ... + def upper_triangular_solve(self, rhs): ... class MutableDenseMatrix(DenseMatrix, MutableRepMatrix): - def simplify(self, **kwargs) -> None: - ... - - + def simplify(self, **kwargs) -> None: ... Matrix = MutableMatrix = MutableDenseMatrix -def list2numpy(l, dtype=...) -> NDArray[Any, Any]: - ... - -def matrix2numpy(m, dtype=...) -> NDArray[Any, Any]: - ... - -def rot_givens(i, j, theta, dim=...): - ... - -def rot_axis3(theta): - ... - -def rot_axis2(theta): - ... - -def rot_axis1(theta): - ... - -def rot_ccw_axis3(theta): - ... - -def rot_ccw_axis2(theta): - ... - -def rot_ccw_axis1(theta): - ... - -@doctest_depends_on(modules=('numpy', )) -def symarray(prefix, shape, **kwargs) -> NDArray[Any, Any]: - ... - -def casoratian(seqs, n, zero=...) -> tuple[Any | Basic, bool] | Any | Basic | Order: - ... - -def eye(*args, **kwargs): - ... - -def diag(*values, strict=..., unpack=..., **kwargs): - ... - -def GramSchmidt(vlist, orthonormal=...) -> list[Any]: - ... - -def hessian(f, varlist, constraints=...): - ... - -def jordan_cell(eigenval, n): - ... - -def matrix_multiply_elementwise(A, B): - ... - -def ones(*args, **kwargs): - ... - -def randMatrix(r, c=..., min=..., max=..., seed=..., symmetric=..., percent=..., prng=...): - ... - -def wronskian(functions, var, method=...) -> tuple[Any | Basic, bool] | Any | Basic | Order: - ... - -def zeros(*args, **kwargs): - ... +def list2numpy(l, dtype=...) -> NDArray[Any, Any]: ... +def matrix2numpy(m, dtype=...) -> NDArray[Any, Any]: ... +def rot_givens(i, j, theta, dim=...): ... +def rot_axis3(theta): ... +def rot_axis2(theta): ... +def rot_axis1(theta): ... +def rot_ccw_axis3(theta): ... +def rot_ccw_axis2(theta): ... +def rot_ccw_axis1(theta): ... +@doctest_depends_on(modules=("numpy",)) +def symarray(prefix, shape, **kwargs) -> NDArray[Any, Any]: ... +def casoratian(seqs, n, zero=...) -> tuple[Any | Basic, bool] | Any | Basic | Order: ... +def eye(*args, **kwargs): ... +def diag(*values, strict=..., unpack=..., **kwargs): ... +def GramSchmidt(vlist, orthonormal=...) -> list[Any]: ... +def hessian(f, varlist, constraints=...): ... +def jordan_cell(eigenval, n): ... +def matrix_multiply_elementwise(A, B): ... +def ones(*args, **kwargs): ... +def randMatrix(r, c=..., min=..., max=..., seed=..., symmetric=..., percent=..., prng=...): ... +def wronskian(functions, var, method=...) -> tuple[Any | Basic, bool] | Any | Basic | Order: ... +def zeros(*args, **kwargs): ... diff --git a/stubs/sympy-stubs/matrices/expressions/__init__.pyi b/stubs/sympy-stubs/matrices/expressions/__init__.pyi index 6aee8758..1347f0ef 100644 --- a/stubs/sympy-stubs/matrices/expressions/__init__.pyi +++ b/stubs/sympy-stubs/matrices/expressions/__init__.pyi @@ -19,4 +19,45 @@ from sympy.matrices.expressions.special import Identity, OneMatrix, ZeroMatrix from sympy.matrices.expressions.trace import Trace, trace from sympy.matrices.expressions.transpose import Transpose -__all__ = ['MatrixSlice', 'BlockMatrix', 'BlockDiagMatrix', 'block_collapse', 'blockcut', 'FunctionMatrix', 'CompanionMatrix', 'Inverse', 'MatAdd', 'Identity', 'MatrixExpr', 'MatrixSymbol', 'ZeroMatrix', 'OneMatrix', 'matrix_symbols', 'MatrixSet', 'MatMul', 'MatPow', 'Trace', 'trace', 'Determinant', 'det', 'Transpose', 'Adjoint', 'hadamard_product', 'HadamardProduct', 'hadamard_power', 'HadamardPower', 'DiagonalMatrix', 'DiagonalOf', 'DiagMatrix', 'diagonalize_vector', 'DotProduct', 'kronecker_product', 'KroneckerProduct', 'combine_kronecker', 'PermutationMatrix', 'MatrixPermute', 'Permanent', 'per'] +__all__ = [ + "MatrixSlice", + "BlockMatrix", + "BlockDiagMatrix", + "block_collapse", + "blockcut", + "FunctionMatrix", + "CompanionMatrix", + "Inverse", + "MatAdd", + "Identity", + "MatrixExpr", + "MatrixSymbol", + "ZeroMatrix", + "OneMatrix", + "matrix_symbols", + "MatrixSet", + "MatMul", + "MatPow", + "Trace", + "trace", + "Determinant", + "det", + "Transpose", + "Adjoint", + "hadamard_product", + "HadamardProduct", + "hadamard_power", + "HadamardPower", + "DiagonalMatrix", + "DiagonalOf", + "DiagMatrix", + "diagonalize_vector", + "DotProduct", + "kronecker_product", + "KroneckerProduct", + "combine_kronecker", + "PermutationMatrix", + "MatrixPermute", + "Permanent", + "per", +] diff --git a/stubs/sympy-stubs/matrices/expressions/adjoint.pyi b/stubs/sympy-stubs/matrices/expressions/adjoint.pyi index 4fc903ea..4aa68a9f 100644 --- a/stubs/sympy-stubs/matrices/expressions/adjoint.pyi +++ b/stubs/sympy-stubs/matrices/expressions/adjoint.pyi @@ -4,16 +4,8 @@ from sympy.matrices.expressions.matexpr import MatrixExpr class Adjoint(MatrixExpr): is_Adjoint = ... - def doit(self, **hints) -> type[UndefinedFunction]: - ... - + def doit(self, **hints) -> type[UndefinedFunction]: ... @property - def arg(self) -> Basic: - ... - + def arg(self) -> Basic: ... @property - def shape(self): - ... - - - + def shape(self): ... diff --git a/stubs/sympy-stubs/matrices/expressions/applyfunc.pyi b/stubs/sympy-stubs/matrices/expressions/applyfunc.pyi index 1d184c03..f86f4a84 100644 --- a/stubs/sympy-stubs/matrices/expressions/applyfunc.pyi +++ b/stubs/sympy-stubs/matrices/expressions/applyfunc.pyi @@ -4,23 +4,11 @@ from sympy.core.basic import Basic from sympy.matrices.expressions import MatrixExpr class ElementwiseApplyFunction(MatrixExpr): - def __new__(cls, function, expr) -> MatrixExpr | Self: - ... - + def __new__(cls, function, expr) -> MatrixExpr | Self: ... @property - def function(self) -> Basic: - ... - + def function(self) -> Basic: ... @property - def expr(self) -> Basic: - ... - + def expr(self) -> Basic: ... @property - def shape(self): - ... - - def doit(self, **hints) -> Basic | Self: - ... - - - + def shape(self): ... + def doit(self, **hints) -> Basic | Self: ... diff --git a/stubs/sympy-stubs/matrices/expressions/blockmatrix.pyi b/stubs/sympy-stubs/matrices/expressions/blockmatrix.pyi index 64770ce6..2561a2d6 100644 --- a/stubs/sympy-stubs/matrices/expressions/blockmatrix.pyi +++ b/stubs/sympy-stubs/matrices/expressions/blockmatrix.pyi @@ -9,132 +9,56 @@ from sympy.matrices.immutable import ImmutableDenseMatrix from sympy.series.order import Order class BlockMatrix(MatrixExpr): - def __new__(cls, *args, **kwargs) -> Self: - ... - + def __new__(cls, *args, **kwargs) -> Self: ... @property - def shape(self) -> tuple[Any | Literal[0], Any | Literal[0]]: - ... - + def shape(self) -> tuple[Any | Literal[0], Any | Literal[0]]: ... @property - def blockshape(self): - ... - + def blockshape(self): ... @property - def blocks(self) -> Basic: - ... - + def blocks(self) -> Basic: ... @property - def rowblocksizes(self) -> list[Any]: - ... - + def rowblocksizes(self) -> list[Any]: ... @property - def colblocksizes(self) -> list[Any]: - ... - - def structurally_equal(self, other) -> bool: - ... - - def transpose(self) -> BlockMatrix: - ... - - def schur(self, mat=..., generalized=...) -> Self: - ... - - def LDUdecomposition(self) -> tuple[BlockMatrix, BlockDiagMatrix, BlockMatrix]: - ... - - def UDLdecomposition(self) -> tuple[BlockMatrix, BlockDiagMatrix, BlockMatrix]: - ... - - def LUdecomposition(self) -> tuple[BlockMatrix, BlockMatrix]: - ... - + def colblocksizes(self) -> list[Any]: ... + def structurally_equal(self, other) -> bool: ... + def transpose(self) -> BlockMatrix: ... + def schur(self, mat=..., generalized=...) -> Self: ... + def LDUdecomposition(self) -> tuple[BlockMatrix, BlockDiagMatrix, BlockMatrix]: ... + def UDLdecomposition(self) -> tuple[BlockMatrix, BlockDiagMatrix, BlockMatrix]: ... + def LUdecomposition(self) -> tuple[BlockMatrix, BlockMatrix]: ... @property - def is_Identity(self) -> bool: - ... - + def is_Identity(self) -> bool: ... @property - def is_structurally_symmetric(self) -> bool: - ... - - def equals(self, other) -> bool: - ... - - + def is_structurally_symmetric(self) -> bool: ... + def equals(self, other) -> bool: ... class BlockDiagMatrix(BlockMatrix): - def __new__(cls, *mats) -> BlockDiagMatrix: - ... - + def __new__(cls, *mats) -> BlockDiagMatrix: ... @property - def diag(self) -> tuple[Basic, ...]: - ... - + def diag(self) -> tuple[Basic, ...]: ... @property - def blocks(self) -> ImmutableDenseMatrix: - ... - + def blocks(self) -> ImmutableDenseMatrix: ... @property - def shape(self) -> tuple[int, int]: - ... - + def shape(self) -> tuple[int, int]: ... @property - def blockshape(self) -> tuple[int, int]: - ... - + def blockshape(self) -> tuple[int, int]: ... @property - def rowblocksizes(self) -> list[Any]: - ... - + def rowblocksizes(self) -> list[Any]: ... @property - def colblocksizes(self) -> list[Any]: - ... - - def get_diag_blocks(self) -> tuple[Basic, ...]: - ... - - - -def block_collapse(expr) -> Any: - ... - -def bc_unpack(expr): - ... - -def bc_matadd(expr): - ... - -def bc_block_plus_ident(expr) -> MatAdd | GenericZeroMatrix: - ... - -def bc_dist(expr) -> BlockDiagMatrix | BlockMatrix: - ... - -def bc_matmul(expr) -> MatPow | GenericIdentity | Order | object: - ... - -def bc_transpose(expr) -> Any: - ... - -def bc_inverse(expr) -> BlockMatrix: - ... - -def blockinverse_1x1(expr) -> BlockMatrix: - ... - -def blockinverse_2x2(expr) -> BlockMatrix: - ... - -def deblock(B) -> BlockMatrix: - ... - -def reblock_2x2(expr) -> BlockMatrix: - ... - -def bounds(sizes) -> list[Any]: - ... - -def blockcut(expr, rowsizes, colsizes) -> BlockMatrix: - ... - + def colblocksizes(self) -> list[Any]: ... + def get_diag_blocks(self) -> tuple[Basic, ...]: ... + +def block_collapse(expr) -> Any: ... +def bc_unpack(expr): ... +def bc_matadd(expr): ... +def bc_block_plus_ident(expr) -> MatAdd | GenericZeroMatrix: ... +def bc_dist(expr) -> BlockDiagMatrix | BlockMatrix: ... +def bc_matmul(expr) -> MatPow | GenericIdentity | Order | object: ... +def bc_transpose(expr) -> Any: ... +def bc_inverse(expr) -> BlockMatrix: ... +def blockinverse_1x1(expr) -> BlockMatrix: ... +def blockinverse_2x2(expr) -> BlockMatrix: ... +def deblock(B) -> BlockMatrix: ... +def reblock_2x2(expr) -> BlockMatrix: ... +def bounds(sizes) -> list[Any]: ... +def blockcut(expr, rowsizes, colsizes) -> BlockMatrix: ... diff --git a/stubs/sympy-stubs/matrices/expressions/companion.pyi b/stubs/sympy-stubs/matrices/expressions/companion.pyi index e2322935..f0081f63 100644 --- a/stubs/sympy-stubs/matrices/expressions/companion.pyi +++ b/stubs/sympy-stubs/matrices/expressions/companion.pyi @@ -3,15 +3,7 @@ from typing import Any, Self from sympy.matrices.expressions.matexpr import MatrixExpr class CompanionMatrix(MatrixExpr): - def __new__(cls, poly) -> Self: - ... - + def __new__(cls, poly) -> Self: ... @property - def shape(self) -> tuple[Any, Any]: - ... - - def as_explicit(self): - ... - - - + def shape(self) -> tuple[Any, Any]: ... + def as_explicit(self): ... diff --git a/stubs/sympy-stubs/matrices/expressions/determinant.pyi b/stubs/sympy-stubs/matrices/expressions/determinant.pyi index 91bf94a6..fb233a5e 100644 --- a/stubs/sympy-stubs/matrices/expressions/determinant.pyi +++ b/stubs/sympy-stubs/matrices/expressions/determinant.pyi @@ -5,41 +5,20 @@ from sympy.core.expr import Expr class Determinant(Expr): is_commutative = ... - def __new__(cls, mat) -> Self: - ... - + def __new__(cls, mat) -> Self: ... @property - def arg(self) -> Basic: - ... - + def arg(self) -> Basic: ... @property - def kind(self): - ... - - def doit(self, expand=..., **hints) -> Self: - ... - + def kind(self): ... + def doit(self, expand=..., **hints) -> Self: ... - -def det(matexpr) -> Determinant: - ... +def det(matexpr) -> Determinant: ... class Permanent(Expr): - def __new__(cls, mat) -> Self: - ... - + def __new__(cls, mat) -> Self: ... @property - def arg(self) -> Basic: - ... - - def doit(self, expand=..., **hints) -> Self: - ... - - - -def per(matexpr) -> Permanent: - ... - -def refine_Determinant(expr, assumptions): - ... + def arg(self) -> Basic: ... + def doit(self, expand=..., **hints) -> Self: ... +def per(matexpr) -> Permanent: ... +def refine_Determinant(expr, assumptions): ... diff --git a/stubs/sympy-stubs/matrices/expressions/diagonal.pyi b/stubs/sympy-stubs/matrices/expressions/diagonal.pyi index 44129d89..6135b790 100644 --- a/stubs/sympy-stubs/matrices/expressions/diagonal.pyi +++ b/stubs/sympy-stubs/matrices/expressions/diagonal.pyi @@ -8,39 +8,20 @@ class DiagonalMatrix(MatrixExpr): arg = ... shape = ... @property - def diagonal_length(self) -> Expr | None: - ... - - + def diagonal_length(self) -> Expr | None: ... class DiagonalOf(MatrixExpr): arg = ... @property - def shape(self) -> tuple[Any | None, Any]: - ... - + def shape(self) -> tuple[Any | None, Any]: ... @property - def diagonal_length(self) -> Any | None: - ... - - + def diagonal_length(self) -> Any | None: ... class DiagMatrix(MatrixExpr): - def __new__(cls, vector) -> Self: - ... - + def __new__(cls, vector) -> Self: ... @property - def shape(self): - ... - - def as_explicit(self): - ... - - def doit(self, **hints) -> MatrixBase | DiagMatrix: - ... - - - -def diagonalize_vector(vector) -> MatrixBase | DiagMatrix: - ... + def shape(self): ... + def as_explicit(self): ... + def doit(self, **hints) -> MatrixBase | DiagMatrix: ... +def diagonalize_vector(vector) -> MatrixBase | DiagMatrix: ... diff --git a/stubs/sympy-stubs/matrices/expressions/dotproduct.pyi b/stubs/sympy-stubs/matrices/expressions/dotproduct.pyi index 51647401..3b4f67e0 100644 --- a/stubs/sympy-stubs/matrices/expressions/dotproduct.pyi +++ b/stubs/sympy-stubs/matrices/expressions/dotproduct.pyi @@ -4,11 +4,5 @@ from sympy.core import Expr from sympy.matrices.expressions.slice import MatrixSlice class DotProduct(Expr): - def __new__(cls, arg1, arg2) -> Self: - ... - - def doit(self, expand=..., **hints) -> Any | MatrixSlice: - ... - - - + def __new__(cls, arg1, arg2) -> Self: ... + def doit(self, expand=..., **hints) -> Any | MatrixSlice: ... diff --git a/stubs/sympy-stubs/matrices/expressions/factorizations.pyi b/stubs/sympy-stubs/matrices/expressions/factorizations.pyi index d29555d6..0469de80 100644 --- a/stubs/sympy-stubs/matrices/expressions/factorizations.pyi +++ b/stubs/sympy-stubs/matrices/expressions/factorizations.pyi @@ -6,87 +6,46 @@ class Factorization(MatrixExpr): arg = ... shape = ... - class LofLU(Factorization): @property - def predicates(self) -> tuple[Any]: - ... - - + def predicates(self) -> tuple[Any]: ... class UofLU(Factorization): @property - def predicates(self) -> tuple[Any]: - ... - - - -class LofCholesky(LofLU): - ... - - -class UofCholesky(UofLU): - ... + def predicates(self) -> tuple[Any]: ... +class LofCholesky(LofLU): ... +class UofCholesky(UofLU): ... class QofQR(Factorization): @property - def predicates(self) -> tuple[Any]: - ... - - + def predicates(self) -> tuple[Any]: ... class RofQR(Factorization): @property - def predicates(self) -> tuple[Any]: - ... - - + def predicates(self) -> tuple[Any]: ... class EigenVectors(Factorization): @property - def predicates(self) -> tuple[Any]: - ... - - + def predicates(self) -> tuple[Any]: ... class EigenValues(Factorization): @property - def predicates(self) -> tuple[Any]: - ... - - + def predicates(self) -> tuple[Any]: ... class UofSVD(Factorization): @property - def predicates(self) -> tuple[Any]: - ... - - + def predicates(self) -> tuple[Any]: ... class SofSVD(Factorization): @property - def predicates(self) -> tuple[Any]: - ... - - + def predicates(self) -> tuple[Any]: ... class VofSVD(Factorization): @property - def predicates(self) -> tuple[Any]: - ... - - - -def lu(expr) -> tuple[LofLU, UofLU]: - ... - -def qr(expr) -> tuple[QofQR, RofQR]: - ... - -def eig(expr) -> tuple[EigenValues, EigenVectors]: - ... - -def svd(expr) -> tuple[UofSVD, SofSVD, VofSVD]: - ... + def predicates(self) -> tuple[Any]: ... +def lu(expr) -> tuple[LofLU, UofLU]: ... +def qr(expr) -> tuple[QofQR, RofQR]: ... +def eig(expr) -> tuple[EigenValues, EigenVectors]: ... +def svd(expr) -> tuple[UofSVD, SofSVD, VofSVD]: ... diff --git a/stubs/sympy-stubs/matrices/expressions/fourier.pyi b/stubs/sympy-stubs/matrices/expressions/fourier.pyi index ecbfc5ed..24b0dfa5 100644 --- a/stubs/sympy-stubs/matrices/expressions/fourier.pyi +++ b/stubs/sympy-stubs/matrices/expressions/fourier.pyi @@ -3,14 +3,9 @@ from typing import Self from sympy.matrices.expressions import MatrixExpr class DFT(MatrixExpr): - def __new__(cls, n) -> Self: - ... - + def __new__(cls, n) -> Self: ... + n = ... shape = ... - -class IDFT(DFT): - ... - - +class IDFT(DFT): ... diff --git a/stubs/sympy-stubs/matrices/expressions/funcmatrix.pyi b/stubs/sympy-stubs/matrices/expressions/funcmatrix.pyi index 39f826dd..f232d50f 100644 --- a/stubs/sympy-stubs/matrices/expressions/funcmatrix.pyi +++ b/stubs/sympy-stubs/matrices/expressions/funcmatrix.pyi @@ -4,16 +4,8 @@ from sympy.core.basic import Basic from sympy.matrices.expressions.matexpr import MatrixExpr class FunctionMatrix(MatrixExpr): - def __new__(cls, rows, cols, lamda) -> Self: - ... - + def __new__(cls, rows, cols, lamda) -> Self: ... @property - def shape(self) -> tuple[Basic, ...]: - ... - + def shape(self) -> tuple[Basic, ...]: ... @property - def lamda(self) -> Basic: - ... - - - + def lamda(self) -> Basic: ... diff --git a/stubs/sympy-stubs/matrices/expressions/hadamard.pyi b/stubs/sympy-stubs/matrices/expressions/hadamard.pyi index e2d00380..be2843b2 100644 --- a/stubs/sympy-stubs/matrices/expressions/hadamard.pyi +++ b/stubs/sympy-stubs/matrices/expressions/hadamard.pyi @@ -3,44 +3,23 @@ from typing import Self from sympy.core.basic import Basic from sympy.matrices.expressions.matexpr import MatrixExpr -def hadamard_product(*matrices): - ... +def hadamard_product(*matrices): ... class HadamardProduct(MatrixExpr): is_HadamardProduct = ... - def __new__(cls, *args, evaluate=..., check=...) -> Self: - ... - + def __new__(cls, *args, evaluate=..., check=...) -> Self: ... @property - def shape(self): - ... - - def doit(self, **hints): - ... - + def shape(self): ... + def doit(self, **hints): ... - -def canonicalize(x): - ... - -def hadamard_power(base, exp) -> HadamardPower: - ... +def canonicalize(x): ... +def hadamard_power(base, exp) -> HadamardPower: ... class HadamardPower(MatrixExpr): - def __new__(cls, base, exp) -> Self: - ... - + def __new__(cls, base, exp) -> Self: ... @property - def base(self) -> Basic: - ... - + def base(self) -> Basic: ... @property - def exp(self) -> Basic: - ... - + def exp(self) -> Basic: ... @property - def shape(self): - ... - - - + def shape(self): ... diff --git a/stubs/sympy-stubs/matrices/expressions/inverse.pyi b/stubs/sympy-stubs/matrices/expressions/inverse.pyi index 735fa246..5d033eda 100644 --- a/stubs/sympy-stubs/matrices/expressions/inverse.pyi +++ b/stubs/sympy-stubs/matrices/expressions/inverse.pyi @@ -6,22 +6,11 @@ from sympy.matrices.expressions.matpow import MatPow class Inverse(MatPow): is_Inverse = ... exp = ... - def __new__(cls, mat, exp=...) -> Self: - ... - + def __new__(cls, mat, exp=...) -> Self: ... @property - def arg(self) -> Basic: - ... - + def arg(self) -> Basic: ... @property - def shape(self): - ... - - def doit(self, **hints) -> Self: - ... - - - -def refine_Inverse(expr, assumptions): - ... + def shape(self): ... + def doit(self, **hints) -> Self: ... +def refine_Inverse(expr, assumptions): ... diff --git a/stubs/sympy-stubs/matrices/expressions/kronecker.pyi b/stubs/sympy-stubs/matrices/expressions/kronecker.pyi index 48057cec..5fe9715e 100644 --- a/stubs/sympy-stubs/matrices/expressions/kronecker.pyi +++ b/stubs/sympy-stubs/matrices/expressions/kronecker.pyi @@ -7,52 +7,26 @@ from sympy.matrices.expressions.special import GenericIdentity, GenericZeroMatri from sympy.matrices.immutable import ImmutableDenseMatrix from sympy.series.order import Order -def kronecker_product(*matrices) -> NotImplementedType | GenericIdentity | Order | object | Identity: - ... +def kronecker_product(*matrices) -> NotImplementedType | GenericIdentity | Order | object | Identity: ... class KroneckerProduct(MatrixExpr): is_KroneckerProduct = ... - def __new__(cls, *args, check=...) -> ImmutableDenseMatrix | Identity | Self: - ... - + def __new__(cls, *args, check=...) -> ImmutableDenseMatrix | Identity | Self: ... @property - def shape(self) -> tuple[Any, Any]: - ... - - def structurally_equal(self, other) -> bool: - ... - - def has_matching_shape(self, other) -> bool | NotImplementedType: - ... - - def doit(self, **hints) -> NotImplementedType | GenericIdentity | Order | object: - ... - + def shape(self) -> tuple[Any, Any]: ... + def structurally_equal(self, other) -> bool: ... + def has_matching_shape(self, other) -> bool | NotImplementedType: ... + def doit(self, **hints) -> NotImplementedType | GenericIdentity | Order | object: ... - -def validate(*args) -> None: - ... - -def extract_commutative(kron) -> NotImplementedType | GenericIdentity | Order | object: - ... - -def matrix_kronecker_product(*matrices): - ... - -def explicit_kronecker_product(kron): - ... +def validate(*args) -> None: ... +def extract_commutative(kron) -> NotImplementedType | GenericIdentity | Order | object: ... +def matrix_kronecker_product(*matrices): ... +def explicit_kronecker_product(kron): ... rules = ... canonicalize = ... -def kronecker_mat_add(expr) -> GenericZeroMatrix | MatAdd: - ... - -def kronecker_mat_mul(expr): - ... - -def kronecker_mat_pow(expr) -> ImmutableDenseMatrix | Identity | KroneckerProduct: - ... - -def combine_kronecker(expr) -> Any: - ... +def kronecker_mat_add(expr) -> GenericZeroMatrix | MatAdd: ... +def kronecker_mat_mul(expr): ... +def kronecker_mat_pow(expr) -> ImmutableDenseMatrix | Identity | KroneckerProduct: ... +def combine_kronecker(expr) -> Any: ... diff --git a/stubs/sympy-stubs/matrices/expressions/matadd.pyi b/stubs/sympy-stubs/matrices/expressions/matadd.pyi index c715e86f..54e65293 100644 --- a/stubs/sympy-stubs/matrices/expressions/matadd.pyi +++ b/stubs/sympy-stubs/matrices/expressions/matadd.pyi @@ -7,31 +7,18 @@ from sympy.matrices.expressions.special import GenericZeroMatrix class MatAdd(MatrixExpr, Add): is_MatAdd = ... identity = ... - def __new__(cls, *args, evaluate=..., check=..., _sympify=...) -> GenericZeroMatrix | MatAdd | Self: - ... - + def __new__(cls, *args, evaluate=..., check=..., _sympify=...) -> GenericZeroMatrix | MatAdd | Self: ... @property - def shape(self): - ... - - def could_extract_minus_sign(self) -> bool: - ... - - def expand(self, **kwargs) -> MatAdd: - ... - - def doit(self, **hints) -> MatAdd: - ... - - + def shape(self): ... + def could_extract_minus_sign(self) -> bool: ... + def expand(self, **kwargs) -> MatAdd: ... + def doit(self, **hints) -> MatAdd: ... factor_of = ... matrix_of = ... -def combine(cnt, mat): - ... -def merge_explicit(matadd) -> MatAdd: - ... +def combine(cnt, mat): ... +def merge_explicit(matadd) -> MatAdd: ... rules = ... canonicalize = ... diff --git a/stubs/sympy-stubs/matrices/expressions/matexpr.pyi b/stubs/sympy-stubs/matrices/expressions/matexpr.pyi index fc613527..6e861923 100644 --- a/stubs/sympy-stubs/matrices/expressions/matexpr.pyi +++ b/stubs/sympy-stubs/matrices/expressions/matexpr.pyi @@ -36,158 +36,78 @@ class MatrixExpr(Expr): is_symbol = ... is_scalar = ... kind: MatrixKind = ... - def __new__(cls, *args, **kwargs) -> Self: - ... - + def __new__(cls, *args, **kwargs) -> Self: ... @property - def shape(self) -> tuple[Expr, Expr]: - ... - - def __neg__(self) -> GenericIdentity | Order | object: - ... - - def __abs__(self): - ... - - @_sympifyit('other', NotImplemented) - @call_highest_priority('__radd__') - def __add__(self, other) -> MatAdd | GenericZeroMatrix: - ... - - @_sympifyit('other', NotImplemented) - @call_highest_priority('__add__') - def __radd__(self, other) -> MatAdd | GenericZeroMatrix: - ... - - @_sympifyit('other', NotImplemented) - @call_highest_priority('__rsub__') - def __sub__(self, other) -> MatAdd | GenericZeroMatrix: - ... - - @_sympifyit('other', NotImplemented) - @call_highest_priority('__sub__') - def __rsub__(self, other) -> MatAdd | GenericZeroMatrix: - ... - - @_sympifyit('other', NotImplemented) - @call_highest_priority('__rmul__') - def __mul__(self, other) -> GenericIdentity | Order | object: - ... - - @_sympifyit('other', NotImplemented) - @call_highest_priority('__rmul__') - def __matmul__(self, other) -> GenericIdentity | Order | object: - ... - - @_sympifyit('other', NotImplemented) - @call_highest_priority('__mul__') - def __rmul__(self, other) -> GenericIdentity | Order | object: - ... - - @_sympifyit('other', NotImplemented) - @call_highest_priority('__mul__') - def __rmatmul__(self, other) -> GenericIdentity | Order | object: - ... - - @_sympifyit('other', NotImplemented) - @call_highest_priority('__rpow__') - def __pow__(self, other) -> Inverse | Basic | Identity | Any | MatPow: - ... - - @_sympifyit('other', NotImplemented) - @call_highest_priority('__pow__') - def __rpow__(self, other): - ... - - @_sympifyit('other', NotImplemented) - @call_highest_priority('__rtruediv__') - def __truediv__(self, other): - ... - - @_sympifyit('other', NotImplemented) - @call_highest_priority('__truediv__') - def __rtruediv__(self, other): - ... - + def shape(self) -> tuple[Expr, Expr]: ... + def __neg__(self) -> GenericIdentity | Order | object: ... + def __abs__(self): ... + @_sympifyit("other", NotImplemented) + @call_highest_priority("__radd__") + def __add__(self, other) -> MatAdd | GenericZeroMatrix: ... + @_sympifyit("other", NotImplemented) + @call_highest_priority("__add__") + def __radd__(self, other) -> MatAdd | GenericZeroMatrix: ... + @_sympifyit("other", NotImplemented) + @call_highest_priority("__rsub__") + def __sub__(self, other) -> MatAdd | GenericZeroMatrix: ... + @_sympifyit("other", NotImplemented) + @call_highest_priority("__sub__") + def __rsub__(self, other) -> MatAdd | GenericZeroMatrix: ... + @_sympifyit("other", NotImplemented) + @call_highest_priority("__rmul__") + def __mul__(self, other) -> GenericIdentity | Order | object: ... + @_sympifyit("other", NotImplemented) + @call_highest_priority("__rmul__") + def __matmul__(self, other) -> GenericIdentity | Order | object: ... + @_sympifyit("other", NotImplemented) + @call_highest_priority("__mul__") + def __rmul__(self, other) -> GenericIdentity | Order | object: ... + @_sympifyit("other", NotImplemented) + @call_highest_priority("__mul__") + def __rmatmul__(self, other) -> GenericIdentity | Order | object: ... + @_sympifyit("other", NotImplemented) + @call_highest_priority("__rpow__") + def __pow__(self, other) -> Inverse | Basic | Identity | Any | MatPow: ... + @_sympifyit("other", NotImplemented) + @call_highest_priority("__pow__") + def __rpow__(self, other): ... + @_sympifyit("other", NotImplemented) + @call_highest_priority("__rtruediv__") + def __truediv__(self, other): ... + @_sympifyit("other", NotImplemented) + @call_highest_priority("__truediv__") + def __rtruediv__(self, other): ... @property - def rows(self) -> Expr: - ... - + def rows(self) -> Expr: ... @property - def cols(self) -> Expr: - ... - + def cols(self) -> Expr: ... @property - def is_square(self) -> bool | None: - ... - - def as_real_imag(self, deep=..., **hints) -> tuple[Any, Any]: - ... - - def adjoint(self) -> type[UndefinedFunction]: - ... - - def as_coeff_Mul(self, rational=...) -> tuple[Any, Self]: - ... - - def conjugate(self) -> type[UndefinedFunction]: - ... - - def transpose(self) -> Any | Transpose: - ... - + def is_square(self) -> bool | None: ... + def as_real_imag(self, deep=..., **hints) -> tuple[Any, Any]: ... + def adjoint(self) -> type[UndefinedFunction]: ... + def as_coeff_Mul(self, rational=...) -> tuple[Any, Self]: ... + def conjugate(self) -> type[UndefinedFunction]: ... + def transpose(self) -> Any | Transpose: ... @property - def T(self) -> Any | Transpose: - ... - - def inverse(self) -> Inverse: - ... - - def inv(self) -> Inverse: - ... - - def det(self) -> Determinant: - ... - + def T(self) -> Any | Transpose: ... + def inverse(self) -> Inverse: ... + def inv(self) -> Inverse: ... + def det(self) -> Determinant: ... @property - def I(self) -> Inverse: - ... - - def valid_index(self, i, j) -> Literal[False]: - ... - - def __getitem__(self, key) -> MatrixSlice: - ... - - def as_explicit(self) -> ImmutableDenseMatrix: - ... - - def as_mutable(self) -> Matrix: - ... - - def __array__(self): - ... - - def equals(self, other) -> bool: - ... - - def canonicalize(self) -> Self: - ... - - def as_coeff_mmul(self) -> tuple[Any, GenericIdentity | Any | Order | object | MatMul]: - ... - + def I(self) -> Inverse: ... + def valid_index(self, i, j) -> Literal[False]: ... + def __getitem__(self, key) -> MatrixSlice: ... + def as_explicit(self) -> ImmutableDenseMatrix: ... + def as_mutable(self) -> Matrix: ... + def __array__(self): ... + def equals(self, other) -> bool: ... + def canonicalize(self) -> Self: ... + def as_coeff_mmul(self) -> tuple[Any, GenericIdentity | Any | Order | object | MatMul]: ... @staticmethod - def from_index_summation(expr, first_index=..., last_index=..., dimensions=...): - ... - - def applyfunc(self, func) -> MatrixExpr | ElementwiseApplyFunction: - ... - + def from_index_summation(expr, first_index=..., last_index=..., dimensions=...): ... + def applyfunc(self, func) -> MatrixExpr | ElementwiseApplyFunction: ... - -def get_postprocessor(cls) -> Callable[..., Any]: - ... +def get_postprocessor(cls) -> Callable[..., Any]: ... class MatrixElement(Expr): parent = ... @@ -196,86 +116,41 @@ class MatrixElement(Expr): _diff_wrt = ... is_symbol = ... is_commutative = ... - def __new__(cls, name, n, m) -> Self: - ... - + def __new__(cls, name, n, m) -> Self: ... @property - def symbol(self) -> Basic: - ... - - def doit(self, **hints): - ... - + def symbol(self) -> Basic: ... + def doit(self, **hints): ... @property - def indices(self) -> tuple[Basic, ...]: - ... - - + def indices(self) -> tuple[Basic, ...]: ... class MatrixSymbol(MatrixExpr): is_commutative = ... is_symbol = ... _diff_wrt = ... - def __new__(cls, name, n, m) -> Self: - ... - + def __new__(cls, name, n, m) -> Self: ... @property - def shape(self) -> tuple[Basic, Basic]: - ... - + def shape(self) -> tuple[Basic, Basic]: ... @property - def name(self): - ... - + def name(self): ... @property - def free_symbols(self) -> set[Self]: - ... - - + def free_symbols(self) -> set[Self]: ... -def matrix_symbols(expr) -> list[Any]: - ... +def matrix_symbols(expr) -> list[Any]: ... class _LeftRightArgs: - def __init__(self, lines, higher=...) -> None: - ... - + def __init__(self, lines, higher=...) -> None: ... @property - def first_pointer(self): - ... - + def first_pointer(self): ... @first_pointer.setter - def first_pointer(self, value) -> None: - ... - + def first_pointer(self, value) -> None: ... @property - def second_pointer(self): - ... - + def second_pointer(self): ... @second_pointer.setter - def second_pointer(self, value) -> None: - ... - - def __repr__(self) -> str: - ... - - def transpose(self) -> Self: - ... - - def build(self) -> list[Any]: - ... - - def matrix_form(self) -> Literal[1]: - ... - - def rank(self) -> int: - ... - - def append_first(self, other) -> None: - ... - - def append_second(self, other) -> None: - ... - - - + def second_pointer(self, value) -> None: ... + def __repr__(self) -> str: ... + def transpose(self) -> Self: ... + def build(self) -> list[Any]: ... + def matrix_form(self) -> Literal[1]: ... + def rank(self) -> int: ... + def append_first(self, other) -> None: ... + def append_second(self, other) -> None: ... diff --git a/stubs/sympy-stubs/matrices/expressions/matmul.pyi b/stubs/sympy-stubs/matrices/expressions/matmul.pyi index 6e073ab8..30140aee 100644 --- a/stubs/sympy-stubs/matrices/expressions/matmul.pyi +++ b/stubs/sympy-stubs/matrices/expressions/matmul.pyi @@ -10,62 +10,27 @@ from sympy.series.order import Order class MatMul(MatrixExpr, Mul): is_MatMul = ... identity = ... - def __new__(cls, *args, evaluate=..., check=..., _sympify=...) -> GenericIdentity | Order | object | Self: - ... - + def __new__(cls, *args, evaluate=..., check=..., _sympify=...) -> GenericIdentity | Order | object | Self: ... @property - def shape(self) -> tuple[Any, Any]: - ... - - def as_coeff_matrices(self) -> tuple[Any | Order, list[Expr]]: - ... - - def as_coeff_mmul(self) -> tuple[Any | Order, GenericIdentity | Any | Order | object | MatMul]: - ... - - def expand(self, **kwargs) -> object: - ... - - def doit(self, **hints) -> object: - ... - - def args_cnc(self, cset=..., warn=..., **kwargs) -> list[Any]: - ... - - - -def newmul(*args) -> MatMul: - ... - -def any_zeros(mul) -> ZeroMatrix: - ... - -def merge_explicit(matmul) -> MatMul: - ... - -def remove_ids(mul) -> MatMul: - ... - -def factor_in_front(mul) -> MatMul: - ... - -def combine_powers(mul) -> MatMul: - ... - -def combine_permutations(mul) -> MatMul: - ... - -def combine_one_matrices(mul) -> MatMul: - ... - -def distribute_monom(mul) -> GenericZeroMatrix | MatAdd: - ... + def shape(self) -> tuple[Any, Any]: ... + def as_coeff_matrices(self) -> tuple[Any | Order, list[Expr]]: ... + def as_coeff_mmul(self) -> tuple[Any | Order, GenericIdentity | Any | Order | object | MatMul]: ... + def expand(self, **kwargs) -> object: ... + def doit(self, **hints) -> object: ... + def args_cnc(self, cset=..., warn=..., **kwargs) -> list[Any]: ... + +def newmul(*args) -> MatMul: ... +def any_zeros(mul) -> ZeroMatrix: ... +def merge_explicit(matmul) -> MatMul: ... +def remove_ids(mul) -> MatMul: ... +def factor_in_front(mul) -> MatMul: ... +def combine_powers(mul) -> MatMul: ... +def combine_permutations(mul) -> MatMul: ... +def combine_one_matrices(mul) -> MatMul: ... +def distribute_monom(mul) -> GenericZeroMatrix | MatAdd: ... rules = ... canonicalize = ... -def only_squares(*matrices) -> list[Any]: - ... - -def refine_MatMul(expr, assumptions) -> GenericIdentity | Order | object | MatMul: - ... +def only_squares(*matrices) -> list[Any]: ... +def refine_MatMul(expr, assumptions) -> GenericIdentity | Order | object | MatMul: ... diff --git a/stubs/sympy-stubs/matrices/expressions/matpow.pyi b/stubs/sympy-stubs/matrices/expressions/matpow.pyi index 2250834b..dd34f4ee 100644 --- a/stubs/sympy-stubs/matrices/expressions/matpow.pyi +++ b/stubs/sympy-stubs/matrices/expressions/matpow.pyi @@ -6,23 +6,11 @@ from sympy.matrices.expressions.matexpr import MatrixExpr from sympy.matrices.expressions.special import Identity class MatPow(MatrixExpr): - def __new__(cls, base, exp, evaluate=..., **options) -> Basic | Identity | Inverse | Any | MatPow | Self: - ... - + def __new__(cls, base, exp, evaluate=..., **options) -> Basic | Identity | Inverse | Any | MatPow | Self: ... @property - def base(self) -> Basic: - ... - + def base(self) -> Basic: ... @property - def exp(self) -> Basic: - ... - + def exp(self) -> Basic: ... @property - def shape(self): - ... - - def doit(self, **hints) -> Basic | Identity | Inverse | Any | MatPow: - ... - - - + def shape(self): ... + def doit(self, **hints) -> Basic | Identity | Inverse | Any | MatPow: ... diff --git a/stubs/sympy-stubs/matrices/expressions/permutation.pyi b/stubs/sympy-stubs/matrices/expressions/permutation.pyi index 0f95f62d..810b988c 100644 --- a/stubs/sympy-stubs/matrices/expressions/permutation.pyi +++ b/stubs/sympy-stubs/matrices/expressions/permutation.pyi @@ -5,33 +5,17 @@ from sympy.matrices.expressions.matexpr import MatrixExpr from sympy.matrices.expressions.special import Identity, OneMatrix, ZeroMatrix class PermutationMatrix(MatrixExpr): - def __new__(cls, perm) -> Self: - ... - + def __new__(cls, perm) -> Self: ... @property - def shape(self) -> tuple[Any, Any]: - ... - + def shape(self) -> tuple[Any, Any]: ... @property - def is_Identity(self): - ... - - def doit(self, **hints) -> Identity | Self: - ... - - _eval_adjoint = ... + def is_Identity(self): ... + def doit(self, **hints) -> Identity | Self: ... + _eval_adjoint = ... class MatrixPermute(MatrixExpr): - def __new__(cls, mat, perm, axis=...) -> Self: - ... - - def doit(self, deep=..., **hints) -> Basic | PermutationMatrix | ZeroMatrix | OneMatrix | MatrixPermute | Self: - ... - + def __new__(cls, mat, perm, axis=...) -> Self: ... + def doit(self, deep=..., **hints) -> Basic | PermutationMatrix | ZeroMatrix | OneMatrix | MatrixPermute | Self: ... @property - def shape(self): - ... - - - + def shape(self): ... diff --git a/stubs/sympy-stubs/matrices/expressions/sets.pyi b/stubs/sympy-stubs/matrices/expressions/sets.pyi index b487d56e..5458abb8 100644 --- a/stubs/sympy-stubs/matrices/expressions/sets.pyi +++ b/stubs/sympy-stubs/matrices/expressions/sets.pyi @@ -5,16 +5,8 @@ from sympy.sets.sets import Set class MatrixSet(Set): is_empty = ... - def __new__(cls, n, m, set) -> Self: - ... - + def __new__(cls, n, m, set) -> Self: ... @property - def shape(self) -> tuple[Basic, ...]: - ... - + def shape(self) -> tuple[Basic, ...]: ... @property - def set(self) -> Basic: - ... - - - + def set(self) -> Basic: ... diff --git a/stubs/sympy-stubs/matrices/expressions/slice.pyi b/stubs/sympy-stubs/matrices/expressions/slice.pyi index e3392122..6eeea819 100644 --- a/stubs/sympy-stubs/matrices/expressions/slice.pyi +++ b/stubs/sympy-stubs/matrices/expressions/slice.pyi @@ -3,29 +3,17 @@ from typing import Any, Literal, Self from sympy.core.function import UndefinedFunction from sympy.matrices.expressions.matexpr import MatrixExpr -def normalize(i, parentsize) -> tuple[Any | Literal[0], Any, Any | Literal[1]]: - ... +def normalize(i, parentsize) -> tuple[Any | Literal[0], Any, Any | Literal[1]]: ... class MatrixSlice(MatrixExpr): parent = ... rowslice = ... colslice = ... - def __new__(cls, parent, rowslice, colslice) -> MatrixSlice | Self: - ... - + def __new__(cls, parent, rowslice, colslice) -> MatrixSlice | Self: ... @property - def shape(self) -> tuple[Any | type[UndefinedFunction], Any | type[UndefinedFunction]]: - ... - + def shape(self) -> tuple[Any | type[UndefinedFunction], Any | type[UndefinedFunction]]: ... @property - def on_diag(self) -> Any: - ... - - - -def slice_of_slice(s, t) -> tuple[Any, Any, Any]: - ... - -def mat_slice_of_slice(parent, rowslice, colslice) -> MatrixSlice: - ... + def on_diag(self) -> Any: ... +def slice_of_slice(s, t) -> tuple[Any, Any, Any]: ... +def mat_slice_of_slice(parent, rowslice, colslice) -> MatrixSlice: ... diff --git a/stubs/sympy-stubs/matrices/expressions/special.pyi b/stubs/sympy-stubs/matrices/expressions/special.pyi index a979a5e6..968c124b 100644 --- a/stubs/sympy-stubs/matrices/expressions/special.pyi +++ b/stubs/sympy-stubs/matrices/expressions/special.pyi @@ -5,113 +5,53 @@ from sympy.matrices.expressions.matexpr import MatrixExpr class ZeroMatrix(MatrixExpr): is_ZeroMatrix = ... - def __new__(cls, m, n) -> Self: - ... - + def __new__(cls, m, n) -> Self: ... @property - def shape(self) -> tuple[Basic, Basic]: - ... - - + def shape(self) -> tuple[Basic, Basic]: ... class GenericZeroMatrix(ZeroMatrix): - def __new__(cls) -> Self: - ... - + def __new__(cls) -> Self: ... @property - def rows(self): - ... - + def rows(self): ... @property - def cols(self): - ... - + def cols(self): ... @property - def shape(self): - ... - - def __eq__(self, other) -> bool: - ... - - def __ne__(self, other) -> bool: - ... - - def __hash__(self) -> int: - ... - - + def shape(self): ... + def __eq__(self, other) -> bool: ... + def __ne__(self, other) -> bool: ... + def __hash__(self) -> int: ... class Identity(MatrixExpr): is_Identity = ... - def __new__(cls, n) -> Self: - ... - + def __new__(cls, n) -> Self: ... @property - def rows(self) -> Basic: - ... - + def rows(self) -> Basic: ... @property - def cols(self) -> Basic: - ... - + def cols(self) -> Basic: ... @property - def shape(self) -> tuple[Basic, Basic]: - ... - + def shape(self) -> tuple[Basic, Basic]: ... @property - def is_square(self) -> Literal[True]: - ... - - + def is_square(self) -> Literal[True]: ... class GenericIdentity(Identity): - def __new__(cls) -> Self: - ... - + def __new__(cls) -> Self: ... @property - def rows(self): - ... - + def rows(self): ... @property - def cols(self): - ... - + def cols(self): ... @property - def shape(self): - ... - + def shape(self): ... @property - def is_square(self) -> Literal[True]: - ... - - def __eq__(self, other) -> bool: - ... - - def __ne__(self, other) -> bool: - ... - - def __hash__(self) -> int: - ... - - + def is_square(self) -> Literal[True]: ... + def __eq__(self, other) -> bool: ... + def __ne__(self, other) -> bool: ... + def __hash__(self) -> int: ... class OneMatrix(MatrixExpr): - def __new__(cls, m, n, evaluate=...) -> Identity | Self: - ... - + def __new__(cls, m, n, evaluate=...) -> Identity | Self: ... @property - def shape(self) -> tuple[Basic, ...]: - ... - + def shape(self) -> tuple[Basic, ...]: ... @property - def is_Identity(self): - ... - - def as_explicit(self): - ... - - def doit(self, **hints) -> Self: - ... - - - + def is_Identity(self): ... + def as_explicit(self): ... + def doit(self, **hints) -> Self: ... diff --git a/stubs/sympy-stubs/matrices/expressions/trace.pyi b/stubs/sympy-stubs/matrices/expressions/trace.pyi index 10ee7c9a..24859298 100644 --- a/stubs/sympy-stubs/matrices/expressions/trace.pyi +++ b/stubs/sympy-stubs/matrices/expressions/trace.pyi @@ -6,21 +6,10 @@ from sympy.core.expr import Expr class Trace(Expr): is_Trace = ... is_commutative = ... - def __new__(cls, mat) -> Self: - ... - + def __new__(cls, mat) -> Self: ... @property - def arg(self) -> Basic: - ... - - def doit(self, **hints) -> Trace: - ... - - def as_explicit(self) -> Trace: - ... - - - -def trace(expr): - ... + def arg(self) -> Basic: ... + def doit(self, **hints) -> Trace: ... + def as_explicit(self) -> Trace: ... +def trace(expr): ... diff --git a/stubs/sympy-stubs/matrices/expressions/transpose.pyi b/stubs/sympy-stubs/matrices/expressions/transpose.pyi index cbabfbcd..c1d29e0f 100644 --- a/stubs/sympy-stubs/matrices/expressions/transpose.pyi +++ b/stubs/sympy-stubs/matrices/expressions/transpose.pyi @@ -5,22 +5,11 @@ from sympy.matrices.expressions.matexpr import MatrixExpr class Transpose(MatrixExpr): is_Transpose = ... - def doit(self, **hints) -> Any | Transpose: - ... - + def doit(self, **hints) -> Any | Transpose: ... @property - def arg(self) -> Basic: - ... - + def arg(self) -> Basic: ... @property - def shape(self): - ... - - - -def transpose(expr) -> Any | Transpose: - ... - -def refine_Transpose(expr, assumptions): - ... + def shape(self): ... +def transpose(expr) -> Any | Transpose: ... +def refine_Transpose(expr, assumptions): ... diff --git a/stubs/sympy-stubs/matrices/immutable.pyi b/stubs/sympy-stubs/matrices/immutable.pyi index f845b76e..6249910e 100644 --- a/stubs/sympy-stubs/matrices/immutable.pyi +++ b/stubs/sympy-stubs/matrices/immutable.pyi @@ -5,53 +5,33 @@ from sympy.matrices.expressions import MatrixExpr from sympy.matrices.repmatrix import RepMatrix from sympy.matrices.sparse import SparseRepMatrix -def sympify_matrix(arg): - ... - -def sympify_mpmath_matrix(arg) -> ImmutableDenseMatrix: - ... +def sympify_matrix(arg): ... +def sympify_mpmath_matrix(arg) -> ImmutableDenseMatrix: ... class ImmutableRepMatrix(RepMatrix, MatrixExpr): - def __new__(cls, *args, **kwargs): - ... - + def __new__(cls, *args, **kwargs): ... + __hash__ = ... - def copy(self) -> Self: - ... - + def copy(self) -> Self: ... @property - def cols(self): - ... - + def cols(self): ... @property - def rows(self): - ... - + def rows(self): ... @property - def shape(self) -> tuple[Any, Any]: - ... - - def as_immutable(self) -> Self: - ... - - def __setitem__(self, *args): - ... - - def is_diagonalizable(self, reals_only=..., **kwargs) -> bool: - ... - - is_diagonalizable = ... + def shape(self) -> tuple[Any, Any]: ... + def as_immutable(self) -> Self: ... + def __setitem__(self, *args): ... + def is_diagonalizable(self, reals_only=..., **kwargs) -> bool: ... + is_diagonalizable = ... class ImmutableDenseMatrix(DenseMatrix, ImmutableRepMatrix): _iterable = ... _class_priority = ... _op_priority = ... - ImmutableMatrix = ImmutableDenseMatrix + class ImmutableSparseMatrix(SparseRepMatrix, ImmutableRepMatrix): is_Matrix = ... _class_priority = ... - - diff --git a/stubs/sympy-stubs/matrices/normalforms.pyi b/stubs/sympy-stubs/matrices/normalforms.pyi index 654dc722..de73e25d 100644 --- a/stubs/sympy-stubs/matrices/normalforms.pyi +++ b/stubs/sympy-stubs/matrices/normalforms.pyi @@ -2,12 +2,6 @@ from typing import Any from sympy.matrices.dense import MutableDenseMatrix -def smith_normal_form(m, domain=...) -> MutableDenseMatrix: - ... - -def invariant_factors(m, domain=...) -> tuple[Any, ...]: - ... - -def hermite_normal_form(A, *, D=..., check_rank=...) -> MutableDenseMatrix: - ... - +def smith_normal_form(m, domain=...) -> MutableDenseMatrix: ... +def invariant_factors(m, domain=...) -> tuple[Any, ...]: ... +def hermite_normal_form(A, *, D=..., check_rank=...) -> MutableDenseMatrix: ... diff --git a/stubs/sympy-stubs/matrices/repmatrix.pyi b/stubs/sympy-stubs/matrices/repmatrix.pyi index fb524ca5..37f02492 100644 --- a/stubs/sympy-stubs/matrices/repmatrix.pyi +++ b/stubs/sympy-stubs/matrices/repmatrix.pyi @@ -8,64 +8,25 @@ from sympy.polys.matrices import DomainMatrix class RepMatrix(MatrixBase): _rep: DomainMatrix - def __eq__(self, other) -> bool: - ... - - def flat(self) -> list[Any]: - ... - - def copy(self): - ... - + def __eq__(self, other) -> bool: ... + def flat(self) -> list[Any]: ... + def copy(self): ... @property - def kind(self) -> MatrixKind: - ... - - def __getitem__(self, key) -> MatrixElement | list[Any]: - ... - - def equals(self, other, failing_expression=...) -> bool: - ... - - + def kind(self) -> MatrixKind: ... + def __getitem__(self, key) -> MatrixElement | list[Any]: ... + def equals(self, other, failing_expression=...) -> bool: ... class MutableRepMatrix(RepMatrix): is_zero = ... - def __new__(cls, *args, **kwargs) -> Self: - ... - - def copy(self) -> Self: - ... - - def as_mutable(self) -> Self: - ... - - def __setitem__(self, key, value) -> None: - ... - - def col_op(self, j, f) -> None: - ... - - def col_swap(self, i, j) -> None: - ... - - def row_op(self, i, f) -> None: - ... - - def row_swap(self, i, j) -> None: - ... - - def zip_row_op(self, i, k, f) -> None: - ... - - def copyin_list(self, key, value) -> None: - ... - - def copyin_matrix(self, key, value) -> None: - ... - - def fill(self, value) -> None: - ... - - - + def __new__(cls, *args, **kwargs) -> Self: ... + def copy(self) -> Self: ... + def as_mutable(self) -> Self: ... + def __setitem__(self, key, value) -> None: ... + def col_op(self, j, f) -> None: ... + def col_swap(self, i, j) -> None: ... + def row_op(self, i, f) -> None: ... + def row_swap(self, i, j) -> None: ... + def zip_row_op(self, i, k, f) -> None: ... + def copyin_list(self, key, value) -> None: ... + def copyin_matrix(self, key, value) -> None: ... + def fill(self, value) -> None: ... diff --git a/stubs/sympy-stubs/matrices/sparse.pyi b/stubs/sympy-stubs/matrices/sparse.pyi index 03550bea..0b43d846 100644 --- a/stubs/sympy-stubs/matrices/sparse.pyi +++ b/stubs/sympy-stubs/matrices/sparse.pyi @@ -5,58 +5,28 @@ from sympy.matrices.immutable import ImmutableSparseMatrix from sympy.matrices.repmatrix import MutableRepMatrix, RepMatrix class SparseRepMatrix(RepMatrix): - def applyfunc(self, f): - ... - - def as_immutable(self) -> ImmutableSparseMatrix: - ... - - def as_mutable(self) -> MutableSparseMatrix: - ... - - def col_list(self) -> list[tuple[Any, ...]]: - ... - - def nnz(self) -> int: - ... - - def row_list(self) -> list[tuple[Any, ...]]: - ... - + def applyfunc(self, f): ... + def as_immutable(self) -> ImmutableSparseMatrix: ... + def as_mutable(self) -> MutableSparseMatrix: ... + def col_list(self) -> list[tuple[Any, ...]]: ... + def nnz(self) -> int: ... + def row_list(self) -> list[tuple[Any, ...]]: ... def scalar_multiply(self, scalar): "Scalar element-wise multiplication" ... - - def solve_least_squares(self, rhs, method=...): - ... - - def solve(self, rhs, method=...) -> NotImplementedType | None: - ... - - RL = ... - CL = ... - def liupc(self) -> tuple[list[list[Any]], Any]: - ... - - def row_structure_symbolic_cholesky(self): - ... - - def cholesky(self, hermitian=...): - ... - - def LDLdecomposition(self, hermitian=...) -> tuple[Any, Any]: - ... - - def lower_triangular_solve(self, rhs): - ... - - def upper_triangular_solve(self, rhs): - ... - + def solve_least_squares(self, rhs, method=...): ... + def solve(self, rhs, method=...) -> NotImplementedType | None: ... -class MutableSparseMatrix(SparseRepMatrix, MutableRepMatrix): - ... + RL = ... + CL = ... + def liupc(self) -> tuple[list[list[Any]], Any]: ... + def row_structure_symbolic_cholesky(self): ... + def cholesky(self, hermitian=...): ... + def LDLdecomposition(self, hermitian=...) -> tuple[Any, Any]: ... + def lower_triangular_solve(self, rhs): ... + def upper_triangular_solve(self, rhs): ... +class MutableSparseMatrix(SparseRepMatrix, MutableRepMatrix): ... SparseMatrix = MutableSparseMatrix diff --git a/stubs/sympy-stubs/matrices/utilities.pyi b/stubs/sympy-stubs/matrices/utilities.pyi index f99e42ec..4ce3ff48 100644 --- a/stubs/sympy-stubs/matrices/utilities.pyi +++ b/stubs/sympy-stubs/matrices/utilities.pyi @@ -3,13 +3,9 @@ from threading import local from typing import Any, Generator class DotProdSimpState(local): - def __init__(self) -> None: - ... - - + def __init__(self) -> None: ... _dotprodsimp_state = ... -@contextmanager -def dotprodsimp(x) -> Generator[None, Any, None]: - ... +@contextmanager +def dotprodsimp(x) -> Generator[None, Any, None]: ... diff --git a/stubs/sympy-stubs/multipledispatch/__init__.pyi b/stubs/sympy-stubs/multipledispatch/__init__.pyi index e1e31cc9..92017a2e 100644 --- a/stubs/sympy-stubs/multipledispatch/__init__.pyi +++ b/stubs/sympy-stubs/multipledispatch/__init__.pyi @@ -2,4 +2,4 @@ from sympy.multipledispatch.core import dispatch from sympy.multipledispatch.dispatcher import Dispatcher, MDNotImplementedError, halt_ordering, restart_ordering __version__ = ... -__all__ = ['dispatch', 'Dispatcher', 'halt_ordering', 'restart_ordering', 'MDNotImplementedError'] +__all__ = ["dispatch", "Dispatcher", "halt_ordering", "restart_ordering", "MDNotImplementedError"] diff --git a/stubs/sympy-stubs/multipledispatch/conflict.pyi b/stubs/sympy-stubs/multipledispatch/conflict.pyi index d8d0d979..09aa5c30 100644 --- a/stubs/sympy-stubs/multipledispatch/conflict.pyi +++ b/stubs/sympy-stubs/multipledispatch/conflict.pyi @@ -1,27 +1,11 @@ from typing import Any, _T_co -class AmbiguityWarning(Warning): - ... - - -def supercedes(a, b) -> bool: - ... - -def consistent(a, b) -> bool: - ... - -def ambiguous(a, b) -> bool: - ... - -def ambiguities(signatures) -> set[tuple[tuple[_T_co, ...], tuple[_T_co, ...]]]: - ... - -def super_signature(signatures) -> list[type]: - ... - -def edge(a, b, tie_breaker=...) -> bool: - ... - -def ordering(signatures): - ... - +class AmbiguityWarning(Warning): ... + +def supercedes(a, b) -> bool: ... +def consistent(a, b) -> bool: ... +def ambiguous(a, b) -> bool: ... +def ambiguities(signatures) -> set[tuple[tuple[_T_co, ...], tuple[_T_co, ...]]]: ... +def super_signature(signatures) -> list[type]: ... +def edge(a, b, tie_breaker=...) -> bool: ... +def ordering(signatures): ... diff --git a/stubs/sympy-stubs/multipledispatch/core.pyi b/stubs/sympy-stubs/multipledispatch/core.pyi index 9bd03dee..beb17adf 100644 --- a/stubs/sympy-stubs/multipledispatch/core.pyi +++ b/stubs/sympy-stubs/multipledispatch/core.pyi @@ -1,9 +1,6 @@ from typing import Any, Callable global_namespace: dict[str, Any] = ... -def dispatch(*types, namespace=..., on_ambiguity=...) -> Callable[..., Any]: - ... - -def ismethod(func) -> bool: - ... +def dispatch(*types, namespace=..., on_ambiguity=...) -> Callable[..., Any]: ... +def ismethod(func) -> bool: ... diff --git a/stubs/sympy-stubs/multipledispatch/dispatcher.pyi b/stubs/sympy-stubs/multipledispatch/dispatcher.pyi index e824c636..108c55cd 100644 --- a/stubs/sympy-stubs/multipledispatch/dispatcher.pyi +++ b/stubs/sympy-stubs/multipledispatch/dispatcher.pyi @@ -2,108 +2,53 @@ from inspect import Parameter from itertools import islice from typing import Any, Callable, Generator, LiteralString, Self, ValuesView -class MDNotImplementedError(NotImplementedError): - ... +class MDNotImplementedError(NotImplementedError): ... - -def ambiguity_warn(dispatcher, ambiguities) -> None: - ... +def ambiguity_warn(dispatcher, ambiguities) -> None: ... class RaiseNotImplementedError: - def __init__(self, dispatcher) -> None: - ... - - def __call__(self, *args, **kwargs): - ... - - + def __init__(self, dispatcher) -> None: ... + def __call__(self, *args, **kwargs): ... -def ambiguity_register_error_ignore_dup(dispatcher, ambiguities) -> None: - ... +def ambiguity_register_error_ignore_dup(dispatcher, ambiguities) -> None: ... _unresolved_dispatchers: set[Dispatcher] = ... _resolve = ... -def halt_ordering() -> None: - ... -def restart_ordering(on_ambiguity=...) -> None: - ... +def halt_ordering() -> None: ... +def restart_ordering(on_ambiguity=...) -> None: ... class Dispatcher: __slots__ = ... - def __init__(self, name, doc=...) -> None: - ... - - def register(self, *types, **kwargs) -> Callable[..., Any]: - ... - + def __init__(self, name, doc=...) -> None: ... + def register(self, *types, **kwargs) -> Callable[..., Any]: ... @classmethod - def get_func_params(cls, func) -> ValuesView[Parameter] | None: - ... - + def get_func_params(cls, func) -> ValuesView[Parameter] | None: ... @classmethod - def get_func_annotations(cls, func) -> tuple[Any, ...] | None: - ... - - def add(self, signature, func, on_ambiguity=...) -> None: - ... - - def reorder(self, on_ambiguity=...) -> None: - ... - - def __call__(self, *args, **kwargs): - ... - - def __str__(self) -> str: - ... - + def get_func_annotations(cls, func) -> tuple[Any, ...] | None: ... + def add(self, signature, func, on_ambiguity=...) -> None: ... + def reorder(self, on_ambiguity=...) -> None: ... + def __call__(self, *args, **kwargs): ... + def __str__(self) -> str: ... + __repr__ = ... - def dispatch(self, *types) -> None: - ... - - def dispatch_iter(self, *types) -> Generator[Any, Any, None]: - ... - - def resolve(self, types) -> None: - ... - - def __getstate__(self) -> dict[str, Any]: - ... - - def __setstate__(self, d) -> None: - ... - + def dispatch(self, *types) -> None: ... + def dispatch_iter(self, *types) -> Generator[Any, Any, None]: ... + def resolve(self, types) -> None: ... + def __getstate__(self) -> dict[str, Any]: ... + def __setstate__(self, d) -> None: ... @property - def __doc__(self) -> str: - ... - - def help(self, *args, **kwargs) -> None: - ... - - def source(self, *args, **kwargs) -> None: - ... - - + def __doc__(self) -> str: ... + def help(self, *args, **kwargs) -> None: ... + def source(self, *args, **kwargs) -> None: ... -def source(func) -> str: - ... +def source(func) -> str: ... class MethodDispatcher(Dispatcher): @classmethod - def get_func_params(cls, func) -> islice[Parameter] | None: - ... - - def __get__(self, instance, owner) -> Self: - ... - - def __call__(self, *args, **kwargs): - ... - - - -def str_signature(sig) -> LiteralString: - ... - -def warning_text(name, amb): - ... + def get_func_params(cls, func) -> islice[Parameter] | None: ... + def __get__(self, instance, owner) -> Self: ... + def __call__(self, *args, **kwargs): ... +def str_signature(sig) -> LiteralString: ... +def warning_text(name, amb): ... diff --git a/stubs/sympy-stubs/multipledispatch/utils.pyi b/stubs/sympy-stubs/multipledispatch/utils.pyi index 2ac18c24..b4b8b859 100644 --- a/stubs/sympy-stubs/multipledispatch/utils.pyi +++ b/stubs/sympy-stubs/multipledispatch/utils.pyi @@ -1,11 +1,5 @@ from typing import Any -def expand_tuples(L) -> list[tuple[()]] | list[Any]: - ... - -def reverse_dict(d) -> dict[Any, Any]: - ... - -def groupby(func, seq) -> dict[Any, Any]: - ... - +def expand_tuples(L) -> list[tuple[()]] | list[Any]: ... +def reverse_dict(d) -> dict[Any, Any]: ... +def groupby(func, seq) -> dict[Any, Any]: ... diff --git a/stubs/sympy-stubs/ntheory/__init__.pyi b/stubs/sympy-stubs/ntheory/__init__.pyi index 3f1c117b..d4a9fbd7 100644 --- a/stubs/sympy-stubs/ntheory/__init__.pyi +++ b/stubs/sympy-stubs/ntheory/__init__.pyi @@ -73,4 +73,76 @@ from sympy.ntheory.residue_ntheory import ( sqrt_mod_iter, ) -__all__ = ['nextprime', 'prevprime', 'prime', 'primepi', 'primerange', 'randprime', 'Sieve', 'sieve', 'primorial', 'cycle_length', 'composite', 'compositepi', 'isprime', 'is_gaussian_prime', 'divisors', 'proper_divisors', 'factorint', 'multiplicity', 'perfect_power', 'pollard_pm1', 'pollard_rho', 'primefactors', 'totient', 'trailing', 'divisor_count', 'proper_divisor_count', 'divisor_sigma', 'factorrat', 'reduced_totient', 'primenu', 'primeomega', 'mersenne_prime_exponent', 'is_perfect', 'is_mersenne_prime', 'is_abundant', 'is_deficient', 'is_amicable', 'abundance', 'dra', 'drm', 'multiplicity_in_factorial', 'npartitions', 'is_primitive_root', 'is_quad_residue', 'legendre_symbol', 'jacobi_symbol', 'n_order', 'sqrt_mod', 'quadratic_residues', 'primitive_root', 'nthroot_mod', 'is_nthpow_residue', 'sqrt_mod_iter', 'mobius', 'discrete_log', 'quadratic_congruence', 'polynomial_congruence', 'binomial_coefficients', 'binomial_coefficients_list', 'multinomial_coefficients', 'continued_fraction_periodic', 'continued_fraction_iterator', 'continued_fraction_reduce', 'continued_fraction_convergents', 'continued_fraction', 'digits', 'count_digits', 'is_palindromic', 'egyptian_fraction', 'ecm', 'qs'] +__all__ = [ + "nextprime", + "prevprime", + "prime", + "primepi", + "primerange", + "randprime", + "Sieve", + "sieve", + "primorial", + "cycle_length", + "composite", + "compositepi", + "isprime", + "is_gaussian_prime", + "divisors", + "proper_divisors", + "factorint", + "multiplicity", + "perfect_power", + "pollard_pm1", + "pollard_rho", + "primefactors", + "totient", + "trailing", + "divisor_count", + "proper_divisor_count", + "divisor_sigma", + "factorrat", + "reduced_totient", + "primenu", + "primeomega", + "mersenne_prime_exponent", + "is_perfect", + "is_mersenne_prime", + "is_abundant", + "is_deficient", + "is_amicable", + "abundance", + "dra", + "drm", + "multiplicity_in_factorial", + "npartitions", + "is_primitive_root", + "is_quad_residue", + "legendre_symbol", + "jacobi_symbol", + "n_order", + "sqrt_mod", + "quadratic_residues", + "primitive_root", + "nthroot_mod", + "is_nthpow_residue", + "sqrt_mod_iter", + "mobius", + "discrete_log", + "quadratic_congruence", + "polynomial_congruence", + "binomial_coefficients", + "binomial_coefficients_list", + "multinomial_coefficients", + "continued_fraction_periodic", + "continued_fraction_iterator", + "continued_fraction_reduce", + "continued_fraction_convergents", + "continued_fraction", + "digits", + "count_digits", + "is_palindromic", + "egyptian_fraction", + "ecm", + "qs", +] diff --git a/stubs/sympy-stubs/ntheory/continued_fraction.pyi b/stubs/sympy-stubs/ntheory/continued_fraction.pyi index bd3a8b51..06d2c06d 100644 --- a/stubs/sympy-stubs/ntheory/continued_fraction.pyi +++ b/stubs/sympy-stubs/ntheory/continued_fraction.pyi @@ -6,18 +6,8 @@ from sympy.core.function import UndefinedFunction from sympy.core.mul import Mul from sympy.series.order import Order -def continued_fraction(a) -> list: - ... - -def continued_fraction_periodic(p, q, d=..., s=...) -> list: - ... - -def continued_fraction_reduce(cf) -> Order | Basic | Any | Add | Mul: - ... - -def continued_fraction_iterator(x) -> Generator[type[UndefinedFunction] | Any, Any, None]: - ... - -def continued_fraction_convergents(cf) -> Generator[Any, Any, None]: - ... - +def continued_fraction(a) -> list: ... +def continued_fraction_periodic(p, q, d=..., s=...) -> list: ... +def continued_fraction_reduce(cf) -> Order | Basic | Any | Add | Mul: ... +def continued_fraction_iterator(x) -> Generator[type[UndefinedFunction] | Any, Any, None]: ... +def continued_fraction_convergents(cf) -> Generator[Any, Any, None]: ... diff --git a/stubs/sympy-stubs/ntheory/digits.pyi b/stubs/sympy-stubs/ntheory/digits.pyi index 5d02cffd..8e72a67f 100644 --- a/stubs/sympy-stubs/ntheory/digits.pyi +++ b/stubs/sympy-stubs/ntheory/digits.pyi @@ -1,12 +1,6 @@ from collections import defaultdict from typing import Any -def digits(n, b=..., digits=...) -> list[Any]: - ... - -def count_digits(n, b=...) -> defaultdict[Any, int]: - ... - -def is_palindromic(n, b=...) -> bool: - ... - +def digits(n, b=..., digits=...) -> list[Any]: ... +def count_digits(n, b=...) -> defaultdict[Any, int]: ... +def is_palindromic(n, b=...) -> bool: ... diff --git a/stubs/sympy-stubs/ntheory/ecm.pyi b/stubs/sympy-stubs/ntheory/ecm.pyi index b8b345d1..ab3a0cff 100644 --- a/stubs/sympy-stubs/ntheory/ecm.pyi +++ b/stubs/sympy-stubs/ntheory/ecm.pyi @@ -1,24 +1,12 @@ from typing import Any, Self rgen = ... -class Point: - def __init__(self, x_cord, z_cord, a_24, mod) -> None: - ... - - def __eq__(self, other) -> bool: - ... - - def add(self, Q, diff) -> Point: - ... - - def double(self) -> Point: - ... - - def mont_ladder(self, k) -> Self | Point: - ... - - -def ecm(n, B1=..., B2=..., max_curve=..., seed=...) -> set[Any]: - ... +class Point: + def __init__(self, x_cord, z_cord, a_24, mod) -> None: ... + def __eq__(self, other) -> bool: ... + def add(self, Q, diff) -> Point: ... + def double(self) -> Point: ... + def mont_ladder(self, k) -> Self | Point: ... +def ecm(n, B1=..., B2=..., max_curve=..., seed=...) -> set[Any]: ... diff --git a/stubs/sympy-stubs/ntheory/egyptian_fraction.pyi b/stubs/sympy-stubs/ntheory/egyptian_fraction.pyi index 7fb79d3f..c037fe1c 100644 --- a/stubs/sympy-stubs/ntheory/egyptian_fraction.pyi +++ b/stubs/sympy-stubs/ntheory/egyptian_fraction.pyi @@ -2,21 +2,9 @@ from typing import Any from sympy.core.numbers import Integer -def egyptian_fraction(r, algorithm=...) -> list[Any | Integer] | list[Any]: - ... - -def egypt_greedy(x, y) -> list[Any]: - ... - -def egypt_graham_jewett(x, y) -> list[Any]: - ... - -def egypt_takenouchi(x, y) -> list[Any]: - ... - -def egypt_golomb(x, y) -> list[Any]: - ... - -def egypt_harmonic(r) -> tuple[list[Any], Any]: - ... - +def egyptian_fraction(r, algorithm=...) -> list[Any | Integer] | list[Any]: ... +def egypt_greedy(x, y) -> list[Any]: ... +def egypt_graham_jewett(x, y) -> list[Any]: ... +def egypt_takenouchi(x, y) -> list[Any]: ... +def egypt_golomb(x, y) -> list[Any]: ... +def egypt_harmonic(r) -> tuple[list[Any], Any]: ... diff --git a/stubs/sympy-stubs/ntheory/factor_.pyi b/stubs/sympy-stubs/ntheory/factor_.pyi index 7c85d6d6..b727ae45 100644 --- a/stubs/sympy-stubs/ntheory/factor_.pyi +++ b/stubs/sympy-stubs/ntheory/factor_.pyi @@ -10,29 +10,17 @@ MERSENNE_PRIME_EXPONENTS = ... PERFECT = ... MERSENNES = ... small_trailing = ... -def smoothness(n) -> tuple[Literal[1], Literal[1]] | tuple[Any, Any]: - ... -def smoothness_p(n, m=..., power=..., visual=...) -> str | dict[Any, Any] | tuple[Any, ...] | tuple[int, list[tuple[Any, tuple[Any, ...]]]] | LiteralString: - ... - -def trailing(n) -> int: - ... - -def multiplicity(p, n) -> int: - ... - -def multiplicity_in_factorial(p, n): - ... - -def perfect_power(n, candidates=..., big=..., factor=...): - ... - -def pollard_rho(n, s=..., a=..., retries=..., seed=..., max_steps=..., F=...) -> int | None: - ... - -def pollard_pm1(n, B=..., a=..., retries=..., seed=...) -> int | None: - ... +def smoothness(n) -> tuple[Literal[1], Literal[1]] | tuple[Any, Any]: ... +def smoothness_p( + n, m=..., power=..., visual=... +) -> str | dict[Any, Any] | tuple[Any, ...] | tuple[int, list[tuple[Any, tuple[Any, ...]]]] | LiteralString: ... +def trailing(n) -> int: ... +def multiplicity(p, n) -> int: ... +def multiplicity_in_factorial(p, n): ... +def perfect_power(n, candidates=..., big=..., factor=...): ... +def pollard_rho(n, s=..., a=..., retries=..., seed=..., max_steps=..., F=...) -> int | None: ... +def pollard_pm1(n, B=..., a=..., retries=..., seed=...) -> int | None: ... trial_int_msg = ... trial_msg = ... @@ -42,108 +30,111 @@ ecm_msg = ... factor_msg = ... fermat_msg = ... complete_msg = ... -def factorint(n, limit=..., use_trial=..., use_rho=..., use_pm1=..., use_ecm=..., verbose=..., visual=..., multiple=...): - ... - -def factorrat(rat, limit=..., use_trial=..., use_rho=..., use_pm1=..., verbose=..., visual=..., multiple=...) -> list[Any] | dict[Any, int] | Order: - ... - -def primefactors(n, limit=..., verbose=...) -> list[Any]: - ... -def divisors(n, generator=..., proper=...) -> list[int] | list[Any] | list[Any | Literal[1]] | Generator[Any | Literal[1], Any, None]: - ... - -def divisor_count(n, modulus=..., proper=...) -> Order | Literal[0]: - ... - -def proper_divisors(n, generator=...) -> list[int] | list[Any] | list[Any | Literal[1]] | Generator[Any | Literal[1], Any, None]: - ... - -def proper_divisor_count(n, modulus=...) -> Order | Literal[0]: - ... - -def udivisors(n, generator=...) -> list[int] | list[Any] | list[Any | Literal[1]] | Generator[Any | Literal[1], Any, None]: - ... - -def udivisor_count(n) -> Any | Literal[0]: - ... - -def antidivisors(n, generator=...) -> list[Any] | list[Any | int] | Generator[Any | int, Any, None]: - ... - -def antidivisor_count(n) -> Literal[0]: - ... +def factorint(n, limit=..., use_trial=..., use_rho=..., use_pm1=..., use_ecm=..., verbose=..., visual=..., multiple=...): ... +def factorrat( + rat, limit=..., use_trial=..., use_rho=..., use_pm1=..., verbose=..., visual=..., multiple=... +) -> list[Any] | dict[Any, int] | Order: ... +def primefactors(n, limit=..., verbose=...) -> list[Any]: ... +def divisors( + n, generator=..., proper=... +) -> list[int] | list[Any] | list[Any | Literal[1]] | Generator[Any | Literal[1], Any, None]: ... +def divisor_count(n, modulus=..., proper=...) -> Order | Literal[0]: ... +def proper_divisors( + n, generator=... +) -> list[int] | list[Any] | list[Any | Literal[1]] | Generator[Any | Literal[1], Any, None]: ... +def proper_divisor_count(n, modulus=...) -> Order | Literal[0]: ... +def udivisors(n, generator=...) -> list[int] | list[Any] | list[Any | Literal[1]] | Generator[Any | Literal[1], Any, None]: ... +def udivisor_count(n) -> Any | Literal[0]: ... +def antidivisors(n, generator=...) -> list[Any] | list[Any | int] | Generator[Any | int, Any, None]: ... +def antidivisor_count(n) -> Literal[0]: ... class totient(Function): @classmethod - def eval(cls, n) -> Literal[1] | None: - ... - - + def eval(cls, n) -> Literal[1] | None: ... class reduced_totient(Function): @classmethod - def eval(cls, n) -> Literal[1, 0] | None: - ... - - + def eval(cls, n) -> Literal[1, 0] | None: ... class divisor_sigma(Function): @classmethod - def eval(cls, n, k=...) -> Integer | Order | None: - ... - - + def eval(cls, n, k=...) -> Integer | Order | None: ... -def core(n, t=...) -> Literal[1]: - ... +def core(n, t=...) -> Literal[1]: ... class udivisor_sigma(Function): @classmethod - def eval(cls, n, k=...) -> Order | None: - ... - - + def eval(cls, n, k=...) -> Order | None: ... class primenu(Function): @classmethod - def eval(cls, n) -> int | None: - ... - - + def eval(cls, n) -> int | None: ... class primeomega(Function): @classmethod - def eval(cls, n) -> int | None: - ... - - - -def mersenne_prime_exponent(nth) -> Literal[2, 3, 5, 7, 13, 17, 19, 31, 61, 89, 107, 127, 521, 607, 1279, 2203, 2281, 3217, 4253, 4423, 9689, 9941, 11213, 19937, 21701, 23209, 44497, 86243, 110503, 132049, 216091, 756839, 859433, 1257787, 1398269, 2976221, 3021377, 6972593, 13466917, 20996011, 24036583, 25964951, 30402457, 32582657, 37156667, 42643801, 43112609, 57885161, 74207281, 77232917, 82589933]: - ... - -def is_perfect(n) -> bool | None: - ... - -def is_mersenne_prime(n) -> bool: - ... - -def abundance(n): - ... - -def is_abundant(n) -> bool: - ... - -def is_deficient(n) -> bool: - ... - -def is_amicable(m, n) -> bool: - ... - -def dra(n, b) -> int: - ... - -def drm(n, b) -> int: - ... - + def eval(cls, n) -> int | None: ... + +def mersenne_prime_exponent( + nth, +) -> Literal[ + 2, + 3, + 5, + 7, + 13, + 17, + 19, + 31, + 61, + 89, + 107, + 127, + 521, + 607, + 1279, + 2203, + 2281, + 3217, + 4253, + 4423, + 9689, + 9941, + 11213, + 19937, + 21701, + 23209, + 44497, + 86243, + 110503, + 132049, + 216091, + 756839, + 859433, + 1257787, + 1398269, + 2976221, + 3021377, + 6972593, + 13466917, + 20996011, + 24036583, + 25964951, + 30402457, + 32582657, + 37156667, + 42643801, + 43112609, + 57885161, + 74207281, + 77232917, + 82589933, +]: ... +def is_perfect(n) -> bool | None: ... +def is_mersenne_prime(n) -> bool: ... +def abundance(n): ... +def is_abundant(n) -> bool: ... +def is_deficient(n) -> bool: ... +def is_amicable(m, n) -> bool: ... +def dra(n, b) -> int: ... +def drm(n, b) -> int: ... diff --git a/stubs/sympy-stubs/ntheory/generate.pyi b/stubs/sympy-stubs/ntheory/generate.pyi index 2a25dc44..7cf088fc 100644 --- a/stubs/sympy-stubs/ntheory/generate.pyi +++ b/stubs/sympy-stubs/ntheory/generate.pyi @@ -6,73 +6,31 @@ from sympy.core.function import UndefinedFunction from sympy.utilities.decorator import deprecated class Sieve: - def __init__(self) -> None: - ... - - def __repr__(self) -> str: - ... - - def extend(self, n) -> None: - ... - - def extend_to_no(self, i) -> None: - ... - - def primerange(self, a, b=...) -> Generator[Any, Any, None]: - ... - - def totientrange(self, a, b) -> Generator[int, Any, None]: - ... - - def mobiusrange(self, a, b) -> Generator[int, Any, None]: - ... - - def search(self, n) -> tuple[int, int]: - ... - - def __contains__(self, n) -> bool: - ... - - def __iter__(self) -> Generator[array[int] | int, Any, None]: - ... - - def __getitem__(self, n) -> array[int] | int: - ... - - + def __init__(self) -> None: ... + def __repr__(self) -> str: ... + def extend(self, n) -> None: ... + def extend_to_no(self, i) -> None: ... + def primerange(self, a, b=...) -> Generator[Any, Any, None]: ... + def totientrange(self, a, b) -> Generator[int, Any, None]: ... + def mobiusrange(self, a, b) -> Generator[int, Any, None]: ... + def search(self, n) -> tuple[int, int]: ... + def __contains__(self, n) -> bool: ... + def __iter__(self) -> Generator[array[int] | int, Any, None]: ... + def __getitem__(self, n) -> array[int] | int: ... sieve = ... -def prime(nth) -> array[int] | int: - ... + +def prime(nth) -> array[int] | int: ... class primepi(Function): @classmethod - def eval(cls, n) -> None: - ... - - - -def nextprime(n, ith=...) -> int | array[int] | None: - ... - -def prevprime(n) -> int | array[int] | None: - ... - -def primerange(a, b=...) -> Generator[Any | int | array[int] | None, Any, None]: - ... - -def randprime(a, b) -> int | array[int] | None: - ... - -def primorial(n, nth=...) -> array[int] | int: - ... - -def cycle_length(f, x0, nmax=..., values=...) -> Generator[Any | tuple[int, None] | tuple[int, int], Any, None]: - ... - -def composite(nth) -> int: - ... - -def compositepi(n) -> Literal[0]: - ... - + def eval(cls, n) -> None: ... + +def nextprime(n, ith=...) -> int | array[int] | None: ... +def prevprime(n) -> int | array[int] | None: ... +def primerange(a, b=...) -> Generator[Any | int | array[int] | None, Any, None]: ... +def randprime(a, b) -> int | array[int] | None: ... +def primorial(n, nth=...) -> array[int] | int: ... +def cycle_length(f, x0, nmax=..., values=...) -> Generator[Any | tuple[int, None] | tuple[int, int], Any, None]: ... +def composite(nth) -> int: ... +def compositepi(n) -> Literal[0]: ... diff --git a/stubs/sympy-stubs/ntheory/modular.pyi b/stubs/sympy-stubs/ntheory/modular.pyi index 65e705f9..7b38fc4d 100644 --- a/stubs/sympy-stubs/ntheory/modular.pyi +++ b/stubs/sympy-stubs/ntheory/modular.pyi @@ -1,17 +1,7 @@ from typing import Any -def symmetric_residue(a, m): - ... - -def crt(m, v, symmetric=..., check=...) -> tuple[Any, Any | int] | None: - ... - -def crt1(m) -> tuple[float, list[Any], list[Any]]: - ... - -def crt2(m, v, mm, e, s, symmetric=...) -> tuple[Any, Any]: - ... - -def solve_congruence(*remainder_modulus_pairs, **hint) -> tuple[Any, Any | int] | None: - ... - +def symmetric_residue(a, m): ... +def crt(m, v, symmetric=..., check=...) -> tuple[Any, Any | int] | None: ... +def crt1(m) -> tuple[float, list[Any], list[Any]]: ... +def crt2(m, v, mm, e, s, symmetric=...) -> tuple[Any, Any]: ... +def solve_congruence(*remainder_modulus_pairs, **hint) -> tuple[Any, Any | int] | None: ... diff --git a/stubs/sympy-stubs/ntheory/multinomial.pyi b/stubs/sympy-stubs/ntheory/multinomial.pyi index 2b09e6f3..0877e0a5 100644 --- a/stubs/sympy-stubs/ntheory/multinomial.pyi +++ b/stubs/sympy-stubs/ntheory/multinomial.pyi @@ -1,14 +1,14 @@ from typing import Any, Generator, Literal -def binomial_coefficients(n) -> dict[tuple[Literal[0], int] | tuple[int, Literal[0]], int]: - ... - -def binomial_coefficients_list(n) -> list[int]: - ... - -def multinomial_coefficients(m, n) -> dict[Any, Any] | dict[tuple[()], int] | dict[tuple[Literal[0], int] | tuple[int, Literal[0]], int] | dict[tuple[Any, ...], Any] | dict[tuple[int, ...], int]: - ... - -def multinomial_coefficients_iterator(m, n, _tuple=...) -> Generator[Any | tuple[tuple[Any, ...], Any], Any, None]: - ... - +def binomial_coefficients(n) -> dict[tuple[Literal[0], int] | tuple[int, Literal[0]], int]: ... +def binomial_coefficients_list(n) -> list[int]: ... +def multinomial_coefficients( + m, n +) -> ( + dict[Any, Any] + | dict[tuple[()], int] + | dict[tuple[Literal[0], int] | tuple[int, Literal[0]], int] + | dict[tuple[Any, ...], Any] + | dict[tuple[int, ...], int] +): ... +def multinomial_coefficients_iterator(m, n, _tuple=...) -> Generator[Any | tuple[tuple[Any, ...], Any], Any, None]: ... diff --git a/stubs/sympy-stubs/ntheory/partitions_.pyi b/stubs/sympy-stubs/ntheory/partitions_.pyi index fb166e7c..54606f4c 100644 --- a/stubs/sympy-stubs/ntheory/partitions_.pyi +++ b/stubs/sympy-stubs/ntheory/partitions_.pyi @@ -1,7 +1,6 @@ from sympy.core.function import UndefinedFunction from sympy.utilities.decorator import deprecated -def npartitions(n, verbose=...) -> int: - ... +def npartitions(n, verbose=...) -> int: ... -__all__ = ['npartitions'] +__all__ = ["npartitions"] diff --git a/stubs/sympy-stubs/ntheory/primetest.pyi b/stubs/sympy-stubs/ntheory/primetest.pyi index 1a770554..de8ec6c8 100644 --- a/stubs/sympy-stubs/ntheory/primetest.pyi +++ b/stubs/sympy-stubs/ntheory/primetest.pyi @@ -1,25 +1,8 @@ - -def is_euler_pseudoprime(n, b) -> bool: - ... - -def is_square(n, prep=...) -> bool: - ... - -def mr(n, bases) -> bool: - ... - -def is_lucas_prp(n) -> bool: - ... - -def is_strong_lucas_prp(n) -> bool: - ... - -def is_extra_strong_lucas_prp(n) -> bool: - ... - -def isprime(n) -> bool: - ... - -def is_gaussian_prime(num) -> bool: - ... - +def is_euler_pseudoprime(n, b) -> bool: ... +def is_square(n, prep=...) -> bool: ... +def mr(n, bases) -> bool: ... +def is_lucas_prp(n) -> bool: ... +def is_strong_lucas_prp(n) -> bool: ... +def is_extra_strong_lucas_prp(n) -> bool: ... +def isprime(n) -> bool: ... +def is_gaussian_prime(num) -> bool: ... diff --git a/stubs/sympy-stubs/ntheory/qs.pyi b/stubs/sympy-stubs/ntheory/qs.pyi index d7ccb762..f1787af2 100644 --- a/stubs/sympy-stubs/ntheory/qs.pyi +++ b/stubs/sympy-stubs/ntheory/qs.pyi @@ -1,21 +1,12 @@ from typing import Any, Literal rgen = ... -class SievePolynomial: - def __init__(self, modified_coeff=..., a=..., b=...) -> None: - ... - - def eval(self, x) -> Literal[0]: - ... - +class SievePolynomial: + def __init__(self, modified_coeff=..., a=..., b=...) -> None: ... + def eval(self, x) -> Literal[0]: ... class FactorBaseElem: - def __init__(self, prime, tmem_p, log_p) -> None: - ... - - - -def qs(N, prime_bound, M, ERROR_TERM=..., seed=...) -> set[Any]: - ... + def __init__(self, prime, tmem_p, log_p) -> None: ... +def qs(N, prime_bound, M, ERROR_TERM=..., seed=...) -> set[Any]: ... diff --git a/stubs/sympy-stubs/ntheory/residue_ntheory.pyi b/stubs/sympy-stubs/ntheory/residue_ntheory.pyi index e4ccbc1d..f25b8d0d 100644 --- a/stubs/sympy-stubs/ntheory/residue_ntheory.pyi +++ b/stubs/sympy-stubs/ntheory/residue_ntheory.pyi @@ -4,52 +4,22 @@ from sympy import Function from sympy.core.function import UndefinedFunction from sympy.utilities.decorator import deprecated -def n_order(a, n) -> Literal[1]: - ... - -def primitive_root(p) -> int | None: - ... - -def is_primitive_root(a, p) -> bool: - ... - -def sqrt_mod(a, p, all_roots=...) -> list[Any | int] | Any | int | None: - ... - -def sqrt_mod_iter(a, p, domain=...) -> Generator[Any | int, Any, None]: - ... - -def is_quad_residue(a, p) -> bool: - ... - -def is_nthpow_residue(a, n, m) -> bool: - ... - -def nthroot_mod(a, n, p, all_roots=...) -> list[Any | int] | Any | int | list[Any] | list[int] | list[int | Any] | None: - ... - -def quadratic_residues(p) -> list[int]: - ... - -def legendre_symbol(a, p) -> Literal[0, 1, -1]: - ... - -def jacobi_symbol(m, n) -> int: - ... +def n_order(a, n) -> Literal[1]: ... +def primitive_root(p) -> int | None: ... +def is_primitive_root(a, p) -> bool: ... +def sqrt_mod(a, p, all_roots=...) -> list[Any | int] | Any | int | None: ... +def sqrt_mod_iter(a, p, domain=...) -> Generator[Any | int, Any, None]: ... +def is_quad_residue(a, p) -> bool: ... +def is_nthpow_residue(a, n, m) -> bool: ... +def nthroot_mod(a, n, p, all_roots=...) -> list[Any | int] | Any | int | list[Any] | list[int] | list[int | Any] | None: ... +def quadratic_residues(p) -> list[int]: ... +def legendre_symbol(a, p) -> Literal[0, 1, -1]: ... +def jacobi_symbol(m, n) -> int: ... class mobius(Function): @classmethod - def eval(cls, n) -> None: - ... - - - -def discrete_log(n, a, b, order=..., prime_order=...) -> int: - ... - -def quadratic_congruence(a, b, c, p) -> list[int] | list[Any]: - ... - -def polynomial_congruence(expr, m) -> list[Any | int] | Any | int | list[Any] | list[int] | list[int | Any] | None: - ... + def eval(cls, n) -> None: ... +def discrete_log(n, a, b, order=..., prime_order=...) -> int: ... +def quadratic_congruence(a, b, c, p) -> list[int] | list[Any]: ... +def polynomial_congruence(expr, m) -> list[Any | int] | Any | int | list[Any] | list[int] | list[int | Any] | None: ... diff --git a/stubs/sympy-stubs/parsing/__init__.pyi b/stubs/sympy-stubs/parsing/__init__.pyi index 9ae0931a..3a1c7b22 100644 --- a/stubs/sympy-stubs/parsing/__init__.pyi +++ b/stubs/sympy-stubs/parsing/__init__.pyi @@ -1,3 +1,3 @@ from sympy.parsing.sympy_parser import parse_expr -__all__ = ['parse_expr'] +__all__ = ["parse_expr"] diff --git a/stubs/sympy-stubs/parsing/sympy_parser.pyi b/stubs/sympy-stubs/parsing/sympy_parser.pyi index da8e4146..4deb61e5 100644 --- a/stubs/sympy-stubs/parsing/sympy_parser.pyi +++ b/stubs/sympy-stubs/parsing/sympy_parser.pyi @@ -5,108 +5,60 @@ null = ... TOKEN = tTuple[int, str] DICT = tDict[str, Any] TRANS = Callable[[List[TOKEN], DICT, DICT], List[TOKEN]] -class ParenthesisGroup(List[TOKEN]): - ... +class ParenthesisGroup(List[TOKEN]): ... class AppliedFunction: - def __init__(self, function: TOKEN, args: ParenthesisGroup, exponent=...) -> None: - ... - - def expand(self) -> List[TOKEN]: - ... - - def __getitem__(self, index) -> Any: - ... - - def __repr__(self) -> str: - ... - + def __init__(self, function: TOKEN, args: ParenthesisGroup, exponent=...) -> None: ... + def expand(self) -> List[TOKEN]: ... + def __getitem__(self, index) -> Any: ... + def __repr__(self) -> str: ... - -def function_exponentiation(tokens: List[TOKEN], local_dict: DICT, global_dict: DICT) -> list[TOKEN]: - ... - -def split_symbols_custom(predicate: Callable[[str], bool]) -> Callable[..., list[TOKEN]]: - ... +def function_exponentiation(tokens: List[TOKEN], local_dict: DICT, global_dict: DICT) -> list[TOKEN]: ... +def split_symbols_custom(predicate: Callable[[str], bool]) -> Callable[..., list[TOKEN]]: ... split_symbols = ... -def implicit_multiplication(tokens: List[TOKEN], local_dict: DICT, global_dict: DICT) -> List[TOKEN]: - ... - -def implicit_application(tokens: List[TOKEN], local_dict: DICT, global_dict: DICT) -> List[TOKEN]: - ... - -def implicit_multiplication_application(result: List[TOKEN], local_dict: DICT, global_dict: DICT) -> List[TOKEN]: - ... - -def auto_symbol(tokens: List[TOKEN], local_dict: DICT, global_dict: DICT) -> list[TOKEN]: - ... - -def lambda_notation(tokens: List[TOKEN], local_dict: DICT, global_dict: DICT) -> list[TOKEN]: - ... - -def factorial_notation(tokens: List[TOKEN], local_dict: DICT, global_dict: DICT) -> list[TOKEN]: - ... - -def convert_xor(tokens: List[TOKEN], local_dict: DICT, global_dict: DICT) -> list[TOKEN]: - ... -def repeated_decimals(tokens: List[TOKEN], local_dict: DICT, global_dict: DICT) -> list[TOKEN]: - ... - -def auto_number(tokens: List[TOKEN], local_dict: DICT, global_dict: DICT) -> list[TOKEN]: - ... - -def rationalize(tokens: List[TOKEN], local_dict: DICT, global_dict: DICT) -> list[TOKEN]: - ... - -def convert_equals_signs(tokens: List[TOKEN], local_dict: DICT, global_dict: DICT) -> List[TOKEN]: - ... +def implicit_multiplication(tokens: List[TOKEN], local_dict: DICT, global_dict: DICT) -> List[TOKEN]: ... +def implicit_application(tokens: List[TOKEN], local_dict: DICT, global_dict: DICT) -> List[TOKEN]: ... +def implicit_multiplication_application(result: List[TOKEN], local_dict: DICT, global_dict: DICT) -> List[TOKEN]: ... +def auto_symbol(tokens: List[TOKEN], local_dict: DICT, global_dict: DICT) -> list[TOKEN]: ... +def lambda_notation(tokens: List[TOKEN], local_dict: DICT, global_dict: DICT) -> list[TOKEN]: ... +def factorial_notation(tokens: List[TOKEN], local_dict: DICT, global_dict: DICT) -> list[TOKEN]: ... +def convert_xor(tokens: List[TOKEN], local_dict: DICT, global_dict: DICT) -> list[TOKEN]: ... +def repeated_decimals(tokens: List[TOKEN], local_dict: DICT, global_dict: DICT) -> list[TOKEN]: ... +def auto_number(tokens: List[TOKEN], local_dict: DICT, global_dict: DICT) -> list[TOKEN]: ... +def rationalize(tokens: List[TOKEN], local_dict: DICT, global_dict: DICT) -> list[TOKEN]: ... +def convert_equals_signs(tokens: List[TOKEN], local_dict: DICT, global_dict: DICT) -> List[TOKEN]: ... standard_transformations: tTuple[TRANS, ...] = ... -def stringify_expr(s: str, local_dict: DICT, global_dict: DICT, transformations: tTuple[TRANS, ...]) -> str: - ... - -def eval_expr(code, local_dict: DICT, global_dict: DICT) -> Any: - ... -def parse_expr(s: str, local_dict: Optional[DICT] = ..., transformations: tUnion[tTuple[TRANS, ...], str] = ..., global_dict: Optional[DICT] = ..., evaluate=...) -> Any: - ... - -def evaluateFalse(s: str) -> ast.Expression: - ... +def stringify_expr(s: str, local_dict: DICT, global_dict: DICT, transformations: tTuple[TRANS, ...]) -> str: ... +def eval_expr(code, local_dict: DICT, global_dict: DICT) -> Any: ... +def parse_expr( + s: str, + local_dict: Optional[DICT] = ..., + transformations: tUnion[tTuple[TRANS, ...], str] = ..., + global_dict: Optional[DICT] = ..., + evaluate=..., +) -> Any: ... +def evaluateFalse(s: str) -> ast.Expression: ... class EvaluateFalseTransformer(ast.NodeTransformer): operators = ... functions = ... relational_operators = ... - def visit_Compare(self, node) -> ast.Call | ast.Compare: - ... - - def flatten(self, args, func) -> list[Any]: - ... - - def visit_BinOp(self, node) -> ast.Call | ast.BinOp: - ... - - def visit_Call(self, node) -> ast.AST: - ... - - + def visit_Compare(self, node) -> ast.Call | ast.Compare: ... + def flatten(self, args, func) -> list[Any]: ... + def visit_BinOp(self, node) -> ast.Call | ast.BinOp: ... + def visit_Call(self, node) -> ast.AST: ... _transformation = ... transformations = ... -class _T: - def __init__(self) -> None: - ... - - def __str__(self) -> str: - ... - - def __getitem__(self, t) -> tuple[Any, ...]: - ... - +class _T: + def __init__(self) -> None: ... + def __str__(self) -> str: ... + def __getitem__(self, t) -> tuple[Any, ...]: ... T = ... diff --git a/stubs/sympy-stubs/physics/__init__.pyi b/stubs/sympy-stubs/physics/__init__.pyi index 12b8fe8a..3b560fd8 100644 --- a/stubs/sympy-stubs/physics/__init__.pyi +++ b/stubs/sympy-stubs/physics/__init__.pyi @@ -1,4 +1,4 @@ from sympy.physics import units from sympy.physics.matrices import mdft, mgamma, minkowski_tensor, msigma -__all__ = ['units', 'mgamma', 'msigma', 'minkowski_tensor', 'mdft'] +__all__ = ["units", "mgamma", "msigma", "minkowski_tensor", "mdft"] diff --git a/stubs/sympy-stubs/physics/control/__init__.pyi b/stubs/sympy-stubs/physics/control/__init__.pyi index 6f80fc82..4b446657 100644 --- a/stubs/sympy-stubs/physics/control/__init__.pyi +++ b/stubs/sympy-stubs/physics/control/__init__.pyi @@ -26,4 +26,28 @@ from sympy.physics.control.lti import ( bilinear, ) -__all__ = ['TransferFunction', 'Series', 'MIMOSeries', 'Parallel', 'MIMOParallel', 'Feedback', 'MIMOFeedback', 'TransferFunctionMatrix', 'bilinear', 'backward_diff', 'pole_zero_numerical_data', 'pole_zero_plot', 'step_response_numerical_data', 'step_response_plot', 'impulse_response_numerical_data', 'impulse_response_plot', 'ramp_response_numerical_data', 'ramp_response_plot', 'bode_magnitude_numerical_data', 'bode_phase_numerical_data', 'bode_magnitude_plot', 'bode_phase_plot', 'bode_plot'] +__all__ = [ + "TransferFunction", + "Series", + "MIMOSeries", + "Parallel", + "MIMOParallel", + "Feedback", + "MIMOFeedback", + "TransferFunctionMatrix", + "bilinear", + "backward_diff", + "pole_zero_numerical_data", + "pole_zero_plot", + "step_response_numerical_data", + "step_response_plot", + "impulse_response_numerical_data", + "impulse_response_plot", + "ramp_response_numerical_data", + "ramp_response_plot", + "bode_magnitude_numerical_data", + "bode_phase_numerical_data", + "bode_magnitude_plot", + "bode_phase_plot", + "bode_plot", +] diff --git a/stubs/sympy-stubs/physics/control/control_plots.pyi b/stubs/sympy-stubs/physics/control/control_plots.pyi index 0160bd17..2f157dd1 100644 --- a/stubs/sympy-stubs/physics/control/control_plots.pyi +++ b/stubs/sympy-stubs/physics/control/control_plots.pyi @@ -1,48 +1,61 @@ from typing import Any -__all__ = ['pole_zero_numerical_data', 'pole_zero_plot', 'step_response_numerical_data', 'step_response_plot', 'impulse_response_numerical_data', 'impulse_response_plot', 'ramp_response_numerical_data', 'ramp_response_plot', 'bode_magnitude_numerical_data', 'bode_phase_numerical_data', 'bode_magnitude_plot', 'bode_phase_plot', 'bode_plot'] +__all__ = [ + "pole_zero_numerical_data", + "pole_zero_plot", + "step_response_numerical_data", + "step_response_plot", + "impulse_response_numerical_data", + "impulse_response_plot", + "ramp_response_numerical_data", + "ramp_response_plot", + "bode_magnitude_numerical_data", + "bode_phase_numerical_data", + "bode_magnitude_plot", + "bode_phase_plot", + "bode_plot", +] matplotlib = ... numpy = ... if matplotlib: plt = ... if numpy: np = ... -def pole_zero_numerical_data(system) -> tuple[Any, Any]: - ... - -def pole_zero_plot(system, pole_color=..., pole_markersize=..., zero_color=..., zero_markersize=..., grid=..., show_axes=..., show=..., **kwargs) -> None: - ... - -def step_response_numerical_data(system, prec=..., lower_limit=..., upper_limit=..., **kwargs) -> tuple[Any, Any] | tuple[list[Any], list[Any]]: - ... - -def step_response_plot(system, color=..., prec=..., lower_limit=..., upper_limit=..., show_axes=..., grid=..., show=..., **kwargs) -> None: - ... - -def impulse_response_numerical_data(system, prec=..., lower_limit=..., upper_limit=..., **kwargs) -> tuple[Any, Any] | tuple[list[Any], list[Any]]: - ... - -def impulse_response_plot(system, color=..., prec=..., lower_limit=..., upper_limit=..., show_axes=..., grid=..., show=..., **kwargs) -> None: - ... - -def ramp_response_numerical_data(system, slope=..., prec=..., lower_limit=..., upper_limit=..., **kwargs) -> tuple[Any, Any] | tuple[list[Any], list[Any]]: - ... - -def ramp_response_plot(system, slope=..., color=..., prec=..., lower_limit=..., upper_limit=..., show_axes=..., grid=..., show=..., **kwargs) -> None: - ... - -def bode_magnitude_numerical_data(system, initial_exp=..., final_exp=..., freq_unit=..., **kwargs) -> tuple[Any | list[Any], Any | list[Any]]: - ... - -def bode_magnitude_plot(system, initial_exp=..., final_exp=..., color=..., show_axes=..., grid=..., show=..., freq_unit=..., **kwargs) -> None: - ... - -def bode_phase_numerical_data(system, initial_exp=..., final_exp=..., freq_unit=..., phase_unit=..., **kwargs) -> tuple[Any | list[Any], Any | list[Any]]: - ... - -def bode_phase_plot(system, initial_exp=..., final_exp=..., color=..., show_axes=..., grid=..., show=..., freq_unit=..., phase_unit=..., **kwargs) -> None: - ... - -def bode_plot(system, initial_exp=..., final_exp=..., grid=..., show_axes=..., show=..., freq_unit=..., phase_unit=..., **kwargs) -> None: - ... +def pole_zero_numerical_data(system) -> tuple[Any, Any]: ... +def pole_zero_plot( + system, pole_color=..., pole_markersize=..., zero_color=..., zero_markersize=..., grid=..., show_axes=..., show=..., **kwargs +) -> None: ... +def step_response_numerical_data( + system, prec=..., lower_limit=..., upper_limit=..., **kwargs +) -> tuple[Any, Any] | tuple[list[Any], list[Any]]: ... +def step_response_plot( + system, color=..., prec=..., lower_limit=..., upper_limit=..., show_axes=..., grid=..., show=..., **kwargs +) -> None: ... +def impulse_response_numerical_data( + system, prec=..., lower_limit=..., upper_limit=..., **kwargs +) -> tuple[Any, Any] | tuple[list[Any], list[Any]]: ... +def impulse_response_plot( + system, color=..., prec=..., lower_limit=..., upper_limit=..., show_axes=..., grid=..., show=..., **kwargs +) -> None: ... +def ramp_response_numerical_data( + system, slope=..., prec=..., lower_limit=..., upper_limit=..., **kwargs +) -> tuple[Any, Any] | tuple[list[Any], list[Any]]: ... +def ramp_response_plot( + system, slope=..., color=..., prec=..., lower_limit=..., upper_limit=..., show_axes=..., grid=..., show=..., **kwargs +) -> None: ... +def bode_magnitude_numerical_data( + system, initial_exp=..., final_exp=..., freq_unit=..., **kwargs +) -> tuple[Any | list[Any], Any | list[Any]]: ... +def bode_magnitude_plot( + system, initial_exp=..., final_exp=..., color=..., show_axes=..., grid=..., show=..., freq_unit=..., **kwargs +) -> None: ... +def bode_phase_numerical_data( + system, initial_exp=..., final_exp=..., freq_unit=..., phase_unit=..., **kwargs +) -> tuple[Any | list[Any], Any | list[Any]]: ... +def bode_phase_plot( + system, initial_exp=..., final_exp=..., color=..., show_axes=..., grid=..., show=..., freq_unit=..., phase_unit=..., **kwargs +) -> None: ... +def bode_plot( + system, initial_exp=..., final_exp=..., grid=..., show_axes=..., show=..., freq_unit=..., phase_unit=..., **kwargs +) -> None: ... diff --git a/stubs/sympy-stubs/physics/control/lti.pyi b/stubs/sympy-stubs/physics/control/lti.pyi index 7533488c..0831a84f 100644 --- a/stubs/sympy-stubs/physics/control/lti.pyi +++ b/stubs/sympy-stubs/physics/control/lti.pyi @@ -6,417 +6,214 @@ from sympy.core.evalf import EvalfMixin from sympy.core.power import Pow from sympy.series.order import Order -__all__ = ['TransferFunction', 'Series', 'MIMOSeries', 'Parallel', 'MIMOParallel', 'Feedback', 'MIMOFeedback', 'TransferFunctionMatrix', 'bilinear', 'backward_diff'] -def bilinear(tf, sample_per) -> tuple[Any, Any]: - ... - -def backward_diff(tf, sample_per) -> tuple[Any, Any]: - ... +__all__ = [ + "TransferFunction", + "Series", + "MIMOSeries", + "Parallel", + "MIMOParallel", + "Feedback", + "MIMOFeedback", + "TransferFunctionMatrix", + "bilinear", + "backward_diff", +] + +def bilinear(tf, sample_per) -> tuple[Any, Any]: ... +def backward_diff(tf, sample_per) -> tuple[Any, Any]: ... class LinearTimeInvariant(Basic, EvalfMixin): _clstype: Type - def __new__(cls, *system, **kwargs) -> Self: - ... - + def __new__(cls, *system, **kwargs) -> Self: ... @property - def is_SISO(self): - ... - - + def is_SISO(self): ... class SISOLinearTimeInvariant(LinearTimeInvariant): _is_SISO = ... - class MIMOLinearTimeInvariant(LinearTimeInvariant): _is_SISO = ... -def _check_other_SISO(func) -> Callable[..., NotImplementedType | Any]: - ... - -def _check_other_MIMO(func) -> Callable[..., NotImplementedType | Any]: - ... +def _check_other_SISO(func) -> Callable[..., NotImplementedType | Any]: ... +def _check_other_MIMO(func) -> Callable[..., NotImplementedType | Any]: ... class TransferFunction(SISOLinearTimeInvariant): - def __new__(cls, num, den, var) -> Self: - ... - + def __new__(cls, num, den, var) -> Self: ... @classmethod - def from_rational_expression(cls, expr, var=...) -> Self: - ... - - @property - def num(self): - ... - - @property - def den(self): - ... - - @property - def var(self): - ... - - def expand(self) -> TransferFunction: - ... - - def dc_gain(self): - ... - - def poles(self) -> list[Any] | Any: - ... - - def zeros(self) -> list[Any] | Any: - ... - - def is_stable(self) -> bool | None: - ... - - def __add__(self, other) -> TransferFunction | Parallel: - ... - - def __radd__(self, other): - ... - - def __sub__(self, other) -> TransferFunction | Parallel: - ... - - def __rsub__(self, other): - ... - - def __mul__(self, other) -> TransferFunction | Series: - ... - + def from_rational_expression(cls, expr, var=...) -> Self: ... + @property + def num(self): ... + @property + def den(self): ... + @property + def var(self): ... + def expand(self) -> TransferFunction: ... + def dc_gain(self): ... + def poles(self) -> list[Any] | Any: ... + def zeros(self) -> list[Any] | Any: ... + def is_stable(self) -> bool | None: ... + def __add__(self, other) -> TransferFunction | Parallel: ... + def __radd__(self, other): ... + def __sub__(self, other) -> TransferFunction | Parallel: ... + def __rsub__(self, other): ... + def __mul__(self, other) -> TransferFunction | Series: ... + __rmul__ = ... - def __truediv__(self, other) -> Feedback: - ... - - __rtruediv__ = ... - def __pow__(self, p) -> TransferFunction: - ... - - def __neg__(self) -> TransferFunction: - ... - - @property - def is_proper(self) -> Any: - ... - - @property - def is_strictly_proper(self) -> Any: - ... - - @property - def is_biproper(self) -> Any: - ... - - def to_expr(self) -> Order | Pow: - ... - + def __truediv__(self, other) -> Feedback: ... + __rtruediv__ = ... + def __pow__(self, p) -> TransferFunction: ... + def __neg__(self) -> TransferFunction: ... + @property + def is_proper(self) -> Any: ... + @property + def is_strictly_proper(self) -> Any: ... + @property + def is_biproper(self) -> Any: ... + def to_expr(self) -> Order | Pow: ... class Series(SISOLinearTimeInvariant): - def __new__(cls, *args, evaluate=...) -> TransferFunction | Self: - ... - - @property - def var(self): - ... - - def doit(self, **hints) -> TransferFunction: - ... - + def __new__(cls, *args, evaluate=...) -> TransferFunction | Self: ... + @property + def var(self): ... + def doit(self, **hints) -> TransferFunction: ... @_check_other_SISO - def __add__(self, other) -> TransferFunction | Parallel: - ... - + def __add__(self, other) -> TransferFunction | Parallel: ... + __radd__ = ... @_check_other_SISO - def __sub__(self, other): - ... - - def __rsub__(self, other): - ... - + def __sub__(self, other): ... + def __rsub__(self, other): ... @_check_other_SISO - def __mul__(self, other) -> TransferFunction | Series: - ... - - def __truediv__(self, other) -> Feedback: - ... - - def __neg__(self) -> TransferFunction | Series: - ... - - def to_expr(self) -> Order: - ... - - @property - def is_proper(self) -> Any: - ... - - @property - def is_strictly_proper(self) -> Any: - ... - - @property - def is_biproper(self) -> Any: - ... - - + def __mul__(self, other) -> TransferFunction | Series: ... + def __truediv__(self, other) -> Feedback: ... + def __neg__(self) -> TransferFunction | Series: ... + def to_expr(self) -> Order: ... + @property + def is_proper(self) -> Any: ... + @property + def is_strictly_proper(self) -> Any: ... + @property + def is_biproper(self) -> Any: ... class MIMOSeries(MIMOLinearTimeInvariant): - def __new__(cls, *args, evaluate=...) -> TransferFunctionMatrix | Basic | Self: - ... - - @property - def var(self): - ... - - @property - def num_inputs(self): - ... - - @property - def num_outputs(self): - ... - - @property - def shape(self) -> tuple[Any, Any]: - ... - - def doit(self, cancel=..., **kwargs) -> TransferFunctionMatrix | Basic: - ... - + def __new__(cls, *args, evaluate=...) -> TransferFunctionMatrix | Basic | Self: ... + @property + def var(self): ... + @property + def num_inputs(self): ... + @property + def num_outputs(self): ... + @property + def shape(self) -> tuple[Any, Any]: ... + def doit(self, cancel=..., **kwargs) -> TransferFunctionMatrix | Basic: ... @_check_other_MIMO - def __add__(self, other) -> TransferFunctionMatrix | MIMOParallel: - ... - + def __add__(self, other) -> TransferFunctionMatrix | MIMOParallel: ... + __radd__ = ... @_check_other_MIMO - def __sub__(self, other): - ... - - def __rsub__(self, other): - ... - + def __sub__(self, other): ... + def __rsub__(self, other): ... @_check_other_MIMO - def __mul__(self, other) -> TransferFunctionMatrix | Basic | MIMOSeries: - ... - - def __neg__(self) -> TransferFunctionMatrix | Basic | MIMOSeries: - ... - - + def __mul__(self, other) -> TransferFunctionMatrix | Basic | MIMOSeries: ... + def __neg__(self) -> TransferFunctionMatrix | Basic | MIMOSeries: ... class Parallel(SISOLinearTimeInvariant): - def __new__(cls, *args, evaluate=...) -> TransferFunction | Self: - ... - - @property - def var(self): - ... - - def doit(self, **hints) -> TransferFunction: - ... - + def __new__(cls, *args, evaluate=...) -> TransferFunction | Self: ... + @property + def var(self): ... + def doit(self, **hints) -> TransferFunction: ... @_check_other_SISO - def __add__(self, other) -> TransferFunction | Parallel: - ... - + def __add__(self, other) -> TransferFunction | Parallel: ... + __radd__ = ... @_check_other_SISO - def __sub__(self, other): - ... - - def __rsub__(self, other): - ... - + def __sub__(self, other): ... + def __rsub__(self, other): ... @_check_other_SISO - def __mul__(self, other) -> TransferFunction | Series: - ... - - def __neg__(self) -> TransferFunction | Series: - ... - - def to_expr(self) -> Order: - ... - - @property - def is_proper(self) -> Any: - ... - - @property - def is_strictly_proper(self) -> Any: - ... - - @property - def is_biproper(self) -> Any: - ... - - + def __mul__(self, other) -> TransferFunction | Series: ... + def __neg__(self) -> TransferFunction | Series: ... + def to_expr(self) -> Order: ... + @property + def is_proper(self) -> Any: ... + @property + def is_strictly_proper(self) -> Any: ... + @property + def is_biproper(self) -> Any: ... class MIMOParallel(MIMOLinearTimeInvariant): - def __new__(cls, *args, evaluate=...) -> TransferFunctionMatrix | Self: - ... - - @property - def var(self): - ... - - @property - def num_inputs(self): - ... - - @property - def num_outputs(self): - ... - - @property - def shape(self) -> tuple[Any, Any]: - ... - - def doit(self, **hints) -> TransferFunctionMatrix: - ... - + def __new__(cls, *args, evaluate=...) -> TransferFunctionMatrix | Self: ... + @property + def var(self): ... + @property + def num_inputs(self): ... + @property + def num_outputs(self): ... + @property + def shape(self) -> tuple[Any, Any]: ... + def doit(self, **hints) -> TransferFunctionMatrix: ... @_check_other_MIMO - def __add__(self, other) -> TransferFunctionMatrix | MIMOParallel: - ... - + def __add__(self, other) -> TransferFunctionMatrix | MIMOParallel: ... + __radd__ = ... @_check_other_MIMO - def __sub__(self, other): - ... - - def __rsub__(self, other): - ... - + def __sub__(self, other): ... + def __rsub__(self, other): ... @_check_other_MIMO - def __mul__(self, other) -> TransferFunctionMatrix | Basic | MIMOSeries: - ... - - def __neg__(self) -> TransferFunctionMatrix | MIMOParallel: - ... - - + def __mul__(self, other) -> TransferFunctionMatrix | Basic | MIMOSeries: ... + def __neg__(self) -> TransferFunctionMatrix | MIMOParallel: ... class Feedback(SISOLinearTimeInvariant): - def __new__(cls, sys1, sys2=..., sign=...) -> Self: - ... - - @property - def sys1(self) -> Basic: - ... - - @property - def sys2(self) -> Basic: - ... - - @property - def var(self): - ... - - @property - def sign(self) -> Basic: - ... - - @property - def sensitivity(self): - ... - - def doit(self, cancel=..., expand=..., **hints) -> TransferFunction: - ... - - def __neg__(self) -> Feedback: - ... - - + def __new__(cls, sys1, sys2=..., sign=...) -> Self: ... + @property + def sys1(self) -> Basic: ... + @property + def sys2(self) -> Basic: ... + @property + def var(self): ... + @property + def sign(self) -> Basic: ... + @property + def sensitivity(self): ... + def doit(self, cancel=..., expand=..., **hints) -> TransferFunction: ... + def __neg__(self) -> Feedback: ... class MIMOFeedback(MIMOLinearTimeInvariant): - def __new__(cls, sys1, sys2, sign=...) -> Self: - ... - - @property - def sys1(self) -> Basic: - ... - - @property - def sys2(self) -> Basic: - ... - - @property - def var(self): - ... - - @property - def sign(self) -> Basic: - ... - - @property - def sensitivity(self): - ... - - def doit(self, cancel=..., expand=..., **hints) -> TransferFunctionMatrix: - ... - - def __neg__(self) -> MIMOFeedback: - ... - - + def __new__(cls, sys1, sys2, sign=...) -> Self: ... + @property + def sys1(self) -> Basic: ... + @property + def sys2(self) -> Basic: ... + @property + def var(self): ... + @property + def sign(self) -> Basic: ... + @property + def sensitivity(self): ... + def doit(self, cancel=..., expand=..., **hints) -> TransferFunctionMatrix: ... + def __neg__(self) -> MIMOFeedback: ... class TransferFunctionMatrix(MIMOLinearTimeInvariant): - def __new__(cls, arg) -> Self: - ... - + def __new__(cls, arg) -> Self: ... @classmethod - def from_Matrix(cls, matrix, var) -> TransferFunctionMatrix: - ... - - @property - def var(self): - ... - - @property - def num_inputs(self): - ... - - @property - def num_outputs(self): - ... - - @property - def shape(self): - ... - - def __neg__(self) -> TransferFunctionMatrix: - ... - + def from_Matrix(cls, matrix, var) -> TransferFunctionMatrix: ... + @property + def var(self): ... + @property + def num_inputs(self): ... + @property + def num_outputs(self): ... + @property + def shape(self): ... + def __neg__(self) -> TransferFunctionMatrix: ... @_check_other_MIMO - def __add__(self, other) -> TransferFunctionMatrix | MIMOParallel: - ... - + def __add__(self, other) -> TransferFunctionMatrix | MIMOParallel: ... @_check_other_MIMO - def __sub__(self, other): - ... - + def __sub__(self, other): ... @_check_other_MIMO - def __mul__(self, other) -> TransferFunctionMatrix | Basic | MIMOSeries: - ... - - def __getitem__(self, key) -> TransferFunctionMatrix | TransferFunction: - ... - - def transpose(self) -> TransferFunctionMatrix: - ... - - def elem_poles(self) -> list[list[Any]]: - ... - - def elem_zeros(self) -> list[list[Any]]: - ... - - def expand(self, **hints) -> TransferFunctionMatrix: - ... - - - + def __mul__(self, other) -> TransferFunctionMatrix | Basic | MIMOSeries: ... + def __getitem__(self, key) -> TransferFunctionMatrix | TransferFunction: ... + def transpose(self) -> TransferFunctionMatrix: ... + def elem_poles(self) -> list[list[Any]]: ... + def elem_zeros(self) -> list[list[Any]]: ... + def expand(self, **hints) -> TransferFunctionMatrix: ... diff --git a/stubs/sympy-stubs/physics/matrices.pyi b/stubs/sympy-stubs/physics/matrices.pyi index ab68b7e9..393ae9ab 100644 --- a/stubs/sympy-stubs/physics/matrices.pyi +++ b/stubs/sympy-stubs/physics/matrices.pyi @@ -2,16 +2,10 @@ from sympy.matrices import Matrix from sympy.matrices.dense import MutableDenseMatrix from sympy.utilities.decorator import deprecated -def msigma(i) -> MutableDenseMatrix: - ... - -def pat_matrix(m, dx, dy, dz): - ... - -def mgamma(mu, lower=...) -> MutableDenseMatrix: - ... +def msigma(i) -> MutableDenseMatrix: ... +def pat_matrix(m, dx, dy, dz): ... +def mgamma(mu, lower=...) -> MutableDenseMatrix: ... minkowski_tensor = ... -def mdft(n) -> Matrix: - ... +def mdft(n) -> Matrix: ... diff --git a/stubs/sympy-stubs/physics/units/__init__.pyi b/stubs/sympy-stubs/physics/units/__init__.pyi index f21cb7a1..8c3ed256 100644 --- a/stubs/sympy-stubs/physics/units/__init__.pyi +++ b/stubs/sympy-stubs/physics/units/__init__.pyi @@ -363,7 +363,369 @@ speed = ... luminosity = ... magnetic_flux_density = ... amount = ... -def find_unit(quantity, unit_system=...) -> list[str]: - ... -__all__ = ['Dimension', 'DimensionSystem', 'UnitSystem', 'convert_to', 'Quantity', 'amount_of_substance', 'acceleration', 'action', 'area', 'capacitance', 'charge', 'conductance', 'current', 'energy', 'force', 'frequency', 'impedance', 'inductance', 'length', 'luminous_intensity', 'magnetic_density', 'magnetic_flux', 'mass', 'momentum', 'power', 'pressure', 'temperature', 'time', 'velocity', 'voltage', 'volume', 'Unit', 'speed', 'luminosity', 'magnetic_flux_density', 'amount', 'yotta', 'zetta', 'exa', 'peta', 'tera', 'giga', 'mega', 'kilo', 'hecto', 'deca', 'deci', 'centi', 'milli', 'micro', 'nano', 'pico', 'femto', 'atto', 'zepto', 'yocto', 'kibi', 'mebi', 'gibi', 'tebi', 'pebi', 'exbi', 'percent', 'percents', 'permille', 'rad', 'radian', 'radians', 'deg', 'degree', 'degrees', 'sr', 'steradian', 'steradians', 'mil', 'angular_mil', 'angular_mils', 'm', 'meter', 'meters', 'kg', 'kilogram', 'kilograms', 's', 'second', 'seconds', 'A', 'ampere', 'amperes', 'K', 'kelvin', 'kelvins', 'mol', 'mole', 'moles', 'cd', 'candela', 'candelas', 'g', 'gram', 'grams', 'mg', 'milligram', 'milligrams', 'ug', 'microgram', 'micrograms', 't', 'tonne', 'metric_ton', 'newton', 'newtons', 'N', 'joule', 'joules', 'J', 'watt', 'watts', 'W', 'pascal', 'pascals', 'Pa', 'pa', 'hertz', 'hz', 'Hz', 'coulomb', 'coulombs', 'C', 'volt', 'volts', 'v', 'V', 'ohm', 'ohms', 'siemens', 'S', 'mho', 'mhos', 'farad', 'farads', 'F', 'henry', 'henrys', 'H', 'tesla', 'teslas', 'T', 'weber', 'webers', 'Wb', 'wb', 'optical_power', 'dioptre', 'D', 'lux', 'lx', 'katal', 'kat', 'gray', 'Gy', 'becquerel', 'Bq', 'km', 'kilometer', 'kilometers', 'dm', 'decimeter', 'decimeters', 'cm', 'centimeter', 'centimeters', 'mm', 'millimeter', 'millimeters', 'um', 'micrometer', 'micrometers', 'micron', 'microns', 'nm', 'nanometer', 'nanometers', 'pm', 'picometer', 'picometers', 'ft', 'foot', 'feet', 'inch', 'inches', 'yd', 'yard', 'yards', 'mi', 'mile', 'miles', 'nmi', 'nautical_mile', 'nautical_miles', 'angstrom', 'angstroms', 'ha', 'hectare', 'l', 'L', 'liter', 'liters', 'dl', 'dL', 'deciliter', 'deciliters', 'cl', 'cL', 'centiliter', 'centiliters', 'ml', 'mL', 'milliliter', 'milliliters', 'ms', 'millisecond', 'milliseconds', 'us', 'microsecond', 'microseconds', 'ns', 'nanosecond', 'nanoseconds', 'ps', 'picosecond', 'picoseconds', 'minute', 'minutes', 'h', 'hour', 'hours', 'day', 'days', 'anomalistic_year', 'anomalistic_years', 'sidereal_year', 'sidereal_years', 'tropical_year', 'tropical_years', 'common_year', 'common_years', 'julian_year', 'julian_years', 'draconic_year', 'draconic_years', 'gaussian_year', 'gaussian_years', 'full_moon_cycle', 'full_moon_cycles', 'year', 'years', 'G', 'gravitational_constant', 'c', 'speed_of_light', 'elementary_charge', 'hbar', 'planck', 'eV', 'electronvolt', 'electronvolts', 'avogadro_number', 'avogadro', 'avogadro_constant', 'boltzmann', 'boltzmann_constant', 'stefan', 'stefan_boltzmann_constant', 'R', 'molar_gas_constant', 'faraday_constant', 'josephson_constant', 'von_klitzing_constant', 'Da', 'dalton', 'amu', 'amus', 'atomic_mass_unit', 'atomic_mass_constant', 'me', 'electron_rest_mass', 'gee', 'gees', 'acceleration_due_to_gravity', 'u0', 'magnetic_constant', 'vacuum_permeability', 'e0', 'electric_constant', 'vacuum_permittivity', 'Z0', 'vacuum_impedance', 'coulomb_constant', 'electric_force_constant', 'atmosphere', 'atmospheres', 'atm', 'kPa', 'bar', 'bars', 'pound', 'pounds', 'psi', 'dHg0', 'mmHg', 'torr', 'mmu', 'mmus', 'milli_mass_unit', 'quart', 'quarts', 'ly', 'lightyear', 'lightyears', 'au', 'astronomical_unit', 'astronomical_units', 'planck_mass', 'planck_time', 'planck_temperature', 'planck_length', 'planck_charge', 'planck_area', 'planck_volume', 'planck_momentum', 'planck_energy', 'planck_force', 'planck_power', 'planck_density', 'planck_energy_density', 'planck_intensity', 'planck_angular_frequency', 'planck_pressure', 'planck_current', 'planck_voltage', 'planck_impedance', 'planck_acceleration', 'bit', 'bits', 'byte', 'kibibyte', 'kibibytes', 'mebibyte', 'mebibytes', 'gibibyte', 'gibibytes', 'tebibyte', 'tebibytes', 'pebibyte', 'pebibytes', 'exbibyte', 'exbibytes', 'mks', 'mksa', 'si'] +def find_unit(quantity, unit_system=...) -> list[str]: ... + +__all__ = [ + "Dimension", + "DimensionSystem", + "UnitSystem", + "convert_to", + "Quantity", + "amount_of_substance", + "acceleration", + "action", + "area", + "capacitance", + "charge", + "conductance", + "current", + "energy", + "force", + "frequency", + "impedance", + "inductance", + "length", + "luminous_intensity", + "magnetic_density", + "magnetic_flux", + "mass", + "momentum", + "power", + "pressure", + "temperature", + "time", + "velocity", + "voltage", + "volume", + "Unit", + "speed", + "luminosity", + "magnetic_flux_density", + "amount", + "yotta", + "zetta", + "exa", + "peta", + "tera", + "giga", + "mega", + "kilo", + "hecto", + "deca", + "deci", + "centi", + "milli", + "micro", + "nano", + "pico", + "femto", + "atto", + "zepto", + "yocto", + "kibi", + "mebi", + "gibi", + "tebi", + "pebi", + "exbi", + "percent", + "percents", + "permille", + "rad", + "radian", + "radians", + "deg", + "degree", + "degrees", + "sr", + "steradian", + "steradians", + "mil", + "angular_mil", + "angular_mils", + "m", + "meter", + "meters", + "kg", + "kilogram", + "kilograms", + "s", + "second", + "seconds", + "A", + "ampere", + "amperes", + "K", + "kelvin", + "kelvins", + "mol", + "mole", + "moles", + "cd", + "candela", + "candelas", + "g", + "gram", + "grams", + "mg", + "milligram", + "milligrams", + "ug", + "microgram", + "micrograms", + "t", + "tonne", + "metric_ton", + "newton", + "newtons", + "N", + "joule", + "joules", + "J", + "watt", + "watts", + "W", + "pascal", + "pascals", + "Pa", + "pa", + "hertz", + "hz", + "Hz", + "coulomb", + "coulombs", + "C", + "volt", + "volts", + "v", + "V", + "ohm", + "ohms", + "siemens", + "S", + "mho", + "mhos", + "farad", + "farads", + "F", + "henry", + "henrys", + "H", + "tesla", + "teslas", + "T", + "weber", + "webers", + "Wb", + "wb", + "optical_power", + "dioptre", + "D", + "lux", + "lx", + "katal", + "kat", + "gray", + "Gy", + "becquerel", + "Bq", + "km", + "kilometer", + "kilometers", + "dm", + "decimeter", + "decimeters", + "cm", + "centimeter", + "centimeters", + "mm", + "millimeter", + "millimeters", + "um", + "micrometer", + "micrometers", + "micron", + "microns", + "nm", + "nanometer", + "nanometers", + "pm", + "picometer", + "picometers", + "ft", + "foot", + "feet", + "inch", + "inches", + "yd", + "yard", + "yards", + "mi", + "mile", + "miles", + "nmi", + "nautical_mile", + "nautical_miles", + "angstrom", + "angstroms", + "ha", + "hectare", + "l", + "L", + "liter", + "liters", + "dl", + "dL", + "deciliter", + "deciliters", + "cl", + "cL", + "centiliter", + "centiliters", + "ml", + "mL", + "milliliter", + "milliliters", + "ms", + "millisecond", + "milliseconds", + "us", + "microsecond", + "microseconds", + "ns", + "nanosecond", + "nanoseconds", + "ps", + "picosecond", + "picoseconds", + "minute", + "minutes", + "h", + "hour", + "hours", + "day", + "days", + "anomalistic_year", + "anomalistic_years", + "sidereal_year", + "sidereal_years", + "tropical_year", + "tropical_years", + "common_year", + "common_years", + "julian_year", + "julian_years", + "draconic_year", + "draconic_years", + "gaussian_year", + "gaussian_years", + "full_moon_cycle", + "full_moon_cycles", + "year", + "years", + "G", + "gravitational_constant", + "c", + "speed_of_light", + "elementary_charge", + "hbar", + "planck", + "eV", + "electronvolt", + "electronvolts", + "avogadro_number", + "avogadro", + "avogadro_constant", + "boltzmann", + "boltzmann_constant", + "stefan", + "stefan_boltzmann_constant", + "R", + "molar_gas_constant", + "faraday_constant", + "josephson_constant", + "von_klitzing_constant", + "Da", + "dalton", + "amu", + "amus", + "atomic_mass_unit", + "atomic_mass_constant", + "me", + "electron_rest_mass", + "gee", + "gees", + "acceleration_due_to_gravity", + "u0", + "magnetic_constant", + "vacuum_permeability", + "e0", + "electric_constant", + "vacuum_permittivity", + "Z0", + "vacuum_impedance", + "coulomb_constant", + "electric_force_constant", + "atmosphere", + "atmospheres", + "atm", + "kPa", + "bar", + "bars", + "pound", + "pounds", + "psi", + "dHg0", + "mmHg", + "torr", + "mmu", + "mmus", + "milli_mass_unit", + "quart", + "quarts", + "ly", + "lightyear", + "lightyears", + "au", + "astronomical_unit", + "astronomical_units", + "planck_mass", + "planck_time", + "planck_temperature", + "planck_length", + "planck_charge", + "planck_area", + "planck_volume", + "planck_momentum", + "planck_energy", + "planck_force", + "planck_power", + "planck_density", + "planck_energy_density", + "planck_intensity", + "planck_angular_frequency", + "planck_pressure", + "planck_current", + "planck_voltage", + "planck_impedance", + "planck_acceleration", + "bit", + "bits", + "byte", + "kibibyte", + "kibibytes", + "mebibyte", + "mebibytes", + "gibibyte", + "gibibytes", + "tebibyte", + "tebibytes", + "pebibyte", + "pebibytes", + "exbibyte", + "exbibytes", + "mks", + "mksa", + "si", +] diff --git a/stubs/sympy-stubs/physics/units/definitions/__init__.pyi b/stubs/sympy-stubs/physics/units/definitions/__init__.pyi index 0a78c9c8..26026f60 100644 --- a/stubs/sympy-stubs/physics/units/definitions/__init__.pyi +++ b/stubs/sympy-stubs/physics/units/definitions/__init__.pyi @@ -301,4 +301,305 @@ from sympy.physics.units.definitions.unit_definitions import ( years, ) -__all__ = ['percent', 'percents', 'permille', 'rad', 'radian', 'radians', 'deg', 'degree', 'degrees', 'sr', 'steradian', 'steradians', 'mil', 'angular_mil', 'angular_mils', 'm', 'meter', 'meters', 'kg', 'kilogram', 'kilograms', 's', 'second', 'seconds', 'A', 'ampere', 'amperes', 'K', 'kelvin', 'kelvins', 'mol', 'mole', 'moles', 'cd', 'candela', 'candelas', 'g', 'gram', 'grams', 'mg', 'milligram', 'milligrams', 'ug', 'microgram', 'micrograms', 't', 'tonne', 'metric_ton', 'newton', 'newtons', 'N', 'joule', 'joules', 'J', 'watt', 'watts', 'W', 'pascal', 'pascals', 'Pa', 'pa', 'hertz', 'hz', 'Hz', 'coulomb', 'coulombs', 'C', 'volt', 'volts', 'v', 'V', 'ohm', 'ohms', 'siemens', 'S', 'mho', 'mhos', 'farad', 'farads', 'F', 'henry', 'henrys', 'H', 'tesla', 'teslas', 'T', 'weber', 'webers', 'Wb', 'wb', 'optical_power', 'dioptre', 'D', 'lux', 'lx', 'katal', 'kat', 'gray', 'Gy', 'becquerel', 'Bq', 'km', 'kilometer', 'kilometers', 'dm', 'decimeter', 'decimeters', 'cm', 'centimeter', 'centimeters', 'mm', 'millimeter', 'millimeters', 'um', 'micrometer', 'micrometers', 'micron', 'microns', 'nm', 'nanometer', 'nanometers', 'pm', 'picometer', 'picometers', 'ft', 'foot', 'feet', 'inch', 'inches', 'yd', 'yard', 'yards', 'mi', 'mile', 'miles', 'nmi', 'nautical_mile', 'nautical_miles', 'ha', 'hectare', 'l', 'L', 'liter', 'liters', 'dl', 'dL', 'deciliter', 'deciliters', 'cl', 'cL', 'centiliter', 'centiliters', 'ml', 'mL', 'milliliter', 'milliliters', 'ms', 'millisecond', 'milliseconds', 'us', 'microsecond', 'microseconds', 'ns', 'nanosecond', 'nanoseconds', 'ps', 'picosecond', 'picoseconds', 'minute', 'minutes', 'h', 'hour', 'hours', 'day', 'days', 'anomalistic_year', 'anomalistic_years', 'sidereal_year', 'sidereal_years', 'tropical_year', 'tropical_years', 'common_year', 'common_years', 'julian_year', 'julian_years', 'draconic_year', 'draconic_years', 'gaussian_year', 'gaussian_years', 'full_moon_cycle', 'full_moon_cycles', 'year', 'years', 'G', 'gravitational_constant', 'c', 'speed_of_light', 'elementary_charge', 'hbar', 'planck', 'eV', 'electronvolt', 'electronvolts', 'avogadro_number', 'avogadro', 'avogadro_constant', 'boltzmann', 'boltzmann_constant', 'stefan', 'stefan_boltzmann_constant', 'R', 'molar_gas_constant', 'faraday_constant', 'josephson_constant', 'von_klitzing_constant', 'Da', 'dalton', 'amu', 'amus', 'atomic_mass_unit', 'atomic_mass_constant', 'me', 'electron_rest_mass', 'gee', 'gees', 'acceleration_due_to_gravity', 'u0', 'magnetic_constant', 'vacuum_permeability', 'e0', 'electric_constant', 'vacuum_permittivity', 'Z0', 'vacuum_impedance', 'coulomb_constant', 'coulombs_constant', 'electric_force_constant', 'atmosphere', 'atmospheres', 'atm', 'kPa', 'kilopascal', 'bar', 'bars', 'pound', 'pounds', 'psi', 'dHg0', 'mmHg', 'torr', 'mmu', 'mmus', 'milli_mass_unit', 'quart', 'quarts', 'angstrom', 'angstroms', 'ly', 'lightyear', 'lightyears', 'au', 'astronomical_unit', 'astronomical_units', 'planck_mass', 'planck_time', 'planck_temperature', 'planck_length', 'planck_charge', 'planck_area', 'planck_volume', 'planck_momentum', 'planck_energy', 'planck_force', 'planck_power', 'planck_density', 'planck_energy_density', 'planck_intensity', 'planck_angular_frequency', 'planck_pressure', 'planck_current', 'planck_voltage', 'planck_impedance', 'planck_acceleration', 'bit', 'bits', 'byte', 'kibibyte', 'kibibytes', 'mebibyte', 'mebibytes', 'gibibyte', 'gibibytes', 'tebibyte', 'tebibytes', 'pebibyte', 'pebibytes', 'exbibyte', 'exbibytes', 'curie', 'rutherford'] +__all__ = [ + "percent", + "percents", + "permille", + "rad", + "radian", + "radians", + "deg", + "degree", + "degrees", + "sr", + "steradian", + "steradians", + "mil", + "angular_mil", + "angular_mils", + "m", + "meter", + "meters", + "kg", + "kilogram", + "kilograms", + "s", + "second", + "seconds", + "A", + "ampere", + "amperes", + "K", + "kelvin", + "kelvins", + "mol", + "mole", + "moles", + "cd", + "candela", + "candelas", + "g", + "gram", + "grams", + "mg", + "milligram", + "milligrams", + "ug", + "microgram", + "micrograms", + "t", + "tonne", + "metric_ton", + "newton", + "newtons", + "N", + "joule", + "joules", + "J", + "watt", + "watts", + "W", + "pascal", + "pascals", + "Pa", + "pa", + "hertz", + "hz", + "Hz", + "coulomb", + "coulombs", + "C", + "volt", + "volts", + "v", + "V", + "ohm", + "ohms", + "siemens", + "S", + "mho", + "mhos", + "farad", + "farads", + "F", + "henry", + "henrys", + "H", + "tesla", + "teslas", + "T", + "weber", + "webers", + "Wb", + "wb", + "optical_power", + "dioptre", + "D", + "lux", + "lx", + "katal", + "kat", + "gray", + "Gy", + "becquerel", + "Bq", + "km", + "kilometer", + "kilometers", + "dm", + "decimeter", + "decimeters", + "cm", + "centimeter", + "centimeters", + "mm", + "millimeter", + "millimeters", + "um", + "micrometer", + "micrometers", + "micron", + "microns", + "nm", + "nanometer", + "nanometers", + "pm", + "picometer", + "picometers", + "ft", + "foot", + "feet", + "inch", + "inches", + "yd", + "yard", + "yards", + "mi", + "mile", + "miles", + "nmi", + "nautical_mile", + "nautical_miles", + "ha", + "hectare", + "l", + "L", + "liter", + "liters", + "dl", + "dL", + "deciliter", + "deciliters", + "cl", + "cL", + "centiliter", + "centiliters", + "ml", + "mL", + "milliliter", + "milliliters", + "ms", + "millisecond", + "milliseconds", + "us", + "microsecond", + "microseconds", + "ns", + "nanosecond", + "nanoseconds", + "ps", + "picosecond", + "picoseconds", + "minute", + "minutes", + "h", + "hour", + "hours", + "day", + "days", + "anomalistic_year", + "anomalistic_years", + "sidereal_year", + "sidereal_years", + "tropical_year", + "tropical_years", + "common_year", + "common_years", + "julian_year", + "julian_years", + "draconic_year", + "draconic_years", + "gaussian_year", + "gaussian_years", + "full_moon_cycle", + "full_moon_cycles", + "year", + "years", + "G", + "gravitational_constant", + "c", + "speed_of_light", + "elementary_charge", + "hbar", + "planck", + "eV", + "electronvolt", + "electronvolts", + "avogadro_number", + "avogadro", + "avogadro_constant", + "boltzmann", + "boltzmann_constant", + "stefan", + "stefan_boltzmann_constant", + "R", + "molar_gas_constant", + "faraday_constant", + "josephson_constant", + "von_klitzing_constant", + "Da", + "dalton", + "amu", + "amus", + "atomic_mass_unit", + "atomic_mass_constant", + "me", + "electron_rest_mass", + "gee", + "gees", + "acceleration_due_to_gravity", + "u0", + "magnetic_constant", + "vacuum_permeability", + "e0", + "electric_constant", + "vacuum_permittivity", + "Z0", + "vacuum_impedance", + "coulomb_constant", + "coulombs_constant", + "electric_force_constant", + "atmosphere", + "atmospheres", + "atm", + "kPa", + "kilopascal", + "bar", + "bars", + "pound", + "pounds", + "psi", + "dHg0", + "mmHg", + "torr", + "mmu", + "mmus", + "milli_mass_unit", + "quart", + "quarts", + "angstrom", + "angstroms", + "ly", + "lightyear", + "lightyears", + "au", + "astronomical_unit", + "astronomical_units", + "planck_mass", + "planck_time", + "planck_temperature", + "planck_length", + "planck_charge", + "planck_area", + "planck_volume", + "planck_momentum", + "planck_energy", + "planck_force", + "planck_power", + "planck_density", + "planck_energy_density", + "planck_intensity", + "planck_angular_frequency", + "planck_pressure", + "planck_current", + "planck_voltage", + "planck_impedance", + "planck_acceleration", + "bit", + "bits", + "byte", + "kibibyte", + "kibibytes", + "mebibyte", + "mebibytes", + "gibibyte", + "gibibytes", + "tebibyte", + "tebibytes", + "pebibyte", + "pebibytes", + "exbibyte", + "exbibytes", + "curie", + "rutherford", +] diff --git a/stubs/sympy-stubs/physics/units/dimensions.pyi b/stubs/sympy-stubs/physics/units/dimensions.pyi index 673f0e8b..2461996a 100644 --- a/stubs/sympy-stubs/physics/units/dimensions.pyi +++ b/stubs/sympy-stubs/physics/units/dimensions.pyi @@ -8,22 +8,11 @@ class _QuantityMapper: _quantity_scale_factors_global: dict[Expr, Expr] = ... _quantity_dimensional_equivalence_map_global: dict[Expr, Expr] = ... _quantity_dimension_global: dict[Expr, Expr] = ... - def __init__(self, *args, **kwargs) -> None: - ... - - def set_quantity_dimension(self, quantity, dimension) -> None: - ... - - def set_quantity_scale_factor(self, quantity, scale_factor) -> None: - ... - - def get_quantity_dimension(self, unit) -> Expr | Dimension: - ... - - def get_quantity_scale_factor(self, unit): - ... - - + def __init__(self, *args, **kwargs) -> None: ... + def set_quantity_dimension(self, quantity, dimension) -> None: ... + def set_quantity_scale_factor(self, quantity, scale_factor) -> None: ... + def get_quantity_dimension(self, unit) -> Expr | Dimension: ... + def get_quantity_scale_factor(self, unit): ... class Dimension(Expr): _op_priority = ... @@ -32,114 +21,47 @@ class Dimension(Expr): is_number = ... is_positive = ... is_real = ... - def __new__(cls, name, symbol=...) -> Self: - ... - + def __new__(cls, name, symbol=...) -> Self: ... @property - def name(self): - ... - + def name(self): ... @property - def symbol(self): - ... - - def __str__(self) -> str: - ... - - def __repr__(self) -> LiteralString: - ... - - def __neg__(self) -> Self: - ... - - def __add__(self, other) -> Self: - ... - - def __radd__(self, other) -> Self: - ... - - def __sub__(self, other): - ... - - def __rsub__(self, other): - ... - - def __pow__(self, other) -> Dimension: - ... - - def __mul__(self, other) -> Dimension | Self: - ... - - def __rmul__(self, other) -> Dimension | Self: - ... - - def __truediv__(self, other) -> Dimension | Self: - ... - - def __rtruediv__(self, other): - ... - - def has_integer_powers(self, dim_sys) -> bool: - ... - - + def symbol(self): ... + def __str__(self) -> str: ... + def __repr__(self) -> LiteralString: ... + def __neg__(self) -> Self: ... + def __add__(self, other) -> Self: ... + def __radd__(self, other) -> Self: ... + def __sub__(self, other): ... + def __rsub__(self, other): ... + def __pow__(self, other) -> Dimension: ... + def __mul__(self, other) -> Dimension | Self: ... + def __rmul__(self, other) -> Dimension | Self: ... + def __truediv__(self, other) -> Dimension | Self: ... + def __rtruediv__(self, other): ... + def has_integer_powers(self, dim_sys) -> bool: ... class DimensionSystem(Basic, _QuantityMapper): - def __new__(cls, base_dims, derived_dims=..., dimensional_dependencies=...) -> Self: - ... - + def __new__(cls, base_dims, derived_dims=..., dimensional_dependencies=...) -> Self: ... @property - def base_dims(self) -> Basic: - ... - + def base_dims(self) -> Basic: ... @property - def derived_dims(self) -> Basic: - ... - + def derived_dims(self) -> Basic: ... @property - def dimensional_dependencies(self) -> Basic: - ... - - def get_dimensional_dependencies(self, name, mark_dimensionless=...) -> dict[Dimension, int] | dict[Any, int | Any]: - ... - - def equivalent_dims(self, dim1, dim2) -> bool: - ... - - def extend(self, new_base_dims, new_derived_dims=..., new_dim_deps=...) -> DimensionSystem: - ... - - def is_dimensionless(self, dimension) -> bool: - ... - + def dimensional_dependencies(self) -> Basic: ... + def get_dimensional_dependencies(self, name, mark_dimensionless=...) -> dict[Dimension, int] | dict[Any, int | Any]: ... + def equivalent_dims(self, dim1, dim2) -> bool: ... + def extend(self, new_base_dims, new_derived_dims=..., new_dim_deps=...) -> DimensionSystem: ... + def is_dimensionless(self, dimension) -> bool: ... @property - def list_can_dims(self) -> tuple[Any, ...]: - ... - + def list_can_dims(self) -> tuple[Any, ...]: ... @property - def inv_can_transf_matrix(self): - ... - + def inv_can_transf_matrix(self): ... @property - def can_transf_matrix(self): - ... - - def dim_can_vector(self, dim) -> Matrix: - ... - - def dim_vector(self, dim): - ... - - def print_dim_base(self, dim): - ... - + def can_transf_matrix(self): ... + def dim_can_vector(self, dim) -> Matrix: ... + def dim_vector(self, dim): ... + def print_dim_base(self, dim): ... @property - def dim(self) -> int: - ... - + def dim(self) -> int: ... @property - def is_consistent(self): - ... - - - + def is_consistent(self): ... diff --git a/stubs/sympy-stubs/physics/units/prefixes.pyi b/stubs/sympy-stubs/physics/units/prefixes.pyi index 2c2af945..6bb3e285 100644 --- a/stubs/sympy-stubs/physics/units/prefixes.pyi +++ b/stubs/sympy-stubs/physics/units/prefixes.pyi @@ -5,44 +5,22 @@ from sympy.core.expr import Expr class Prefix(Expr): _op_priority = ... is_commutative = ... - def __new__(cls, name, abbrev, exponent, base=..., latex_repr=...) -> Self: - ... - + def __new__(cls, name, abbrev, exponent, base=..., latex_repr=...) -> Self: ... @property - def name(self): - ... - + def name(self): ... @property - def abbrev(self): - ... - + def abbrev(self): ... @property - def scale_factor(self): - ... - + def scale_factor(self): ... @property - def base(self): - ... - - def __str__(self) -> str: - ... - - def __repr__(self) -> str: - ... - - def __mul__(self, other) -> Prefix | Literal[1]: - ... - - def __truediv__(self, other) -> Prefix | Literal[1]: - ... - - def __rtruediv__(self, other) -> Prefix: - ... - + def base(self): ... + def __str__(self) -> str: ... + def __repr__(self) -> str: ... + def __mul__(self, other) -> Prefix | Literal[1]: ... + def __truediv__(self, other) -> Prefix | Literal[1]: ... + def __rtruediv__(self, other) -> Prefix: ... - -def prefix_unit(unit, prefixes) -> list[Any]: - ... +def prefix_unit(unit, prefixes) -> list[Any]: ... yotta = ... zetta = ... diff --git a/stubs/sympy-stubs/physics/units/quantities.pyi b/stubs/sympy-stubs/physics/units/quantities.pyi index 841858e7..1f3fdaba 100644 --- a/stubs/sympy-stubs/physics/units/quantities.pyi +++ b/stubs/sympy-stubs/physics/units/quantities.pyi @@ -11,45 +11,32 @@ class Quantity(AtomicExpr): is_nonzero = ... is_physical_constant = ... _diff_wrt = ... - def __new__(cls, name, abbrev=..., latex_repr=..., pretty_unicode_repr=..., pretty_ascii_repr=..., mathml_presentation_repr=..., is_prefixed=..., **assumptions) -> Self: - ... - - def set_global_dimension(self, dimension) -> None: - ... - - def set_global_relative_scale_factor(self, scale_factor, reference_quantity) -> None: - ... - + def __new__( + cls, + name, + abbrev=..., + latex_repr=..., + pretty_unicode_repr=..., + pretty_ascii_repr=..., + mathml_presentation_repr=..., + is_prefixed=..., + **assumptions, + ) -> Self: ... + def set_global_dimension(self, dimension) -> None: ... + def set_global_relative_scale_factor(self, scale_factor, reference_quantity) -> None: ... @property - def name(self): - ... - + def name(self): ... @property - def dimension(self) -> Expr | Dimension: - ... - + def dimension(self) -> Expr | Dimension: ... @property - def abbrev(self): - ... - + def abbrev(self): ... @property - def scale_factor(self): - ... - - def convert_to(self, other, unit_system=...) -> Add | Quantity: - ... - + def scale_factor(self): ... + def convert_to(self, other, unit_system=...) -> Add | Quantity: ... @property - def free_symbols(self) -> set[Any]: - ... - + def free_symbols(self) -> set[Any]: ... @property - def is_prefixed(self) -> bool: - ... - - + def is_prefixed(self) -> bool: ... class PhysicalConstant(Quantity): is_physical_constant = ... - - diff --git a/stubs/sympy-stubs/physics/units/unitsystem.pyi b/stubs/sympy-stubs/physics/units/unitsystem.pyi index c79bf7ed..95b44c68 100644 --- a/stubs/sympy-stubs/physics/units/unitsystem.pyi +++ b/stubs/sympy-stubs/physics/units/unitsystem.pyi @@ -8,52 +8,26 @@ from sympy.series.order import Order class UnitSystem(_QuantityMapper): _unit_systems: tDict[str, UnitSystem] = ... - def __init__(self, base_units, units=..., name=..., descr=..., dimension_system=..., derived_units: tDict[Dimension, Quantity] = ...) -> None: - ... - - def __str__(self) -> str: - ... - - def __repr__(self) -> str: - ... - - def extend(self, base, units=..., name=..., description=..., dimension_system=..., derived_units: tDict[Dimension, Quantity] = ...) -> UnitSystem: - ... - - def get_dimension_system(self) -> None: - ... - - def get_quantity_dimension(self, unit) -> Expr | Dimension: - ... - - def get_quantity_scale_factor(self, unit): - ... - + def __init__( + self, base_units, units=..., name=..., descr=..., dimension_system=..., derived_units: tDict[Dimension, Quantity] = ... + ) -> None: ... + def __str__(self) -> str: ... + def __repr__(self) -> str: ... + def extend( + self, base, units=..., name=..., description=..., dimension_system=..., derived_units: tDict[Dimension, Quantity] = ... + ) -> UnitSystem: ... + def get_dimension_system(self) -> None: ... + def get_quantity_dimension(self, unit) -> Expr | Dimension: ... + def get_quantity_scale_factor(self, unit): ... @staticmethod - def get_unit_system(unit_system) -> UnitSystem: - ... - + def get_unit_system(unit_system) -> UnitSystem: ... @staticmethod - def get_default_unit_system() -> UnitSystem: - ... - + def get_default_unit_system() -> UnitSystem: ... @property - def dim(self) -> int: - ... - + def dim(self) -> int: ... @property - def is_consistent(self): - ... - + def is_consistent(self): ... @property - def derived_units(self) -> tDict[Dimension, Quantity]: - ... - - def get_dimensional_expr(self, expr) -> Order | type[UndefinedFunction]: - ... - - def get_units_non_prefixed(self) -> tSet[Quantity]: - ... - - - + def derived_units(self) -> tDict[Dimension, Quantity]: ... + def get_dimensional_expr(self, expr) -> Order | type[UndefinedFunction]: ... + def get_units_non_prefixed(self) -> tSet[Quantity]: ... diff --git a/stubs/sympy-stubs/physics/units/util.pyi b/stubs/sympy-stubs/physics/units/util.pyi index 749b0f89..3f26a51c 100644 --- a/stubs/sympy-stubs/physics/units/util.pyi +++ b/stubs/sympy-stubs/physics/units/util.pyi @@ -1,12 +1,6 @@ from sympy.core.add import Add from sympy.physics.units.quantities import Quantity -def convert_to(expr, target_units, unit_system=...) -> Add | Quantity: - ... - -def quantity_simplify(expr, across_dimensions: bool = ..., unit_system=...) -> Add | Quantity: - ... - -def check_dimensions(expr, unit_system=...): - ... - +def convert_to(expr, target_units, unit_system=...) -> Add | Quantity: ... +def quantity_simplify(expr, across_dimensions: bool = ..., unit_system=...) -> Add | Quantity: ... +def check_dimensions(expr, unit_system=...): ... diff --git a/stubs/sympy-stubs/plotting/__init__.pyi b/stubs/sympy-stubs/plotting/__init__.pyi index b3a6fe72..97995e92 100644 --- a/stubs/sympy-stubs/plotting/__init__.pyi +++ b/stubs/sympy-stubs/plotting/__init__.pyi @@ -12,4 +12,16 @@ from sympy.plotting.plot_implicit import plot_implicit from sympy.plotting.pygletplot import PygletPlot from sympy.plotting.textplot import textplot -__all__ = ['plot_backends', 'plot_implicit', 'textplot', 'PygletPlot', 'PlotGrid', 'plot', 'plot_parametric', 'plot3d', 'plot3d_parametric_surface', 'plot3d_parametric_line', 'plot_contour'] +__all__ = [ + "plot_backends", + "plot_implicit", + "textplot", + "PygletPlot", + "PlotGrid", + "plot", + "plot_parametric", + "plot3d", + "plot3d_parametric_surface", + "plot3d_parametric_line", + "plot_contour", +] diff --git a/stubs/sympy-stubs/plotting/intervalmath/__init__.pyi b/stubs/sympy-stubs/plotting/intervalmath/__init__.pyi index 4346f223..7df945b1 100644 --- a/stubs/sympy-stubs/plotting/intervalmath/__init__.pyi +++ b/stubs/sympy-stubs/plotting/intervalmath/__init__.pyi @@ -25,4 +25,29 @@ from sympy.plotting.intervalmath.lib_interval import ( tanh, ) -__all__ = ['interval', 'Abs', 'exp', 'log', 'log10', 'sin', 'cos', 'tan', 'sqrt', 'imin', 'imax', 'sinh', 'cosh', 'tanh', 'acosh', 'asinh', 'atanh', 'asin', 'acos', 'atan', 'ceil', 'floor', 'And', 'Or'] +__all__ = [ + "interval", + "Abs", + "exp", + "log", + "log10", + "sin", + "cos", + "tan", + "sqrt", + "imin", + "imax", + "sinh", + "cosh", + "tanh", + "acosh", + "asinh", + "atanh", + "asin", + "acos", + "atan", + "ceil", + "floor", + "And", + "Or", +] diff --git a/stubs/sympy-stubs/plotting/intervalmath/interval_arithmetic.pyi b/stubs/sympy-stubs/plotting/intervalmath/interval_arithmetic.pyi index 619fbd60..c6c943f6 100644 --- a/stubs/sympy-stubs/plotting/intervalmath/interval_arithmetic.pyi +++ b/stubs/sympy-stubs/plotting/intervalmath/interval_arithmetic.pyi @@ -2,75 +2,31 @@ from types import NotImplementedType from typing import Self class interval: - def __init__(self, *args, is_valid=..., **kwargs) -> None: - ... - + def __init__(self, *args, is_valid=..., **kwargs) -> None: ... @property - def mid(self) -> float: - ... - + def mid(self) -> float: ... @property - def width(self) -> float: - ... - - def __repr__(self) -> str: - ... - - def __str__(self) -> str: - ... - - def __lt__(self, other) -> bool: - ... - - def __gt__(self, other) -> bool: - ... - - def __eq__(self, other) -> bool: - ... - - def __ne__(self, other) -> bool: - ... - - def __le__(self, other) -> bool: - ... - - def __ge__(self, other) -> bool: - ... - - def __add__(self, other) -> interval | NotImplementedType: - ... - - __radd__ = ... - def __sub__(self, other) -> interval | NotImplementedType: - ... - - def __rsub__(self, other) -> interval | NotImplementedType: - ... - - def __neg__(self) -> interval: - ... - - def __mul__(self, other) -> interval | NotImplementedType: - ... - - __rmul__ = ... - def __contains__(self, other) -> bool: - ... - - def __rtruediv__(self, other) -> interval | NotImplementedType: - ... - - def __truediv__(self, other) -> interval | NotImplementedType: - ... - - def __pow__(self, other) -> Self | interval | NotImplementedType: - ... - - def __rpow__(self, other) -> Self | interval | NotImplementedType: - ... - - def __hash__(self) -> int: - ... - + def width(self) -> float: ... + def __repr__(self) -> str: ... + def __str__(self) -> str: ... + def __lt__(self, other) -> bool: ... + def __gt__(self, other) -> bool: ... + def __eq__(self, other) -> bool: ... + def __ne__(self, other) -> bool: ... + def __le__(self, other) -> bool: ... + def __ge__(self, other) -> bool: ... + def __add__(self, other) -> interval | NotImplementedType: ... + __radd__ = ... + def __sub__(self, other) -> interval | NotImplementedType: ... + def __rsub__(self, other) -> interval | NotImplementedType: ... + def __neg__(self) -> interval: ... + def __mul__(self, other) -> interval | NotImplementedType: ... + __rmul__ = ... + def __contains__(self, other) -> bool: ... + def __rtruediv__(self, other) -> interval | NotImplementedType: ... + def __truediv__(self, other) -> interval | NotImplementedType: ... + def __pow__(self, other) -> Self | interval | NotImplementedType: ... + def __rpow__(self, other) -> Self | interval | NotImplementedType: ... + def __hash__(self) -> int: ... diff --git a/stubs/sympy-stubs/plotting/intervalmath/interval_membership.pyi b/stubs/sympy-stubs/plotting/intervalmath/interval_membership.pyi index abbbf260..02663e64 100644 --- a/stubs/sympy-stubs/plotting/intervalmath/interval_membership.pyi +++ b/stubs/sympy-stubs/plotting/intervalmath/interval_membership.pyi @@ -1,39 +1,16 @@ from typing import Any, Iterator, Literal class intervalMembership: - def __init__(self, a, b) -> None: - ... - - def __getitem__(self, i) -> Any: - ... - - def __len__(self) -> Literal[2]: - ... - - def __iter__(self) -> Iterator[Any]: - ... - - def __str__(self) -> str: - ... - - __repr__ = ... - def __and__(self, other) -> intervalMembership: - ... - - def __or__(self, other) -> intervalMembership: - ... - - def __invert__(self) -> intervalMembership: - ... - - def __xor__(self, other) -> intervalMembership: - ... - - def __eq__(self, other) -> bool: - ... - - def __ne__(self, other) -> bool: - ... - - + def __init__(self, a, b) -> None: ... + def __getitem__(self, i) -> Any: ... + def __len__(self) -> Literal[2]: ... + def __iter__(self) -> Iterator[Any]: ... + def __str__(self) -> str: ... + __repr__ = ... + def __and__(self, other) -> intervalMembership: ... + def __or__(self, other) -> intervalMembership: ... + def __invert__(self) -> intervalMembership: ... + def __xor__(self, other) -> intervalMembership: ... + def __eq__(self, other) -> bool: ... + def __ne__(self, other) -> bool: ... diff --git a/stubs/sympy-stubs/plotting/intervalmath/lib_interval.pyi b/stubs/sympy-stubs/plotting/intervalmath/lib_interval.pyi index d77827b0..cb745293 100644 --- a/stubs/sympy-stubs/plotting/intervalmath/lib_interval.pyi +++ b/stubs/sympy-stubs/plotting/intervalmath/lib_interval.pyi @@ -2,72 +2,26 @@ from types import NotImplementedType from sympy.plotting.intervalmath.interval_arithmetic import interval -def Abs(x) -> interval: - ... - -def exp(x) -> interval: - ... - -def log(x) -> interval: - ... - -def log10(x) -> interval: - ... - -def atan(x) -> interval: - ... - -def sin(x) -> interval: - ... - -def cos(x) -> interval: - ... - -def tan(x) -> interval | NotImplementedType: - ... - -def sqrt(x) -> interval: - ... - -def imin(*args) -> type[NotImplementedError] | interval: - ... - -def imax(*args) -> type[NotImplementedError] | interval: - ... - -def sinh(x) -> interval: - ... - -def cosh(x) -> interval: - ... - -def tanh(x) -> interval: - ... - -def asin(x) -> interval | None: - ... - -def acos(x) -> interval | None: - ... - -def ceil(x) -> interval | type[NotImplementedError]: - ... - -def floor(x) -> interval | type[NotImplementedError]: - ... - -def acosh(x) -> interval | type[NotImplementedError]: - ... - -def asinh(x) -> interval | type[NotImplementedError]: - ... - -def atanh(x) -> interval | type[NotImplementedError]: - ... - -def And(*args) -> tuple[bool | None, bool | None]: - ... - -def Or(*args) -> tuple[bool | None, bool | None]: - ... - +def Abs(x) -> interval: ... +def exp(x) -> interval: ... +def log(x) -> interval: ... +def log10(x) -> interval: ... +def atan(x) -> interval: ... +def sin(x) -> interval: ... +def cos(x) -> interval: ... +def tan(x) -> interval | NotImplementedType: ... +def sqrt(x) -> interval: ... +def imin(*args) -> type[NotImplementedError] | interval: ... +def imax(*args) -> type[NotImplementedError] | interval: ... +def sinh(x) -> interval: ... +def cosh(x) -> interval: ... +def tanh(x) -> interval: ... +def asin(x) -> interval | None: ... +def acos(x) -> interval | None: ... +def ceil(x) -> interval | type[NotImplementedError]: ... +def floor(x) -> interval | type[NotImplementedError]: ... +def acosh(x) -> interval | type[NotImplementedError]: ... +def asinh(x) -> interval | type[NotImplementedError]: ... +def atanh(x) -> interval | type[NotImplementedError]: ... +def And(*args) -> tuple[bool | None, bool | None]: ... +def Or(*args) -> tuple[bool | None, bool | None]: ... diff --git a/stubs/sympy-stubs/plotting/plot.pyi b/stubs/sympy-stubs/plotting/plot.pyi index 3ed07340..85c067ab 100644 --- a/stubs/sympy-stubs/plotting/plot.pyi +++ b/stubs/sympy-stubs/plotting/plot.pyi @@ -2,53 +2,49 @@ from types import NotImplementedType from typing import Any, Tuple _show = ... -def unset_show() -> None: - ... -class Plot: - def __init__(self, *args, title=..., xlabel=..., ylabel=..., zlabel=..., aspect_ratio=..., xlim=..., ylim=..., axis_center=..., axis=..., xscale=..., yscale=..., legend=..., autoscale=..., margin=..., annotations=..., markers=..., rectangles=..., fill=..., backend=..., size=..., **kwargs) -> None: - ... - - def show(self) -> None: - ... - - def save(self, path) -> None: - ... - - def __str__(self) -> str: - ... - - def __getitem__(self, index): - ... - - def __setitem__(self, index, *args) -> None: - ... - - def __delitem__(self, index) -> None: - ... - - def append(self, arg) -> None: - ... - - def extend(self, arg) -> None: - ... - +def unset_show() -> None: ... +class Plot: + def __init__( + self, + *args, + title=..., + xlabel=..., + ylabel=..., + zlabel=..., + aspect_ratio=..., + xlim=..., + ylim=..., + axis_center=..., + axis=..., + xscale=..., + yscale=..., + legend=..., + autoscale=..., + margin=..., + annotations=..., + markers=..., + rectangles=..., + fill=..., + backend=..., + size=..., + **kwargs, + ) -> None: ... + def show(self) -> None: ... + def save(self, path) -> None: ... + def __str__(self) -> str: ... + def __getitem__(self, index): ... + def __setitem__(self, index, *args) -> None: ... + def __delitem__(self, index) -> None: ... + def append(self, arg) -> None: ... + def extend(self, arg) -> None: ... class PlotGrid: - def __init__(self, nrows, ncolumns, *args, show=..., size=..., **kwargs) -> None: - ... - - def show(self) -> None: - ... - - def save(self, path) -> None: - ... - - def __str__(self) -> str: - ... - - + def __init__(self, nrows, ncolumns, *args, show=..., size=..., **kwargs) -> None: ... + def show(self) -> None: ... + def save(self, path) -> None: ... + def __str__(self) -> str: ... class BaseSeries: is_2Dline = ... @@ -57,235 +53,105 @@ class BaseSeries: is_contour = ... is_implicit = ... is_parametric = ... - def __init__(self) -> None: - ... - + def __init__(self) -> None: ... @property - def is_3D(self) -> bool: - ... - + def is_3D(self) -> bool: ... @property - def is_line(self) -> bool: - ... - - + def is_line(self) -> bool: ... class Line2DBaseSeries(BaseSeries): is_2Dline = ... _dim = ... - def __init__(self) -> None: - ... - - def get_data(self) -> tuple[Any, Any] | tuple[Any, Any, Any]: - ... - - def get_segments(self): - ... - - def get_color_array(self): - ... - - + def __init__(self) -> None: ... + def get_data(self) -> tuple[Any, Any] | tuple[Any, Any, Any]: ... + def get_segments(self): ... + def get_color_array(self): ... class List2DSeries(Line2DBaseSeries): - def __init__(self, list_x, list_y) -> None: - ... - - def __str__(self) -> str: - ... - - def get_points(self) -> tuple[Any, Any]: - ... - - + def __init__(self, list_x, list_y) -> None: ... + def __str__(self) -> str: ... + def get_points(self) -> tuple[Any, Any]: ... class LineOver1DRangeSeries(Line2DBaseSeries): - def __init__(self, expr, var_start_end, **kwargs) -> None: - ... - - def __str__(self) -> str: - ... - - def get_points(self) -> tuple[Any, Any] | tuple[list[Any], list[Any]]: - ... - - + def __init__(self, expr, var_start_end, **kwargs) -> None: ... + def __str__(self) -> str: ... + def get_points(self) -> tuple[Any, Any] | tuple[list[Any], list[Any]]: ... class Parametric2DLineSeries(Line2DBaseSeries): is_parametric = ... - def __init__(self, expr_x, expr_y, var_start_end, **kwargs) -> None: - ... - - def __str__(self) -> str: - ... - - def get_parameter_points(self): - ... - - def get_points(self) -> tuple[Any, Any] | tuple[list[Any], list[Any]]: - ... - - + def __init__(self, expr_x, expr_y, var_start_end, **kwargs) -> None: ... + def __str__(self) -> str: ... + def get_parameter_points(self): ... + def get_points(self) -> tuple[Any, Any] | tuple[list[Any], list[Any]]: ... class Line3DBaseSeries(Line2DBaseSeries): is_2Dline = ... is_3Dline = ... _dim = ... - def __init__(self) -> None: - ... - - + def __init__(self) -> None: ... class Parametric3DLineSeries(Line3DBaseSeries): is_parametric = ... - def __init__(self, expr_x, expr_y, expr_z, var_start_end, **kwargs) -> None: - ... - - def __str__(self) -> str: - ... - - def get_parameter_points(self): - ... - - def get_points(self) -> tuple[Any, Any, Any]: - ... - - + def __init__(self, expr_x, expr_y, expr_z, var_start_end, **kwargs) -> None: ... + def __str__(self) -> str: ... + def get_parameter_points(self): ... + def get_points(self) -> tuple[Any, Any, Any]: ... class SurfaceBaseSeries(BaseSeries): is_3Dsurface = ... - def __init__(self) -> None: - ... - - def get_color_array(self): - ... - - + def __init__(self) -> None: ... + def get_color_array(self): ... class SurfaceOver2DRangeSeries(SurfaceBaseSeries): - def __init__(self, expr, var_start_end_x, var_start_end_y, **kwargs) -> None: - ... - - def __str__(self) -> str: - ... - - def get_meshes(self) -> tuple[Any, Any, Any]: - ... - - + def __init__(self, expr, var_start_end_x, var_start_end_y, **kwargs) -> None: ... + def __str__(self) -> str: ... + def get_meshes(self) -> tuple[Any, Any, Any]: ... class ParametricSurfaceSeries(SurfaceBaseSeries): is_parametric = ... - def __init__(self, expr_x, expr_y, expr_z, var_start_end_u, var_start_end_v, **kwargs) -> None: - ... - - def __str__(self) -> str: - ... - - def get_parameter_meshes(self): - ... - - def get_meshes(self) -> tuple[Any, Any, Any]: - ... - - + def __init__(self, expr_x, expr_y, expr_z, var_start_end_u, var_start_end_v, **kwargs) -> None: ... + def __str__(self) -> str: ... + def get_parameter_meshes(self): ... + def get_meshes(self) -> tuple[Any, Any, Any]: ... class ContourSeries(BaseSeries): is_contour = ... - def __init__(self, expr, var_start_end_x, var_start_end_y) -> None: - ... - - def __str__(self) -> str: - ... - - def get_meshes(self) -> tuple[Any, Any, Any]: - ... - - + def __init__(self, expr, var_start_end_x, var_start_end_y) -> None: ... + def __str__(self) -> str: ... + def get_meshes(self) -> tuple[Any, Any, Any]: ... class BaseBackend: - def __init__(self, parent) -> None: - ... - - def show(self): - ... - - def save(self, path): - ... - - def close(self): - ... - - + def __init__(self, parent) -> None: ... + def show(self): ... + def save(self, path): ... + def close(self): ... class MatplotlibBackend(BaseBackend): - def __init__(self, parent) -> None: - ... - + def __init__(self, parent) -> None: ... @staticmethod - def get_segments(x, y, z=...): - ... - - def process_series(self) -> None: - ... - - def show(self) -> None: - ... - - def save(self, path) -> None: - ... - - def close(self) -> None: - ... - - + def get_segments(x, y, z=...): ... + def process_series(self) -> None: ... + def show(self) -> None: ... + def save(self, path) -> None: ... + def close(self) -> None: ... class TextBackend(BaseBackend): - def __init__(self, parent) -> None: - ... - - def show(self) -> None: - ... - - def close(self) -> None: - ... - - + def __init__(self, parent) -> None: ... + def show(self) -> None: ... + def close(self) -> None: ... class DefaultBackend(BaseBackend): - def __new__(cls, parent) -> MatplotlibBackend | TextBackend: - ... - - + def __new__(cls, parent) -> MatplotlibBackend | TextBackend: ... plot_backends = ... -def centers_of_segments(array): - ... - -def centers_of_faces(array): - ... - -def flat(x, y, z, eps=...): - ... - -def plot(*args, show=..., **kwargs) -> Plot: - ... - -def plot_parametric(*args, show=..., **kwargs) -> Plot: - ... - -def plot3d_parametric_line(*args, show=..., **kwargs) -> Plot: - ... - -def plot3d(*args, show=..., **kwargs) -> Plot: - ... - -def plot3d_parametric_surface(*args, show=..., **kwargs) -> Plot: - ... - -def plot_contour(*args, show=..., **kwargs) -> Plot: - ... - -def check_arguments(args, expr_len, nb_of_free_symbols) -> list[Any] | list[Tuple | NotImplementedType] | None: - ... +def centers_of_segments(array): ... +def centers_of_faces(array): ... +def flat(x, y, z, eps=...): ... +def plot(*args, show=..., **kwargs) -> Plot: ... +def plot_parametric(*args, show=..., **kwargs) -> Plot: ... +def plot3d_parametric_line(*args, show=..., **kwargs) -> Plot: ... +def plot3d(*args, show=..., **kwargs) -> Plot: ... +def plot3d_parametric_surface(*args, show=..., **kwargs) -> Plot: ... +def plot_contour(*args, show=..., **kwargs) -> Plot: ... +def check_arguments(args, expr_len, nb_of_free_symbols) -> list[Any] | list[Tuple | NotImplementedType] | None: ... diff --git a/stubs/sympy-stubs/plotting/plot_implicit.pyi b/stubs/sympy-stubs/plotting/plot_implicit.pyi index 74e1dee0..03a13ccf 100644 --- a/stubs/sympy-stubs/plotting/plot_implicit.pyi +++ b/stubs/sympy-stubs/plotting/plot_implicit.pyi @@ -5,18 +5,17 @@ from sympy.utilities.decorator import doctest_depends_on class ImplicitSeries(BaseSeries): is_implicit = ... - def __init__(self, expr, var_start_end_x, var_start_end_y, has_equality, use_interval_math, depth, nb_of_points, line_color) -> None: - ... - - def __str__(self) -> str: - ... - - def get_raster(self) -> tuple[list[Any], Literal['fill']] | tuple[Any, Any, Any, Literal['contour']] | tuple[Any, Any, Any, Literal['contourf']]: - ... - - - -@doctest_depends_on(modules=('matplotlib', )) -def plot_implicit(expr, x_var=..., y_var=..., adaptive=..., depth=..., points=..., line_color=..., show=..., **kwargs) -> Plot: - ... + def __init__( + self, expr, var_start_end_x, var_start_end_y, has_equality, use_interval_math, depth, nb_of_points, line_color + ) -> None: ... + def __str__(self) -> str: ... + def get_raster( + self, + ) -> ( + tuple[list[Any], Literal["fill"]] | tuple[Any, Any, Any, Literal["contour"]] | tuple[Any, Any, Any, Literal["contourf"]] + ): ... +@doctest_depends_on(modules=("matplotlib",)) +def plot_implicit( + expr, x_var=..., y_var=..., adaptive=..., depth=..., points=..., line_color=..., show=..., **kwargs +) -> Plot: ... diff --git a/stubs/sympy-stubs/plotting/pygletplot/__init__.pyi b/stubs/sympy-stubs/plotting/pygletplot/__init__.pyi index bc5f4a4c..37206008 100644 --- a/stubs/sympy-stubs/plotting/pygletplot/__init__.pyi +++ b/stubs/sympy-stubs/plotting/pygletplot/__init__.pyi @@ -1,7 +1,5 @@ from sympy.plotting.pygletplot.plot import PygletPlot as Plot from sympy.utilities.decorator import doctest_depends_on -@doctest_depends_on(modules=('pyglet', )) -def PygletPlot(*args, **kwargs) -> PygletPlot: - ... - +@doctest_depends_on(modules=("pyglet",)) +def PygletPlot(*args, **kwargs) -> PygletPlot: ... diff --git a/stubs/sympy-stubs/plotting/pygletplot/color_scheme.pyi b/stubs/sympy-stubs/plotting/pygletplot/color_scheme.pyi index 39b1b4e4..6972a354 100644 --- a/stubs/sympy-stubs/plotting/pygletplot/color_scheme.pyi +++ b/stubs/sympy-stubs/plotting/pygletplot/color_scheme.pyi @@ -3,36 +3,16 @@ from typing import Any class ColorGradient: colors = ... intervals = ... - def __init__(self, *args) -> None: - ... - - def copy(self) -> ColorGradient: - ... - - def __call__(self, r, g, b) -> tuple[Any, Any, Any]: - ... - - + def __init__(self, *args) -> None: ... + def copy(self) -> ColorGradient: ... + def __call__(self, r, g, b) -> tuple[Any, Any, Any]: ... default_color_schemes = ... -class ColorScheme: - def __init__(self, *args, **kwargs) -> None: - ... - - def __call__(self, x, y, z, u, v) -> None: - ... - - def apply_to_curve(self, verts, u_set, set_len=..., inc_pos=...) -> list[Any]: - ... - - def apply_to_surface(self, verts, u_set, v_set, set_len=..., inc_pos=...) -> list[Any]: - ... - - def str_base(self) -> str: - ... - - def __repr__(self) -> str: - ... - - +class ColorScheme: + def __init__(self, *args, **kwargs) -> None: ... + def __call__(self, x, y, z, u, v) -> None: ... + def apply_to_curve(self, verts, u_set, set_len=..., inc_pos=...) -> list[Any]: ... + def apply_to_surface(self, verts, u_set, v_set, set_len=..., inc_pos=...) -> list[Any]: ... + def str_base(self) -> str: ... + def __repr__(self) -> str: ... diff --git a/stubs/sympy-stubs/plotting/pygletplot/managed_window.pyi b/stubs/sympy-stubs/plotting/pygletplot/managed_window.pyi index 4f6b5d25..2558a9c0 100644 --- a/stubs/sympy-stubs/plotting/pygletplot/managed_window.pyi +++ b/stubs/sympy-stubs/plotting/pygletplot/managed_window.pyi @@ -1,26 +1,14 @@ gl_lock = ... -class ManagedWindow(): + +class ManagedWindow: fps_limit = ... default_win_args = ... - def __init__(self, **win_args) -> None: - ... - - def __event_loop__(self, **win_args) -> None: - ... - - def close(self) -> None: - ... - - def setup(self) -> None: - ... - - def update(self, dt) -> None: - ... - - def draw(self) -> None: - ... - - + def __init__(self, **win_args) -> None: ... + def __event_loop__(self, **win_args) -> None: ... + def close(self) -> None: ... + def setup(self) -> None: ... + def update(self, dt) -> None: ... + def draw(self) -> None: ... -if __name__ == '__main__': +if __name__ == "__main__": ... diff --git a/stubs/sympy-stubs/plotting/pygletplot/plot.pyi b/stubs/sympy-stubs/plotting/pygletplot/plot.pyi index 813e7144..edcafd20 100644 --- a/stubs/sympy-stubs/plotting/pygletplot/plot.pyi +++ b/stubs/sympy-stubs/plotting/pygletplot/plot.pyi @@ -1,67 +1,26 @@ from sympy.utilities.decorator import doctest_depends_on -@doctest_depends_on(modules=('pyglet', )) +@doctest_depends_on(modules=("pyglet",)) class PygletPlot: - @doctest_depends_on(modules=('pyglet', )) - def __init__(self, *fargs, **win_args) -> None: - ... - - def show(self) -> None: - ... - - def close(self) -> None: - ... - - def saveimage(self, outfile=..., format=..., size=...) -> None: - ... - - def clear(self) -> None: - ... - - def __getitem__(self, i): - ... - - def __setitem__(self, i, args) -> None: - ... - - def __delitem__(self, i) -> None: - ... - - def firstavailableindex(self) -> int: - ... - - def append(self, *args) -> None: - ... - - def __len__(self) -> int: - ... - - def __iter__(self): - ... - - def __repr__(self) -> str: - ... - - def __str__(self) -> str: - ... - - def adjust_all_bounds(self) -> None: - ... - - def wait_for_calculations(self) -> None: - ... - - + @doctest_depends_on(modules=("pyglet",)) + def __init__(self, *fargs, **win_args) -> None: ... + def show(self) -> None: ... + def close(self) -> None: ... + def saveimage(self, outfile=..., format=..., size=...) -> None: ... + def clear(self) -> None: ... + def __getitem__(self, i): ... + def __setitem__(self, i, args) -> None: ... + def __delitem__(self, i) -> None: ... + def firstavailableindex(self) -> int: ... + def append(self, *args) -> None: ... + def __len__(self) -> int: ... + def __iter__(self): ... + def __repr__(self) -> str: ... + def __str__(self) -> str: ... + def adjust_all_bounds(self) -> None: ... + def wait_for_calculations(self) -> None: ... class ScreenShot: - def __init__(self, plot) -> None: - ... - - def __bool__(self) -> bool: - ... - - def save(self, outfile=..., format=..., size=...) -> None: - ... - - - + def __init__(self, plot) -> None: ... + def __bool__(self) -> bool: ... + def save(self, outfile=..., format=..., size=...) -> None: ... diff --git a/stubs/sympy-stubs/plotting/pygletplot/plot_axes.pyi b/stubs/sympy-stubs/plotting/pygletplot/plot_axes.pyi index dfd8db01..ff462d3b 100644 --- a/stubs/sympy-stubs/plotting/pygletplot/plot_axes.pyi +++ b/stubs/sympy-stubs/plotting/pygletplot/plot_axes.pyi @@ -1,80 +1,49 @@ from sympy.plotting.pygletplot.plot_object import PlotObject class PlotAxes(PlotObject): - def __init__(self, *args, style=..., none=..., frame=..., box=..., ordinate=..., stride=..., visible=..., overlay=..., colored=..., label_axes=..., label_ticks=..., tick_length=..., font_face=..., font_size=..., **kwargs) -> None: - ... - - def reset_resources(self) -> None: - ... - - def reset_bounding_box(self) -> None: - ... - - def draw(self) -> None: - ... - - def adjust_bounds(self, child_bounds) -> None: - ... - - def toggle_visible(self) -> None: - ... - - def toggle_colors(self) -> None: - ... - - + def __init__( + self, + *args, + style=..., + none=..., + frame=..., + box=..., + ordinate=..., + stride=..., + visible=..., + overlay=..., + colored=..., + label_axes=..., + label_ticks=..., + tick_length=..., + font_face=..., + font_size=..., + **kwargs, + ) -> None: ... + def reset_resources(self) -> None: ... + def reset_bounding_box(self) -> None: ... + def draw(self) -> None: ... + def adjust_bounds(self, child_bounds) -> None: ... + def toggle_visible(self) -> None: ... + def toggle_colors(self) -> None: ... class PlotAxesBase(PlotObject): - def __init__(self, parent_axes) -> None: - ... - - def draw(self) -> None: - ... - - def draw_background(self, color) -> None: - ... - - def draw_axis(self, axis, color): - ... - - def draw_text(self, text, position, color, scale=...) -> None: - ... - - def draw_line(self, v, color) -> None: - ... - - + def __init__(self, parent_axes) -> None: ... + def draw(self) -> None: ... + def draw_background(self, color) -> None: ... + def draw_axis(self, axis, color): ... + def draw_text(self, text, position, color, scale=...) -> None: ... + def draw_line(self, v, color) -> None: ... class PlotAxesOrdinate(PlotAxesBase): - def __init__(self, parent_axes) -> None: - ... - - def draw_axis(self, axis, color) -> None: - ... - - def draw_axis_line(self, axis, color, a_min, a_max, labels_visible) -> None: - ... - - def draw_axis_line_labels(self, axis, color, axis_line) -> None: - ... - - def draw_tick_line(self, axis, color, radius, tick, labels_visible) -> None: - ... - - def draw_tick_line_label(self, axis, color, radius, tick) -> None: - ... - - + def __init__(self, parent_axes) -> None: ... + def draw_axis(self, axis, color) -> None: ... + def draw_axis_line(self, axis, color, a_min, a_max, labels_visible) -> None: ... + def draw_axis_line_labels(self, axis, color, axis_line) -> None: ... + def draw_tick_line(self, axis, color, radius, tick, labels_visible) -> None: ... + def draw_tick_line_label(self, axis, color, radius, tick) -> None: ... class PlotAxesFrame(PlotAxesBase): - def __init__(self, parent_axes) -> None: - ... - - def draw_background(self, color) -> None: - ... - - def draw_axis(self, axis, color): - ... - - - + def __init__(self, parent_axes) -> None: ... + def draw_background(self, color) -> None: ... + def draw_axis(self, axis, color): ... diff --git a/stubs/sympy-stubs/plotting/pygletplot/plot_camera.pyi b/stubs/sympy-stubs/plotting/pygletplot/plot_camera.pyi index 00c5d4b4..7c4088bd 100644 --- a/stubs/sympy-stubs/plotting/pygletplot/plot_camera.pyi +++ b/stubs/sympy-stubs/plotting/pygletplot/plot_camera.pyi @@ -6,38 +6,14 @@ class PlotCamera: _default_dist = ... _default_ortho_dist = ... rot_presets = ... - def __init__(self, window, ortho=...) -> None: - ... - - def init_rot_matrix(self) -> None: - ... - - def set_rot_preset(self, preset_name) -> None: - ... - - def reset(self) -> None: - ... - - def mult_rot_matrix(self, rot) -> None: - ... - - def setup_projection(self) -> None: - ... - - def apply_transformation(self) -> None: - ... - - def spherical_rotate(self, p1, p2, sensitivity=...) -> None: - ... - - def euler_rotate(self, angle, x, y, z) -> None: - ... - - def zoom_relative(self, clicks, sensitivity) -> None: - ... - - def mouse_translate(self, x, y, dx, dy) -> None: - ... - - - + def __init__(self, window, ortho=...) -> None: ... + def init_rot_matrix(self) -> None: ... + def set_rot_preset(self, preset_name) -> None: ... + def reset(self) -> None: ... + def mult_rot_matrix(self, rot) -> None: ... + def setup_projection(self) -> None: ... + def apply_transformation(self) -> None: ... + def spherical_rotate(self, p1, p2, sensitivity=...) -> None: ... + def euler_rotate(self, angle, x, y, z) -> None: ... + def zoom_relative(self, clicks, sensitivity) -> None: ... + def mouse_translate(self, x, y, dx, dy) -> None: ... diff --git a/stubs/sympy-stubs/plotting/pygletplot/plot_controller.pyi b/stubs/sympy-stubs/plotting/pygletplot/plot_controller.pyi index 7b4ecbce..c826f95b 100644 --- a/stubs/sympy-stubs/plotting/pygletplot/plot_controller.pyi +++ b/stubs/sympy-stubs/plotting/pygletplot/plot_controller.pyi @@ -4,32 +4,12 @@ class PlotController: normal_key_sensitivity = ... modified_key_sensitivity = ... keymap = ... - def __init__(self, window, *, invert_mouse_zoom=..., **kwargs) -> None: - ... - - def update(self, dt): - ... - - def get_mouse_sensitivity(self) -> float: - ... - - def get_key_sensitivity(self) -> float: - ... - - def on_key_press(self, symbol, modifiers) -> None: - ... - - def on_key_release(self, symbol, modifiers) -> None: - ... - - def on_mouse_drag(self, x, y, dx, dy, buttons, modifiers) -> None: - ... - - def on_mouse_scroll(self, x, y, dx, dy) -> None: - ... - - def is_2D(self) -> bool: - ... - - - + def __init__(self, window, *, invert_mouse_zoom=..., **kwargs) -> None: ... + def update(self, dt): ... + def get_mouse_sensitivity(self) -> float: ... + def get_key_sensitivity(self) -> float: ... + def on_key_press(self, symbol, modifiers) -> None: ... + def on_key_release(self, symbol, modifiers) -> None: ... + def on_mouse_drag(self, x, y, dx, dy, buttons, modifiers) -> None: ... + def on_mouse_scroll(self, x, y, dx, dy) -> None: ... + def is_2D(self) -> bool: ... diff --git a/stubs/sympy-stubs/plotting/pygletplot/plot_curve.pyi b/stubs/sympy-stubs/plotting/pygletplot/plot_curve.pyi index 37105d6b..b3b89bf5 100644 --- a/stubs/sympy-stubs/plotting/pygletplot/plot_curve.pyi +++ b/stubs/sympy-stubs/plotting/pygletplot/plot_curve.pyi @@ -4,11 +4,5 @@ from sympy.plotting.pygletplot.plot_mode_base import PlotModeBase class PlotCurve(PlotModeBase): style_override = ... - def calculate_one_cvert(self, t) -> Any: - ... - - def draw_verts(self, use_cverts) -> Callable[[], None]: - ... - - - + def calculate_one_cvert(self, t) -> Any: ... + def draw_verts(self, use_cverts) -> Callable[[], None]: ... diff --git a/stubs/sympy-stubs/plotting/pygletplot/plot_interval.pyi b/stubs/sympy-stubs/plotting/pygletplot/plot_interval.pyi index 80f3a1de..b59d5b2f 100644 --- a/stubs/sympy-stubs/plotting/pygletplot/plot_interval.pyi +++ b/stubs/sympy-stubs/plotting/pygletplot/plot_interval.pyi @@ -5,72 +5,33 @@ from sympy.core.symbol import Symbol class PlotInterval: @staticmethod - def require_all_args(f) -> Callable[..., Any]: - ... - - def __init__(self, *args) -> None: - ... - - def get_v(self) -> Symbol | None: - ... - - def set_v(self, v) -> None: - ... - - def get_v_min(self) -> None: - ... - - def set_v_min(self, v_min) -> None: - ... - - def get_v_max(self) -> None: - ... - - def set_v_max(self, v_max) -> None: - ... - - def get_v_steps(self) -> Integer | None: - ... - - def set_v_steps(self, v_steps) -> None: - ... - + def require_all_args(f) -> Callable[..., Any]: ... + def __init__(self, *args) -> None: ... + def get_v(self) -> Symbol | None: ... + def set_v(self, v) -> None: ... + def get_v_min(self) -> None: ... + def set_v_min(self, v_min) -> None: ... + def get_v_max(self) -> None: ... + def set_v_max(self, v_max) -> None: ... + def get_v_steps(self) -> Integer | None: ... + def set_v_steps(self, v_steps) -> None: ... @require_all_args - def get_v_len(self) -> Any: - ... - + def get_v_len(self) -> Any: ... + v = ... v_min = ... v_max = ... v_steps = ... v_len = ... - def fill_from(self, b) -> None: - ... - + def fill_from(self, b) -> None: ... @staticmethod - def try_parse(*args) -> PlotInterval | None: - ... - - def __repr__(self) -> str: - ... - - def __str__(self) -> str: - ... - + def try_parse(*args) -> PlotInterval | None: ... + def __repr__(self) -> str: ... + def __str__(self) -> str: ... @require_all_args - def assert_complete(self) -> None: - ... - + def assert_complete(self) -> None: ... @require_all_args - def vrange(self) -> Generator[Any, Any, None]: - ... - + def vrange(self) -> Generator[Any, Any, None]: ... @require_all_args - def vrange2(self) -> Generator[tuple[Any, Any], Any, None]: - ... - - def frange(self) -> Generator[float, Any, None]: - ... - - - + def vrange2(self) -> Generator[tuple[Any, Any], Any, None]: ... + def frange(self) -> Generator[float, Any, None]: ... diff --git a/stubs/sympy-stubs/plotting/pygletplot/plot_mode.pyi b/stubs/sympy-stubs/plotting/pygletplot/plot_mode.pyi index 4afc92d7..d4e21656 100644 --- a/stubs/sympy-stubs/plotting/pygletplot/plot_mode.pyi +++ b/stubs/sympy-stubs/plotting/pygletplot/plot_mode.pyi @@ -4,18 +4,13 @@ class PlotMode(PlotObject): intervals = ... aliases = ... is_default = ... - def draw(self): - ... - + def draw(self): ... + _mode_alias_list = ... _mode_map = ... _mode_default_map = ... - def __new__(cls, *args, **kwargs) -> PlotMode: - ... - - _was_initialized = ... + def __new__(cls, *args, **kwargs) -> PlotMode: ... + _was_initialized = ... -def var_count_error(is_independent, is_plotting) -> str: - ... - +def var_count_error(is_independent, is_plotting) -> str: ... diff --git a/stubs/sympy-stubs/plotting/pygletplot/plot_mode_base.pyi b/stubs/sympy-stubs/plotting/pygletplot/plot_mode_base.pyi index 38118cce..d1512a2c 100644 --- a/stubs/sympy-stubs/plotting/pygletplot/plot_mode_base.pyi +++ b/stubs/sympy-stubs/plotting/pygletplot/plot_mode_base.pyi @@ -11,25 +11,16 @@ class PlotModeBase(PlotMode): default_wireframe_color = ... default_solid_color = ... default_rot_preset = ... - def __init__(self, *args, bounds_callback=..., **kwargs) -> None: - ... - + def __init__(self, *args, bounds_callback=..., **kwargs) -> None: ... @staticmethod - def synchronized(f) -> Callable[..., Any]: - ... - + def synchronized(f) -> Callable[..., Any]: ... @synchronized - def push_wireframe(self, function) -> None: - ... - + def push_wireframe(self, function) -> None: ... @synchronized - def push_solid(self, function) -> None: - ... - + def push_solid(self, function) -> None: ... @synchronized - def draw(self) -> None: - ... - + def draw(self) -> None: ... + style = ... color = ... calculating_verts = ... @@ -38,11 +29,5 @@ class PlotModeBase(PlotMode): calculating_cverts = ... calculating_cverts_pos = ... calculating_cverts_len = ... - def __str__(self) -> str: - ... - - def __repr__(self) -> str: - ... - - - + def __str__(self) -> str: ... + def __repr__(self) -> str: ... diff --git a/stubs/sympy-stubs/plotting/pygletplot/plot_modes.pyi b/stubs/sympy-stubs/plotting/pygletplot/plot_modes.pyi index 1650c265..5622c0a0 100644 --- a/stubs/sympy-stubs/plotting/pygletplot/plot_modes.pyi +++ b/stubs/sympy-stubs/plotting/pygletplot/plot_modes.pyi @@ -3,54 +3,44 @@ from typing import Callable from sympy.plotting.pygletplot.plot_curve import PlotCurve from sympy.plotting.pygletplot.plot_surface import PlotSurface -def float_vec3(f) -> Callable[..., tuple[float, float, float]]: - ... +def float_vec3(f) -> Callable[..., tuple[float, float, float]]: ... class Cartesian2D(PlotCurve): intervals = ... aliases = ... is_default = ... - class Cartesian3D(PlotSurface): intervals = ... aliases = ... is_default = ... - class ParametricCurve2D(PlotCurve): intervals = ... aliases = ... is_default = ... - class ParametricCurve3D(PlotCurve): intervals = ... aliases = ... is_default = ... - class ParametricSurface(PlotSurface): intervals = ... aliases = ... is_default = ... - class Polar(PlotCurve): intervals = ... aliases = ... is_default = ... - class Cylindrical(PlotSurface): intervals = ... aliases = ... is_default = ... - class Spherical(PlotSurface): intervals = ... aliases = ... is_default = ... - - diff --git a/stubs/sympy-stubs/plotting/pygletplot/plot_object.pyi b/stubs/sympy-stubs/plotting/pygletplot/plot_object.pyi index 7dd56820..abcd0125 100644 --- a/stubs/sympy-stubs/plotting/pygletplot/plot_object.pyi +++ b/stubs/sympy-stubs/plotting/pygletplot/plot_object.pyi @@ -1,7 +1,3 @@ class PlotObject: visible = ... - def draw(self) -> None: - ... - - - + def draw(self) -> None: ... diff --git a/stubs/sympy-stubs/plotting/pygletplot/plot_rotation.pyi b/stubs/sympy-stubs/plotting/pygletplot/plot_rotation.pyi index b5529e3a..a545c9d8 100644 --- a/stubs/sympy-stubs/plotting/pygletplot/plot_rotation.pyi +++ b/stubs/sympy-stubs/plotting/pygletplot/plot_rotation.pyi @@ -1,22 +1,12 @@ from ctypes import Array, c_float from typing import Any -def cross(a, b) -> tuple[Any, Any, Any]: - ... - -def dot(a, b): - ... - -def mag(a) -> float: - ... - -def norm(a) -> tuple[Any, Any, Any]: - ... - -def get_sphere_mapping(x, y, width, height) -> tuple[Any, Any, float] | tuple[Any, Any, Any]: - ... +def cross(a, b) -> tuple[Any, Any, Any]: ... +def dot(a, b): ... +def mag(a) -> float: ... +def norm(a) -> tuple[Any, Any, Any]: ... +def get_sphere_mapping(x, y, width, height) -> tuple[Any, Any, float] | tuple[Any, Any, Any]: ... rad2deg = ... -def get_spherical_rotatation(p1, p2, width, height, theta_multiplier) -> Array[c_float] | None: - ... +def get_spherical_rotatation(p1, p2, width, height, theta_multiplier) -> Array[c_float] | None: ... diff --git a/stubs/sympy-stubs/plotting/pygletplot/plot_surface.pyi b/stubs/sympy-stubs/plotting/pygletplot/plot_surface.pyi index e1afa893..e65c293e 100644 --- a/stubs/sympy-stubs/plotting/pygletplot/plot_surface.pyi +++ b/stubs/sympy-stubs/plotting/pygletplot/plot_surface.pyi @@ -4,11 +4,5 @@ from sympy.plotting.pygletplot.plot_mode_base import PlotModeBase class PlotSurface(PlotModeBase): default_rot_preset = ... - def calculate_one_cvert(self, u, v) -> Any: - ... - - def draw_verts(self, use_cverts, use_solid_color) -> Callable[[], None]: - ... - - - + def calculate_one_cvert(self, u, v) -> Any: ... + def draw_verts(self, use_cverts, use_solid_color) -> Callable[[], None]: ... diff --git a/stubs/sympy-stubs/plotting/pygletplot/plot_window.pyi b/stubs/sympy-stubs/plotting/pygletplot/plot_window.pyi index 11a3e685..d1b6f4d4 100644 --- a/stubs/sympy-stubs/plotting/pygletplot/plot_window.pyi +++ b/stubs/sympy-stubs/plotting/pygletplot/plot_window.pyi @@ -1,23 +1,11 @@ from sympy.plotting.pygletplot.managed_window import ManagedWindow class PlotWindow(ManagedWindow): - def __init__(self, plot, antialiasing=..., ortho=..., invert_mouse_zoom=..., linewidth=..., caption=..., **kwargs) -> None: - ... - - def setup(self) -> None: - ... - - def on_resize(self, w, h) -> None: - ... - - def update(self, dt) -> None: - ... - - def draw(self) -> None: - ... - - def update_caption(self, calc_verts_pos, calc_verts_len, calc_cverts_pos, calc_cverts_len) -> None: - ... - - - + def __init__( + self, plot, antialiasing=..., ortho=..., invert_mouse_zoom=..., linewidth=..., caption=..., **kwargs + ) -> None: ... + def setup(self) -> None: ... + def on_resize(self, w, h) -> None: ... + def update(self, dt) -> None: ... + def draw(self) -> None: ... + def update_caption(self, calc_verts_pos, calc_verts_len, calc_cverts_pos, calc_cverts_len) -> None: ... diff --git a/stubs/sympy-stubs/plotting/pygletplot/util.pyi b/stubs/sympy-stubs/plotting/pygletplot/util.pyi index 557c80e6..9cb51157 100644 --- a/stubs/sympy-stubs/plotting/pygletplot/util.pyi +++ b/stubs/sympy-stubs/plotting/pygletplot/util.pyi @@ -1,69 +1,29 @@ from ctypes import Array, c_float, c_int from typing import Any, Literal -def get_model_matrix(array_type=..., glGetMethod=...) -> Array[c_float]: - ... - -def get_projection_matrix(array_type=..., glGetMethod=...) -> Array[c_float]: - ... - -def get_viewport() -> Array[c_int]: - ... - -def get_direction_vectors() -> tuple[tuple[Any, Any, Any], tuple[Any, Any, Any], tuple[Any, Any, Any]]: - ... - -def get_view_direction_vectors() -> tuple[tuple[Any, Any, Any], tuple[Any, Any, Any], tuple[Any, Any, Any]]: - ... - -def get_basis_vectors() -> tuple[tuple[Literal[1], Literal[0], Literal[0]], tuple[Literal[0], Literal[1], Literal[0]], tuple[Literal[0], Literal[0], Literal[1]]]: - ... - -def screen_to_model(x, y, z) -> tuple[float, float, float]: - ... - -def model_to_screen(x, y, z) -> tuple[float, float, float]: - ... - -def vec_subs(a, b) -> tuple[Any, ...]: - ... - -def billboard_matrix() -> None: - ... - -def create_bounds() -> list[list[Any]]: - ... - -def update_bounds(b, v) -> None: - ... - -def interpolate(a_min, a_max, a_ratio): - ... - -def rinterpolate(a_min, a_max, a_value): - ... - -def interpolate_color(color1, color2, ratio) -> tuple[Any, ...]: - ... - -def scale_value(v, v_min, v_len): - ... - -def scale_value_list(flist) -> list[Any]: - ... - -def strided_range(r_min, r_max, stride, max_steps=...) -> list[Any]: - ... - -def parse_option_string(s) -> dict[Any, Any] | None: - ... - -def dot_product(v1, v2) -> int: - ... - -def vec_sub(v1, v2) -> tuple[Any, ...]: - ... - -def vec_mag(v) -> Any: - ... - +def get_model_matrix(array_type=..., glGetMethod=...) -> Array[c_float]: ... +def get_projection_matrix(array_type=..., glGetMethod=...) -> Array[c_float]: ... +def get_viewport() -> Array[c_int]: ... +def get_direction_vectors() -> tuple[tuple[Any, Any, Any], tuple[Any, Any, Any], tuple[Any, Any, Any]]: ... +def get_view_direction_vectors() -> tuple[tuple[Any, Any, Any], tuple[Any, Any, Any], tuple[Any, Any, Any]]: ... +def get_basis_vectors() -> tuple[ + tuple[Literal[1], Literal[0], Literal[0]], + tuple[Literal[0], Literal[1], Literal[0]], + tuple[Literal[0], Literal[0], Literal[1]], +]: ... +def screen_to_model(x, y, z) -> tuple[float, float, float]: ... +def model_to_screen(x, y, z) -> tuple[float, float, float]: ... +def vec_subs(a, b) -> tuple[Any, ...]: ... +def billboard_matrix() -> None: ... +def create_bounds() -> list[list[Any]]: ... +def update_bounds(b, v) -> None: ... +def interpolate(a_min, a_max, a_ratio): ... +def rinterpolate(a_min, a_max, a_value): ... +def interpolate_color(color1, color2, ratio) -> tuple[Any, ...]: ... +def scale_value(v, v_min, v_len): ... +def scale_value_list(flist) -> list[Any]: ... +def strided_range(r_min, r_max, stride, max_steps=...) -> list[Any]: ... +def parse_option_string(s) -> dict[Any, Any] | None: ... +def dot_product(v1, v2) -> int: ... +def vec_sub(v1, v2) -> tuple[Any, ...]: ... +def vec_mag(v) -> Any: ... diff --git a/stubs/sympy-stubs/plotting/textplot.pyi b/stubs/sympy-stubs/plotting/textplot.pyi index ebdf9e72..fdf366dc 100644 --- a/stubs/sympy-stubs/plotting/textplot.pyi +++ b/stubs/sympy-stubs/plotting/textplot.pyi @@ -1,17 +1,7 @@ from typing import Any, Generator -def is_valid(x) -> bool: - ... - -def rescale(y, W, H, mi, ma) -> list[Any]: - ... - -def linspace(start, stop, num) -> list[Any]: - ... - -def textplot_str(expr, a, b, W=..., H=...) -> Generator[str, Any, None]: - ... - -def textplot(expr, a, b, W=..., H=...) -> None: - ... - +def is_valid(x) -> bool: ... +def rescale(y, W, H, mi, ma) -> list[Any]: ... +def linspace(start, stop, num) -> list[Any]: ... +def textplot_str(expr, a, b, W=..., H=...) -> Generator[str, Any, None]: ... +def textplot(expr, a, b, W=..., H=...) -> None: ... diff --git a/stubs/sympy-stubs/polys/__init__.pyi b/stubs/sympy-stubs/polys/__init__.pyi index a45e679c..c2ce178c 100644 --- a/stubs/sympy-stubs/polys/__init__.pyi +++ b/stubs/sympy-stubs/polys/__init__.pyi @@ -154,4 +154,180 @@ from sympy.polys.rings import ring, sring, vring, xring from sympy.polys.rootoftools import ComplexRootOf, CRootOf, RootOf, RootSum, rootof from sympy.polys.specialpolys import cyclotomic_poly, interpolating_poly, random_poly, swinnerton_dyer_poly, symmetric_poly -__all__ = ['Poly', 'PurePoly', 'poly_from_expr', 'parallel_poly_from_expr', 'degree', 'total_degree', 'degree_list', 'LC', 'LM', 'LT', 'pdiv', 'prem', 'pquo', 'pexquo', 'div', 'rem', 'quo', 'exquo', 'half_gcdex', 'gcdex', 'invert', 'subresultants', 'resultant', 'discriminant', 'cofactors', 'gcd_list', 'gcd', 'lcm_list', 'lcm', 'terms_gcd', 'trunc', 'monic', 'content', 'primitive', 'compose', 'decompose', 'sturm', 'gff_list', 'gff', 'sqf_norm', 'sqf_part', 'sqf_list', 'sqf', 'factor_list', 'factor', 'intervals', 'refine_root', 'count_roots', 'real_roots', 'nroots', 'ground_roots', 'nth_power_roots_poly', 'cancel', 'reduced', 'groebner', 'is_zero_dimensional', 'GroebnerBasis', 'poly', 'symmetrize', 'horner', 'interpolate', 'rational_interpolate', 'viete', 'together', 'BasePolynomialError', 'ExactQuotientFailed', 'PolynomialDivisionFailed', 'OperationNotSupported', 'HeuristicGCDFailed', 'HomomorphismFailed', 'IsomorphismFailed', 'ExtraneousFactors', 'EvaluationFailed', 'RefinementFailed', 'CoercionFailed', 'NotInvertible', 'NotReversible', 'NotAlgebraic', 'DomainError', 'PolynomialError', 'UnificationFailed', 'GeneratorsError', 'GeneratorsNeeded', 'ComputationFailed', 'UnivariatePolynomialError', 'MultivariatePolynomialError', 'PolificationFailed', 'OptionError', 'FlagError', 'minpoly', 'minimal_polynomial', 'primitive_element', 'field_isomorphism', 'to_number_field', 'isolate', 'round_two', 'prime_decomp', 'prime_valuation', 'galois_group', 'itermonomials', 'Monomial', 'lex', 'grlex', 'grevlex', 'ilex', 'igrlex', 'igrevlex', 'CRootOf', 'rootof', 'RootOf', 'ComplexRootOf', 'RootSum', 'roots', 'Domain', 'FiniteField', 'IntegerRing', 'RationalField', 'RealField', 'ComplexField', 'PythonFiniteField', 'GMPYFiniteField', 'PythonIntegerRing', 'GMPYIntegerRing', 'PythonRational', 'GMPYRationalField', 'AlgebraicField', 'PolynomialRing', 'FractionField', 'ExpressionDomain', 'FF_python', 'FF_gmpy', 'ZZ_python', 'ZZ_gmpy', 'QQ_python', 'QQ_gmpy', 'GF', 'FF', 'ZZ', 'QQ', 'ZZ_I', 'QQ_I', 'RR', 'CC', 'EX', 'EXRAW', 'construct_domain', 'swinnerton_dyer_poly', 'cyclotomic_poly', 'symmetric_poly', 'random_poly', 'interpolating_poly', 'jacobi_poly', 'chebyshevt_poly', 'chebyshevu_poly', 'hermite_poly', 'hermite_prob_poly', 'legendre_poly', 'laguerre_poly', 'bernoulli_poly', 'bernoulli_c_poly', 'genocchi_poly', 'euler_poly', 'andre_poly', 'apart', 'apart_list', 'assemble_partfrac_list', 'Options', 'ring', 'xring', 'vring', 'sring', 'field', 'xfield', 'vfield', 'sfield'] +__all__ = [ + "Poly", + "PurePoly", + "poly_from_expr", + "parallel_poly_from_expr", + "degree", + "total_degree", + "degree_list", + "LC", + "LM", + "LT", + "pdiv", + "prem", + "pquo", + "pexquo", + "div", + "rem", + "quo", + "exquo", + "half_gcdex", + "gcdex", + "invert", + "subresultants", + "resultant", + "discriminant", + "cofactors", + "gcd_list", + "gcd", + "lcm_list", + "lcm", + "terms_gcd", + "trunc", + "monic", + "content", + "primitive", + "compose", + "decompose", + "sturm", + "gff_list", + "gff", + "sqf_norm", + "sqf_part", + "sqf_list", + "sqf", + "factor_list", + "factor", + "intervals", + "refine_root", + "count_roots", + "real_roots", + "nroots", + "ground_roots", + "nth_power_roots_poly", + "cancel", + "reduced", + "groebner", + "is_zero_dimensional", + "GroebnerBasis", + "poly", + "symmetrize", + "horner", + "interpolate", + "rational_interpolate", + "viete", + "together", + "BasePolynomialError", + "ExactQuotientFailed", + "PolynomialDivisionFailed", + "OperationNotSupported", + "HeuristicGCDFailed", + "HomomorphismFailed", + "IsomorphismFailed", + "ExtraneousFactors", + "EvaluationFailed", + "RefinementFailed", + "CoercionFailed", + "NotInvertible", + "NotReversible", + "NotAlgebraic", + "DomainError", + "PolynomialError", + "UnificationFailed", + "GeneratorsError", + "GeneratorsNeeded", + "ComputationFailed", + "UnivariatePolynomialError", + "MultivariatePolynomialError", + "PolificationFailed", + "OptionError", + "FlagError", + "minpoly", + "minimal_polynomial", + "primitive_element", + "field_isomorphism", + "to_number_field", + "isolate", + "round_two", + "prime_decomp", + "prime_valuation", + "galois_group", + "itermonomials", + "Monomial", + "lex", + "grlex", + "grevlex", + "ilex", + "igrlex", + "igrevlex", + "CRootOf", + "rootof", + "RootOf", + "ComplexRootOf", + "RootSum", + "roots", + "Domain", + "FiniteField", + "IntegerRing", + "RationalField", + "RealField", + "ComplexField", + "PythonFiniteField", + "GMPYFiniteField", + "PythonIntegerRing", + "GMPYIntegerRing", + "PythonRational", + "GMPYRationalField", + "AlgebraicField", + "PolynomialRing", + "FractionField", + "ExpressionDomain", + "FF_python", + "FF_gmpy", + "ZZ_python", + "ZZ_gmpy", + "QQ_python", + "QQ_gmpy", + "GF", + "FF", + "ZZ", + "QQ", + "ZZ_I", + "QQ_I", + "RR", + "CC", + "EX", + "EXRAW", + "construct_domain", + "swinnerton_dyer_poly", + "cyclotomic_poly", + "symmetric_poly", + "random_poly", + "interpolating_poly", + "jacobi_poly", + "chebyshevt_poly", + "chebyshevu_poly", + "hermite_poly", + "hermite_prob_poly", + "legendre_poly", + "laguerre_poly", + "bernoulli_poly", + "bernoulli_c_poly", + "genocchi_poly", + "euler_poly", + "andre_poly", + "apart", + "apart_list", + "assemble_partfrac_list", + "Options", + "ring", + "xring", + "vring", + "sring", + "field", + "xfield", + "vfield", + "sfield", +] diff --git a/stubs/sympy-stubs/polys/agca/extensions.pyi b/stubs/sympy-stubs/polys/agca/extensions.pyi index e03a05f8..29097eac 100644 --- a/stubs/sympy-stubs/polys/agca/extensions.pyi +++ b/stubs/sympy-stubs/polys/agca/extensions.pyi @@ -5,129 +5,62 @@ from sympy.polys.domains.domain import Domain from sympy.polys.domains.domainelement import DomainElement from sympy.printing.defaults import DefaultPrinting -class ExtensionElement(DomainElement, DefaultPrinting): # type: ignore +class ExtensionElement(DomainElement, DefaultPrinting): # type: ignore __slots__ = ... - def __init__(self, rep, ext) -> None: - ... - - def parent(self) -> Any: - ... - - def __bool__(self) -> bool: - ... - - def __pos__(self) -> Self: - ... - - def __neg__(self) -> ExtElem: - ... - - def __add__(self, g) -> ExtElem | NotImplementedType: - ... - + def __init__(self, rep, ext) -> None: ... + def parent(self) -> Any: ... + def __bool__(self) -> bool: ... + def __pos__(self) -> Self: ... + def __neg__(self) -> ExtElem: ... + def __add__(self, g) -> ExtElem | NotImplementedType: ... + __radd__ = ... - def __sub__(self, g) -> ExtElem | NotImplementedType: - ... - - def __rsub__(self, g) -> ExtElem | NotImplementedType: - ... - - def __mul__(self, g) -> ExtElem | NotImplementedType: - ... - + def __sub__(self, g) -> ExtElem | NotImplementedType: ... + def __rsub__(self, g) -> ExtElem | NotImplementedType: ... + def __mul__(self, g) -> ExtElem | NotImplementedType: ... + __rmul__ = ... - def inverse(self) -> ExtElem: - ... - - def __truediv__(self, g) -> NotImplementedType | ExtElem: - ... - + def inverse(self) -> ExtElem: ... + def __truediv__(self, g) -> NotImplementedType | ExtElem: ... + __floordiv__ = ... - def __rtruediv__(self, g) -> NotImplementedType: - ... - + def __rtruediv__(self, g) -> NotImplementedType: ... + __rfloordiv__ = ... - def __mod__(self, g) -> NotImplementedType: - ... - - def __rmod__(self, g) -> NotImplementedType: - ... - - def __pow__(self, n) -> ExtElem: - ... - - def __eq__(self, g) -> bool: - ... - - def __ne__(self, g) -> bool: - ... - - def __hash__(self) -> int: - ... - - def __str__(self) -> str: - ... - + def __mod__(self, g) -> NotImplementedType: ... + def __rmod__(self, g) -> NotImplementedType: ... + def __pow__(self, n) -> ExtElem: ... + def __eq__(self, g) -> bool: ... + def __ne__(self, g) -> bool: ... + def __hash__(self) -> int: ... + def __str__(self) -> str: ... + __repr__ = ... @property - def is_ground(f): - ... - - def to_ground(self): - ... - - + def is_ground(f): ... + def to_ground(self): ... ExtElem = ExtensionElement -class MonogenicFiniteExtension(Domain): # type: ignore + +class MonogenicFiniteExtension(Domain): # type: ignore is_FiniteExtension = ... dtype = ExtensionElement - def __init__(self, mod) -> None: - ... - - def new(self, arg) -> ExtElem: - ... - - def __eq__(self, other) -> bool: - ... - - def __hash__(self) -> int: - ... - - def __str__(self) -> str: - ... - - __repr__ = ... - def convert(self, f, base=...) -> ExtElem: - ... - - def convert_from(self, f, base) -> ExtElem: - ... - - def to_sympy(self, f): - ... - - def from_sympy(self, f) -> ExtElem: - ... - - def set_domain(self, K) -> Self: - ... - - def drop(self, *symbols) -> Self: - ... - - def quo(self, f, g) -> ExtElem: - ... - - def exquo(self, f, g) -> ExtElem: - ... - - def is_negative(self, a) -> Literal[False]: - ... - - def is_unit(self, a) -> bool | None: - ... - + def __init__(self, mod) -> None: ... + def new(self, arg) -> ExtElem: ... + def __eq__(self, other) -> bool: ... + def __hash__(self) -> int: ... + def __str__(self) -> str: ... + __repr__ = ... + def convert(self, f, base=...) -> ExtElem: ... + def convert_from(self, f, base) -> ExtElem: ... + def to_sympy(self, f): ... + def from_sympy(self, f) -> ExtElem: ... + def set_domain(self, K) -> Self: ... + def drop(self, *symbols) -> Self: ... + def quo(self, f, g) -> ExtElem: ... + def exquo(self, f, g) -> ExtElem: ... + def is_negative(self, a) -> Literal[False]: ... + def is_unit(self, a) -> bool | None: ... FiniteExtension = MonogenicFiniteExtension diff --git a/stubs/sympy-stubs/polys/agca/homomorphisms.pyi b/stubs/sympy-stubs/polys/agca/homomorphisms.pyi index eb2fe686..14ccfd44 100644 --- a/stubs/sympy-stubs/polys/agca/homomorphisms.pyi +++ b/stubs/sympy-stubs/polys/agca/homomorphisms.pyi @@ -2,80 +2,32 @@ from types import NotImplementedType from typing import Self class ModuleHomomorphism: - def __init__(self, domain, codomain) -> None: - ... - - def kernel(self): - ... - - def image(self): - ... - - def restrict_domain(self, sm) -> Self: - ... - - def restrict_codomain(self, sm) -> Self: - ... - - def quotient_domain(self, sm) -> Self: - ... - - def quotient_codomain(self, sm) -> Self: - ... - - def __call__(self, elem): - ... - - def __mul__(self, oth) -> NotImplementedType: - ... - - __rmul__ = ... - def __truediv__(self, oth) -> NotImplementedType: - ... - - def __add__(self, oth) -> NotImplementedType: - ... - - def __sub__(self, oth) -> NotImplementedType: - ... - - def is_injective(self): - ... - - def is_surjective(self): - ... - - def is_isomorphism(self): - ... - - def is_zero(self): - ... - - def __eq__(self, oth) -> bool: - ... - - def __ne__(self, oth) -> bool: - ... - + def __init__(self, domain, codomain) -> None: ... + def kernel(self): ... + def image(self): ... + def restrict_domain(self, sm) -> Self: ... + def restrict_codomain(self, sm) -> Self: ... + def quotient_domain(self, sm) -> Self: ... + def quotient_codomain(self, sm) -> Self: ... + def __call__(self, elem): ... + def __mul__(self, oth) -> NotImplementedType: ... + __rmul__ = ... + def __truediv__(self, oth) -> NotImplementedType: ... + def __add__(self, oth) -> NotImplementedType: ... + def __sub__(self, oth) -> NotImplementedType: ... + def is_injective(self): ... + def is_surjective(self): ... + def is_isomorphism(self): ... + def is_zero(self): ... + def __eq__(self, oth) -> bool: ... + def __ne__(self, oth) -> bool: ... class MatrixHomomorphism(ModuleHomomorphism): - def __init__(self, domain, codomain, matrix) -> None: - ... - - def __repr__(self) -> str: - ... - - - -class FreeModuleHomomorphism(MatrixHomomorphism): - ... - - -class SubModuleHomomorphism(MatrixHomomorphism): - ... - + def __init__(self, domain, codomain, matrix) -> None: ... + def __repr__(self) -> str: ... -def homomorphism(domain, codomain, matrix) -> FreeModuleHomomorphism: - ... +class FreeModuleHomomorphism(MatrixHomomorphism): ... +class SubModuleHomomorphism(MatrixHomomorphism): ... +def homomorphism(domain, codomain, matrix) -> FreeModuleHomomorphism: ... diff --git a/stubs/sympy-stubs/polys/agca/ideals.pyi b/stubs/sympy-stubs/polys/agca/ideals.pyi index 0406b702..911a577c 100644 --- a/stubs/sympy-stubs/polys/agca/ideals.pyi +++ b/stubs/sympy-stubs/polys/agca/ideals.pyi @@ -4,101 +4,40 @@ from typing import Any, Generator, LiteralString from sympy.polys.polyutils import IntegerPowerable class Ideal(IntegerPowerable): - def is_whole_ring(self): - ... - - def is_zero(self): - ... - - def is_prime(self): - ... - - def is_maximal(self): - ... - - def is_radical(self): - ... - - def is_primary(self): - ... - - def is_principal(self): - ... - - def radical(self): - ... - - def depth(self): - ... - - def height(self): - ... - - def __init__(self, ring) -> None: - ... - - def contains(self, elem): - ... - - def subset(self, other) -> bool: - ... - - def quotient(self, J, **opts): - ... - - def intersect(self, J): - ... - - def saturate(self, J): - ... - - def union(self, J): - ... - - def product(self, J): - ... - - def reduce_element(self, x): - ... - - def __add__(self, e): - ... - + def is_whole_ring(self): ... + def is_zero(self): ... + def is_prime(self): ... + def is_maximal(self): ... + def is_radical(self): ... + def is_primary(self): ... + def is_principal(self): ... + def radical(self): ... + def depth(self): ... + def height(self): ... + def __init__(self, ring) -> None: ... + def contains(self, elem): ... + def subset(self, other) -> bool: ... + def quotient(self, J, **opts): ... + def intersect(self, J): ... + def saturate(self, J): ... + def union(self, J): ... + def product(self, J): ... + def reduce_element(self, x): ... + def __add__(self, e): ... + __radd__ = ... - def __mul__(self, e) -> NotImplementedType: - ... - - __rmul__ = ... - def __eq__(self, e) -> bool: - ... - - def __ne__(self, e) -> bool: - ... - + def __mul__(self, e) -> NotImplementedType: ... + __rmul__ = ... + def __eq__(self, e) -> bool: ... + def __ne__(self, e) -> bool: ... class ModuleImplementedIdeal(Ideal): - def __init__(self, ring, module) -> None: - ... - + def __init__(self, ring, module) -> None: ... @property - def gens(self) -> Generator[Any, None, None]: - ... - - def is_zero(self): - ... - - def is_whole_ring(self): - ... - - def __repr__(self) -> LiteralString: - ... - - def in_terms_of_generators(self, e): - ... - - def reduce_element(self, x, **options): - ... - - - + def gens(self) -> Generator[Any, None, None]: ... + def is_zero(self): ... + def is_whole_ring(self): ... + def __repr__(self) -> LiteralString: ... + def in_terms_of_generators(self, e): ... + def reduce_element(self, x, **options): ... diff --git a/stubs/sympy-stubs/polys/agca/modules.pyi b/stubs/sympy-stubs/polys/agca/modules.pyi index 5b299008..b924ee3d 100644 --- a/stubs/sympy-stubs/polys/agca/modules.pyi +++ b/stubs/sympy-stubs/polys/agca/modules.pyi @@ -5,307 +5,126 @@ from sympy.polys.agca.homomorphisms import FreeModuleHomomorphism from sympy.polys.orderings import ProductOrder class Module: - def __init__(self, ring) -> None: - ... - - def convert(self, elem, M=...): - ... - - def submodule(self, *gens): - ... - - def quotient_module(self, other): - ... - - def __truediv__(self, e): - ... - - def contains(self, elem) -> bool: - ... - - def __contains__(self, elem) -> bool: - ... - - def subset(self, other) -> bool: - ... - - def __eq__(self, other) -> bool: - ... - - def __ne__(self, other) -> bool: - ... - - def is_zero(self): - ... - - def is_submodule(self, other): - ... - - def multiply_ideal(self, other): - ... - - def __mul__(self, e) -> NotImplementedType: - ... - - __rmul__ = ... - def identity_hom(self): - ... - + def __init__(self, ring) -> None: ... + def convert(self, elem, M=...): ... + def submodule(self, *gens): ... + def quotient_module(self, other): ... + def __truediv__(self, e): ... + def contains(self, elem) -> bool: ... + def __contains__(self, elem) -> bool: ... + def subset(self, other) -> bool: ... + def __eq__(self, other) -> bool: ... + def __ne__(self, other) -> bool: ... + def is_zero(self): ... + def is_submodule(self, other): ... + def multiply_ideal(self, other): ... + def __mul__(self, e) -> NotImplementedType: ... + __rmul__ = ... + def identity_hom(self): ... class ModuleElement: - def __init__(self, module, data) -> None: - ... - - def add(self, d1, d2): - ... - - def mul(self, m, d): - ... - - def div(self, m, d): - ... - - def eq(self, d1, d2): - ... - - def __add__(self, om) -> NotImplementedType | Self: - ... - + def __init__(self, module, data) -> None: ... + def add(self, d1, d2): ... + def mul(self, m, d): ... + def div(self, m, d): ... + def eq(self, d1, d2): ... + def __add__(self, om) -> NotImplementedType | Self: ... + __radd__ = ... - def __neg__(self) -> Self: - ... - - def __sub__(self, om) -> NotImplementedType | Self: - ... - - def __rsub__(self, om) -> NotImplementedType | ModuleElement: - ... - - def __mul__(self, o) -> NotImplementedType | Self: - ... - - __rmul__ = ... - def __truediv__(self, o) -> NotImplementedType | Self: - ... - - def __eq__(self, om) -> bool: - ... - - def __ne__(self, om) -> bool: - ... - + def __neg__(self) -> Self: ... + def __sub__(self, om) -> NotImplementedType | Self: ... + def __rsub__(self, om) -> NotImplementedType | ModuleElement: ... + def __mul__(self, o) -> NotImplementedType | Self: ... + __rmul__ = ... + def __truediv__(self, o) -> NotImplementedType | Self: ... + def __eq__(self, om) -> bool: ... + def __ne__(self, om) -> bool: ... class FreeModuleElement(ModuleElement): - def add(self, d1, d2) -> tuple[Any, ...]: - ... - - def mul(self, d, p) -> tuple[Any, ...]: - ... - - def div(self, d, p) -> tuple[Any, ...]: - ... - - def __repr__(self) -> LiteralString: - ... - - def __iter__(self): - ... - - def __getitem__(self, idx): - ... - - + def add(self, d1, d2) -> tuple[Any, ...]: ... + def mul(self, d, p) -> tuple[Any, ...]: ... + def div(self, d, p) -> tuple[Any, ...]: ... + def __repr__(self) -> LiteralString: ... + def __iter__(self): ... + def __getitem__(self, idx): ... class FreeModule(Module): dtype = FreeModuleElement - def __init__(self, ring, rank) -> None: - ... - - def __repr__(self) -> str: - ... - - def is_submodule(self, other) -> Literal[False]: - ... - - def convert(self, elem, M=...) -> FreeModuleElement: - ... - - def is_zero(self): - ... - - def basis(self) -> tuple[FreeModuleElement, ...]: - ... - - def quotient_module(self, submodule) -> QuotientModule: - ... - - def multiply_ideal(self, other): - ... - - def identity_hom(self) -> FreeModuleHomomorphism: - ... - - + def __init__(self, ring, rank) -> None: ... + def __repr__(self) -> str: ... + def is_submodule(self, other) -> Literal[False]: ... + def convert(self, elem, M=...) -> FreeModuleElement: ... + def is_zero(self): ... + def basis(self) -> tuple[FreeModuleElement, ...]: ... + def quotient_module(self, submodule) -> QuotientModule: ... + def multiply_ideal(self, other): ... + def identity_hom(self) -> FreeModuleHomomorphism: ... class FreeModulePolyRing(FreeModule): - def __init__(self, ring, rank) -> None: - ... - - def submodule(self, *gens, **opts) -> SubModulePolyRing: - ... - - + def __init__(self, ring, rank) -> None: ... + def submodule(self, *gens, **opts) -> SubModulePolyRing: ... class FreeModuleQuotientRing(FreeModule): - def __init__(self, ring, rank) -> None: - ... - - def __repr__(self) -> str: - ... - - def submodule(self, *gens, **opts) -> SubModuleQuotientRing: - ... - - def lift(self, elem): - ... - - def unlift(self, elem) -> FreeModuleElement: - ... - - + def __init__(self, ring, rank) -> None: ... + def __repr__(self) -> str: ... + def submodule(self, *gens, **opts) -> SubModuleQuotientRing: ... + def lift(self, elem): ... + def unlift(self, elem) -> FreeModuleElement: ... class SubModule(Module): - def __init__(self, gens, container) -> None: - ... - - def __repr__(self) -> str: - ... - - def convert(self, elem, M=...): - ... - - def intersect(self, other, **options): - ... - - def module_quotient(self, other, **options): - ... - - def union(self, other) -> Self: - ... - - def is_zero(self) -> bool: - ... - - def submodule(self, *gens) -> Self: - ... - - def is_full_module(self) -> bool: - ... - - def is_submodule(self, other) -> bool: - ... - - def syzygy_module(self, **opts): - ... - - def in_terms_of_generators(self, e): - ... - - def reduce_element(self, x): - ... - - def quotient_module(self, other, **opts) -> SubQuotientModule: - ... - - def __add__(self, oth): - ... - - __radd__ = ... - def multiply_ideal(self, I) -> Self: - ... - - def inclusion_hom(self): - ... - - def identity_hom(self): - ... - + def __init__(self, gens, container) -> None: ... + def __repr__(self) -> str: ... + def convert(self, elem, M=...): ... + def intersect(self, other, **options): ... + def module_quotient(self, other, **options): ... + def union(self, other) -> Self: ... + def is_zero(self) -> bool: ... + def submodule(self, *gens) -> Self: ... + def is_full_module(self) -> bool: ... + def is_submodule(self, other) -> bool: ... + def syzygy_module(self, **opts): ... + def in_terms_of_generators(self, e): ... + def reduce_element(self, x): ... + def quotient_module(self, other, **opts) -> SubQuotientModule: ... + def __add__(self, oth): ... + __radd__ = ... + def multiply_ideal(self, I) -> Self: ... + def inclusion_hom(self): ... + def identity_hom(self): ... class SubQuotientModule(SubModule): - def __init__(self, gens, container, **opts) -> None: - ... - - def is_full_module(self): - ... - - def quotient_hom(self): - ... - - + def __init__(self, gens, container, **opts) -> None: ... + def is_full_module(self): ... + def quotient_hom(self): ... _subs0 = ... _subs1 = ... -class ModuleOrder(ProductOrder): - def __init__(self, o1, o2, TOP) -> None: - ... - +class ModuleOrder(ProductOrder): + def __init__(self, o1, o2, TOP) -> None: ... class SubModulePolyRing(SubModule): - def __init__(self, gens, container, order=..., TOP=...) -> None: - ... - - def __eq__(self, other) -> bool: - ... - - def reduce_element(self, x, NF=...): - ... - - + def __init__(self, gens, container, order=..., TOP=...) -> None: ... + def __eq__(self, other) -> bool: ... + def reduce_element(self, x, NF=...): ... class SubModuleQuotientRing(SubModule): - def __init__(self, gens, container) -> None: - ... - - + def __init__(self, gens, container) -> None: ... class QuotientModuleElement(ModuleElement): - def eq(self, d1, d2): - ... - - def __repr__(self) -> str: - ... - - + def eq(self, d1, d2): ... + def __repr__(self) -> str: ... class QuotientModule(Module): dtype = QuotientModuleElement - def __init__(self, ring, base, submodule) -> None: - ... - - def __repr__(self) -> str: - ... - - def is_zero(self): - ... - - def is_submodule(self, other) -> Literal[False]: - ... - - def submodule(self, *gens, **opts) -> SubQuotientModule: - ... - - def convert(self, elem, M=...) -> QuotientModuleElement: - ... - - def identity_hom(self): - ... - - def quotient_hom(self): - ... - - - + def __init__(self, ring, base, submodule) -> None: ... + def __repr__(self) -> str: ... + def is_zero(self): ... + def is_submodule(self, other) -> Literal[False]: ... + def submodule(self, *gens, **opts) -> SubQuotientModule: ... + def convert(self, elem, M=...) -> QuotientModuleElement: ... + def identity_hom(self): ... + def quotient_hom(self): ... diff --git a/stubs/sympy-stubs/polys/appellseqs.pyi b/stubs/sympy-stubs/polys/appellseqs.pyi index 3dcf40a1..194920b1 100644 --- a/stubs/sympy-stubs/polys/appellseqs.pyi +++ b/stubs/sympy-stubs/polys/appellseqs.pyi @@ -2,38 +2,18 @@ from typing import Any from sympy.utilities import public -def dup_bernoulli(n, K) -> list[Any]: - ... - +def dup_bernoulli(n, K) -> list[Any]: ... @public -def bernoulli_poly(n, x=..., polys=...): - ... - -def dup_bernoulli_c(n, K) -> list[Any]: - ... - +def bernoulli_poly(n, x=..., polys=...): ... +def dup_bernoulli_c(n, K) -> list[Any]: ... @public -def bernoulli_c_poly(n, x=..., polys=...): - ... - -def dup_genocchi(n, K) -> list[Any]: - ... - +def bernoulli_c_poly(n, x=..., polys=...): ... +def dup_genocchi(n, K) -> list[Any]: ... @public -def genocchi_poly(n, x=..., polys=...): - ... - -def dup_euler(n, K) -> list[Any]: - ... - +def genocchi_poly(n, x=..., polys=...): ... +def dup_euler(n, K) -> list[Any]: ... @public -def euler_poly(n, x=..., polys=...): - ... - -def dup_andre(n, K) -> list[Any]: - ... - +def euler_poly(n, x=..., polys=...): ... +def dup_andre(n, K) -> list[Any]: ... @public -def andre_poly(n, x=..., polys=...): - ... - +def andre_poly(n, x=..., polys=...): ... diff --git a/stubs/sympy-stubs/polys/compatibility.pyi b/stubs/sympy-stubs/polys/compatibility.pyi index a3418d53..ec2b2d8f 100644 --- a/stubs/sympy-stubs/polys/compatibility.pyi +++ b/stubs/sympy-stubs/polys/compatibility.pyi @@ -11,887 +11,329 @@ class IPolys: domain = ... order = ... gens = ... - def drop(self, gen) -> None: - ... - - def clone(self, symbols=..., domain=..., order=...) -> None: - ... - - def to_ground(self) -> None: - ... - - def ground_new(self, element) -> None: - ... - - def domain_new(self, element) -> None: - ... - - def from_dict(self, d) -> None: - ... - - def wrap(self, element) -> PolyElement | None: - ... - - def to_dense(self, element) -> list[Any] | list[list[Any]]: - ... - - def from_dense(self, element) -> None: - ... - - def dup_add_term(self, f, c, i) -> None: - ... - - def dmp_add_term(self, f, c, i) -> None: - ... - - def dup_sub_term(self, f, c, i) -> None: - ... - - def dmp_sub_term(self, f, c, i) -> None: - ... - - def dup_mul_term(self, f, c, i) -> None: - ... - - def dmp_mul_term(self, f, c, i) -> None: - ... - - def dup_add_ground(self, f, c) -> None: - ... - - def dmp_add_ground(self, f, c) -> None: - ... - - def dup_sub_ground(self, f, c) -> None: - ... - - def dmp_sub_ground(self, f, c) -> None: - ... - - def dup_mul_ground(self, f, c) -> None: - ... - - def dmp_mul_ground(self, f, c) -> None: - ... - - def dup_quo_ground(self, f, c) -> None: - ... - - def dmp_quo_ground(self, f, c) -> None: - ... - - def dup_exquo_ground(self, f, c) -> None: - ... - - def dmp_exquo_ground(self, f, c) -> None: - ... - - def dup_lshift(self, f, n) -> None: - ... - - def dup_rshift(self, f, n) -> None: - ... - - def dup_abs(self, f) -> None: - ... - - def dmp_abs(self, f) -> None: - ... - - def dup_neg(self, f) -> None: - ... - - def dmp_neg(self, f) -> None: - ... - - def dup_add(self, f, g) -> None: - ... - - def dmp_add(self, f, g) -> None: - ... - - def dup_sub(self, f, g) -> None: - ... - - def dmp_sub(self, f, g) -> None: - ... - - def dup_add_mul(self, f, g, h) -> None: - ... - - def dmp_add_mul(self, f, g, h) -> None: - ... - - def dup_sub_mul(self, f, g, h) -> None: - ... - - def dmp_sub_mul(self, f, g, h) -> None: - ... - - def dup_mul(self, f, g) -> None: - ... - - def dmp_mul(self, f, g) -> None: - ... - - def dup_sqr(self, f) -> None: - ... - - def dmp_sqr(self, f) -> None: - ... - - def dup_pow(self, f, n) -> None: - ... - - def dmp_pow(self, f, n) -> None: - ... - - def dup_pdiv(self, f, g) -> tuple[None, None]: - ... - - def dup_prem(self, f, g) -> None: - ... - - def dup_pquo(self, f, g) -> None: - ... - - def dup_pexquo(self, f, g) -> None: - ... - - def dmp_pdiv(self, f, g) -> tuple[None, None]: - ... - - def dmp_prem(self, f, g) -> None: - ... - - def dmp_pquo(self, f, g) -> None: - ... - - def dmp_pexquo(self, f, g) -> None: - ... - - def dup_rr_div(self, f, g) -> tuple[None, None]: - ... - - def dmp_rr_div(self, f, g) -> tuple[None, None]: - ... - - def dup_ff_div(self, f, g) -> tuple[None, None]: - ... - - def dmp_ff_div(self, f, g) -> tuple[None, None]: - ... - - def dup_div(self, f, g) -> tuple[None, None]: - ... - - def dup_rem(self, f, g) -> None: - ... - - def dup_quo(self, f, g) -> None: - ... - - def dup_exquo(self, f, g) -> None: - ... - - def dmp_div(self, f, g) -> tuple[None, None]: - ... - - def dmp_rem(self, f, g) -> None: - ... - - def dmp_quo(self, f, g) -> None: - ... - - def dmp_exquo(self, f, g) -> None: - ... - - def dup_max_norm(self, f): - ... - - def dmp_max_norm(self, f): - ... - - def dup_l1_norm(self, f) -> int: - ... - - def dmp_l1_norm(self, f) -> int: - ... - - def dup_l2_norm_squared(self, f) -> int: - ... - - def dmp_l2_norm_squared(self, f) -> int: - ... - - def dup_expand(self, polys) -> None: - ... - - def dmp_expand(self, polys) -> None: - ... - - def dup_LC(self, f): - ... - - def dmp_LC(self, f): - ... - - def dup_TC(self, f): - ... - - def dmp_TC(self, f): - ... - - def dmp_ground_LC(self, f): - ... - - def dmp_ground_TC(self, f): - ... - - def dup_degree(self, f) -> int: - ... - - def dmp_degree(self, f) -> int: - ... - - def dmp_degree_in(self, f, j) -> int: - ... - - def dup_integrate(self, f, m) -> None: - ... - - def dmp_integrate(self, f, m) -> None: - ... - - def dup_diff(self, f, m) -> None: - ... - - def dmp_diff(self, f, m) -> None: - ... - - def dmp_diff_in(self, f, m, j) -> None: - ... - - def dmp_integrate_in(self, f, m, j) -> None: - ... - - def dup_eval(self, f, a): - ... - - def dmp_eval(self, f, a): - ... - - def dmp_eval_in(self, f, a, j): - ... - - def dmp_diff_eval_in(self, f, m, a, j): - ... - - def dmp_eval_tail(self, f, A): - ... - - def dup_trunc(self, f, p) -> None: - ... - - def dmp_trunc(self, f, g) -> None: - ... - - def dmp_ground_trunc(self, f, p) -> None: - ... - - def dup_monic(self, f) -> None: - ... - - def dmp_ground_monic(self, f) -> None: - ... - - def dup_extract(self, f, g) -> tuple[Any, None, None]: - ... - - def dmp_ground_extract(self, f, g) -> tuple[Any, None, None]: - ... - - def dup_real_imag(self, f) -> tuple[None, None]: - ... - - def dup_mirror(self, f) -> None: - ... - - def dup_scale(self, f, a) -> None: - ... - - def dup_shift(self, f, a) -> None: - ... - - def dup_transform(self, f, p, q) -> None: - ... - - def dup_compose(self, f, g) -> None: - ... - - def dmp_compose(self, f, g) -> None: - ... - - def dup_decompose(self, f) -> list[None]: - ... - - def dmp_lift(self, f): - ... - - def dup_sign_variations(self, f) -> int: - ... - - def dup_clear_denoms(self, f, convert=...) -> tuple[Any, None]: - ... - - def dmp_clear_denoms(self, f, convert=...) -> tuple[Any, None]: - ... - - def dup_revert(self, f, n) -> None: - ... - - def dup_half_gcdex(self, f, g) -> tuple[None, None]: - ... - - def dmp_half_gcdex(self, f, g) -> tuple[None, None]: - ... - - def dup_gcdex(self, f, g) -> tuple[None, None, None]: - ... - - def dmp_gcdex(self, f, g) -> tuple[None, None, None]: - ... - - def dup_invert(self, f, g) -> None: - ... - - def dmp_invert(self, f, g) -> None: - ... - - def dup_euclidean_prs(self, f, g) -> list[None]: - ... - - def dmp_euclidean_prs(self, f, g) -> list[None]: - ... - - def dup_primitive_prs(self, f, g) -> list[None]: - ... - - def dmp_primitive_prs(self, f, g) -> list[None]: - ... - - def dup_inner_subresultants(self, f, g) -> tuple[list[None], list[Any]]: - ... - - def dmp_inner_subresultants(self, f, g) -> tuple[list[None], list[list[list[Any]] | Any | list[Any]]]: - ... - - def dup_subresultants(self, f, g) -> list[None]: - ... - - def dmp_subresultants(self, f, g) -> list[None]: - ... - - def dup_prs_resultant(self, f, g) -> tuple[Any, list[None]]: - ... - - def dmp_prs_resultant(self, f, g) -> tuple[Any, list[None]]: - ... - - def dmp_zz_modular_resultant(self, f, g, p): - ... - - def dmp_zz_collins_resultant(self, f, g): - ... - - def dmp_qq_collins_resultant(self, f, g): - ... - - def dup_resultant(self, f, g) -> tuple[Any, list[Any]]: - ... - - def dmp_resultant(self, f, g) -> tuple[Any, list[Any]] | tuple[list[list[Any]], list[Any]] | tuple[list[list[Any]] | Any | list[Any], list[Any]]: - ... - - def dup_discriminant(self, f): - ... - - def dmp_discriminant(self, f): - ... - - def dup_rr_prs_gcd(self, f, g) -> tuple[None, None, None]: - ... - - def dup_ff_prs_gcd(self, f, g) -> tuple[None, None, None]: - ... - - def dmp_rr_prs_gcd(self, f, g) -> tuple[None, None, None]: - ... - - def dmp_ff_prs_gcd(self, f, g) -> tuple[None, None, None]: - ... - - def dup_zz_heu_gcd(self, f, g) -> tuple[None, None, None]: - ... - - def dmp_zz_heu_gcd(self, f, g) -> tuple[None, None, None]: - ... - - def dup_qq_heu_gcd(self, f, g) -> tuple[None, None, None]: - ... - - def dmp_qq_heu_gcd(self, f, g) -> tuple[None, None, None]: - ... - - def dup_inner_gcd(self, f, g) -> tuple[None, None, None]: - ... - - def dmp_inner_gcd(self, f, g) -> tuple[None, None, None]: - ... - - def dup_gcd(self, f, g) -> None: - ... - - def dmp_gcd(self, f, g) -> None: - ... - - def dup_rr_lcm(self, f, g) -> None: - ... - - def dup_ff_lcm(self, f, g) -> None: - ... - - def dup_lcm(self, f, g) -> None: - ... - - def dmp_rr_lcm(self, f, g) -> None: - ... - - def dmp_ff_lcm(self, f, g) -> None: - ... - - def dmp_lcm(self, f, g) -> None: - ... - - def dup_content(self, f): - ... - - def dup_primitive(self, f) -> tuple[Any, None]: - ... - - def dmp_content(self, f): - ... - - def dmp_primitive(self, f) -> tuple[Any, None]: - ... - - def dmp_ground_content(self, f): - ... - - def dmp_ground_primitive(self, f) -> tuple[Any, None]: - ... - - def dup_cancel(self, f, g, include=...) -> tuple[Any | list[Any], Any | list[Any], None, None] | tuple[None, None]: - ... - - def dmp_cancel(self, f, g, include=...) -> tuple[Any | list[Any], Any | list[Any], None, None] | tuple[None, None]: - ... - - def dup_trial_division(self, f, factors) -> list[tuple[None, Any]]: - ... - - def dmp_trial_division(self, f, factors) -> list[tuple[None, Any]]: - ... - - def dup_zz_mignotte_bound(self, f): - ... - - def dmp_zz_mignotte_bound(self, f): - ... - - def dup_zz_hensel_step(self, m, f, g, h, s, t) -> tuple[None, None, None, None]: - ... - - def dup_zz_hensel_lift(self, p, f, f_list, l) -> list[None]: - ... - - def dup_zz_zassenhaus(self, f) -> list[tuple[None, Any]]: - ... - - def dup_zz_irreducible_p(self, f) -> Literal[True] | None: - ... - - def dup_cyclotomic_p(self, f, irreducible=...) -> bool: - ... - - def dup_zz_cyclotomic_poly(self, n) -> None: - ... - - def dup_zz_cyclotomic_factor(self, f) -> list[None] | None: - ... - - def dmp_zz_wang_non_divisors(self, E, cs, ct) -> list[Any] | None: - ... - - def dmp_zz_wang_lead_coeffs(self, f, T, cs, E, H, A) -> tuple[None, list[Any], list[Any]]: - ... - - def dup_zz_diophantine(self, F, m, p) -> list[None]: - ... - - def dmp_zz_diophantine(self, F, c, A, d, p) -> list[None]: - ... - - def dmp_zz_wang_hensel_lifting(self, f, H, LC, A, p) -> list[None]: - ... - - def dmp_zz_wang(self, f, mod=..., seed=...) -> list[None]: - ... - - def dup_zz_factor_sqf(self, f) -> tuple[Any, list[None]]: - ... - - def dup_zz_factor(self, f) -> tuple[Any, list[tuple[None, Literal[1]]]]: - ... - - def dmp_zz_factor(self, f) -> tuple[Any, list[tuple[None, Literal[1]]]]: - ... - - def dup_qq_i_factor(self, f) -> tuple[Any, list[tuple[None, Any]]]: - ... - - def dmp_qq_i_factor(self, f) -> tuple[Any, list[tuple[None, Any]]]: - ... - - def dup_zz_i_factor(self, f) -> tuple[Any, list[tuple[None, Any]]]: - ... - - def dmp_zz_i_factor(self, f) -> tuple[Any, list[tuple[None, Any]]]: - ... - - def dup_ext_factor(self, f) -> tuple[Any, list[tuple[None, Any | int]]]: - ... - - def dmp_ext_factor(self, f) -> tuple[Any, list[tuple[None, Any | int]]]: - ... - - def dup_gf_factor(self, f) -> tuple[Any, list[tuple[None, Any]]]: - ... - - def dmp_gf_factor(self, f) -> tuple[Any, list[tuple[None, Any]]]: - ... - - def dup_factor_list(self, f) -> tuple[Any, list[tuple[None, Any]]]: - ... - - def dup_factor_list_include(self, f) -> list[tuple[None, Any | Literal[1]]]: - ... - - def dmp_factor_list(self, f) -> tuple[Any, list[tuple[None, Any]]]: - ... - - def dmp_factor_list_include(self, f) -> list[tuple[None, Any | Literal[1]]]: - ... - - def dup_irreducible_p(self, f) -> bool: - ... - - def dmp_irreducible_p(self, f) -> bool: - ... - - def dup_sturm(self, f) -> list[None]: - ... - - def dup_sqf_p(self, f) -> bool: - ... - - def dmp_sqf_p(self, f) -> bool: - ... - - def dup_sqf_norm(self, f) -> tuple[int, None, Any]: - ... - - def dmp_sqf_norm(self, f) -> tuple[int, None, Any]: - ... - - def dup_gf_sqf_part(self, f) -> None: - ... - - def dmp_gf_sqf_part(self, f) -> None: - ... - - def dup_sqf_part(self, f) -> None: - ... - - def dmp_sqf_part(self, f) -> None: - ... - - def dup_gf_sqf_list(self, f, all=...) -> tuple[Any, list[tuple[None, Any]]]: - ... - - def dmp_gf_sqf_list(self, f, all=...) -> tuple[Any, list[tuple[None, Any]]]: - ... - - def dup_sqf_list(self, f, all=...) -> tuple[Any, list[tuple[None, Any]]]: - ... - - def dup_sqf_list_include(self, f, all=...) -> list[tuple[None, Literal[1]]]: - ... - - def dmp_sqf_list(self, f, all=...) -> tuple[Any, list[tuple[None, Any]]]: - ... - - def dmp_sqf_list_include(self, f, all=...) -> list[tuple[None, Literal[1]]]: - ... - - def dup_gff_list(self, f) -> list[tuple[None, Any]]: - ... - - def dmp_gff_list(self, f) -> list[tuple[None, Any]]: - ... - - def dup_root_upper_bound(self, f) -> None: - ... - - def dup_root_lower_bound(self, f) -> None: - ... - - def dup_step_refine_real_root(self, f, M, fast=...) -> tuple[Any, tuple[Any, Any, Any, Any]] | tuple[list[Any], tuple[Any, Any, Any, Any]] | tuple[list[Any] | Any, tuple[Any, Any, Any, Any]]: - ... - - def dup_inner_refine_real_root(self, f, M, eps=..., steps=..., disjoint=..., fast=..., mobius=...) -> tuple[Any, Any] | tuple[Any | list[Any], tuple[Any, Any, Any, Any]]: - ... - - def dup_outer_refine_real_root(self, f, s, t, eps=..., steps=..., disjoint=..., fast=...) -> tuple[Any, Any] | tuple[Any | list[Any], tuple[Any, Any, Any, Any]]: - ... - - def dup_refine_real_root(self, f, s, t, eps=..., steps=..., disjoint=..., fast=...) -> tuple[Any, Any] | tuple[Any | list[Any], Any | tuple[Any, Any, Any, Any]]: - ... - - def dup_inner_isolate_real_roots(self, f, eps=..., fast=...) -> list[Any] | list[tuple[Any, Any] | tuple[Any | list[Any], tuple[Any, Any, Any, Any]]]: - ... - - def dup_inner_isolate_positive_roots(self, f, eps=..., inf=..., sup=..., fast=..., mobius=...) -> list[Any] | list[tuple[Any, Any] | tuple[Any | list[Any], tuple[Any, Any, Any, Any]]]: - ... - - def dup_inner_isolate_negative_roots(self, f, inf=..., sup=..., eps=..., fast=..., mobius=...) -> list[Any] | list[tuple[Any, Any] | tuple[Any | list[Any], tuple[Any, Any, Any, Any]]]: - ... - - def dup_isolate_real_roots_sqf(self, f, eps=..., inf=..., sup=..., fast=..., blackbox=...) -> list[Any] | list[tuple[Any, Any] | tuple[Any | list[Any], tuple[Any, Any, Any, Any]]] | list[RealInterval]: - ... - - def dup_isolate_real_roots(self, f, eps=..., inf=..., sup=..., basis=..., fast=...) -> list[Any] | list[tuple[tuple[Any, Any], Any, Any] | tuple[Any, Any]]: - ... - - def dup_isolate_real_roots_list(self, polys, eps=..., inf=..., sup=..., strict=..., basis=..., fast=...) -> list[tuple[tuple[Any, Any], Any, Any] | tuple[tuple[Any, Any], dict[Any, Any]]]: - ... - - def dup_count_real_roots(self, f, inf=..., sup=...) -> int: - ... - - def dup_count_complex_roots(self, f, inf=..., sup=..., exclude=...) -> int: - ... - - def dup_isolate_complex_roots_sqf(self, f, eps=..., inf=..., sup=..., blackbox=...): - ... - - def dup_isolate_all_roots_sqf(self, f, eps=..., inf=..., sup=..., fast=..., blackbox=...) -> tuple[list[Any] | list[tuple[Any, Any] | tuple[Any | list[Any], tuple[Any, Any, Any, Any]]] | list[RealInterval], Any]: - ... - - def dup_isolate_all_roots(self, f, eps=..., inf=..., sup=..., fast=...) -> tuple[list[tuple[tuple[Any | list[Any], Any | tuple[Any, Any, Any, Any]], Any]], list[tuple[tuple[Any, Any], Any]]]: - ... - - def fateman_poly_F_1(self) -> tuple[None, ...]: - ... - - def fateman_poly_F_2(self) -> tuple[None, ...]: - ... - - def fateman_poly_F_3(self) -> tuple[None, ...]: - ... - - def to_gf_dense(self, element): - ... - - def from_gf_dense(self, element) -> None: - ... - - def gf_degree(self, f) -> int: - ... - - def gf_LC(self, f): - ... - - def gf_TC(self, f): - ... - - def gf_strip(self, f) -> None: - ... - - def gf_trunc(self, f) -> None: - ... - - def gf_normal(self, f) -> None: - ... - - def gf_from_dict(self, f) -> None: - ... - - def gf_to_dict(self, f, symmetric=...) -> dict[Any, Any]: - ... - - def gf_from_int_poly(self, f) -> None: - ... - - def gf_to_int_poly(self, f, symmetric=...) -> list[Any]: - ... - - def gf_neg(self, f) -> None: - ... - - def gf_add_ground(self, f, a) -> None: - ... - - def gf_sub_ground(self, f, a) -> None: - ... - - def gf_mul_ground(self, f, a) -> None: - ... - - def gf_quo_ground(self, f, a) -> None: - ... - - def gf_add(self, f, g) -> None: - ... - - def gf_sub(self, f, g) -> None: - ... - - def gf_mul(self, f, g) -> None: - ... - - def gf_sqr(self, f) -> None: - ... - - def gf_add_mul(self, f, g, h) -> None: - ... - - def gf_sub_mul(self, f, g, h) -> None: - ... - - def gf_expand(self, F) -> None: - ... - - def gf_div(self, f, g) -> tuple[None, None]: - ... - - def gf_rem(self, f, g) -> None: - ... - - def gf_quo(self, f, g) -> None: - ... - - def gf_exquo(self, f, g) -> None: - ... - - def gf_lshift(self, f, n) -> None: - ... - - def gf_rshift(self, f, n) -> None: - ... - - def gf_pow(self, f, n) -> None: - ... - - def gf_pow_mod(self, f, n, g) -> None: - ... - - def gf_cofactors(self, f, g) -> tuple[None, None, None]: - ... - - def gf_gcd(self, f, g) -> None: - ... - - def gf_lcm(self, f, g) -> None: - ... - - def gf_gcdex(self, f, g) -> None: - ... - - def gf_monic(self, f) -> None: - ... - - def gf_diff(self, f) -> None: - ... - - def gf_eval(self, f, a): - ... - - def gf_multi_eval(self, f, A) -> list[Any]: - ... - - def gf_compose(self, f, g) -> None: - ... - - def gf_compose_mod(self, g, h, f) -> None: - ... - - def gf_trace_map(self, a, b, c, n, f) -> tuple[None, None]: - ... - - def gf_random(self, n) -> None: - ... - - def gf_irreducible(self, n) -> None: - ... - - def gf_irred_p_ben_or(self, f) -> bool: - ... - - def gf_irred_p_rabin(self, f) -> bool: - ... - - def gf_irreducible_p(self, f) -> bool: - ... - - def gf_sqf_p(self, f) -> bool: - ... - - def gf_sqf_part(self, f) -> None: - ... - - def gf_sqf_list(self, f, all=...) -> tuple[Any, list[tuple[None, Any]]]: - ... - - def gf_Qmatrix(self, f) -> list[list[Any]]: - ... - - def gf_berlekamp(self, f) -> list[None]: - ... - - def gf_ddf_zassenhaus(self, f) -> list[tuple[None, Any]]: - ... - - def gf_edf_zassenhaus(self, f, n) -> list[None]: - ... - - def gf_ddf_shoup(self, f) -> list[tuple[None, Any]]: - ... - - def gf_edf_shoup(self, f, n) -> list[None]: - ... - - def gf_zassenhaus(self, f) -> list[None]: - ... - - def gf_shoup(self, f) -> list[None]: - ... - - def gf_factor_sqf(self, f, method=...) -> tuple[Any, list[None]]: - ... - - def gf_factor(self, f) -> tuple[Any, list[tuple[None, Any]]]: - ... - - - + def drop(self, gen) -> None: ... + def clone(self, symbols=..., domain=..., order=...) -> None: ... + def to_ground(self) -> None: ... + def ground_new(self, element) -> None: ... + def domain_new(self, element) -> None: ... + def from_dict(self, d) -> None: ... + def wrap(self, element) -> PolyElement | None: ... + def to_dense(self, element) -> list[Any] | list[list[Any]]: ... + def from_dense(self, element) -> None: ... + def dup_add_term(self, f, c, i) -> None: ... + def dmp_add_term(self, f, c, i) -> None: ... + def dup_sub_term(self, f, c, i) -> None: ... + def dmp_sub_term(self, f, c, i) -> None: ... + def dup_mul_term(self, f, c, i) -> None: ... + def dmp_mul_term(self, f, c, i) -> None: ... + def dup_add_ground(self, f, c) -> None: ... + def dmp_add_ground(self, f, c) -> None: ... + def dup_sub_ground(self, f, c) -> None: ... + def dmp_sub_ground(self, f, c) -> None: ... + def dup_mul_ground(self, f, c) -> None: ... + def dmp_mul_ground(self, f, c) -> None: ... + def dup_quo_ground(self, f, c) -> None: ... + def dmp_quo_ground(self, f, c) -> None: ... + def dup_exquo_ground(self, f, c) -> None: ... + def dmp_exquo_ground(self, f, c) -> None: ... + def dup_lshift(self, f, n) -> None: ... + def dup_rshift(self, f, n) -> None: ... + def dup_abs(self, f) -> None: ... + def dmp_abs(self, f) -> None: ... + def dup_neg(self, f) -> None: ... + def dmp_neg(self, f) -> None: ... + def dup_add(self, f, g) -> None: ... + def dmp_add(self, f, g) -> None: ... + def dup_sub(self, f, g) -> None: ... + def dmp_sub(self, f, g) -> None: ... + def dup_add_mul(self, f, g, h) -> None: ... + def dmp_add_mul(self, f, g, h) -> None: ... + def dup_sub_mul(self, f, g, h) -> None: ... + def dmp_sub_mul(self, f, g, h) -> None: ... + def dup_mul(self, f, g) -> None: ... + def dmp_mul(self, f, g) -> None: ... + def dup_sqr(self, f) -> None: ... + def dmp_sqr(self, f) -> None: ... + def dup_pow(self, f, n) -> None: ... + def dmp_pow(self, f, n) -> None: ... + def dup_pdiv(self, f, g) -> tuple[None, None]: ... + def dup_prem(self, f, g) -> None: ... + def dup_pquo(self, f, g) -> None: ... + def dup_pexquo(self, f, g) -> None: ... + def dmp_pdiv(self, f, g) -> tuple[None, None]: ... + def dmp_prem(self, f, g) -> None: ... + def dmp_pquo(self, f, g) -> None: ... + def dmp_pexquo(self, f, g) -> None: ... + def dup_rr_div(self, f, g) -> tuple[None, None]: ... + def dmp_rr_div(self, f, g) -> tuple[None, None]: ... + def dup_ff_div(self, f, g) -> tuple[None, None]: ... + def dmp_ff_div(self, f, g) -> tuple[None, None]: ... + def dup_div(self, f, g) -> tuple[None, None]: ... + def dup_rem(self, f, g) -> None: ... + def dup_quo(self, f, g) -> None: ... + def dup_exquo(self, f, g) -> None: ... + def dmp_div(self, f, g) -> tuple[None, None]: ... + def dmp_rem(self, f, g) -> None: ... + def dmp_quo(self, f, g) -> None: ... + def dmp_exquo(self, f, g) -> None: ... + def dup_max_norm(self, f): ... + def dmp_max_norm(self, f): ... + def dup_l1_norm(self, f) -> int: ... + def dmp_l1_norm(self, f) -> int: ... + def dup_l2_norm_squared(self, f) -> int: ... + def dmp_l2_norm_squared(self, f) -> int: ... + def dup_expand(self, polys) -> None: ... + def dmp_expand(self, polys) -> None: ... + def dup_LC(self, f): ... + def dmp_LC(self, f): ... + def dup_TC(self, f): ... + def dmp_TC(self, f): ... + def dmp_ground_LC(self, f): ... + def dmp_ground_TC(self, f): ... + def dup_degree(self, f) -> int: ... + def dmp_degree(self, f) -> int: ... + def dmp_degree_in(self, f, j) -> int: ... + def dup_integrate(self, f, m) -> None: ... + def dmp_integrate(self, f, m) -> None: ... + def dup_diff(self, f, m) -> None: ... + def dmp_diff(self, f, m) -> None: ... + def dmp_diff_in(self, f, m, j) -> None: ... + def dmp_integrate_in(self, f, m, j) -> None: ... + def dup_eval(self, f, a): ... + def dmp_eval(self, f, a): ... + def dmp_eval_in(self, f, a, j): ... + def dmp_diff_eval_in(self, f, m, a, j): ... + def dmp_eval_tail(self, f, A): ... + def dup_trunc(self, f, p) -> None: ... + def dmp_trunc(self, f, g) -> None: ... + def dmp_ground_trunc(self, f, p) -> None: ... + def dup_monic(self, f) -> None: ... + def dmp_ground_monic(self, f) -> None: ... + def dup_extract(self, f, g) -> tuple[Any, None, None]: ... + def dmp_ground_extract(self, f, g) -> tuple[Any, None, None]: ... + def dup_real_imag(self, f) -> tuple[None, None]: ... + def dup_mirror(self, f) -> None: ... + def dup_scale(self, f, a) -> None: ... + def dup_shift(self, f, a) -> None: ... + def dup_transform(self, f, p, q) -> None: ... + def dup_compose(self, f, g) -> None: ... + def dmp_compose(self, f, g) -> None: ... + def dup_decompose(self, f) -> list[None]: ... + def dmp_lift(self, f): ... + def dup_sign_variations(self, f) -> int: ... + def dup_clear_denoms(self, f, convert=...) -> tuple[Any, None]: ... + def dmp_clear_denoms(self, f, convert=...) -> tuple[Any, None]: ... + def dup_revert(self, f, n) -> None: ... + def dup_half_gcdex(self, f, g) -> tuple[None, None]: ... + def dmp_half_gcdex(self, f, g) -> tuple[None, None]: ... + def dup_gcdex(self, f, g) -> tuple[None, None, None]: ... + def dmp_gcdex(self, f, g) -> tuple[None, None, None]: ... + def dup_invert(self, f, g) -> None: ... + def dmp_invert(self, f, g) -> None: ... + def dup_euclidean_prs(self, f, g) -> list[None]: ... + def dmp_euclidean_prs(self, f, g) -> list[None]: ... + def dup_primitive_prs(self, f, g) -> list[None]: ... + def dmp_primitive_prs(self, f, g) -> list[None]: ... + def dup_inner_subresultants(self, f, g) -> tuple[list[None], list[Any]]: ... + def dmp_inner_subresultants(self, f, g) -> tuple[list[None], list[list[list[Any]] | Any | list[Any]]]: ... + def dup_subresultants(self, f, g) -> list[None]: ... + def dmp_subresultants(self, f, g) -> list[None]: ... + def dup_prs_resultant(self, f, g) -> tuple[Any, list[None]]: ... + def dmp_prs_resultant(self, f, g) -> tuple[Any, list[None]]: ... + def dmp_zz_modular_resultant(self, f, g, p): ... + def dmp_zz_collins_resultant(self, f, g): ... + def dmp_qq_collins_resultant(self, f, g): ... + def dup_resultant(self, f, g) -> tuple[Any, list[Any]]: ... + def dmp_resultant( + self, f, g + ) -> tuple[Any, list[Any]] | tuple[list[list[Any]], list[Any]] | tuple[list[list[Any]] | Any | list[Any], list[Any]]: ... + def dup_discriminant(self, f): ... + def dmp_discriminant(self, f): ... + def dup_rr_prs_gcd(self, f, g) -> tuple[None, None, None]: ... + def dup_ff_prs_gcd(self, f, g) -> tuple[None, None, None]: ... + def dmp_rr_prs_gcd(self, f, g) -> tuple[None, None, None]: ... + def dmp_ff_prs_gcd(self, f, g) -> tuple[None, None, None]: ... + def dup_zz_heu_gcd(self, f, g) -> tuple[None, None, None]: ... + def dmp_zz_heu_gcd(self, f, g) -> tuple[None, None, None]: ... + def dup_qq_heu_gcd(self, f, g) -> tuple[None, None, None]: ... + def dmp_qq_heu_gcd(self, f, g) -> tuple[None, None, None]: ... + def dup_inner_gcd(self, f, g) -> tuple[None, None, None]: ... + def dmp_inner_gcd(self, f, g) -> tuple[None, None, None]: ... + def dup_gcd(self, f, g) -> None: ... + def dmp_gcd(self, f, g) -> None: ... + def dup_rr_lcm(self, f, g) -> None: ... + def dup_ff_lcm(self, f, g) -> None: ... + def dup_lcm(self, f, g) -> None: ... + def dmp_rr_lcm(self, f, g) -> None: ... + def dmp_ff_lcm(self, f, g) -> None: ... + def dmp_lcm(self, f, g) -> None: ... + def dup_content(self, f): ... + def dup_primitive(self, f) -> tuple[Any, None]: ... + def dmp_content(self, f): ... + def dmp_primitive(self, f) -> tuple[Any, None]: ... + def dmp_ground_content(self, f): ... + def dmp_ground_primitive(self, f) -> tuple[Any, None]: ... + def dup_cancel(self, f, g, include=...) -> tuple[Any | list[Any], Any | list[Any], None, None] | tuple[None, None]: ... + def dmp_cancel(self, f, g, include=...) -> tuple[Any | list[Any], Any | list[Any], None, None] | tuple[None, None]: ... + def dup_trial_division(self, f, factors) -> list[tuple[None, Any]]: ... + def dmp_trial_division(self, f, factors) -> list[tuple[None, Any]]: ... + def dup_zz_mignotte_bound(self, f): ... + def dmp_zz_mignotte_bound(self, f): ... + def dup_zz_hensel_step(self, m, f, g, h, s, t) -> tuple[None, None, None, None]: ... + def dup_zz_hensel_lift(self, p, f, f_list, l) -> list[None]: ... + def dup_zz_zassenhaus(self, f) -> list[tuple[None, Any]]: ... + def dup_zz_irreducible_p(self, f) -> Literal[True] | None: ... + def dup_cyclotomic_p(self, f, irreducible=...) -> bool: ... + def dup_zz_cyclotomic_poly(self, n) -> None: ... + def dup_zz_cyclotomic_factor(self, f) -> list[None] | None: ... + def dmp_zz_wang_non_divisors(self, E, cs, ct) -> list[Any] | None: ... + def dmp_zz_wang_lead_coeffs(self, f, T, cs, E, H, A) -> tuple[None, list[Any], list[Any]]: ... + def dup_zz_diophantine(self, F, m, p) -> list[None]: ... + def dmp_zz_diophantine(self, F, c, A, d, p) -> list[None]: ... + def dmp_zz_wang_hensel_lifting(self, f, H, LC, A, p) -> list[None]: ... + def dmp_zz_wang(self, f, mod=..., seed=...) -> list[None]: ... + def dup_zz_factor_sqf(self, f) -> tuple[Any, list[None]]: ... + def dup_zz_factor(self, f) -> tuple[Any, list[tuple[None, Literal[1]]]]: ... + def dmp_zz_factor(self, f) -> tuple[Any, list[tuple[None, Literal[1]]]]: ... + def dup_qq_i_factor(self, f) -> tuple[Any, list[tuple[None, Any]]]: ... + def dmp_qq_i_factor(self, f) -> tuple[Any, list[tuple[None, Any]]]: ... + def dup_zz_i_factor(self, f) -> tuple[Any, list[tuple[None, Any]]]: ... + def dmp_zz_i_factor(self, f) -> tuple[Any, list[tuple[None, Any]]]: ... + def dup_ext_factor(self, f) -> tuple[Any, list[tuple[None, Any | int]]]: ... + def dmp_ext_factor(self, f) -> tuple[Any, list[tuple[None, Any | int]]]: ... + def dup_gf_factor(self, f) -> tuple[Any, list[tuple[None, Any]]]: ... + def dmp_gf_factor(self, f) -> tuple[Any, list[tuple[None, Any]]]: ... + def dup_factor_list(self, f) -> tuple[Any, list[tuple[None, Any]]]: ... + def dup_factor_list_include(self, f) -> list[tuple[None, Any | Literal[1]]]: ... + def dmp_factor_list(self, f) -> tuple[Any, list[tuple[None, Any]]]: ... + def dmp_factor_list_include(self, f) -> list[tuple[None, Any | Literal[1]]]: ... + def dup_irreducible_p(self, f) -> bool: ... + def dmp_irreducible_p(self, f) -> bool: ... + def dup_sturm(self, f) -> list[None]: ... + def dup_sqf_p(self, f) -> bool: ... + def dmp_sqf_p(self, f) -> bool: ... + def dup_sqf_norm(self, f) -> tuple[int, None, Any]: ... + def dmp_sqf_norm(self, f) -> tuple[int, None, Any]: ... + def dup_gf_sqf_part(self, f) -> None: ... + def dmp_gf_sqf_part(self, f) -> None: ... + def dup_sqf_part(self, f) -> None: ... + def dmp_sqf_part(self, f) -> None: ... + def dup_gf_sqf_list(self, f, all=...) -> tuple[Any, list[tuple[None, Any]]]: ... + def dmp_gf_sqf_list(self, f, all=...) -> tuple[Any, list[tuple[None, Any]]]: ... + def dup_sqf_list(self, f, all=...) -> tuple[Any, list[tuple[None, Any]]]: ... + def dup_sqf_list_include(self, f, all=...) -> list[tuple[None, Literal[1]]]: ... + def dmp_sqf_list(self, f, all=...) -> tuple[Any, list[tuple[None, Any]]]: ... + def dmp_sqf_list_include(self, f, all=...) -> list[tuple[None, Literal[1]]]: ... + def dup_gff_list(self, f) -> list[tuple[None, Any]]: ... + def dmp_gff_list(self, f) -> list[tuple[None, Any]]: ... + def dup_root_upper_bound(self, f) -> None: ... + def dup_root_lower_bound(self, f) -> None: ... + def dup_step_refine_real_root( + self, f, M, fast=... + ) -> ( + tuple[Any, tuple[Any, Any, Any, Any]] + | tuple[list[Any], tuple[Any, Any, Any, Any]] + | tuple[list[Any] | Any, tuple[Any, Any, Any, Any]] + ): ... + def dup_inner_refine_real_root( + self, f, M, eps=..., steps=..., disjoint=..., fast=..., mobius=... + ) -> tuple[Any, Any] | tuple[Any | list[Any], tuple[Any, Any, Any, Any]]: ... + def dup_outer_refine_real_root( + self, f, s, t, eps=..., steps=..., disjoint=..., fast=... + ) -> tuple[Any, Any] | tuple[Any | list[Any], tuple[Any, Any, Any, Any]]: ... + def dup_refine_real_root( + self, f, s, t, eps=..., steps=..., disjoint=..., fast=... + ) -> tuple[Any, Any] | tuple[Any | list[Any], Any | tuple[Any, Any, Any, Any]]: ... + def dup_inner_isolate_real_roots( + self, f, eps=..., fast=... + ) -> list[Any] | list[tuple[Any, Any] | tuple[Any | list[Any], tuple[Any, Any, Any, Any]]]: ... + def dup_inner_isolate_positive_roots( + self, f, eps=..., inf=..., sup=..., fast=..., mobius=... + ) -> list[Any] | list[tuple[Any, Any] | tuple[Any | list[Any], tuple[Any, Any, Any, Any]]]: ... + def dup_inner_isolate_negative_roots( + self, f, inf=..., sup=..., eps=..., fast=..., mobius=... + ) -> list[Any] | list[tuple[Any, Any] | tuple[Any | list[Any], tuple[Any, Any, Any, Any]]]: ... + def dup_isolate_real_roots_sqf( + self, f, eps=..., inf=..., sup=..., fast=..., blackbox=... + ) -> list[Any] | list[tuple[Any, Any] | tuple[Any | list[Any], tuple[Any, Any, Any, Any]]] | list[RealInterval]: ... + def dup_isolate_real_roots( + self, f, eps=..., inf=..., sup=..., basis=..., fast=... + ) -> list[Any] | list[tuple[tuple[Any, Any], Any, Any] | tuple[Any, Any]]: ... + def dup_isolate_real_roots_list( + self, polys, eps=..., inf=..., sup=..., strict=..., basis=..., fast=... + ) -> list[tuple[tuple[Any, Any], Any, Any] | tuple[tuple[Any, Any], dict[Any, Any]]]: ... + def dup_count_real_roots(self, f, inf=..., sup=...) -> int: ... + def dup_count_complex_roots(self, f, inf=..., sup=..., exclude=...) -> int: ... + def dup_isolate_complex_roots_sqf(self, f, eps=..., inf=..., sup=..., blackbox=...): ... + def dup_isolate_all_roots_sqf( + self, f, eps=..., inf=..., sup=..., fast=..., blackbox=... + ) -> tuple[ + list[Any] | list[tuple[Any, Any] | tuple[Any | list[Any], tuple[Any, Any, Any, Any]]] | list[RealInterval], Any + ]: ... + def dup_isolate_all_roots( + self, f, eps=..., inf=..., sup=..., fast=... + ) -> tuple[list[tuple[tuple[Any | list[Any], Any | tuple[Any, Any, Any, Any]], Any]], list[tuple[tuple[Any, Any], Any]]]: ... + def fateman_poly_F_1(self) -> tuple[None, ...]: ... + def fateman_poly_F_2(self) -> tuple[None, ...]: ... + def fateman_poly_F_3(self) -> tuple[None, ...]: ... + def to_gf_dense(self, element): ... + def from_gf_dense(self, element) -> None: ... + def gf_degree(self, f) -> int: ... + def gf_LC(self, f): ... + def gf_TC(self, f): ... + def gf_strip(self, f) -> None: ... + def gf_trunc(self, f) -> None: ... + def gf_normal(self, f) -> None: ... + def gf_from_dict(self, f) -> None: ... + def gf_to_dict(self, f, symmetric=...) -> dict[Any, Any]: ... + def gf_from_int_poly(self, f) -> None: ... + def gf_to_int_poly(self, f, symmetric=...) -> list[Any]: ... + def gf_neg(self, f) -> None: ... + def gf_add_ground(self, f, a) -> None: ... + def gf_sub_ground(self, f, a) -> None: ... + def gf_mul_ground(self, f, a) -> None: ... + def gf_quo_ground(self, f, a) -> None: ... + def gf_add(self, f, g) -> None: ... + def gf_sub(self, f, g) -> None: ... + def gf_mul(self, f, g) -> None: ... + def gf_sqr(self, f) -> None: ... + def gf_add_mul(self, f, g, h) -> None: ... + def gf_sub_mul(self, f, g, h) -> None: ... + def gf_expand(self, F) -> None: ... + def gf_div(self, f, g) -> tuple[None, None]: ... + def gf_rem(self, f, g) -> None: ... + def gf_quo(self, f, g) -> None: ... + def gf_exquo(self, f, g) -> None: ... + def gf_lshift(self, f, n) -> None: ... + def gf_rshift(self, f, n) -> None: ... + def gf_pow(self, f, n) -> None: ... + def gf_pow_mod(self, f, n, g) -> None: ... + def gf_cofactors(self, f, g) -> tuple[None, None, None]: ... + def gf_gcd(self, f, g) -> None: ... + def gf_lcm(self, f, g) -> None: ... + def gf_gcdex(self, f, g) -> None: ... + def gf_monic(self, f) -> None: ... + def gf_diff(self, f) -> None: ... + def gf_eval(self, f, a): ... + def gf_multi_eval(self, f, A) -> list[Any]: ... + def gf_compose(self, f, g) -> None: ... + def gf_compose_mod(self, g, h, f) -> None: ... + def gf_trace_map(self, a, b, c, n, f) -> tuple[None, None]: ... + def gf_random(self, n) -> None: ... + def gf_irreducible(self, n) -> None: ... + def gf_irred_p_ben_or(self, f) -> bool: ... + def gf_irred_p_rabin(self, f) -> bool: ... + def gf_irreducible_p(self, f) -> bool: ... + def gf_sqf_p(self, f) -> bool: ... + def gf_sqf_part(self, f) -> None: ... + def gf_sqf_list(self, f, all=...) -> tuple[Any, list[tuple[None, Any]]]: ... + def gf_Qmatrix(self, f) -> list[list[Any]]: ... + def gf_berlekamp(self, f) -> list[None]: ... + def gf_ddf_zassenhaus(self, f) -> list[tuple[None, Any]]: ... + def gf_edf_zassenhaus(self, f, n) -> list[None]: ... + def gf_ddf_shoup(self, f) -> list[tuple[None, Any]]: ... + def gf_edf_shoup(self, f, n) -> list[None]: ... + def gf_zassenhaus(self, f) -> list[None]: ... + def gf_shoup(self, f) -> list[None]: ... + def gf_factor_sqf(self, f, method=...) -> tuple[Any, list[None]]: ... + def gf_factor(self, f) -> tuple[Any, list[tuple[None, Any]]]: ... diff --git a/stubs/sympy-stubs/polys/constructor.pyi b/stubs/sympy-stubs/polys/constructor.pyi index e917ad42..904ead01 100644 --- a/stubs/sympy-stubs/polys/constructor.pyi +++ b/stubs/sympy-stubs/polys/constructor.pyi @@ -4,6 +4,10 @@ from sympy.polys.domains.gaussiandomains import GaussianIntegerRing, GaussianRat from sympy.utilities import public @public -def construct_domain(obj, **args) -> tuple[Any | GaussianRationalField | GaussianIntegerRing, dict[Any, Any | int]] | tuple[Any | GaussianRationalField | GaussianIntegerRing, list[Any | int] | list[Any] | Any] | tuple[Any | GaussianRationalField | GaussianIntegerRing, Any | int]: - ... - +def construct_domain( + obj, **args +) -> ( + tuple[Any | GaussianRationalField | GaussianIntegerRing, dict[Any, Any | int]] + | tuple[Any | GaussianRationalField | GaussianIntegerRing, list[Any | int] | list[Any] | Any] + | tuple[Any | GaussianRationalField | GaussianIntegerRing, Any | int] +): ... diff --git a/stubs/sympy-stubs/polys/densearith.pyi b/stubs/sympy-stubs/polys/densearith.pyi index d8f0b344..b2c86a25 100644 --- a/stubs/sympy-stubs/polys/densearith.pyi +++ b/stubs/sympy-stubs/polys/densearith.pyi @@ -1,194 +1,96 @@ from typing import Any -def dup_add_term(f, c, i, K): - ... - -def dmp_add_term(f, c, i, u, K) -> list[list[Any]]: - ... - -def dup_sub_term(f, c, i, K): - ... - -def dmp_sub_term(f, c, i, u, K) -> list[list[Any]]: - ... - -def dup_mul_term(f, c, i, K) -> list[Any]: - ... - -def dmp_mul_term(f, c, i, u, K) -> list[Any] | list[list[Any]] | list[Any | list[Any] | list[list[Any]]]: - ... - -def dup_add_ground(f, c, K): - ... - -def dmp_add_ground(f, c, u, K) -> list[list[Any]]: - ... - -def dup_sub_ground(f, c, K): - ... - -def dmp_sub_ground(f, c, u, K) -> list[list[Any]]: - ... - -def dup_mul_ground(f, c, K) -> list[Any]: - ... - -def dmp_mul_ground(f, c, u, K) -> list[Any]: - ... - -def dup_quo_ground(f, c, K) -> list[Any]: - ... - -def dmp_quo_ground(f, c, u, K) -> list[Any]: - ... - -def dup_exquo_ground(f, c, K) -> list[Any]: - ... - -def dmp_exquo_ground(f, c, u, K) -> list[Any]: - ... - -def dup_lshift(f, n, K): - ... - -def dup_rshift(f, n, K): - ... - -def dup_abs(f, K) -> list[Any]: - ... - -def dmp_abs(f, u, K) -> list[Any]: - ... - -def dup_neg(f, K) -> list[Any]: - ... - -def dmp_neg(f, u, K) -> list[Any]: - ... - -def dup_add(f, g, K): - ... - -def dmp_add(f, g, u, K) -> list[list[Any]]: - ... - -def dup_sub(f, g, K) -> list[Any]: - ... - -def dmp_sub(f, g, u, K) -> list[Any] | list[list[Any]]: - ... - -def dup_add_mul(f, g, h, K): - ... - -def dmp_add_mul(f, g, h, u, K) -> list[list[Any]]: - ... - -def dup_sub_mul(f, g, h, K) -> list[Any]: - ... - -def dmp_sub_mul(f, g, h, u, K) -> list[Any] | list[list[Any]]: - ... - -def dup_mul(f, g, K) -> list[Any]: - ... - -def dmp_mul(f, g, u, K) -> list[Any] | list[list[Any]]: - ... - -def dup_sqr(f, K): - ... - -def dmp_sqr(f, u, K) -> list[list[Any]]: - ... - -def dup_pow(f, n, K) -> list[Any]: - ... - -def dmp_pow(f, n, u, K) -> list[Any] | list[list[Any]]: - ... - -def dup_pdiv(f, g, K) -> tuple[list[Any], Any] | tuple[list[Any], list[Any]]: - ... - -def dup_prem(f, g, K) -> list[Any]: - ... - -def dup_pquo(f, g, K) -> list[Any]: - ... - -def dup_pexquo(f, g, K) -> list[Any]: - ... - -def dmp_pdiv(f, g, u, K) -> tuple[list[Any], Any] | tuple[list[Any], list[Any]] | tuple[list[list[Any]], Any] | tuple[list[Any] | Any | list[list[Any]] | list[Any | list[Any] | list[list[Any]]], list[Any] | Any | list[list[Any]] | list[Any | list[Any] | list[list[Any]]]]: - ... - -def dmp_prem(f, g, u, K) -> list[Any] | list[list[Any]] | list[Any | list[Any] | list[list[Any]]]: - ... - -def dmp_pquo(f, g, u, K) -> list[list[Any]] | list[Any] | list[Any | list[Any] | list[list[Any]]]: - ... - -def dmp_pexquo(f, g, u, K) -> list[Any] | list[list[Any]] | list[Any | list[Any] | list[list[Any]]]: - ... - -def dup_rr_div(f, g, K) -> tuple[list[Any], Any] | tuple[Any | list[Any], Any | list[Any]]: - ... - -def dmp_rr_div(f, g, u, K) -> tuple[list[Any], Any] | tuple[Any | list[Any], Any | list[Any]] | tuple[list[list[Any]], Any] | tuple[list[list[Any]] | Any, Any | list[Any] | list[list[Any]]]: - ... - -def dup_ff_div(f, g, K) -> tuple[list[Any], Any] | tuple[Any, list[Any] | Any]: - ... - -def dmp_ff_div(f, g, u, K) -> tuple[list[Any], Any] | tuple[Any, list[Any] | Any] | tuple[list[list[Any]], Any] | tuple[list[list[Any]] | Any, Any | list[Any] | list[list[Any]]]: - ... - -def dup_div(f, g, K) -> tuple[list[Any], Any] | tuple[Any, list[Any] | Any] | tuple[Any | list[Any], Any | list[Any]]: - ... - -def dup_rem(f, g, K) -> list[Any]: - ... - -def dup_quo(f, g, K) -> list[Any]: - ... - -def dup_exquo(f, g, K) -> list[Any]: - ... - -def dmp_div(f, g, u, K) -> tuple[list[Any], Any] | tuple[Any, list[Any] | Any] | tuple[list[list[Any]], Any] | tuple[list[list[Any]] | Any, Any | list[Any] | list[list[Any]]] | tuple[Any | list[Any], Any | list[Any]]: - ... - -def dmp_rem(f, g, u, K) -> list[Any] | list[list[Any]]: - ... - -def dmp_quo(f, g, u, K) -> list[list[Any]]: - ... - -def dmp_exquo(f, g, u, K) -> list[list[Any]]: - ... - -def dup_max_norm(f, K): - ... - -def dmp_max_norm(f, u, K): - ... - -def dup_l1_norm(f, K) -> int: - ... - -def dmp_l1_norm(f, u, K) -> int: - ... - -def dup_l2_norm_squared(f, K) -> int: - ... - -def dmp_l2_norm_squared(f, u, K) -> int: - ... - -def dup_expand(polys, K) -> list[Any]: - ... - -def dmp_expand(polys, u, K) -> list[list[Any]] | list[Any]: - ... - +def dup_add_term(f, c, i, K): ... +def dmp_add_term(f, c, i, u, K) -> list[list[Any]]: ... +def dup_sub_term(f, c, i, K): ... +def dmp_sub_term(f, c, i, u, K) -> list[list[Any]]: ... +def dup_mul_term(f, c, i, K) -> list[Any]: ... +def dmp_mul_term(f, c, i, u, K) -> list[Any] | list[list[Any]] | list[Any | list[Any] | list[list[Any]]]: ... +def dup_add_ground(f, c, K): ... +def dmp_add_ground(f, c, u, K) -> list[list[Any]]: ... +def dup_sub_ground(f, c, K): ... +def dmp_sub_ground(f, c, u, K) -> list[list[Any]]: ... +def dup_mul_ground(f, c, K) -> list[Any]: ... +def dmp_mul_ground(f, c, u, K) -> list[Any]: ... +def dup_quo_ground(f, c, K) -> list[Any]: ... +def dmp_quo_ground(f, c, u, K) -> list[Any]: ... +def dup_exquo_ground(f, c, K) -> list[Any]: ... +def dmp_exquo_ground(f, c, u, K) -> list[Any]: ... +def dup_lshift(f, n, K): ... +def dup_rshift(f, n, K): ... +def dup_abs(f, K) -> list[Any]: ... +def dmp_abs(f, u, K) -> list[Any]: ... +def dup_neg(f, K) -> list[Any]: ... +def dmp_neg(f, u, K) -> list[Any]: ... +def dup_add(f, g, K): ... +def dmp_add(f, g, u, K) -> list[list[Any]]: ... +def dup_sub(f, g, K) -> list[Any]: ... +def dmp_sub(f, g, u, K) -> list[Any] | list[list[Any]]: ... +def dup_add_mul(f, g, h, K): ... +def dmp_add_mul(f, g, h, u, K) -> list[list[Any]]: ... +def dup_sub_mul(f, g, h, K) -> list[Any]: ... +def dmp_sub_mul(f, g, h, u, K) -> list[Any] | list[list[Any]]: ... +def dup_mul(f, g, K) -> list[Any]: ... +def dmp_mul(f, g, u, K) -> list[Any] | list[list[Any]]: ... +def dup_sqr(f, K): ... +def dmp_sqr(f, u, K) -> list[list[Any]]: ... +def dup_pow(f, n, K) -> list[Any]: ... +def dmp_pow(f, n, u, K) -> list[Any] | list[list[Any]]: ... +def dup_pdiv(f, g, K) -> tuple[list[Any], Any] | tuple[list[Any], list[Any]]: ... +def dup_prem(f, g, K) -> list[Any]: ... +def dup_pquo(f, g, K) -> list[Any]: ... +def dup_pexquo(f, g, K) -> list[Any]: ... +def dmp_pdiv(f, g, u, K) -> ( + tuple[list[Any], Any] + | tuple[list[Any], list[Any]] + | tuple[list[list[Any]], Any] + | tuple[ + list[Any] | Any | list[list[Any]] | list[Any | list[Any] | list[list[Any]]], + list[Any] | Any | list[list[Any]] | list[Any | list[Any] | list[list[Any]]], + ] +): ... +def dmp_prem(f, g, u, K) -> list[Any] | list[list[Any]] | list[Any | list[Any] | list[list[Any]]]: ... +def dmp_pquo(f, g, u, K) -> list[list[Any]] | list[Any] | list[Any | list[Any] | list[list[Any]]]: ... +def dmp_pexquo(f, g, u, K) -> list[Any] | list[list[Any]] | list[Any | list[Any] | list[list[Any]]]: ... +def dup_rr_div(f, g, K) -> tuple[list[Any], Any] | tuple[Any | list[Any], Any | list[Any]]: ... +def dmp_rr_div( + f, g, u, K +) -> ( + tuple[list[Any], Any] + | tuple[Any | list[Any], Any | list[Any]] + | tuple[list[list[Any]], Any] + | tuple[list[list[Any]] | Any, Any | list[Any] | list[list[Any]]] +): ... +def dup_ff_div(f, g, K) -> tuple[list[Any], Any] | tuple[Any, list[Any] | Any]: ... +def dmp_ff_div( + f, g, u, K +) -> ( + tuple[list[Any], Any] + | tuple[Any, list[Any] | Any] + | tuple[list[list[Any]], Any] + | tuple[list[list[Any]] | Any, Any | list[Any] | list[list[Any]]] +): ... +def dup_div(f, g, K) -> tuple[list[Any], Any] | tuple[Any, list[Any] | Any] | tuple[Any | list[Any], Any | list[Any]]: ... +def dup_rem(f, g, K) -> list[Any]: ... +def dup_quo(f, g, K) -> list[Any]: ... +def dup_exquo(f, g, K) -> list[Any]: ... +def dmp_div( + f, g, u, K +) -> ( + tuple[list[Any], Any] + | tuple[Any, list[Any] | Any] + | tuple[list[list[Any]], Any] + | tuple[list[list[Any]] | Any, Any | list[Any] | list[list[Any]]] + | tuple[Any | list[Any], Any | list[Any]] +): ... +def dmp_rem(f, g, u, K) -> list[Any] | list[list[Any]]: ... +def dmp_quo(f, g, u, K) -> list[list[Any]]: ... +def dmp_exquo(f, g, u, K) -> list[list[Any]]: ... +def dup_max_norm(f, K): ... +def dmp_max_norm(f, u, K): ... +def dup_l1_norm(f, K) -> int: ... +def dmp_l1_norm(f, u, K) -> int: ... +def dup_l2_norm_squared(f, K) -> int: ... +def dmp_l2_norm_squared(f, u, K) -> int: ... +def dup_expand(polys, K) -> list[Any]: ... +def dmp_expand(polys, u, K) -> list[list[Any]] | list[Any]: ... diff --git a/stubs/sympy-stubs/polys/densebasic.pyi b/stubs/sympy-stubs/polys/densebasic.pyi index 2d7c2685..3b22c1e0 100644 --- a/stubs/sympy-stubs/polys/densebasic.pyi +++ b/stubs/sympy-stubs/polys/densebasic.pyi @@ -1,199 +1,77 @@ from typing import Any, Literal -def poly_LC(f, K): - ... - -def poly_TC(f, K): - ... +def poly_LC(f, K): ... +def poly_TC(f, K): ... dmp_LC = ... dmp_TC = ... -def dmp_ground_LC(f, u, K): - ... - -def dmp_ground_TC(f, u, K): - ... - -def dmp_true_LT(f, u, K) -> tuple[tuple[Any, ...], Any]: - ... - -def dup_degree(f) -> int: - ... - -def dmp_degree(f, u) -> int: - ... - -def dmp_degree_in(f, j, u) -> int: - ... - -def dmp_degree_list(f, u) -> tuple[Any, ...]: - ... - -def dup_strip(f): - ... - -def dmp_strip(f, u) -> list[list[Any]]: - ... - -def dmp_validate(f, K=...) -> tuple[Any | list[list[Any]], Any]: - ... - -def dup_reverse(f): - ... - -def dup_copy(f) -> list[Any]: - ... - -def dmp_copy(f, u) -> list[Any]: - ... - -def dup_to_tuple(f) -> tuple[Any, ...]: - ... - -def dmp_to_tuple(f, u) -> tuple[Any, ...]: - ... - -def dup_normal(f, K): - ... - -def dmp_normal(f, u, K) -> list[list[Any]]: - ... - -def dup_convert(f, K0, K1): - ... - -def dmp_convert(f, u, K0, K1) -> list[list[Any]]: - ... - -def dup_from_sympy(f, K): - ... - -def dmp_from_sympy(f, u, K) -> list[list[Any]]: - ... - -def dup_nth(f, n, K): - ... - -def dmp_nth(f, n, u, K) -> list[list[Any]]: - ... - -def dmp_ground_nth(f, N, u, K): - ... - -def dmp_zero_p(f, u) -> bool: - ... - -def dmp_zero(u) -> list[list[Any]]: - ... - -def dmp_one_p(f, u, K) -> bool: - ... - -def dmp_one(u, K) -> list[list[Any]] | list[Any]: - ... - -def dmp_ground_p(f, c, u) -> bool: - ... - -def dmp_ground(c, u) -> list[list[Any]] | list[Any]: - ... - -def dmp_zeros(n, u, K) -> list[Any] | list[list[list[Any]]]: - ... - -def dmp_grounds(c, n, u) -> list[Any] | list[list[list[Any]] | Any | list[Any]]: - ... - -def dmp_negative_p(f, u, K): - ... - -def dmp_positive_p(f, u, K): - ... - -def dup_from_dict(f, K) -> list[Any]: - ... - -def dup_from_raw_dict(f, K) -> list[Any]: - ... - -def dmp_from_dict(f, u, K) -> list[Any] | list[list[Any]]: - ... - -def dup_to_dict(f, K=..., zero=...) -> dict[tuple[Literal[0]], Any] | dict[Any, Any]: - ... - -def dup_to_raw_dict(f, K=..., zero=...) -> dict[int, Any] | dict[Any, Any]: - ... - -def dmp_to_dict(f, u, K=..., zero=...) -> dict[tuple[Literal[0]], Any] | dict[Any, Any]: - ... - -def dmp_swap(f, i, j, u, K) -> list[Any] | list[list[Any]]: - ... - -def dmp_permute(f, P, u, K) -> list[Any] | list[list[Any]]: - ... - -def dmp_nest(f, l, K) -> list[list[Any]] | list[Any]: - ... - -def dmp_raise(f, l, u, K) -> list[list[Any]] | list[list[list[Any]] | Any | list[Any]] | list[Any]: - ... - -def dup_deflate(f, K) -> tuple[Literal[1], Any] | tuple[int, Any]: - ... - -def dmp_deflate(f, u, K) -> tuple[Any, Any] | tuple[tuple[Any, ...], Any] | tuple[tuple[Any, ...], list[Any] | Any | list[list[Any]]]: - ... - -def dup_multi_deflate(polys, K) -> tuple[Literal[1], Any] | tuple[int, tuple[Any, ...]]: - ... - -def dmp_multi_deflate(polys, u, K) -> tuple[tuple[int], Any | tuple[Any, ...]] | tuple[tuple[Any, ...], Any] | tuple[tuple[Any, ...], tuple[Any, ...]]: - ... - -def dup_inflate(f, m, K) -> list[Any]: - ... - -def dmp_inflate(f, M, u, K) -> list[Any]: - ... - -def dmp_exclude(f, u, K) -> tuple[list[Any], Any, Any] | tuple[list[Any], list[Any] | Any | list[list[Any]], Any]: - ... - -def dmp_include(f, J, u, K) -> list[Any] | list[list[Any]]: - ... - -def dmp_inject(f, u, K, front=...) -> tuple[list[Any] | Any | list[list[Any]], Any]: - ... - -def dmp_eject(f, u, K, front=...) -> list[Any] | list[list[Any]]: - ... - -def dup_terms_gcd(f, K) -> tuple[Literal[0], Any] | tuple[int, Any]: - ... - -def dmp_terms_gcd(f, u, K) -> tuple[Any, Any] | tuple[tuple[Any, ...], Any] | tuple[tuple[Any, ...], list[Any] | Any | list[list[Any]]]: - ... - -def dmp_list_terms(f, u, K, order=...) -> list[tuple[Any, Any]] | list[Any]: - ... - -def dup_apply_pairs(f, g, h, args, K): - ... - -def dmp_apply_pairs(f, g, h, args, u, K) -> list[list[Any]]: - ... - -def dup_slice(f, m, n, K) -> list[Any]: - ... - -def dmp_slice(f, m, n, u, K) -> list[Any] | list[list[Any]]: - ... - -def dmp_slice_in(f, m, n, j, u, K) -> list[Any] | list[list[Any]]: - ... - -def dup_random(n, a, b, K) -> list[Any]: - ... +def dmp_ground_LC(f, u, K): ... +def dmp_ground_TC(f, u, K): ... +def dmp_true_LT(f, u, K) -> tuple[tuple[Any, ...], Any]: ... +def dup_degree(f) -> int: ... +def dmp_degree(f, u) -> int: ... +def dmp_degree_in(f, j, u) -> int: ... +def dmp_degree_list(f, u) -> tuple[Any, ...]: ... +def dup_strip(f): ... +def dmp_strip(f, u) -> list[list[Any]]: ... +def dmp_validate(f, K=...) -> tuple[Any | list[list[Any]], Any]: ... +def dup_reverse(f): ... +def dup_copy(f) -> list[Any]: ... +def dmp_copy(f, u) -> list[Any]: ... +def dup_to_tuple(f) -> tuple[Any, ...]: ... +def dmp_to_tuple(f, u) -> tuple[Any, ...]: ... +def dup_normal(f, K): ... +def dmp_normal(f, u, K) -> list[list[Any]]: ... +def dup_convert(f, K0, K1): ... +def dmp_convert(f, u, K0, K1) -> list[list[Any]]: ... +def dup_from_sympy(f, K): ... +def dmp_from_sympy(f, u, K) -> list[list[Any]]: ... +def dup_nth(f, n, K): ... +def dmp_nth(f, n, u, K) -> list[list[Any]]: ... +def dmp_ground_nth(f, N, u, K): ... +def dmp_zero_p(f, u) -> bool: ... +def dmp_zero(u) -> list[list[Any]]: ... +def dmp_one_p(f, u, K) -> bool: ... +def dmp_one(u, K) -> list[list[Any]] | list[Any]: ... +def dmp_ground_p(f, c, u) -> bool: ... +def dmp_ground(c, u) -> list[list[Any]] | list[Any]: ... +def dmp_zeros(n, u, K) -> list[Any] | list[list[list[Any]]]: ... +def dmp_grounds(c, n, u) -> list[Any] | list[list[list[Any]] | Any | list[Any]]: ... +def dmp_negative_p(f, u, K): ... +def dmp_positive_p(f, u, K): ... +def dup_from_dict(f, K) -> list[Any]: ... +def dup_from_raw_dict(f, K) -> list[Any]: ... +def dmp_from_dict(f, u, K) -> list[Any] | list[list[Any]]: ... +def dup_to_dict(f, K=..., zero=...) -> dict[tuple[Literal[0]], Any] | dict[Any, Any]: ... +def dup_to_raw_dict(f, K=..., zero=...) -> dict[int, Any] | dict[Any, Any]: ... +def dmp_to_dict(f, u, K=..., zero=...) -> dict[tuple[Literal[0]], Any] | dict[Any, Any]: ... +def dmp_swap(f, i, j, u, K) -> list[Any] | list[list[Any]]: ... +def dmp_permute(f, P, u, K) -> list[Any] | list[list[Any]]: ... +def dmp_nest(f, l, K) -> list[list[Any]] | list[Any]: ... +def dmp_raise(f, l, u, K) -> list[list[Any]] | list[list[list[Any]] | Any | list[Any]] | list[Any]: ... +def dup_deflate(f, K) -> tuple[Literal[1], Any] | tuple[int, Any]: ... +def dmp_deflate( + f, u, K +) -> tuple[Any, Any] | tuple[tuple[Any, ...], Any] | tuple[tuple[Any, ...], list[Any] | Any | list[list[Any]]]: ... +def dup_multi_deflate(polys, K) -> tuple[Literal[1], Any] | tuple[int, tuple[Any, ...]]: ... +def dmp_multi_deflate( + polys, u, K +) -> tuple[tuple[int], Any | tuple[Any, ...]] | tuple[tuple[Any, ...], Any] | tuple[tuple[Any, ...], tuple[Any, ...]]: ... +def dup_inflate(f, m, K) -> list[Any]: ... +def dmp_inflate(f, M, u, K) -> list[Any]: ... +def dmp_exclude(f, u, K) -> tuple[list[Any], Any, Any] | tuple[list[Any], list[Any] | Any | list[list[Any]], Any]: ... +def dmp_include(f, J, u, K) -> list[Any] | list[list[Any]]: ... +def dmp_inject(f, u, K, front=...) -> tuple[list[Any] | Any | list[list[Any]], Any]: ... +def dmp_eject(f, u, K, front=...) -> list[Any] | list[list[Any]]: ... +def dup_terms_gcd(f, K) -> tuple[Literal[0], Any] | tuple[int, Any]: ... +def dmp_terms_gcd( + f, u, K +) -> tuple[Any, Any] | tuple[tuple[Any, ...], Any] | tuple[tuple[Any, ...], list[Any] | Any | list[list[Any]]]: ... +def dmp_list_terms(f, u, K, order=...) -> list[tuple[Any, Any]] | list[Any]: ... +def dup_apply_pairs(f, g, h, args, K): ... +def dmp_apply_pairs(f, g, h, args, u, K) -> list[list[Any]]: ... +def dup_slice(f, m, n, K) -> list[Any]: ... +def dmp_slice(f, m, n, u, K) -> list[Any] | list[list[Any]]: ... +def dmp_slice_in(f, m, n, j, u, K) -> list[Any] | list[list[Any]]: ... +def dup_random(n, a, b, K) -> list[Any]: ... diff --git a/stubs/sympy-stubs/polys/densetools.pyi b/stubs/sympy-stubs/polys/densetools.pyi index 8af45101..86d4b08b 100644 --- a/stubs/sympy-stubs/polys/densetools.pyi +++ b/stubs/sympy-stubs/polys/densetools.pyi @@ -1,110 +1,42 @@ from typing import Any -def dup_integrate(f, m, K): - ... - -def dmp_integrate(f, m, u, K) -> list[Any] | list[list[list[Any]]]: - ... - -def dmp_integrate_in(f, m, j, u, K) -> list[Any] | list[list[list[Any]]] | list[list[Any]]: - ... - -def dup_diff(f, m, K) -> list[Any]: - ... - -def dmp_diff(f, m, u, K) -> list[Any] | list[list[Any]]: - ... - -def dmp_diff_in(f, m, j, u, K) -> list[Any] | list[list[Any]]: - ... - -def dup_eval(f, a, K): - ... - -def dmp_eval(f, a, u, K) -> list[list[Any]]: - ... - -def dmp_eval_in(f, a, j, u, K) -> list[list[Any]]: - ... - -def dmp_eval_tail(f, A, u, K) -> list[list[Any]] | list[Any]: - ... - -def dmp_diff_eval_in(f, m, a, j, u, K) -> list[list[Any]]: - ... - -def dup_trunc(f, p, K): - ... - -def dmp_trunc(f, p, u, K) -> list[list[Any]]: - ... - -def dmp_ground_trunc(f, p, u, K) -> list[list[Any]]: - ... - -def dup_monic(f, K) -> list[Any]: - ... - -def dmp_ground_monic(f, u, K) -> list[Any]: - ... - -def dup_content(f, K): - ... - -def dmp_ground_content(f, u, K): - ... - -def dup_primitive(f, K) -> tuple[Any, Any] | tuple[Any, Any | list[Any]]: - ... - -def dmp_ground_primitive(f, u, K) -> tuple[Any, Any] | tuple[Any, Any | list[Any]]: - ... - -def dup_extract(f, g, K) -> tuple[Any, Any | list[Any], Any | list[Any]]: - ... - -def dmp_ground_extract(f, g, u, K) -> tuple[Any, Any | list[Any], Any | list[Any]]: - ... - -def dup_real_imag(f, K) -> tuple[list[list[Any]], list[list[Any]]] | tuple[list[list[Any]] | Any | list[Any], list[list[Any]] | Any | list[Any]]: - ... - -def dup_mirror(f, K) -> list[Any]: - ... - -def dup_scale(f, a, K) -> list[Any]: - ... - -def dup_shift(f, a, K) -> list[Any]: - ... - -def dup_transform(f, p, q, K) -> list[Any]: - ... - -def dup_compose(f, g, K) -> list[Any]: - ... - -def dmp_compose(f, g, u, K) -> list[Any] | list[list[Any]]: - ... - -def dup_decompose(f, K) -> list[Any | list[Any]]: - ... - -def dmp_lift(f, u, K) -> list[list[Any]]: - ... - -def dup_sign_variations(f, K) -> int: - ... - -def dup_clear_denoms(f, K0, K1=..., convert=...) -> tuple[Any, list[Any] | Any] | tuple[Any, Any]: - ... - -def dmp_clear_denoms(f, u, K0, K1=..., convert=...) -> tuple[Any, list[Any] | Any] | tuple[Any, Any] | tuple[Any, Any | list[list[Any]]]: - ... - -def dup_revert(f, n, K) -> list[Any]: - ... - -def dmp_revert(f, g, u, K) -> list[Any]: - ... - +def dup_integrate(f, m, K): ... +def dmp_integrate(f, m, u, K) -> list[Any] | list[list[list[Any]]]: ... +def dmp_integrate_in(f, m, j, u, K) -> list[Any] | list[list[list[Any]]] | list[list[Any]]: ... +def dup_diff(f, m, K) -> list[Any]: ... +def dmp_diff(f, m, u, K) -> list[Any] | list[list[Any]]: ... +def dmp_diff_in(f, m, j, u, K) -> list[Any] | list[list[Any]]: ... +def dup_eval(f, a, K): ... +def dmp_eval(f, a, u, K) -> list[list[Any]]: ... +def dmp_eval_in(f, a, j, u, K) -> list[list[Any]]: ... +def dmp_eval_tail(f, A, u, K) -> list[list[Any]] | list[Any]: ... +def dmp_diff_eval_in(f, m, a, j, u, K) -> list[list[Any]]: ... +def dup_trunc(f, p, K): ... +def dmp_trunc(f, p, u, K) -> list[list[Any]]: ... +def dmp_ground_trunc(f, p, u, K) -> list[list[Any]]: ... +def dup_monic(f, K) -> list[Any]: ... +def dmp_ground_monic(f, u, K) -> list[Any]: ... +def dup_content(f, K): ... +def dmp_ground_content(f, u, K): ... +def dup_primitive(f, K) -> tuple[Any, Any] | tuple[Any, Any | list[Any]]: ... +def dmp_ground_primitive(f, u, K) -> tuple[Any, Any] | tuple[Any, Any | list[Any]]: ... +def dup_extract(f, g, K) -> tuple[Any, Any | list[Any], Any | list[Any]]: ... +def dmp_ground_extract(f, g, u, K) -> tuple[Any, Any | list[Any], Any | list[Any]]: ... +def dup_real_imag( + f, K +) -> tuple[list[list[Any]], list[list[Any]]] | tuple[list[list[Any]] | Any | list[Any], list[list[Any]] | Any | list[Any]]: ... +def dup_mirror(f, K) -> list[Any]: ... +def dup_scale(f, a, K) -> list[Any]: ... +def dup_shift(f, a, K) -> list[Any]: ... +def dup_transform(f, p, q, K) -> list[Any]: ... +def dup_compose(f, g, K) -> list[Any]: ... +def dmp_compose(f, g, u, K) -> list[Any] | list[list[Any]]: ... +def dup_decompose(f, K) -> list[Any | list[Any]]: ... +def dmp_lift(f, u, K) -> list[list[Any]]: ... +def dup_sign_variations(f, K) -> int: ... +def dup_clear_denoms(f, K0, K1=..., convert=...) -> tuple[Any, list[Any] | Any] | tuple[Any, Any]: ... +def dmp_clear_denoms( + f, u, K0, K1=..., convert=... +) -> tuple[Any, list[Any] | Any] | tuple[Any, Any] | tuple[Any, Any | list[list[Any]]]: ... +def dup_revert(f, n, K) -> list[Any]: ... +def dmp_revert(f, g, u, K) -> list[Any]: ... diff --git a/stubs/sympy-stubs/polys/dispersion.pyi b/stubs/sympy-stubs/polys/dispersion.pyi index dcdecaae..d81f1992 100644 --- a/stubs/sympy-stubs/polys/dispersion.pyi +++ b/stubs/sympy-stubs/polys/dispersion.pyi @@ -1,8 +1,4 @@ from typing import Any -def dispersionset(p, q=..., *gens, **args) -> set[int] | set[Any]: - ... - -def dispersion(p, q=..., *gens, **args) -> int: - ... - +def dispersionset(p, q=..., *gens, **args) -> set[int] | set[Any]: ... +def dispersion(p, q=..., *gens, **args) -> int: ... diff --git a/stubs/sympy-stubs/polys/distributedmodules.pyi b/stubs/sympy-stubs/polys/distributedmodules.pyi index e78170bb..2f372bda 100644 --- a/stubs/sympy-stubs/polys/distributedmodules.pyi +++ b/stubs/sympy-stubs/polys/distributedmodules.pyi @@ -1,71 +1,47 @@ from typing import Any -def sdm_monomial_mul(M, X) -> tuple[Any, *tuple[Any, ...]]: - ... - -def sdm_monomial_deg(M) -> int: - ... - -def sdm_monomial_lcm(A, B) -> tuple[Any, *tuple[Any, ...]]: - ... - -def sdm_monomial_divides(A, B) -> bool: - ... - -def sdm_LC(f, K): - ... - -def sdm_to_dict(f) -> dict[Any, Any]: - ... - -def sdm_from_dict(d, O) -> list[tuple[Any, Any]]: - ... - -def sdm_sort(f, O) -> list[Any]: - ... - -def sdm_strip(f) -> list[tuple[Any, Any]]: - ... - -def sdm_add(f, g, O, K) -> list[tuple[Any, Any]]: - ... - -def sdm_LM(f): - ... - -def sdm_LT(f): - ... - -def sdm_mul_term(f, term, O, K) -> list[Any] | list[tuple[tuple[Any, *tuple[Any, ...]], Any]]: - ... - -def sdm_zero() -> list[Any]: - ... - -def sdm_deg(f) -> int: - ... - -def sdm_from_vector(vec, O, K, **opts) -> list[tuple[Any, Any]]: - ... - -def sdm_to_vector(f, gens, K, n=...) -> list[Any]: - ... - -def sdm_spoly(f, g, O, K, phantom=...) -> list[Any] | list[tuple[Any, Any]] | tuple[list[tuple[Any, Any]], list[tuple[Any, Any]]]: - ... - -def sdm_ecart(f) -> int: - ... - -def sdm_nf_mora(f, G, O, K, phantom=...) -> tuple[Any | tuple[Any, Any] | list[tuple[Any, Any]] | list[Any] | tuple[list[tuple[Any, Any]], list[tuple[Any, Any]]], Any | tuple[Any, Any] | list[tuple[Any, Any]]] | tuple[Any, Any] | list[tuple[Any, Any]] | list[Any] | tuple[list[tuple[Any, Any]], list[tuple[Any, Any]]]: - ... - -def sdm_nf_buchberger(f, G, O, K, phantom=...) -> tuple[Any | tuple[Any, Any] | list[tuple[Any, Any]] | list[Any] | tuple[list[tuple[Any, Any]], list[tuple[Any, Any]]], Any | tuple[Any, Any] | list[tuple[Any, Any]]] | tuple[Any, Any] | list[tuple[Any, Any]] | list[Any] | tuple[list[tuple[Any, Any]], list[tuple[Any, Any]]]: - ... - -def sdm_nf_buchberger_reduced(f, G, O, K) -> list[Any] | list[tuple[Any, Any]]: - ... - -def sdm_groebner(G, NF, O, K, extended=...) -> tuple[list[Any], list[Any]] | list[Any] | tuple[list[list[Any]], list[Any]] | list[list[Any]]: - ... - +def sdm_monomial_mul(M, X) -> tuple[Any, *tuple[Any, ...]]: ... +def sdm_monomial_deg(M) -> int: ... +def sdm_monomial_lcm(A, B) -> tuple[Any, *tuple[Any, ...]]: ... +def sdm_monomial_divides(A, B) -> bool: ... +def sdm_LC(f, K): ... +def sdm_to_dict(f) -> dict[Any, Any]: ... +def sdm_from_dict(d, O) -> list[tuple[Any, Any]]: ... +def sdm_sort(f, O) -> list[Any]: ... +def sdm_strip(f) -> list[tuple[Any, Any]]: ... +def sdm_add(f, g, O, K) -> list[tuple[Any, Any]]: ... +def sdm_LM(f): ... +def sdm_LT(f): ... +def sdm_mul_term(f, term, O, K) -> list[Any] | list[tuple[tuple[Any, *tuple[Any, ...]], Any]]: ... +def sdm_zero() -> list[Any]: ... +def sdm_deg(f) -> int: ... +def sdm_from_vector(vec, O, K, **opts) -> list[tuple[Any, Any]]: ... +def sdm_to_vector(f, gens, K, n=...) -> list[Any]: ... +def sdm_spoly( + f, g, O, K, phantom=... +) -> list[Any] | list[tuple[Any, Any]] | tuple[list[tuple[Any, Any]], list[tuple[Any, Any]]]: ... +def sdm_ecart(f) -> int: ... +def sdm_nf_mora(f, G, O, K, phantom=...) -> ( + tuple[ + Any | tuple[Any, Any] | list[tuple[Any, Any]] | list[Any] | tuple[list[tuple[Any, Any]], list[tuple[Any, Any]]], + Any | tuple[Any, Any] | list[tuple[Any, Any]], + ] + | tuple[Any, Any] + | list[tuple[Any, Any]] + | list[Any] + | tuple[list[tuple[Any, Any]], list[tuple[Any, Any]]] +): ... +def sdm_nf_buchberger(f, G, O, K, phantom=...) -> ( + tuple[ + Any | tuple[Any, Any] | list[tuple[Any, Any]] | list[Any] | tuple[list[tuple[Any, Any]], list[tuple[Any, Any]]], + Any | tuple[Any, Any] | list[tuple[Any, Any]], + ] + | tuple[Any, Any] + | list[tuple[Any, Any]] + | list[Any] + | tuple[list[tuple[Any, Any]], list[tuple[Any, Any]]] +): ... +def sdm_nf_buchberger_reduced(f, G, O, K) -> list[Any] | list[tuple[Any, Any]]: ... +def sdm_groebner( + G, NF, O, K, extended=... +) -> tuple[list[Any], list[Any]] | list[Any] | tuple[list[list[Any]], list[Any]] | list[list[Any]]: ... diff --git a/stubs/sympy-stubs/polys/domains/__init__.pyi b/stubs/sympy-stubs/polys/domains/__init__.pyi index 7ed4905f..5bd5f399 100644 --- a/stubs/sympy-stubs/polys/domains/__init__.pyi +++ b/stubs/sympy-stubs/polys/domains/__init__.pyi @@ -19,7 +19,29 @@ from sympy.polys.domains.pythonrationalfield import PythonRationalField from sympy.polys.domains.rationalfield import QQ, RationalField from sympy.polys.domains.realfield import RR, RealField -__all__ = ['Domain', 'FiniteField', 'IntegerRing', 'RationalField', 'RealField', 'ComplexField', 'AlgebraicField', 'PolynomialRing', 'FractionField', 'ExpressionDomain', 'PythonRational', 'GF', 'FF', 'ZZ', 'QQ', 'ZZ_I', 'QQ_I', 'RR', 'CC', 'EX', 'EXRAW'] +__all__ = [ + "Domain", + "FiniteField", + "IntegerRing", + "RationalField", + "RealField", + "ComplexField", + "AlgebraicField", + "PolynomialRing", + "FractionField", + "ExpressionDomain", + "PythonRational", + "GF", + "FF", + "ZZ", + "QQ", + "ZZ_I", + "QQ_I", + "RR", + "CC", + "EX", + "EXRAW", +] FF_python = ... FF_gmpy = ... ZZ_python = ... diff --git a/stubs/sympy-stubs/polys/domains/algebraicfield.pyi b/stubs/sympy-stubs/polys/domains/algebraicfield.pyi index a839d8cc..25c4f9d6 100644 --- a/stubs/sympy-stubs/polys/domains/algebraicfield.pyi +++ b/stubs/sympy-stubs/polys/domains/algebraicfield.pyi @@ -11,98 +11,34 @@ class AlgebraicField(Field, CharacteristicZero, SimpleDomain): is_Numerical = ... has_assoc_Ring = ... has_assoc_Field = ... - def __init__(self, dom, *ext, alias=...) -> None: - ... - - def new(self, element) -> dtype: - ... - - def __str__(self) -> str: - ... - - def __hash__(self) -> int: - ... - - def __eq__(self, other) -> bool: - ... - - def algebraic_field(self, *extension, alias=...) -> Any: - ... - - def to_alg_num(self, a) -> Any: - ... - - def to_sympy(self, a) -> Order: - ... - - def from_sympy(self, a): - ... - - def from_ZZ(K1, a, K0): - ... - - def from_ZZ_python(K1, a, K0): - ... - - def from_QQ(K1, a, K0): - ... - - def from_QQ_python(K1, a, K0): - ... - - def from_ZZ_gmpy(K1, a, K0): - ... - - def from_QQ_gmpy(K1, a, K0): - ... - - def from_RealField(K1, a, K0): - ... - - def get_ring(self): - ... - - def is_positive(self, a): - ... - - def is_negative(self, a): - ... - - def is_nonpositive(self, a): - ... - - def is_nonnegative(self, a): - ... - - def numer(self, a): - ... - - def denom(self, a) -> ANP: - ... - - def from_AlgebraicField(K1, a, K0): - ... - - def from_GaussianIntegerRing(K1, a, K0): - ... - - def from_GaussianRationalField(K1, a, K0): - ... - - def maximal_order(self) -> Any | None: - ... - - def integral_basis(self, fmt=...) -> list[Any | Order] | list[Any] | list[dtype]: - ... - - def discriminant(self) -> Any | None: - ... - - def primes_above(self, p) -> Any: - ... - - def galois_group(self, by_name=..., max_tries=..., randomize=...) -> Any: - ... - - - + def __init__(self, dom, *ext, alias=...) -> None: ... + def new(self, element) -> dtype: ... + def __str__(self) -> str: ... + def __hash__(self) -> int: ... + def __eq__(self, other) -> bool: ... + def algebraic_field(self, *extension, alias=...) -> Any: ... + def to_alg_num(self, a) -> Any: ... + def to_sympy(self, a) -> Order: ... + def from_sympy(self, a): ... + def from_ZZ(K1, a, K0): ... + def from_ZZ_python(K1, a, K0): ... + def from_QQ(K1, a, K0): ... + def from_QQ_python(K1, a, K0): ... + def from_ZZ_gmpy(K1, a, K0): ... + def from_QQ_gmpy(K1, a, K0): ... + def from_RealField(K1, a, K0): ... + def get_ring(self): ... + def is_positive(self, a): ... + def is_negative(self, a): ... + def is_nonpositive(self, a): ... + def is_nonnegative(self, a): ... + def numer(self, a): ... + def denom(self, a) -> ANP: ... + def from_AlgebraicField(K1, a, K0): ... + def from_GaussianIntegerRing(K1, a, K0): ... + def from_GaussianRationalField(K1, a, K0): ... + def maximal_order(self) -> Any | None: ... + def integral_basis(self, fmt=...) -> list[Any | Order] | list[Any] | list[dtype]: ... + def discriminant(self) -> Any | None: ... + def primes_above(self, p) -> Any: ... + def galois_group(self, by_name=..., max_tries=..., randomize=...) -> Any: ... diff --git a/stubs/sympy-stubs/polys/domains/characteristiczero.pyi b/stubs/sympy-stubs/polys/domains/characteristiczero.pyi index 3e1569d1..1c605087 100644 --- a/stubs/sympy-stubs/polys/domains/characteristiczero.pyi +++ b/stubs/sympy-stubs/polys/domains/characteristiczero.pyi @@ -5,8 +5,4 @@ from sympy.utilities import public class CharacteristicZero(Domain): has_CharacteristicZero = ... - def characteristic(self) -> Literal[0]: - ... - - - + def characteristic(self) -> Literal[0]: ... diff --git a/stubs/sympy-stubs/polys/domains/complexfield.pyi b/stubs/sympy-stubs/polys/domains/complexfield.pyi index bb1714b6..9078d301 100644 --- a/stubs/sympy-stubs/polys/domains/complexfield.pyi +++ b/stubs/sympy-stubs/polys/domains/complexfield.pyi @@ -13,96 +13,37 @@ class ComplexField(Field, CharacteristicZero, SimpleDomain): has_assoc_Field = ... _default_precision = ... @property - def has_default_precision(self) -> Any: - ... - + def has_default_precision(self) -> Any: ... @property - def precision(self) -> Any: - ... - + def precision(self) -> Any: ... @property - def dps(self) -> Any: - ... - + def dps(self) -> Any: ... @property - def tolerance(self) -> Any: - ... - - def __init__(self, prec=..., dps=..., tol=...) -> None: - ... - - def __eq__(self, other) -> bool: - ... - - def __hash__(self) -> int: - ... - - def to_sympy(self, element): - ... - - def from_sympy(self, expr) -> Any: - ... - - def from_ZZ(self, element, base) -> Any: - ... - - def from_QQ(self, element, base) -> Any: - ... - - def from_ZZ_python(self, element, base) -> Any: - ... - - def from_QQ_python(self, element, base): - ... - - def from_ZZ_gmpy(self, element, base) -> Any: - ... - - def from_QQ_gmpy(self, element, base) -> Any: - ... - - def from_GaussianIntegerRing(self, element, base) -> Any: - ... - - def from_GaussianRationalField(self, element, base) -> Any: - ... - - def from_AlgebraicField(self, element, base) -> Any: - ... - - def from_RealField(self, element, base) -> Any: - ... - - def from_ComplexField(self, element, base) -> Any: - ... - - def get_ring(self): - ... - - def get_exact(self): - ... - - def is_negative(self, element) -> Literal[False]: - ... - - def is_positive(self, element) -> Literal[False]: - ... - - def is_nonnegative(self, element) -> Literal[False]: - ... - - def is_nonpositive(self, element) -> Literal[False]: - ... - - def gcd(self, a, b) -> Any: - ... - - def lcm(self, a, b): - ... - - def almosteq(self, a, b, tolerance=...) -> Any: - ... - - + def tolerance(self) -> Any: ... + def __init__(self, prec=..., dps=..., tol=...) -> None: ... + def __eq__(self, other) -> bool: ... + def __hash__(self) -> int: ... + def to_sympy(self, element): ... + def from_sympy(self, expr) -> Any: ... + def from_ZZ(self, element, base) -> Any: ... + def from_QQ(self, element, base) -> Any: ... + def from_ZZ_python(self, element, base) -> Any: ... + def from_QQ_python(self, element, base): ... + def from_ZZ_gmpy(self, element, base) -> Any: ... + def from_QQ_gmpy(self, element, base) -> Any: ... + def from_GaussianIntegerRing(self, element, base) -> Any: ... + def from_GaussianRationalField(self, element, base) -> Any: ... + def from_AlgebraicField(self, element, base) -> Any: ... + def from_RealField(self, element, base) -> Any: ... + def from_ComplexField(self, element, base) -> Any: ... + def get_ring(self): ... + def get_exact(self): ... + def is_negative(self, element) -> Literal[False]: ... + def is_positive(self, element) -> Literal[False]: ... + def is_nonnegative(self, element) -> Literal[False]: ... + def is_nonpositive(self, element) -> Literal[False]: ... + def gcd(self, a, b) -> Any: ... + def lcm(self, a, b): ... + def almosteq(self, a, b, tolerance=...) -> Any: ... CC = ... diff --git a/stubs/sympy-stubs/polys/domains/compositedomain.pyi b/stubs/sympy-stubs/polys/domains/compositedomain.pyi index 80bd0243..b39d34ac 100644 --- a/stubs/sympy-stubs/polys/domains/compositedomain.pyi +++ b/stubs/sympy-stubs/polys/domains/compositedomain.pyi @@ -4,11 +4,5 @@ from sympy.polys.domains.domain import Domain class CompositeDomain(Domain): is_Composite = ... - def inject(self, *symbols) -> Self: - ... - - def drop(self, *symbols) -> Self: - ... - - - + def inject(self, *symbols) -> Self: ... + def drop(self, *symbols) -> Self: ... diff --git a/stubs/sympy-stubs/polys/domains/domain.pyi b/stubs/sympy-stubs/polys/domains/domain.pyi index 376b0ac8..2870b7c2 100644 --- a/stubs/sympy-stubs/polys/domains/domain.pyi +++ b/stubs/sympy-stubs/polys/domains/domain.pyi @@ -29,260 +29,92 @@ class Domain: has_CharacteristicZero = ... rep: str | None = ... alias: str | None = ... - def __init__(self) -> None: - ... - - def __str__(self) -> str: - ... - - def __repr__(self) -> str: - ... - - def __hash__(self) -> int: - ... - - def new(self, *args): - ... - + def __init__(self) -> None: ... + def __str__(self) -> str: ... + def __repr__(self) -> str: ... + def __hash__(self) -> int: ... + def new(self, *args): ... @property - def tp(self) -> None: - ... - - def __call__(self, *args): - ... - - def normal(self, *args): - ... - - def convert_from(self, element, base) -> Any: - ... - - def convert(self, element, base=...) -> Any: - ... - - def of_type(self, element) -> bool: - ... - - def __contains__(self, a) -> bool: - ... - - def to_sympy(self, a): - ... - - def from_sympy(self, a): - ... - - def sum(self, args) -> int: - ... - - def from_FF(K1, a, K0) -> None: - ... - - def from_FF_python(K1, a, K0) -> None: - ... - - def from_ZZ_python(K1, a, K0) -> None: - ... - - def from_QQ_python(K1, a, K0) -> None: - ... - - def from_FF_gmpy(K1, a, K0) -> None: - ... - - def from_ZZ_gmpy(K1, a, K0) -> None: - ... - - def from_QQ_gmpy(K1, a, K0) -> None: - ... - - def from_RealField(K1, a, K0) -> None: - ... - - def from_ComplexField(K1, a, K0) -> None: - ... - - def from_AlgebraicField(K1, a, K0) -> None: - ... - - def from_PolynomialRing(K1, a, K0) -> Any | None: - ... - - def from_FractionField(K1, a, K0) -> None: - ... - - def from_MonogenicFiniteExtension(K1, a, K0) -> Any: - ... - - def from_ExpressionDomain(K1, a, K0): - ... - - def from_ExpressionRawDomain(K1, a, K0): - ... - - def from_GlobalPolynomialRing(K1, a, K0) -> Any | None: - ... - - def from_GeneralizedPolynomialRing(K1, a, K0) -> None: - ... - - def unify_with_symbols(K0, K1, symbols): - ... - - def unify(K0, K1, symbols=...): - ... - - def __eq__(self, other) -> bool: - ... - - def __ne__(self, other) -> bool: - ... - - def map(self, seq) -> list[Any]: - ... - - def get_ring(self): - ... - - def get_field(self): - ... - - def get_exact(self) -> Self: - ... - - def __getitem__(self, symbols) -> Any: - ... - - def poly_ring(self, *symbols, order=...) -> Any: - ... - - def frac_field(self, *symbols, order=...) -> Any: - ... - - def old_poly_ring(self, *symbols, **kwargs) -> Any: - ... - - def old_frac_field(self, *symbols, **kwargs) -> Any: - ... - - def algebraic_field(self, *extension, alias=...): - ... - - def alg_field_from_poly(self, poly, alias=..., root_index=...): - ... - - def cyclotomic_field(self, n, ss=..., alias=..., gen=..., root_index=...): - ... - - def inject(self, *symbols): - ... - - def drop(self, *symbols) -> Self: - ... - - def is_zero(self, a) -> bool: - ... - - def is_one(self, a): - ... - - def is_positive(self, a): - ... - - def is_negative(self, a): - ... - - def is_nonpositive(self, a): - ... - - def is_nonnegative(self, a): - ... - - def canonical_unit(self, a) -> Any: - ... - - def abs(self, a): - ... - - def neg(self, a): - ... - - def pos(self, a): - ... - - def add(self, a, b): - ... - - def sub(self, a, b): - ... - - def mul(self, a, b): - ... - - def pow(self, a, b): - ... - - def exquo(self, a, b): - ... - - def quo(self, a, b): - ... - - def rem(self, a, b): - ... - - def div(self, a, b): - ... - - def invert(self, a, b): - ... - - def revert(self, a): - ... - - def numer(self, a): - ... - - def denom(self, a): - ... - - def half_gcdex(self, a, b) -> tuple[Any, Any]: - ... - - def gcdex(self, a, b): - ... - - def cofactors(self, a, b) -> tuple[Any, Any, Any]: - ... - - def gcd(self, a, b): - ... - - def lcm(self, a, b): - ... - - def log(self, a, b): - ... - - def sqrt(self, a): - ... - - def evalf(self, a, prec=..., **options): - ... - - n = ... - def real(self, a): - ... - - def imag(self, a) -> Any: - ... - - def almosteq(self, a, b, tolerance=...): - ... - - def characteristic(self): - ... - + def tp(self) -> None: ... + def __call__(self, *args): ... + def normal(self, *args): ... + def convert_from(self, element, base) -> Any: ... + def convert(self, element, base=...) -> Any: ... + def of_type(self, element) -> bool: ... + def __contains__(self, a) -> bool: ... + def to_sympy(self, a): ... + def from_sympy(self, a): ... + def sum(self, args) -> int: ... + def from_FF(K1, a, K0) -> None: ... + def from_FF_python(K1, a, K0) -> None: ... + def from_ZZ_python(K1, a, K0) -> None: ... + def from_QQ_python(K1, a, K0) -> None: ... + def from_FF_gmpy(K1, a, K0) -> None: ... + def from_ZZ_gmpy(K1, a, K0) -> None: ... + def from_QQ_gmpy(K1, a, K0) -> None: ... + def from_RealField(K1, a, K0) -> None: ... + def from_ComplexField(K1, a, K0) -> None: ... + def from_AlgebraicField(K1, a, K0) -> None: ... + def from_PolynomialRing(K1, a, K0) -> Any | None: ... + def from_FractionField(K1, a, K0) -> None: ... + def from_MonogenicFiniteExtension(K1, a, K0) -> Any: ... + def from_ExpressionDomain(K1, a, K0): ... + def from_ExpressionRawDomain(K1, a, K0): ... + def from_GlobalPolynomialRing(K1, a, K0) -> Any | None: ... + def from_GeneralizedPolynomialRing(K1, a, K0) -> None: ... + def unify_with_symbols(K0, K1, symbols): ... + def unify(K0, K1, symbols=...): ... + def __eq__(self, other) -> bool: ... + def __ne__(self, other) -> bool: ... + def map(self, seq) -> list[Any]: ... + def get_ring(self): ... + def get_field(self): ... + def get_exact(self) -> Self: ... + def __getitem__(self, symbols) -> Any: ... + def poly_ring(self, *symbols, order=...) -> Any: ... + def frac_field(self, *symbols, order=...) -> Any: ... + def old_poly_ring(self, *symbols, **kwargs) -> Any: ... + def old_frac_field(self, *symbols, **kwargs) -> Any: ... + def algebraic_field(self, *extension, alias=...): ... + def alg_field_from_poly(self, poly, alias=..., root_index=...): ... + def cyclotomic_field(self, n, ss=..., alias=..., gen=..., root_index=...): ... + def inject(self, *symbols): ... + def drop(self, *symbols) -> Self: ... + def is_zero(self, a) -> bool: ... + def is_one(self, a): ... + def is_positive(self, a): ... + def is_negative(self, a): ... + def is_nonpositive(self, a): ... + def is_nonnegative(self, a): ... + def canonical_unit(self, a) -> Any: ... + def abs(self, a): ... + def neg(self, a): ... + def pos(self, a): ... + def add(self, a, b): ... + def sub(self, a, b): ... + def mul(self, a, b): ... + def pow(self, a, b): ... + def exquo(self, a, b): ... + def quo(self, a, b): ... + def rem(self, a, b): ... + def div(self, a, b): ... + def invert(self, a, b): ... + def revert(self, a): ... + def numer(self, a): ... + def denom(self, a): ... + def half_gcdex(self, a, b) -> tuple[Any, Any]: ... + def gcdex(self, a, b): ... + def cofactors(self, a, b) -> tuple[Any, Any, Any]: ... + def gcd(self, a, b): ... + def lcm(self, a, b): ... + def log(self, a, b): ... + def sqrt(self, a): ... + def evalf(self, a, prec=..., **options): ... + n = ... + def real(self, a): ... + def imag(self, a) -> Any: ... + def almosteq(self, a, b, tolerance=...): ... + def characteristic(self): ... -__all__ = ['Domain'] +__all__ = ["Domain"] diff --git a/stubs/sympy-stubs/polys/domains/expressiondomain.pyi b/stubs/sympy-stubs/polys/domains/expressiondomain.pyi index d3078be3..e0f208b9 100644 --- a/stubs/sympy-stubs/polys/domains/expressiondomain.pyi +++ b/stubs/sympy-stubs/polys/domains/expressiondomain.pyi @@ -6,166 +6,68 @@ from sympy.polys.polyutils import PicklableWithSlots from sympy.utilities import public eflags = ... + @public class ExpressionDomain(Field, CharacteristicZero, SimpleDomain): is_EX = ... + class Expression(PicklableWithSlots): __slots__ = ... - def __init__(self, ex) -> None: - ... - - def __repr__(f) -> str: - ... - - def __str__(f) -> str: - ... - - def __hash__(self) -> int: - ... - - def as_expr(f): - ... - - def numer(f) -> Self: - ... - - def denom(f) -> Self: - ... - - def simplify(f, ex) -> Self: - ... - - def __abs__(f) -> Self: - ... - - def __neg__(f) -> Self: - ... - - def __add__(f, g) -> NotImplementedType | Self: - ... - - def __radd__(f, g) -> Self: - ... - - def __sub__(f, g) -> NotImplementedType | Self | Expression: - ... - - def __rsub__(f, g) -> Self: - ... - - def __mul__(f, g) -> NotImplementedType | Any | Self: - ... - - def __rmul__(f, g) -> Self: - ... - - def __pow__(f, n) -> Self | NotImplementedType: - ... - - def __truediv__(f, g) -> Self | NotImplementedType: - ... - - def __rtruediv__(f, g) -> Self: - ... - - def __eq__(f, g) -> bool: - ... - - def __ne__(f, g) -> bool: - ... - - def __bool__(f) -> bool: - ... - - def gcd(f, g) -> Self: - ... - - def lcm(f, g) -> Self: - ... - - - + def __init__(self, ex) -> None: ... + def __repr__(f) -> str: ... + def __str__(f) -> str: ... + def __hash__(self) -> int: ... + def as_expr(f): ... + def numer(f) -> Self: ... + def denom(f) -> Self: ... + def simplify(f, ex) -> Self: ... + def __abs__(f) -> Self: ... + def __neg__(f) -> Self: ... + def __add__(f, g) -> NotImplementedType | Self: ... + def __radd__(f, g) -> Self: ... + def __sub__(f, g) -> NotImplementedType | Self | Expression: ... + def __rsub__(f, g) -> Self: ... + def __mul__(f, g) -> NotImplementedType | Any | Self: ... + def __rmul__(f, g) -> Self: ... + def __pow__(f, n) -> Self | NotImplementedType: ... + def __truediv__(f, g) -> Self | NotImplementedType: ... + def __rtruediv__(f, g) -> Self: ... + def __eq__(f, g) -> bool: ... + def __ne__(f, g) -> bool: ... + def __bool__(f) -> bool: ... + def gcd(f, g) -> Self: ... + def lcm(f, g) -> Self: ... + dtype = Expression zero = ... one = ... rep = ... has_assoc_Ring = ... has_assoc_Field = ... - def __init__(self) -> None: - ... - - def to_sympy(self, a): - ... - - def from_sympy(self, a) -> dtype: - ... - - def from_ZZ(K1, a, K0): - ... - - def from_ZZ_python(K1, a, K0): - ... - - def from_QQ(K1, a, K0): - ... - - def from_QQ_python(K1, a, K0): - ... - - def from_ZZ_gmpy(K1, a, K0): - ... - - def from_QQ_gmpy(K1, a, K0): - ... - - def from_GaussianIntegerRing(K1, a, K0): - ... - - def from_GaussianRationalField(K1, a, K0): - ... - - def from_RealField(K1, a, K0): - ... - - def from_PolynomialRing(K1, a, K0): - ... - - def from_FractionField(K1, a, K0): - ... - - def from_ExpressionDomain(K1, a, K0): - ... - - def get_ring(self) -> Self: - ... - - def get_field(self) -> Self: - ... - - def is_positive(self, a): - ... - - def is_negative(self, a): - ... - - def is_nonpositive(self, a): - ... - - def is_nonnegative(self, a): - ... - - def numer(self, a): - ... - - def denom(self, a): - ... - - def gcd(self, a, b): - ... - - def lcm(self, a, b): - ... - - + def __init__(self) -> None: ... + def to_sympy(self, a): ... + def from_sympy(self, a) -> dtype: ... + def from_ZZ(K1, a, K0): ... + def from_ZZ_python(K1, a, K0): ... + def from_QQ(K1, a, K0): ... + def from_QQ_python(K1, a, K0): ... + def from_ZZ_gmpy(K1, a, K0): ... + def from_QQ_gmpy(K1, a, K0): ... + def from_GaussianIntegerRing(K1, a, K0): ... + def from_GaussianRationalField(K1, a, K0): ... + def from_RealField(K1, a, K0): ... + def from_PolynomialRing(K1, a, K0): ... + def from_FractionField(K1, a, K0): ... + def from_ExpressionDomain(K1, a, K0): ... + def get_ring(self) -> Self: ... + def get_field(self) -> Self: ... + def is_positive(self, a): ... + def is_negative(self, a): ... + def is_nonpositive(self, a): ... + def is_nonnegative(self, a): ... + def numer(self, a): ... + def denom(self, a): ... + def gcd(self, a, b): ... + def lcm(self, a, b): ... EX = ... diff --git a/stubs/sympy-stubs/polys/domains/expressionrawdomain.pyi b/stubs/sympy-stubs/polys/domains/expressionrawdomain.pyi index 89b22cc5..4dd5d7bf 100644 --- a/stubs/sympy-stubs/polys/domains/expressionrawdomain.pyi +++ b/stubs/sympy-stubs/polys/domains/expressionrawdomain.pyi @@ -13,28 +13,13 @@ class ExpressionRawDomain(Field, CharacteristicZero, SimpleDomain): rep = ... has_assoc_Ring = ... has_assoc_Field = ... - def __init__(self) -> None: - ... - + def __init__(self) -> None: ... @classmethod - def new(self, a): - ... - - def to_sympy(self, a): - ... - - def from_sympy(self, a) -> Expr: - ... - - def convert_from(self, a, K): - ... - - def get_field(self) -> Self: - ... - - def sum(self, items) -> Order: - ... - - + def new(self, a): ... + def to_sympy(self, a): ... + def from_sympy(self, a) -> Expr: ... + def convert_from(self, a, K): ... + def get_field(self) -> Self: ... + def sum(self, items) -> Order: ... EXRAW = ... diff --git a/stubs/sympy-stubs/polys/domains/field.pyi b/stubs/sympy-stubs/polys/domains/field.pyi index 4f01a5e8..525a12ef 100644 --- a/stubs/sympy-stubs/polys/domains/field.pyi +++ b/stubs/sympy-stubs/polys/domains/field.pyi @@ -5,35 +5,13 @@ from sympy.polys.domains.ring import Ring class Field(Ring): is_Field = ... is_PID = ... - def get_ring(self): - ... - - def get_field(self) -> Self: - ... - - def exquo(self, a, b): - ... - - def quo(self, a, b): - ... - - def rem(self, a, b): - ... - - def div(self, a, b) -> tuple[Any, Any]: - ... - - def gcd(self, a, b): - ... - - def lcm(self, a, b): - ... - - def revert(self, a): - ... - - def is_unit(self, a) -> bool: - ... - - - + def get_ring(self): ... + def get_field(self) -> Self: ... + def exquo(self, a, b): ... + def quo(self, a, b): ... + def rem(self, a, b): ... + def div(self, a, b) -> tuple[Any, Any]: ... + def gcd(self, a, b): ... + def lcm(self, a, b): ... + def revert(self, a): ... + def is_unit(self, a) -> bool: ... diff --git a/stubs/sympy-stubs/polys/domains/finitefield.pyi b/stubs/sympy-stubs/polys/domains/finitefield.pyi index a281a4de..be993958 100644 --- a/stubs/sympy-stubs/polys/domains/finitefield.pyi +++ b/stubs/sympy-stubs/polys/domains/finitefield.pyi @@ -6,7 +6,7 @@ from sympy.polys.domains.field import Field from sympy.polys.domains.simpledomain import SimpleDomain from sympy.utilities.decorator import doctest_depends_on -class FiniteField(Field, SimpleDomain): # type: ignore +class FiniteField(Field, SimpleDomain): # type: ignore rep = ... alias = ... is_FF = ... @@ -15,61 +15,24 @@ class FiniteField(Field, SimpleDomain): # type: ignore has_assoc_Field = ... dom = ... mod = ... - def __init__(self, mod, symmetric=...) -> None: - ... - - def __str__(self) -> str: - ... - - def __hash__(self) -> int: - ... - - def __eq__(self, other) -> bool: - ... - - def characteristic(self) -> Any | None: - ... - - def get_field(self) -> Self: - ... - - def to_sympy(self, a) -> Integer: - ... - - def from_sympy(self, a) -> Any | Self: - ... - - def from_FF(K1, a, K0=...) -> Any | Self: - ... - - def from_FF_python(K1, a, K0=...) -> Any | Self: - ... - - def from_ZZ(K1, a, K0=...) -> Any | Self: - ... - - def from_ZZ_python(K1, a, K0=...) -> Any | Self: - ... - - def from_QQ(K1, a, K0=...) -> Any | Self | None: - ... - - def from_QQ_python(K1, a, K0=...) -> Any | Self | None: - ... - - def from_FF_gmpy(K1, a, K0=...) -> Any | Self: - ... - - def from_ZZ_gmpy(K1, a, K0=...) -> Any | Self: - ... - - def from_QQ_gmpy(K1, a, K0=...) -> Any | Self | None: - ... - - def from_RealField(K1, a, K0) -> Any | Self | None: - ... - - + def __init__(self, mod, symmetric=...) -> None: ... + def __str__(self) -> str: ... + def __hash__(self) -> int: ... + def __eq__(self, other) -> bool: ... + def characteristic(self) -> Any | None: ... + def get_field(self) -> Self: ... + def to_sympy(self, a) -> Integer: ... + def from_sympy(self, a) -> Any | Self: ... + def from_FF(K1, a, K0=...) -> Any | Self: ... + def from_FF_python(K1, a, K0=...) -> Any | Self: ... + def from_ZZ(K1, a, K0=...) -> Any | Self: ... + def from_ZZ_python(K1, a, K0=...) -> Any | Self: ... + def from_QQ(K1, a, K0=...) -> Any | Self | None: ... + def from_QQ_python(K1, a, K0=...) -> Any | Self | None: ... + def from_FF_gmpy(K1, a, K0=...) -> Any | Self: ... + def from_ZZ_gmpy(K1, a, K0=...) -> Any | Self: ... + def from_QQ_gmpy(K1, a, K0=...) -> Any | Self | None: ... + def from_RealField(K1, a, K0) -> Any | Self | None: ... GF = ... FF = ... diff --git a/stubs/sympy-stubs/polys/domains/fractionfield.pyi b/stubs/sympy-stubs/polys/domains/fractionfield.pyi index 9ebc6967..8bbdd79b 100644 --- a/stubs/sympy-stubs/polys/domains/fractionfield.pyi +++ b/stubs/sympy-stubs/polys/domains/fractionfield.pyi @@ -9,108 +9,40 @@ class FractionField(Field, CompositeDomain): is_Frac = ... has_assoc_Ring = ... has_assoc_Field = ... - def __init__(self, domain_or_field, symbols=..., order=...) -> None: - ... - - def new(self, element) -> FracElement: - ... - + def __init__(self, domain_or_field, symbols=..., order=...) -> None: ... + def new(self, element) -> FracElement: ... @property - def zero(self): - ... - + def zero(self): ... @property - def one(self): - ... - + def one(self): ... @property - def order(self): - ... - + def order(self): ... @property - def is_Exact(self): - ... - - def get_exact(self) -> Any: - ... - - def __str__(self) -> str: - ... - - def __hash__(self) -> int: - ... - - def __eq__(self, other) -> bool: - ... - - def to_sympy(self, a): - ... - - def from_sympy(self, a): - ... - - def from_ZZ(K1, a, K0): - ... - - def from_ZZ_python(K1, a, K0): - ... - - def from_QQ(K1, a, K0): - ... - - def from_QQ_python(K1, a, K0): - ... - - def from_ZZ_gmpy(K1, a, K0): - ... - - def from_QQ_gmpy(K1, a, K0): - ... - - def from_GaussianRationalField(K1, a, K0): - ... - - def from_GaussianIntegerRing(K1, a, K0): - ... - - def from_RealField(K1, a, K0): - ... - - def from_ComplexField(K1, a, K0): - ... - - def from_AlgebraicField(K1, a, K0) -> FracElement | None: - ... - - def from_PolynomialRing(K1, a, K0) -> FracElement | None: - ... - - def from_FractionField(K1, a, K0) -> None: - ... - - def get_ring(self) -> Any: - ... - - def is_positive(self, a): - ... - - def is_negative(self, a): - ... - - def is_nonpositive(self, a): - ... - - def is_nonnegative(self, a): - ... - - def numer(self, a): - ... - - def denom(self, a): - ... - - def factorial(self, a): - ... - - - + def is_Exact(self): ... + def get_exact(self) -> Any: ... + def __str__(self) -> str: ... + def __hash__(self) -> int: ... + def __eq__(self, other) -> bool: ... + def to_sympy(self, a): ... + def from_sympy(self, a): ... + def from_ZZ(K1, a, K0): ... + def from_ZZ_python(K1, a, K0): ... + def from_QQ(K1, a, K0): ... + def from_QQ_python(K1, a, K0): ... + def from_ZZ_gmpy(K1, a, K0): ... + def from_QQ_gmpy(K1, a, K0): ... + def from_GaussianRationalField(K1, a, K0): ... + def from_GaussianIntegerRing(K1, a, K0): ... + def from_RealField(K1, a, K0): ... + def from_ComplexField(K1, a, K0): ... + def from_AlgebraicField(K1, a, K0) -> FracElement | None: ... + def from_PolynomialRing(K1, a, K0) -> FracElement | None: ... + def from_FractionField(K1, a, K0) -> None: ... + def get_ring(self) -> Any: ... + def is_positive(self, a): ... + def is_negative(self, a): ... + def is_nonpositive(self, a): ... + def is_nonnegative(self, a): ... + def numer(self, a): ... + def denom(self, a): ... + def factorial(self, a): ... diff --git a/stubs/sympy-stubs/polys/domains/gaussiandomains.pyi b/stubs/sympy-stubs/polys/domains/gaussiandomains.pyi index d3721e27..34243a18 100644 --- a/stubs/sympy-stubs/polys/domains/gaussiandomains.pyi +++ b/stubs/sympy-stubs/polys/domains/gaussiandomains.pyi @@ -8,103 +8,48 @@ from sympy.polys.domains.integerring import ZZ from sympy.polys.domains.rationalfield import QQ from sympy.polys.domains.ring import Ring -class GaussianElement(DomainElement): # type: ignore +class GaussianElement(DomainElement): # type: ignore base: Domain _parent: Domain __slots__ = ... - def __new__(cls, x, y=...): - ... - + def __new__(cls, x, y=...): ... @classmethod - def new(cls, x, y): - ... - - def parent(self): - ... - - def __hash__(self) -> int: - ... - - def __eq__(self, other) -> bool: - ... - - def __lt__(self, other) -> bool: - ... - - def __pos__(self) -> Self: - ... - - def __neg__(self): - ... - - def __repr__(self) -> LiteralString: - ... - - def __str__(self) -> str: - ... - - def __add__(self, other) -> NotImplementedType: - ... - + def new(cls, x, y): ... + def parent(self): ... + def __hash__(self) -> int: ... + def __eq__(self, other) -> bool: ... + def __lt__(self, other) -> bool: ... + def __pos__(self) -> Self: ... + def __neg__(self): ... + def __repr__(self) -> LiteralString: ... + def __str__(self) -> str: ... + def __add__(self, other) -> NotImplementedType: ... + __radd__ = ... - def __sub__(self, other) -> NotImplementedType: - ... - - def __rsub__(self, other) -> NotImplementedType: - ... - - def __mul__(self, other) -> NotImplementedType: - ... - - __rmul__ = ... - def __pow__(self, exp) -> float | Self: - ... - - def __bool__(self) -> bool: - ... - - def quadrant(self) -> Literal[0, 1, 2, 3]: - ... - - def __rdivmod__(self, other) -> NotImplementedType: - ... - - def __rtruediv__(self, other) -> NotImplementedType: - ... - - def __floordiv__(self, other): - ... - - def __rfloordiv__(self, other) -> NotImplementedType: - ... - - def __mod__(self, other): - ... - - def __rmod__(self, other) -> NotImplementedType: - ... - + def __sub__(self, other) -> NotImplementedType: ... + def __rsub__(self, other) -> NotImplementedType: ... + def __mul__(self, other) -> NotImplementedType: ... + __rmul__ = ... + def __pow__(self, exp) -> float | Self: ... + def __bool__(self) -> bool: ... + def quadrant(self) -> Literal[0, 1, 2, 3]: ... + def __rdivmod__(self, other) -> NotImplementedType: ... + def __rtruediv__(self, other) -> NotImplementedType: ... + def __floordiv__(self, other): ... + def __rfloordiv__(self, other) -> NotImplementedType: ... + def __mod__(self, other): ... + def __rmod__(self, other) -> NotImplementedType: ... class GaussianInteger(GaussianElement): base = ... - def __truediv__(self, other): - ... - - def __divmod__(self, other) -> NotImplementedType | tuple[GaussianInteger, Any]: - ... - - + def __truediv__(self, other): ... + def __divmod__(self, other) -> NotImplementedType | tuple[GaussianInteger, Any]: ... class GaussianRational(GaussianElement): base = ... - def __truediv__(self, other) -> NotImplementedType | GaussianRational: - ... - - def __divmod__(self, other) -> NotImplementedType | tuple[Any, Any]: - ... - - + def __truediv__(self, other) -> NotImplementedType | GaussianRational: ... + def __divmod__(self, other) -> NotImplementedType | tuple[Any, Any]: ... class GaussianDomain: dom: Domain = ... @@ -112,52 +57,21 @@ class GaussianDomain: is_Exact = ... has_assoc_Ring = ... has_assoc_Field = ... - def to_sympy(self, a): - ... - - def from_sympy(self, a): - ... - - def inject(self, *gens): - ... - - def canonical_unit(self, d): - ... - - def is_negative(self, element) -> Literal[False]: - ... - - def is_positive(self, element) -> Literal[False]: - ... - - def is_nonnegative(self, element) -> Literal[False]: - ... - - def is_nonpositive(self, element) -> Literal[False]: - ... - - def from_ZZ_gmpy(K1, a, K0): - ... - - def from_ZZ(K1, a, K0): - ... - - def from_ZZ_python(K1, a, K0): - ... - - def from_QQ(K1, a, K0): - ... - - def from_QQ_gmpy(K1, a, K0): - ... - - def from_QQ_python(K1, a, K0): - ... - - def from_AlgebraicField(K1, a, K0) -> None: - ... - - + def to_sympy(self, a): ... + def from_sympy(self, a): ... + def inject(self, *gens): ... + def canonical_unit(self, d): ... + def is_negative(self, element) -> Literal[False]: ... + def is_positive(self, element) -> Literal[False]: ... + def is_nonnegative(self, element) -> Literal[False]: ... + def is_nonpositive(self, element) -> Literal[False]: ... + def from_ZZ_gmpy(K1, a, K0): ... + def from_ZZ(K1, a, K0): ... + def from_ZZ_python(K1, a, K0): ... + def from_QQ(K1, a, K0): ... + def from_QQ_gmpy(K1, a, K0): ... + def from_QQ_python(K1, a, K0): ... + def from_AlgebraicField(K1, a, K0) -> None: ... class GaussianIntegerRing(GaussianDomain, Ring): dom = ... @@ -169,31 +83,14 @@ class GaussianIntegerRing(GaussianDomain, Ring): rep = ... is_GaussianRing = ... is_ZZ_I = ... - def __init__(self) -> None: - ... - - def get_ring(self) -> Self: - ... - - def get_field(self) -> GaussianRationalField: - ... - - def normalize(self, d, *args) -> tuple[Any, *tuple[Any, ...]]: - ... - - def gcd(self, a, b) -> tuple[Any, *tuple[Any, ...]]: - ... - - def lcm(self, a, b): - ... - - def from_GaussianIntegerRing(K1, a, K0): - ... - - def from_GaussianRationalField(K1, a, K0): - ... - - + def __init__(self) -> None: ... + def get_ring(self) -> Self: ... + def get_field(self) -> GaussianRationalField: ... + def normalize(self, d, *args) -> tuple[Any, *tuple[Any, ...]]: ... + def gcd(self, a, b) -> tuple[Any, *tuple[Any, ...]]: ... + def lcm(self, a, b): ... + def from_GaussianIntegerRing(K1, a, K0): ... + def from_GaussianRationalField(K1, a, K0): ... class GaussianRationalField(GaussianDomain, Field): dom = ... @@ -205,31 +102,14 @@ class GaussianRationalField(GaussianDomain, Field): rep = ... is_GaussianField = ... is_QQ_I = ... - def __init__(self) -> None: - ... - - def get_ring(self) -> GaussianIntegerRing: - ... - - def get_field(self) -> Self: - ... - - def as_AlgebraicField(self) -> Any: - ... - - def numer(self, a): - ... - - def denom(self, a): - ... - - def from_GaussianIntegerRing(K1, a, K0): - ... - - def from_GaussianRationalField(K1, a, K0): - ... - - + def __init__(self) -> None: ... + def get_ring(self) -> GaussianIntegerRing: ... + def get_field(self) -> Self: ... + def as_AlgebraicField(self) -> Any: ... + def numer(self, a): ... + def denom(self, a): ... + def from_GaussianIntegerRing(K1, a, K0): ... + def from_GaussianRationalField(K1, a, K0): ... QQ_I = ... -ZZ_I = ... \ No newline at end of file +ZZ_I = ... diff --git a/stubs/sympy-stubs/polys/domains/gmpyintegerring.pyi b/stubs/sympy-stubs/polys/domains/gmpyintegerring.pyi index 9ab556e0..a198d34a 100644 --- a/stubs/sympy-stubs/polys/domains/gmpyintegerring.pyi +++ b/stubs/sympy-stubs/polys/domains/gmpyintegerring.pyi @@ -11,56 +11,20 @@ class GMPYIntegerRing(IntegerRing): one = dtype(1) tp = type(one) alias = ... - def __init__(self) -> None: - ... - - def to_sympy(self, a) -> Integer: - ... - - def from_sympy(self, a) -> _GMPYInteger: - ... - - def from_FF_python(K1, a, K0) -> _GMPYInteger: - ... - - def from_ZZ_python(K1, a, K0) -> _GMPYInteger: - ... - - def from_QQ(K1, a, K0) -> _GMPYInteger | None: - ... - - def from_QQ_python(K1, a, K0) -> _GMPYInteger | None: - ... - - def from_FF_gmpy(K1, a, K0): - ... - - def from_ZZ_gmpy(K1, a, K0): - ... - - def from_QQ_gmpy(K1, a, K0) -> None: - ... - - def from_RealField(K1, a, K0) -> _GMPYInteger | None: - ... - - def from_GaussianIntegerRing(K1, a, K0) -> None: - ... - - def gcdex(self, a, b) -> tuple[Any, Any, Any]: - ... - - def gcd(self, a, b): - ... - - def lcm(self, a, b): - ... - - def sqrt(self, a) -> int: - ... - - def factorial(self, a) -> int: - ... - - - + def __init__(self) -> None: ... + def to_sympy(self, a) -> Integer: ... + def from_sympy(self, a) -> _GMPYInteger: ... + def from_FF_python(K1, a, K0) -> _GMPYInteger: ... + def from_ZZ_python(K1, a, K0) -> _GMPYInteger: ... + def from_QQ(K1, a, K0) -> _GMPYInteger | None: ... + def from_QQ_python(K1, a, K0) -> _GMPYInteger | None: ... + def from_FF_gmpy(K1, a, K0): ... + def from_ZZ_gmpy(K1, a, K0): ... + def from_QQ_gmpy(K1, a, K0) -> None: ... + def from_RealField(K1, a, K0) -> _GMPYInteger | None: ... + def from_GaussianIntegerRing(K1, a, K0) -> None: ... + def gcdex(self, a, b) -> tuple[Any, Any, Any]: ... + def gcd(self, a, b): ... + def lcm(self, a, b): ... + def sqrt(self, a) -> int: ... + def factorial(self, a) -> int: ... diff --git a/stubs/sympy-stubs/polys/domains/gmpyrationalfield.pyi b/stubs/sympy-stubs/polys/domains/gmpyrationalfield.pyi index 2c38c694..a0ff0f71 100644 --- a/stubs/sympy-stubs/polys/domains/gmpyrationalfield.pyi +++ b/stubs/sympy-stubs/polys/domains/gmpyrationalfield.pyi @@ -11,56 +11,20 @@ class GMPYRationalField(RationalField): one = dtype(1) tp = type(one) alias = ... - def __init__(self) -> None: - ... - - def get_ring(self) -> Any: - ... - - def to_sympy(self, a) -> Rational: - ... - - def from_sympy(self, a) -> _GMPYRational: - ... - - def from_ZZ_python(K1, a, K0) -> _GMPYRational: - ... - - def from_QQ_python(K1, a, K0) -> _GMPYRational: - ... - - def from_ZZ_gmpy(K1, a, K0) -> _GMPYRational: - ... - - def from_QQ_gmpy(K1, a, K0): - ... - - def from_GaussianRationalField(K1, a, K0) -> _GMPYRational | None: - ... - - def from_RealField(K1, a, K0) -> _GMPYRational: - ... - - def exquo(self, a, b): - ... - - def quo(self, a, b): - ... - - def rem(self, a, b) -> dtype: - ... - - def div(self, a, b) -> tuple[Any, dtype]: - ... - - def numer(self, a): - ... - - def denom(self, a): - ... - - def factorial(self, a) -> _GMPYRational: - ... - - - + def __init__(self) -> None: ... + def get_ring(self) -> Any: ... + def to_sympy(self, a) -> Rational: ... + def from_sympy(self, a) -> _GMPYRational: ... + def from_ZZ_python(K1, a, K0) -> _GMPYRational: ... + def from_QQ_python(K1, a, K0) -> _GMPYRational: ... + def from_ZZ_gmpy(K1, a, K0) -> _GMPYRational: ... + def from_QQ_gmpy(K1, a, K0): ... + def from_GaussianRationalField(K1, a, K0) -> _GMPYRational | None: ... + def from_RealField(K1, a, K0) -> _GMPYRational: ... + def exquo(self, a, b): ... + def quo(self, a, b): ... + def rem(self, a, b) -> dtype: ... + def div(self, a, b) -> tuple[Any, dtype]: ... + def numer(self, a): ... + def denom(self, a): ... + def factorial(self, a) -> _GMPYRational: ... diff --git a/stubs/sympy-stubs/polys/domains/integerring.pyi b/stubs/sympy-stubs/polys/domains/integerring.pyi index 31a0e968..71d891f7 100644 --- a/stubs/sympy-stubs/polys/domains/integerring.pyi +++ b/stubs/sympy-stubs/polys/domains/integerring.pyi @@ -7,7 +7,7 @@ from sympy.polys.domains.ring import Ring from sympy.polys.domains.simpledomain import SimpleDomain from sympy.utilities import public -class IntegerRing(Ring, CharacteristicZero, SimpleDomain): # type: ignore +class IntegerRing(Ring, CharacteristicZero, SimpleDomain): # type: ignore rep = ... alias = ... dtype = MPZ @@ -19,75 +19,33 @@ class IntegerRing(Ring, CharacteristicZero, SimpleDomain): # type: ignore is_PID = ... has_assoc_Ring = ... has_assoc_Field = ... - def __init__(self) -> None: - ... - - def to_sympy(self, a) -> Integer: - ... - - def from_sympy(self, a) -> int: - ... - - def get_field(self) -> Any: - ... - - def algebraic_field(self, *extension, alias=...) -> Any: - ... - - def from_AlgebraicField(K1, a, K0) -> None: - ... - - def log(self, a, b) -> dtype: - ... - - def from_FF(K1, a, K0) -> int: - ... - - def from_FF_python(K1, a, K0) -> int: - ... - - def from_ZZ(K1, a, K0) -> int: - ... - - def from_ZZ_python(K1, a, K0) -> int: - ... - - def from_QQ(K1, a, K0) -> int | None: - ... - - def from_QQ_python(K1, a, K0) -> int | None: - ... - - def from_FF_gmpy(K1, a, K0): - ... - - def from_ZZ_gmpy(K1, a, K0): - ... - - def from_QQ_gmpy(K1, a, K0) -> None: - ... - - def from_RealField(K1, a, K0) -> int | None: - ... - - def from_GaussianIntegerRing(K1, a, K0) -> None: - ... - - def gcdex(self, a, b) -> tuple[Any | Literal[1, 0, -1], Any | Literal[0], Any | Literal[0, -1, 1]] | tuple[Any | Literal[0, -1, 1], Any | Literal[1, 0, -1], Any | Literal[0]]: - ... - - def gcd(self, a, b) -> int: - ... - - def lcm(self, a, b) -> Literal[0]: - ... - - def sqrt(self, a) -> int: - ... - - def factorial(self, a) -> int: - ... - - + def __init__(self) -> None: ... + def to_sympy(self, a) -> Integer: ... + def from_sympy(self, a) -> int: ... + def get_field(self) -> Any: ... + def algebraic_field(self, *extension, alias=...) -> Any: ... + def from_AlgebraicField(K1, a, K0) -> None: ... + def log(self, a, b) -> dtype: ... + def from_FF(K1, a, K0) -> int: ... + def from_FF_python(K1, a, K0) -> int: ... + def from_ZZ(K1, a, K0) -> int: ... + def from_ZZ_python(K1, a, K0) -> int: ... + def from_QQ(K1, a, K0) -> int | None: ... + def from_QQ_python(K1, a, K0) -> int | None: ... + def from_FF_gmpy(K1, a, K0): ... + def from_ZZ_gmpy(K1, a, K0): ... + def from_QQ_gmpy(K1, a, K0) -> None: ... + def from_RealField(K1, a, K0) -> int | None: ... + def from_GaussianIntegerRing(K1, a, K0) -> None: ... + def gcdex( + self, a, b + ) -> ( + tuple[Any | Literal[1, 0, -1], Any | Literal[0], Any | Literal[0, -1, 1]] + | tuple[Any | Literal[0, -1, 1], Any | Literal[1, 0, -1], Any | Literal[0]] + ): ... + def gcd(self, a, b) -> int: ... + def lcm(self, a, b) -> Literal[0]: ... + def sqrt(self, a) -> int: ... + def factorial(self, a) -> int: ... ZZ = ... diff --git a/stubs/sympy-stubs/polys/domains/modularinteger.pyi b/stubs/sympy-stubs/polys/domains/modularinteger.pyi index b0ccb287..c340d49f 100644 --- a/stubs/sympy-stubs/polys/domains/modularinteger.pyi +++ b/stubs/sympy-stubs/polys/domains/modularinteger.pyi @@ -8,93 +8,35 @@ from sympy.utilities import public @public class ModularInteger(PicklableWithSlots, DomainElement): __slots__ = ... - def parent(self) -> None: - ... - - def __init__(self, val) -> None: - ... - - def __hash__(self) -> int: - ... - - def __repr__(self) -> LiteralString: - ... - - def __str__(self) -> str: - ... - - def __int__(self) -> int: - ... - - def to_int(self): - ... - - def __pos__(self) -> Self: - ... - - def __neg__(self) -> Self: - ... - - def __add__(self, other) -> Self | NotImplementedType: - ... - - def __radd__(self, other) -> Self | NotImplementedType: - ... - - def __sub__(self, other) -> Self | NotImplementedType: - ... - - def __rsub__(self, other) -> Self | NotImplementedType: - ... - - def __mul__(self, other) -> Self | NotImplementedType: - ... - - def __rmul__(self, other) -> Self | NotImplementedType: - ... - - def __truediv__(self, other) -> Self | NotImplementedType: - ... - - def __rtruediv__(self, other) -> Self | NotImplementedType: - ... - - def __mod__(self, other) -> Self | NotImplementedType: - ... - - def __rmod__(self, other) -> Self | NotImplementedType: - ... - - def __pow__(self, exp) -> Self: - ... - - def __eq__(self, other) -> bool: - ... - - def __ne__(self, other) -> bool: - ... - - def __lt__(self, other) -> bool: - ... - - def __le__(self, other) -> bool: - ... - - def __gt__(self, other) -> bool: - ... - - def __ge__(self, other) -> bool: - ... - - def __bool__(self) -> bool: - ... - - def invert(self) -> Self: - ... - - + def parent(self) -> None: ... + def __init__(self, val) -> None: ... + def __hash__(self) -> int: ... + def __repr__(self) -> LiteralString: ... + def __str__(self) -> str: ... + def __int__(self) -> int: ... + def to_int(self): ... + def __pos__(self) -> Self: ... + def __neg__(self) -> Self: ... + def __add__(self, other) -> Self | NotImplementedType: ... + def __radd__(self, other) -> Self | NotImplementedType: ... + def __sub__(self, other) -> Self | NotImplementedType: ... + def __rsub__(self, other) -> Self | NotImplementedType: ... + def __mul__(self, other) -> Self | NotImplementedType: ... + def __rmul__(self, other) -> Self | NotImplementedType: ... + def __truediv__(self, other) -> Self | NotImplementedType: ... + def __rtruediv__(self, other) -> Self | NotImplementedType: ... + def __mod__(self, other) -> Self | NotImplementedType: ... + def __rmod__(self, other) -> Self | NotImplementedType: ... + def __pow__(self, exp) -> Self: ... + def __eq__(self, other) -> bool: ... + def __ne__(self, other) -> bool: ... + def __lt__(self, other) -> bool: ... + def __le__(self, other) -> bool: ... + def __gt__(self, other) -> bool: ... + def __ge__(self, other) -> bool: ... + def __bool__(self) -> bool: ... + def invert(self) -> Self: ... _modular_integer_cache: dict[tuple[Any, Any, Any], type[ModularInteger]] = ... -def ModularIntegerFactory(_mod, _dom, _sym, parent) -> type[Any]: - ... +def ModularIntegerFactory(_mod, _dom, _sym, parent) -> type[Any]: ... diff --git a/stubs/sympy-stubs/polys/domains/mpelements.pyi b/stubs/sympy-stubs/polys/domains/mpelements.pyi index 1d4c2d1c..aeb40b34 100644 --- a/stubs/sympy-stubs/polys/domains/mpelements.pyi +++ b/stubs/sympy-stubs/polys/domains/mpelements.pyi @@ -8,34 +8,19 @@ from sympy.utilities import public class RealElement(_mpf, DomainElement): __slots__ = ... _mpf_ = ... - def parent(self): - ... - - + def parent(self): ... @public class ComplexElement(_mpc, DomainElement): __slots__ = ... _mpc_ = ... - def parent(self): - ... - - + def parent(self): ... new = ... + @public class MPContext(PythonMPContext): - def __init__(ctx, prec=..., dps=..., tol=..., real=...) -> None: - ... - - def make_tol(ctx) -> _mpf: - ... - - def to_rational(ctx, s, limit=...) -> tuple[Any, Any | Literal[1]]: - ... - - def almosteq(ctx, s, t, rel_eps=..., abs_eps=...) -> Literal[True]: - ... - - - + def __init__(ctx, prec=..., dps=..., tol=..., real=...) -> None: ... + def make_tol(ctx) -> _mpf: ... + def to_rational(ctx, s, limit=...) -> tuple[Any, Any | Literal[1]]: ... + def almosteq(ctx, s, t, rel_eps=..., abs_eps=...) -> Literal[True]: ... diff --git a/stubs/sympy-stubs/polys/domains/old_fractionfield.pyi b/stubs/sympy-stubs/polys/domains/old_fractionfield.pyi index 69fa6d3c..981e9682 100644 --- a/stubs/sympy-stubs/polys/domains/old_fractionfield.pyi +++ b/stubs/sympy-stubs/polys/domains/old_fractionfield.pyi @@ -11,80 +11,28 @@ class FractionField(Field, CharacteristicZero, CompositeDomain): is_Frac = ... has_assoc_Ring = ... has_assoc_Field = ... - def __init__(self, dom, *gens) -> None: - ... - - def new(self, element) -> dtype: - ... - - def __str__(self) -> str: - ... - - def __hash__(self) -> int: - ... - - def __eq__(self, other) -> bool: - ... - - def to_sympy(self, a): - ... - - def from_sympy(self, a): - ... - - def from_ZZ(K1, a, K0): - ... - - def from_ZZ_python(K1, a, K0): - ... - - def from_QQ_python(K1, a, K0): - ... - - def from_ZZ_gmpy(K1, a, K0): - ... - - def from_QQ_gmpy(K1, a, K0): - ... - - def from_RealField(K1, a, K0): - ... - - def from_GlobalPolynomialRing(K1, a, K0): - ... - - def from_FractionField(K1, a, K0) -> None: - ... - - def get_ring(self) -> Any: - ... - - def poly_ring(self, *gens): - ... - - def frac_field(self, *gens): - ... - - def is_positive(self, a): - ... - - def is_negative(self, a): - ... - - def is_nonpositive(self, a): - ... - - def is_nonnegative(self, a): - ... - - def numer(self, a): - ... - - def denom(self, a): - ... - - def factorial(self, a) -> dtype: - ... - - - + def __init__(self, dom, *gens) -> None: ... + def new(self, element) -> dtype: ... + def __str__(self) -> str: ... + def __hash__(self) -> int: ... + def __eq__(self, other) -> bool: ... + def to_sympy(self, a): ... + def from_sympy(self, a): ... + def from_ZZ(K1, a, K0): ... + def from_ZZ_python(K1, a, K0): ... + def from_QQ_python(K1, a, K0): ... + def from_ZZ_gmpy(K1, a, K0): ... + def from_QQ_gmpy(K1, a, K0): ... + def from_RealField(K1, a, K0): ... + def from_GlobalPolynomialRing(K1, a, K0): ... + def from_FractionField(K1, a, K0) -> None: ... + def get_ring(self) -> Any: ... + def poly_ring(self, *gens): ... + def frac_field(self, *gens): ... + def is_positive(self, a): ... + def is_negative(self, a): ... + def is_nonpositive(self, a): ... + def is_nonnegative(self, a): ... + def numer(self, a): ... + def denom(self, a): ... + def factorial(self, a) -> dtype: ... diff --git a/stubs/sympy-stubs/polys/domains/old_polynomialring.pyi b/stubs/sympy-stubs/polys/domains/old_polynomialring.pyi index 3a330902..c30136f4 100644 --- a/stubs/sympy-stubs/polys/domains/old_polynomialring.pyi +++ b/stubs/sympy-stubs/polys/domains/old_polynomialring.pyi @@ -12,127 +12,50 @@ class PolynomialRingBase(Ring, CharacteristicZero, CompositeDomain): has_assoc_Ring = ... has_assoc_Field = ... default_order = ... - def __init__(self, dom, *gens, **opts) -> None: - ... - - def new(self, element): - ... - - def __str__(self) -> str: - ... - - def __hash__(self) -> int: - ... - - def __eq__(self, other) -> bool: - ... - - def from_ZZ(K1, a, K0): - ... - - def from_ZZ_python(K1, a, K0): - ... - - def from_QQ(K1, a, K0): - ... - - def from_QQ_python(K1, a, K0): - ... - - def from_ZZ_gmpy(K1, a, K0): - ... - - def from_QQ_gmpy(K1, a, K0): - ... - - def from_RealField(K1, a, K0): - ... - - def from_AlgebraicField(K1, a, K0) -> None: - ... - - def from_PolynomialRing(K1, a, K0): - ... - - def from_GlobalPolynomialRing(K1, a, K0): - ... - - def get_field(self) -> Any: - ... - - def poly_ring(self, *gens): - ... - - def frac_field(self, *gens): - ... - - def revert(self, a): - ... - - def gcdex(self, a, b): - ... - - def gcd(self, a, b): - ... - - def lcm(self, a, b): - ... - - def factorial(self, a): - ... - - def free_module(self, rank) -> FreeModulePolyRing: - ... - - + def __init__(self, dom, *gens, **opts) -> None: ... + def new(self, element): ... + def __str__(self) -> str: ... + def __hash__(self) -> int: ... + def __eq__(self, other) -> bool: ... + def from_ZZ(K1, a, K0): ... + def from_ZZ_python(K1, a, K0): ... + def from_QQ(K1, a, K0): ... + def from_QQ_python(K1, a, K0): ... + def from_ZZ_gmpy(K1, a, K0): ... + def from_QQ_gmpy(K1, a, K0): ... + def from_RealField(K1, a, K0): ... + def from_AlgebraicField(K1, a, K0) -> None: ... + def from_PolynomialRing(K1, a, K0): ... + def from_GlobalPolynomialRing(K1, a, K0): ... + def get_field(self) -> Any: ... + def poly_ring(self, *gens): ... + def frac_field(self, *gens): ... + def revert(self, a): ... + def gcdex(self, a, b): ... + def gcd(self, a, b): ... + def lcm(self, a, b): ... + def factorial(self, a): ... + def free_module(self, rank) -> FreeModulePolyRing: ... @public class GlobalPolynomialRing(PolynomialRingBase): is_Poly = ... dtype = DMP - def from_FractionField(K1, a, K0) -> None: - ... - - def to_sympy(self, a) -> Order: - ... - - def from_sympy(self, a): - ... - - def is_positive(self, a): - ... - - def is_negative(self, a): - ... - - def is_nonpositive(self, a): - ... - - def is_nonnegative(self, a): - ... - - + def from_FractionField(K1, a, K0) -> None: ... + def to_sympy(self, a) -> Order: ... + def from_sympy(self, a): ... + def is_positive(self, a): ... + def is_negative(self, a): ... + def is_nonpositive(self, a): ... + def is_nonnegative(self, a): ... class GeneralizedPolynomialRing(PolynomialRingBase): dtype = DMF - def new(self, a) -> dtype: - ... - - def __contains__(self, a) -> Literal[False]: - ... - - def from_FractionField(K1, a, K0): - ... - - def to_sympy(self, a): - ... - - def from_sympy(self, a): - ... - - + def new(self, a) -> dtype: ... + def __contains__(self, a) -> Literal[False]: ... + def from_FractionField(K1, a, K0): ... + def to_sympy(self, a): ... + def from_sympy(self, a): ... @public -def PolynomialRing(dom, *gens, **opts) -> Any | GeneralizedPolynomialRing: - ... - +def PolynomialRing(dom, *gens, **opts) -> Any | GeneralizedPolynomialRing: ... diff --git a/stubs/sympy-stubs/polys/domains/polynomialring.pyi b/stubs/sympy-stubs/polys/domains/polynomialring.pyi index 722c9563..a859eb2f 100644 --- a/stubs/sympy-stubs/polys/domains/polynomialring.pyi +++ b/stubs/sympy-stubs/polys/domains/polynomialring.pyi @@ -9,113 +9,41 @@ class PolynomialRing(Ring, CompositeDomain): is_Poly = ... has_assoc_Ring = ... has_assoc_Field = ... - def __init__(self, domain_or_ring, symbols=..., order=...) -> None: - ... - - def new(self, element) -> PolyElement: - ... - + def __init__(self, domain_or_ring, symbols=..., order=...) -> None: ... + def new(self, element) -> PolyElement: ... @property - def zero(self): - ... - + def zero(self): ... @property - def one(self): - ... - + def one(self): ... @property - def order(self): - ... - - def __str__(self) -> str: - ... - - def __hash__(self) -> int: - ... - - def __eq__(self, other) -> bool: - ... - - def is_unit(self, a) -> Literal[False]: - ... - - def canonical_unit(self, a): - ... - - def to_sympy(self, a): - ... - - def from_sympy(self, a): - ... - - def from_ZZ(K1, a, K0): - ... - - def from_ZZ_python(K1, a, K0): - ... - - def from_QQ(K1, a, K0): - ... - - def from_QQ_python(K1, a, K0): - ... - - def from_ZZ_gmpy(K1, a, K0): - ... - - def from_QQ_gmpy(K1, a, K0): - ... - - def from_GaussianIntegerRing(K1, a, K0): - ... - - def from_GaussianRationalField(K1, a, K0): - ... - - def from_RealField(K1, a, K0): - ... - - def from_ComplexField(K1, a, K0): - ... - - def from_AlgebraicField(K1, a, K0) -> PolyElement | None: - ... - - def from_PolynomialRing(K1, a, K0) -> None: - ... - - def from_FractionField(K1, a, K0) -> None: - ... - - def from_GlobalPolynomialRing(K1, a, K0) -> None: - ... - - def get_field(self) -> Any: - ... - - def is_positive(self, a): - ... - - def is_negative(self, a): - ... - - def is_nonpositive(self, a): - ... - - def is_nonnegative(self, a): - ... - - def gcdex(self, a, b): - ... - - def gcd(self, a, b): - ... - - def lcm(self, a, b): - ... - - def factorial(self, a): - ... - - - + def order(self): ... + def __str__(self) -> str: ... + def __hash__(self) -> int: ... + def __eq__(self, other) -> bool: ... + def is_unit(self, a) -> Literal[False]: ... + def canonical_unit(self, a): ... + def to_sympy(self, a): ... + def from_sympy(self, a): ... + def from_ZZ(K1, a, K0): ... + def from_ZZ_python(K1, a, K0): ... + def from_QQ(K1, a, K0): ... + def from_QQ_python(K1, a, K0): ... + def from_ZZ_gmpy(K1, a, K0): ... + def from_QQ_gmpy(K1, a, K0): ... + def from_GaussianIntegerRing(K1, a, K0): ... + def from_GaussianRationalField(K1, a, K0): ... + def from_RealField(K1, a, K0): ... + def from_ComplexField(K1, a, K0): ... + def from_AlgebraicField(K1, a, K0) -> PolyElement | None: ... + def from_PolynomialRing(K1, a, K0) -> None: ... + def from_FractionField(K1, a, K0) -> None: ... + def from_GlobalPolynomialRing(K1, a, K0) -> None: ... + def get_field(self) -> Any: ... + def is_positive(self, a): ... + def is_negative(self, a): ... + def is_nonpositive(self, a): ... + def is_nonnegative(self, a): ... + def gcdex(self, a, b): ... + def gcd(self, a, b): ... + def lcm(self, a, b): ... + def factorial(self, a): ... diff --git a/stubs/sympy-stubs/polys/domains/pythonintegerring.pyi b/stubs/sympy-stubs/polys/domains/pythonintegerring.pyi index c0e34dc4..4af331ed 100644 --- a/stubs/sympy-stubs/polys/domains/pythonintegerring.pyi +++ b/stubs/sympy-stubs/polys/domains/pythonintegerring.pyi @@ -10,53 +10,26 @@ class PythonIntegerRing(IntegerRing): zero = dtype(0) one = dtype(1) alias = ... - def __init__(self) -> None: - ... - - def to_sympy(self, a) -> Integer: - ... - - def from_sympy(self, a) -> PythonInteger: - ... - - def from_FF_python(K1, a, K0): - ... - - def from_ZZ_python(K1, a, K0): - ... - - def from_QQ(K1, a, K0) -> None: - ... - - def from_QQ_python(K1, a, K0) -> None: - ... - - def from_FF_gmpy(K1, a, K0) -> PythonInteger: - ... - - def from_ZZ_gmpy(K1, a, K0) -> PythonInteger: - ... - - def from_QQ_gmpy(K1, a, K0) -> PythonInteger | None: - ... - - def from_RealField(K1, a, K0) -> PythonInteger | None: - ... - - def gcdex(self, a, b) -> tuple[Literal[0], Literal[1], Literal[0]] | tuple[Literal[0], Any, Any] | tuple[Any, Literal[0], Any] | tuple[Literal[-1, 1, 0], Literal[0, -1, 1], Any]: - ... - - def gcd(self, a, b) -> int: - ... - - def lcm(self, a, b) -> Literal[0]: - ... - - def sqrt(self, a) -> int: - ... - - def factorial(self, a) -> int: - ... - - - + def __init__(self) -> None: ... + def to_sympy(self, a) -> Integer: ... + def from_sympy(self, a) -> PythonInteger: ... + def from_FF_python(K1, a, K0): ... + def from_ZZ_python(K1, a, K0): ... + def from_QQ(K1, a, K0) -> None: ... + def from_QQ_python(K1, a, K0) -> None: ... + def from_FF_gmpy(K1, a, K0) -> PythonInteger: ... + def from_ZZ_gmpy(K1, a, K0) -> PythonInteger: ... + def from_QQ_gmpy(K1, a, K0) -> PythonInteger | None: ... + def from_RealField(K1, a, K0) -> PythonInteger | None: ... + def gcdex( + self, a, b + ) -> ( + tuple[Literal[0], Literal[1], Literal[0]] + | tuple[Literal[0], Any, Any] + | tuple[Any, Literal[0], Any] + | tuple[Literal[-1, 1, 0], Literal[0, -1, 1], Any] + ): ... + def gcd(self, a, b) -> int: ... + def lcm(self, a, b) -> Literal[0]: ... + def sqrt(self, a) -> int: ... + def factorial(self, a) -> int: ... diff --git a/stubs/sympy-stubs/polys/domains/pythonrational.pyi b/stubs/sympy-stubs/polys/domains/pythonrational.pyi index 5086e582..582bccb9 100644 --- a/stubs/sympy-stubs/polys/domains/pythonrational.pyi +++ b/stubs/sympy-stubs/polys/domains/pythonrational.pyi @@ -1,6 +1,5 @@ from sympy.core.numbers import Integer, Rational PythonRational = ... -def sympify_pythonrational(arg) -> Rational | Integer: - ... +def sympify_pythonrational(arg) -> Rational | Integer: ... diff --git a/stubs/sympy-stubs/polys/domains/pythonrationalfield.pyi b/stubs/sympy-stubs/polys/domains/pythonrationalfield.pyi index 9de41bd0..15944367 100644 --- a/stubs/sympy-stubs/polys/domains/pythonrationalfield.pyi +++ b/stubs/sympy-stubs/polys/domains/pythonrationalfield.pyi @@ -9,38 +9,14 @@ class PythonRationalField(RationalField): zero = ... one = ... alias = ... - def __init__(self) -> None: - ... - - def get_ring(self) -> Any: - ... - - def to_sympy(self, a) -> Rational | Integer: - ... - - def from_sympy(self, a) -> Any: - ... - - def from_ZZ_python(K1, a, K0) -> Any: - ... - - def from_QQ_python(K1, a, K0): - ... - - def from_ZZ_gmpy(K1, a, K0) -> Any: - ... - - def from_QQ_gmpy(K1, a, K0) -> Any: - ... - - def from_RealField(K1, a, K0) -> Any: - ... - - def numer(self, a): - ... - - def denom(self, a): - ... - - - + def __init__(self) -> None: ... + def get_ring(self) -> Any: ... + def to_sympy(self, a) -> Rational | Integer: ... + def from_sympy(self, a) -> Any: ... + def from_ZZ_python(K1, a, K0) -> Any: ... + def from_QQ_python(K1, a, K0): ... + def from_ZZ_gmpy(K1, a, K0) -> Any: ... + def from_QQ_gmpy(K1, a, K0) -> Any: ... + def from_RealField(K1, a, K0) -> Any: ... + def numer(self, a): ... + def denom(self, a): ... diff --git a/stubs/sympy-stubs/polys/domains/quotientring.pyi b/stubs/sympy-stubs/polys/domains/quotientring.pyi index 2c7db3c8..42113c6c 100644 --- a/stubs/sympy-stubs/polys/domains/quotientring.pyi +++ b/stubs/sympy-stubs/polys/domains/quotientring.pyi @@ -6,72 +6,37 @@ from sympy.polys.domains.ring import Ring from sympy.utilities import public class QuotientRingElement: - def __init__(self, ring, data) -> None: - ... - - def __str__(self) -> str: - ... - + def __init__(self, ring, data) -> None: ... + def __str__(self) -> str: ... + __repr__ = ... - def __bool__(self) -> bool: - ... - - def __add__(self, om) -> NotImplementedType: - ... - + def __bool__(self) -> bool: ... + def __add__(self, om) -> NotImplementedType: ... + __radd__ = ... - def __neg__(self): - ... - - def __sub__(self, om) -> NotImplementedType: - ... - - def __rsub__(self, om): - ... - - def __mul__(self, o) -> NotImplementedType: - ... - - __rmul__ = ... - def __rtruediv__(self, o): - ... - - def __truediv__(self, o) -> NotImplementedType: - ... - - def __pow__(self, oth): - ... - - def __eq__(self, om) -> bool: - ... - - def __ne__(self, om) -> bool: - ... - + def __neg__(self): ... + def __sub__(self, om) -> NotImplementedType: ... + def __rsub__(self, om): ... + def __mul__(self, o) -> NotImplementedType: ... + __rmul__ = ... + def __rtruediv__(self, o): ... + def __truediv__(self, o) -> NotImplementedType: ... + def __pow__(self, oth): ... + def __eq__(self, om) -> bool: ... + def __ne__(self, om) -> bool: ... class QuotientRing(Ring): has_assoc_Ring = ... has_assoc_Field = ... dtype = ... - def __init__(self, ring, ideal) -> None: - ... - - def __str__(self) -> str: - ... - - def __hash__(self) -> int: - ... - - def new(self, a) -> Any: - ... - - def __eq__(self, other) -> bool: - ... - - def from_ZZ(K1, a, K0): - ... - + def __init__(self, ring, ideal) -> None: ... + def __str__(self) -> str: ... + def __hash__(self) -> int: ... + def new(self, a) -> Any: ... + def __eq__(self, other) -> bool: ... + def from_ZZ(K1, a, K0): ... + from_ZZ_python = ... from_QQ_python = ... from_ZZ_gmpy = ... @@ -79,29 +44,11 @@ class QuotientRing(Ring): from_RealField = ... from_GlobalPolynomialRing = ... from_FractionField = ... - def from_sympy(self, a): - ... - - def to_sympy(self, a): - ... - - def from_QuotientRing(self, a, K0) -> None: - ... - - def poly_ring(self, *gens): - ... - - def frac_field(self, *gens): - ... - - def revert(self, a): - ... - - def is_zero(self, a): - ... - - def free_module(self, rank) -> FreeModuleQuotientRing: - ... - - - + def from_sympy(self, a): ... + def to_sympy(self, a): ... + def from_QuotientRing(self, a, K0) -> None: ... + def poly_ring(self, *gens): ... + def frac_field(self, *gens): ... + def revert(self, a): ... + def is_zero(self, a): ... + def free_module(self, rank) -> FreeModuleQuotientRing: ... diff --git a/stubs/sympy-stubs/polys/domains/rationalfield.pyi b/stubs/sympy-stubs/polys/domains/rationalfield.pyi index 12adb632..07946787 100644 --- a/stubs/sympy-stubs/polys/domains/rationalfield.pyi +++ b/stubs/sympy-stubs/polys/domains/rationalfield.pyi @@ -20,66 +20,25 @@ class RationalField(Field, CharacteristicZero, SimpleDomain): zero = dtype(0) one = dtype(1) tp = type(one) - def __init__(self) -> None: - ... - - def get_ring(self) -> Any: - ... - - def to_sympy(self, a) -> Rational | Integer: - ... - - def from_sympy(self, a) -> PythonMPQ: - ... - - def algebraic_field(self, *extension, alias=...) -> Any: - ... - - def from_AlgebraicField(K1, a, K0) -> None: - ... - - def from_ZZ(K1, a, K0) -> PythonMPQ: - ... - - def from_ZZ_python(K1, a, K0) -> PythonMPQ: - ... - - def from_QQ(K1, a, K0) -> PythonMPQ: - ... - - def from_QQ_python(K1, a, K0) -> PythonMPQ: - ... - - def from_ZZ_gmpy(K1, a, K0) -> PythonMPQ: - ... - - def from_QQ_gmpy(K1, a, K0): - ... - - def from_GaussianRationalField(K1, a, K0) -> PythonMPQ | None: - ... - - def from_RealField(K1, a, K0) -> PythonMPQ: - ... - - def exquo(self, a, b) -> NotImplementedType | Self: - ... - - def quo(self, a, b) -> NotImplementedType | Self: - ... - - def rem(self, a, b) -> dtype: - ... - - def div(self, a, b) -> tuple[NotImplementedType | Self, dtype]: - ... - - def numer(self, a): - ... - - def denom(self, a): - ... - - + def __init__(self) -> None: ... + def get_ring(self) -> Any: ... + def to_sympy(self, a) -> Rational | Integer: ... + def from_sympy(self, a) -> PythonMPQ: ... + def algebraic_field(self, *extension, alias=...) -> Any: ... + def from_AlgebraicField(K1, a, K0) -> None: ... + def from_ZZ(K1, a, K0) -> PythonMPQ: ... + def from_ZZ_python(K1, a, K0) -> PythonMPQ: ... + def from_QQ(K1, a, K0) -> PythonMPQ: ... + def from_QQ_python(K1, a, K0) -> PythonMPQ: ... + def from_ZZ_gmpy(K1, a, K0) -> PythonMPQ: ... + def from_QQ_gmpy(K1, a, K0): ... + def from_GaussianRationalField(K1, a, K0) -> PythonMPQ | None: ... + def from_RealField(K1, a, K0) -> PythonMPQ: ... + def exquo(self, a, b) -> NotImplementedType | Self: ... + def quo(self, a, b) -> NotImplementedType | Self: ... + def rem(self, a, b) -> dtype: ... + def div(self, a, b) -> tuple[NotImplementedType | Self, dtype]: ... + def numer(self, a): ... + def denom(self, a): ... QQ = ... diff --git a/stubs/sympy-stubs/polys/domains/realfield.pyi b/stubs/sympy-stubs/polys/domains/realfield.pyi index b35bd681..634e30bc 100644 --- a/stubs/sympy-stubs/polys/domains/realfield.pyi +++ b/stubs/sympy-stubs/polys/domains/realfield.pyi @@ -16,81 +16,32 @@ class RealField(Field, CharacteristicZero, SimpleDomain): has_assoc_Field = ... _default_precision = ... @property - def has_default_precision(self) -> Any: - ... - + def has_default_precision(self) -> Any: ... @property - def precision(self) -> Any: - ... - + def precision(self) -> Any: ... @property - def dps(self) -> Any: - ... - + def dps(self) -> Any: ... @property - def tolerance(self) -> Any: - ... - - def __init__(self, prec=..., dps=..., tol=...) -> None: - ... - - def __eq__(self, other) -> bool: - ... - - def __hash__(self) -> int: - ... - - def to_sympy(self, element) -> Float: - ... - - def from_sympy(self, expr) -> Any: - ... - - def from_ZZ(self, element, base) -> Any: - ... - - def from_ZZ_python(self, element, base) -> Any: - ... - - def from_QQ(self, element, base): - ... - - def from_QQ_python(self, element, base): - ... - - def from_ZZ_gmpy(self, element, base) -> Any: - ... - - def from_QQ_gmpy(self, element, base) -> Any: - ... - - def from_AlgebraicField(self, element, base) -> Any: - ... - - def from_RealField(self, element, base) -> Any: - ... - - def from_ComplexField(self, element, base) -> Any | None: - ... - - def to_rational(self, element, limit=...) -> Any: - ... - - def get_ring(self) -> Self: - ... - - def get_exact(self) -> Any: - ... - - def gcd(self, a, b) -> Any: - ... - - def lcm(self, a, b): - ... - - def almosteq(self, a, b, tolerance=...) -> Any: - ... - - + def tolerance(self) -> Any: ... + def __init__(self, prec=..., dps=..., tol=...) -> None: ... + def __eq__(self, other) -> bool: ... + def __hash__(self) -> int: ... + def to_sympy(self, element) -> Float: ... + def from_sympy(self, expr) -> Any: ... + def from_ZZ(self, element, base) -> Any: ... + def from_ZZ_python(self, element, base) -> Any: ... + def from_QQ(self, element, base): ... + def from_QQ_python(self, element, base): ... + def from_ZZ_gmpy(self, element, base) -> Any: ... + def from_QQ_gmpy(self, element, base) -> Any: ... + def from_AlgebraicField(self, element, base) -> Any: ... + def from_RealField(self, element, base) -> Any: ... + def from_ComplexField(self, element, base) -> Any | None: ... + def to_rational(self, element, limit=...) -> Any: ... + def get_ring(self) -> Self: ... + def get_exact(self) -> Any: ... + def gcd(self, a, b) -> Any: ... + def lcm(self, a, b): ... + def almosteq(self, a, b, tolerance=...) -> Any: ... RR = ... diff --git a/stubs/sympy-stubs/polys/domains/ring.pyi b/stubs/sympy-stubs/polys/domains/ring.pyi index 402f00e1..287b5d07 100644 --- a/stubs/sympy-stubs/polys/domains/ring.pyi +++ b/stubs/sympy-stubs/polys/domains/ring.pyi @@ -7,47 +7,17 @@ from sympy.utilities import public class Ring(Domain): is_Ring = ... - def get_ring(self) -> Self: - ... - - def exquo(self, a, b): - ... - - def quo(self, a, b): - ... - - def rem(self, a, b): - ... - - def div(self, a, b): - ... - - def invert(self, a, b): - ... - - def revert(self, a): - ... - - def is_unit(self, a) -> bool: - ... - - def numer(self, a): - ... - - def denom(self, a): - ... - - def free_module(self, rank): - ... - - def ideal(self, *gens) -> ModuleImplementedIdeal: - ... - - def quotient_ring(self, e) -> QuotientRing: - ... - - def __truediv__(self, e) -> QuotientRing: - ... - - - + def get_ring(self) -> Self: ... + def exquo(self, a, b): ... + def quo(self, a, b): ... + def rem(self, a, b): ... + def div(self, a, b): ... + def invert(self, a, b): ... + def revert(self, a): ... + def is_unit(self, a) -> bool: ... + def numer(self, a): ... + def denom(self, a): ... + def free_module(self, rank): ... + def ideal(self, *gens) -> ModuleImplementedIdeal: ... + def quotient_ring(self, e) -> QuotientRing: ... + def __truediv__(self, e) -> QuotientRing: ... diff --git a/stubs/sympy-stubs/polys/domains/simpledomain.pyi b/stubs/sympy-stubs/polys/domains/simpledomain.pyi index ce49dafe..2b4fbecc 100644 --- a/stubs/sympy-stubs/polys/domains/simpledomain.pyi +++ b/stubs/sympy-stubs/polys/domains/simpledomain.pyi @@ -4,6 +4,4 @@ from sympy.polys.domains.domain import Domain class SimpleDomain(Domain): is_Simple = True - def inject(self, *gens) -> Self: - ... - + def inject(self, *gens) -> Self: ... diff --git a/stubs/sympy-stubs/polys/euclidtools.pyi b/stubs/sympy-stubs/polys/euclidtools.pyi index 843a3e3a..8bb87bc2 100644 --- a/stubs/sympy-stubs/polys/euclidtools.pyi +++ b/stubs/sympy-stubs/polys/euclidtools.pyi @@ -1,138 +1,161 @@ from typing import Any -def dup_half_gcdex(f, g, K) -> tuple[Any | list[Any], Any | list[Any]]: - ... - -def dmp_half_gcdex(f, g, u, K) -> tuple[Any | list[Any], Any | list[Any]]: - ... - -def dup_gcdex(f, g, K) -> tuple[Any | list[Any], Any | list[Any], Any | list[Any]]: - ... - -def dmp_gcdex(f, g, u, K) -> tuple[Any | list[Any], Any | list[Any], Any | list[Any]]: - ... - -def dup_invert(f, g, K) -> list[Any]: - ... - -def dmp_invert(f, g, u, K) -> list[Any]: - ... - -def dup_euclidean_prs(f, g, K) -> list[Any]: - ... - -def dmp_euclidean_prs(f, g, u, K) -> list[Any]: - ... - -def dup_primitive_prs(f, g, K) -> list[Any]: - ... - -def dmp_primitive_prs(f, g, u, K) -> list[Any]: - ... - -def dup_inner_subresultants(f, g, K) -> tuple[list[Any], list[Any]]: - ... - -def dup_subresultants(f, g, K) -> list[Any]: - ... - -def dup_prs_resultant(f, g, K) -> tuple[Any, list[Any]]: - ... - -def dup_resultant(f, g, K, includePRS=...) -> tuple[Any, list[Any]]: - ... - -def dmp_inner_subresultants(f, g, u, K) -> tuple[list[Any], list[Any]] | tuple[list[Any], list[list[list[Any]] | Any | list[Any]]]: - ... - -def dmp_subresultants(f, g, u, K) -> list[Any]: - ... - -def dmp_prs_resultant(f, g, u, K) -> tuple[Any, list[Any]] | tuple[list[list[Any]], list[Any]] | tuple[list[list[Any]] | Any | list[Any], list[Any]]: - ... - -def dmp_zz_modular_resultant(f, g, p, u, K) -> list[list[Any]]: - ... - -def dmp_zz_collins_resultant(f, g, u, K) -> list[list[Any]]: - ... - -def dmp_qq_collins_resultant(f, g, u, K0) -> list[list[Any]] | list[Any]: - ... - -def dmp_resultant(f, g, u, K, includePRS=...) -> tuple[Any, list[Any]] | tuple[list[list[Any]], list[Any]] | tuple[list[list[Any]] | Any | list[Any], list[Any]] | list[list[Any]] | list[Any]: - ... - -def dup_discriminant(f, K): - ... - -def dmp_discriminant(f, u, K) -> list[list[Any]]: - ... - -def dup_rr_prs_gcd(f, g, K) -> tuple[list[Any], list[Any], list[Any]] | tuple[Any, list[Any], list[Any]] | tuple[list[Any], Any | list[Any], Any | list[Any]]: - ... - -def dup_ff_prs_gcd(f, g, K) -> tuple[list[Any], list[Any], list[Any]] | tuple[Any | list[Any], list[Any], list[Any]] | tuple[Any | list[Any], Any | list[Any], Any | list[Any]]: - ... - -def dmp_rr_prs_gcd(f, g, u, K) -> tuple[list[Any], list[Any], list[Any]] | tuple[Any, list[Any], list[Any]] | tuple[list[Any], Any | list[Any], Any | list[Any]] | tuple[list[list[Any]], ...] | tuple[Any, list[list[Any]], list[list[Any]] | Any | list[Any]] | tuple[list[Any], list[list[Any]], list[list[Any]] | Any | list[Any]] | tuple[Any, list[list[Any]] | Any | list[Any], list[list[Any]]] | tuple[list[Any], list[list[Any]] | Any | list[Any], list[list[Any]]] | tuple[list[list[Any]] | Any | list[Any], Any, Any] | tuple[list[Any], list[Any | list[list[Any]]], list[Any | list[list[Any]]]] | tuple[list[Any] | Any | list[list[Any]] | list[Any | list[Any] | list[list[Any]]], Any | list[list[Any]], Any | list[list[Any]]]: - ... - -def dmp_ff_prs_gcd(f, g, u, K) -> tuple[list[Any], list[Any], list[Any]] | tuple[Any | list[Any], list[Any], list[Any]] | tuple[Any | list[Any], Any | list[Any], Any | list[Any]] | tuple[list[list[Any]], ...] | tuple[Any | list[Any], list[list[Any]], list[list[Any]] | Any | list[Any]] | tuple[Any | list[Any], list[list[Any]] | Any | list[Any], list[list[Any]]] | tuple[list[Any], list[Any | list[list[Any]]], list[Any | list[list[Any]]]] | tuple[Any | list[Any], Any | list[list[Any]], Any | list[list[Any]]]: - ... +def dup_half_gcdex(f, g, K) -> tuple[Any | list[Any], Any | list[Any]]: ... +def dmp_half_gcdex(f, g, u, K) -> tuple[Any | list[Any], Any | list[Any]]: ... +def dup_gcdex(f, g, K) -> tuple[Any | list[Any], Any | list[Any], Any | list[Any]]: ... +def dmp_gcdex(f, g, u, K) -> tuple[Any | list[Any], Any | list[Any], Any | list[Any]]: ... +def dup_invert(f, g, K) -> list[Any]: ... +def dmp_invert(f, g, u, K) -> list[Any]: ... +def dup_euclidean_prs(f, g, K) -> list[Any]: ... +def dmp_euclidean_prs(f, g, u, K) -> list[Any]: ... +def dup_primitive_prs(f, g, K) -> list[Any]: ... +def dmp_primitive_prs(f, g, u, K) -> list[Any]: ... +def dup_inner_subresultants(f, g, K) -> tuple[list[Any], list[Any]]: ... +def dup_subresultants(f, g, K) -> list[Any]: ... +def dup_prs_resultant(f, g, K) -> tuple[Any, list[Any]]: ... +def dup_resultant(f, g, K, includePRS=...) -> tuple[Any, list[Any]]: ... +def dmp_inner_subresultants( + f, g, u, K +) -> tuple[list[Any], list[Any]] | tuple[list[Any], list[list[list[Any]] | Any | list[Any]]]: ... +def dmp_subresultants(f, g, u, K) -> list[Any]: ... +def dmp_prs_resultant( + f, g, u, K +) -> tuple[Any, list[Any]] | tuple[list[list[Any]], list[Any]] | tuple[list[list[Any]] | Any | list[Any], list[Any]]: ... +def dmp_zz_modular_resultant(f, g, p, u, K) -> list[list[Any]]: ... +def dmp_zz_collins_resultant(f, g, u, K) -> list[list[Any]]: ... +def dmp_qq_collins_resultant(f, g, u, K0) -> list[list[Any]] | list[Any]: ... +def dmp_resultant( + f, g, u, K, includePRS=... +) -> ( + tuple[Any, list[Any]] + | tuple[list[list[Any]], list[Any]] + | tuple[list[list[Any]] | Any | list[Any], list[Any]] + | list[list[Any]] + | list[Any] +): ... +def dup_discriminant(f, K): ... +def dmp_discriminant(f, u, K) -> list[list[Any]]: ... +def dup_rr_prs_gcd( + f, g, K +) -> ( + tuple[list[Any], list[Any], list[Any]] | tuple[Any, list[Any], list[Any]] | tuple[list[Any], Any | list[Any], Any | list[Any]] +): ... +def dup_ff_prs_gcd( + f, g, K +) -> ( + tuple[list[Any], list[Any], list[Any]] + | tuple[Any | list[Any], list[Any], list[Any]] + | tuple[Any | list[Any], Any | list[Any], Any | list[Any]] +): ... +def dmp_rr_prs_gcd( + f, g, u, K +) -> ( + tuple[list[Any], list[Any], list[Any]] + | tuple[Any, list[Any], list[Any]] + | tuple[list[Any], Any | list[Any], Any | list[Any]] + | tuple[list[list[Any]], ...] + | tuple[Any, list[list[Any]], list[list[Any]] | Any | list[Any]] + | tuple[list[Any], list[list[Any]], list[list[Any]] | Any | list[Any]] + | tuple[Any, list[list[Any]] | Any | list[Any], list[list[Any]]] + | tuple[list[Any], list[list[Any]] | Any | list[Any], list[list[Any]]] + | tuple[list[list[Any]] | Any | list[Any], Any, Any] + | tuple[list[Any], list[Any | list[list[Any]]], list[Any | list[list[Any]]]] + | tuple[ + list[Any] | Any | list[list[Any]] | list[Any | list[Any] | list[list[Any]]], Any | list[list[Any]], Any | list[list[Any]] + ] +): ... +def dmp_ff_prs_gcd( + f, g, u, K +) -> ( + tuple[list[Any], list[Any], list[Any]] + | tuple[Any | list[Any], list[Any], list[Any]] + | tuple[Any | list[Any], Any | list[Any], Any | list[Any]] + | tuple[list[list[Any]], ...] + | tuple[Any | list[Any], list[list[Any]], list[list[Any]] | Any | list[Any]] + | tuple[Any | list[Any], list[list[Any]] | Any | list[Any], list[list[Any]]] + | tuple[list[Any], list[Any | list[list[Any]]], list[Any | list[list[Any]]]] + | tuple[Any | list[Any], Any | list[list[Any]], Any | list[list[Any]]] +): ... HEU_GCD_MAX = ... -def dup_zz_heu_gcd(f, g, K) -> tuple[list[Any], list[Any], list[Any]] | tuple[Any, list[Any], list[Any]] | tuple[list[Any], Any | list[Any], Any | list[Any]] | tuple[list[Any], list[Any], Any | list[Any]] | tuple[list[Any], Any | list[Any], list[Any]]: - ... - -def dmp_zz_heu_gcd(f, g, u, K) -> tuple[list[Any], list[Any], list[Any]] | tuple[Any, list[Any], list[Any]] | tuple[list[Any], Any | list[Any], Any | list[Any]] | tuple[list[Any], list[Any], Any | list[Any]] | tuple[list[Any], Any | list[Any], list[Any]] | tuple[list[list[Any]], ...] | tuple[Any, list[list[Any]], list[list[Any]] | Any | list[Any]] | tuple[list[Any], list[list[Any]], list[list[Any]] | Any | list[Any]] | tuple[Any, list[list[Any]] | Any | list[Any], list[list[Any]]] | tuple[list[Any], list[list[Any]] | Any | list[Any], list[list[Any]]] | tuple[list[list[Any]] | Any | list[Any], Any, Any] | tuple[list[Any], list[Any | list[list[Any]]], list[Any | list[list[Any]]]] | tuple[list[Any], Any | list[list[Any]], Any | list[list[Any]]] | tuple[list[Any], list[Any], Any | list[list[Any]]] | tuple[list[Any], Any | list[list[Any]], list[Any]]: - ... - -def dup_qq_heu_gcd(f, g, K0) -> tuple[list[Any], list[Any], list[Any]] | tuple[Any | list[Any], list[Any], list[Any]]: - ... - -def dmp_qq_heu_gcd(f, g, u, K0) -> tuple[list[list[Any]], ...] | tuple[Any | list[Any], list[list[Any]], list[list[Any]] | Any | list[Any]] | tuple[Any | list[Any], list[list[Any]] | Any | list[Any], list[list[Any]]] | tuple[list[Any], list[Any | list[list[Any]]], list[Any | list[list[Any]]]] | tuple[Any | list[Any], list[Any], list[Any]]: - ... - -def dup_inner_gcd(f, g, K) -> tuple[list[Any], Any, Any] | tuple[Any, Any, Any] | tuple[list[Any], list[Any], list[Any]] | tuple[Any | list[Any], list[Any], list[Any]] | tuple[Any | list[Any], Any | list[Any], Any | list[Any]] | tuple[Any, list[Any], list[Any]] | tuple[list[Any], Any | list[Any], Any | list[Any]] | tuple[list[Any], list[Any], Any | list[Any]] | tuple[list[Any], Any | list[Any], list[Any]]: - ... - -def dmp_inner_gcd(f, g, u, K) -> tuple[list[Any], Any, Any] | tuple[Any, Any, Any] | tuple[list[Any], list[Any], list[Any]] | tuple[Any | list[Any], list[Any], list[Any]] | tuple[Any | list[Any], Any | list[Any], Any | list[Any]] | tuple[Any, list[Any], list[Any]] | tuple[list[Any], Any | list[Any], Any | list[Any]] | tuple[list[Any], list[Any], Any | list[Any]] | tuple[list[Any], Any | list[Any], list[Any]]: - ... - -def dup_gcd(f, g, K) -> list[Any]: - ... - -def dmp_gcd(f, g, u, K): - ... - -def dup_rr_lcm(f, g, K) -> list[Any]: - ... - -def dup_ff_lcm(f, g, K) -> list[Any]: - ... - -def dup_lcm(f, g, K) -> list[Any]: - ... - -def dmp_rr_lcm(f, g, u, K) -> list[Any]: - ... - -def dmp_ff_lcm(f, g, u, K) -> list[Any]: - ... - -def dmp_lcm(f, g, u, K) -> list[Any]: - ... - -def dmp_content(f, u, K) -> list[Any]: - ... - -def dmp_primitive(f, u, K) -> tuple[Any | list[Any], Any] | tuple[Any | list[Any], list[Any | list[list[Any]]]]: - ... - -def dup_cancel(f, g, K, include=...) -> tuple[Any, Any, list[Any] | Any | list[list[Any]], list[Any] | Any | list[list[Any]]] | tuple[list[Any], list[Any]]: - ... - -def dmp_cancel(f, g, u, K, include=...) -> tuple[Any, Any, list[Any] | Any | list[list[Any]], list[Any] | Any | list[list[Any]]] | tuple[list[Any], list[Any]]: - ... +def dup_zz_heu_gcd( + f, g, K +) -> ( + tuple[list[Any], list[Any], list[Any]] + | tuple[Any, list[Any], list[Any]] + | tuple[list[Any], Any | list[Any], Any | list[Any]] + | tuple[list[Any], list[Any], Any | list[Any]] + | tuple[list[Any], Any | list[Any], list[Any]] +): ... +def dmp_zz_heu_gcd( + f, g, u, K +) -> ( + tuple[list[Any], list[Any], list[Any]] + | tuple[Any, list[Any], list[Any]] + | tuple[list[Any], Any | list[Any], Any | list[Any]] + | tuple[list[Any], list[Any], Any | list[Any]] + | tuple[list[Any], Any | list[Any], list[Any]] + | tuple[list[list[Any]], ...] + | tuple[Any, list[list[Any]], list[list[Any]] | Any | list[Any]] + | tuple[list[Any], list[list[Any]], list[list[Any]] | Any | list[Any]] + | tuple[Any, list[list[Any]] | Any | list[Any], list[list[Any]]] + | tuple[list[Any], list[list[Any]] | Any | list[Any], list[list[Any]]] + | tuple[list[list[Any]] | Any | list[Any], Any, Any] + | tuple[list[Any], list[Any | list[list[Any]]], list[Any | list[list[Any]]]] + | tuple[list[Any], Any | list[list[Any]], Any | list[list[Any]]] + | tuple[list[Any], list[Any], Any | list[list[Any]]] + | tuple[list[Any], Any | list[list[Any]], list[Any]] +): ... +def dup_qq_heu_gcd(f, g, K0) -> tuple[list[Any], list[Any], list[Any]] | tuple[Any | list[Any], list[Any], list[Any]]: ... +def dmp_qq_heu_gcd( + f, g, u, K0 +) -> ( + tuple[list[list[Any]], ...] + | tuple[Any | list[Any], list[list[Any]], list[list[Any]] | Any | list[Any]] + | tuple[Any | list[Any], list[list[Any]] | Any | list[Any], list[list[Any]]] + | tuple[list[Any], list[Any | list[list[Any]]], list[Any | list[list[Any]]]] + | tuple[Any | list[Any], list[Any], list[Any]] +): ... +def dup_inner_gcd( + f, g, K +) -> ( + tuple[list[Any], Any, Any] + | tuple[Any, Any, Any] + | tuple[list[Any], list[Any], list[Any]] + | tuple[Any | list[Any], list[Any], list[Any]] + | tuple[Any | list[Any], Any | list[Any], Any | list[Any]] + | tuple[Any, list[Any], list[Any]] + | tuple[list[Any], Any | list[Any], Any | list[Any]] + | tuple[list[Any], list[Any], Any | list[Any]] + | tuple[list[Any], Any | list[Any], list[Any]] +): ... +def dmp_inner_gcd( + f, g, u, K +) -> ( + tuple[list[Any], Any, Any] + | tuple[Any, Any, Any] + | tuple[list[Any], list[Any], list[Any]] + | tuple[Any | list[Any], list[Any], list[Any]] + | tuple[Any | list[Any], Any | list[Any], Any | list[Any]] + | tuple[Any, list[Any], list[Any]] + | tuple[list[Any], Any | list[Any], Any | list[Any]] + | tuple[list[Any], list[Any], Any | list[Any]] + | tuple[list[Any], Any | list[Any], list[Any]] +): ... +def dup_gcd(f, g, K) -> list[Any]: ... +def dmp_gcd(f, g, u, K): ... +def dup_rr_lcm(f, g, K) -> list[Any]: ... +def dup_ff_lcm(f, g, K) -> list[Any]: ... +def dup_lcm(f, g, K) -> list[Any]: ... +def dmp_rr_lcm(f, g, u, K) -> list[Any]: ... +def dmp_ff_lcm(f, g, u, K) -> list[Any]: ... +def dmp_lcm(f, g, u, K) -> list[Any]: ... +def dmp_content(f, u, K) -> list[Any]: ... +def dmp_primitive(f, u, K) -> tuple[Any | list[Any], Any] | tuple[Any | list[Any], list[Any | list[list[Any]]]]: ... +def dup_cancel( + f, g, K, include=... +) -> tuple[Any, Any, list[Any] | Any | list[list[Any]], list[Any] | Any | list[list[Any]]] | tuple[list[Any], list[Any]]: ... +def dmp_cancel( + f, g, u, K, include=... +) -> tuple[Any, Any, list[Any] | Any | list[list[Any]], list[Any] | Any | list[list[Any]]] | tuple[list[Any], list[Any]]: ... diff --git a/stubs/sympy-stubs/polys/factortools.pyi b/stubs/sympy-stubs/polys/factortools.pyi index 8d0259b5..ebb26610 100644 --- a/stubs/sympy-stubs/polys/factortools.pyi +++ b/stubs/sympy-stubs/polys/factortools.pyi @@ -2,108 +2,54 @@ from typing import Any, Literal from sympy.external.gmpy import GROUND_TYPES -def dup_trial_division(f, factors, K) -> list[Any]: - ... - -def dmp_trial_division(f, factors, u, K) -> list[Any]: - ... - -def dup_zz_mignotte_bound(f, K): - ... - -def dmp_zz_mignotte_bound(f, u, K): - ... - -def dup_zz_hensel_step(m, f, g, h, s, t, K) -> tuple[Any, Any, Any, Any]: - ... - -def dup_zz_hensel_lift(p, f, f_list, l, K) -> list[Any]: - ... - -def dup_zz_zassenhaus(f, K) -> list[Any]: - ... - -def dup_zz_irreducible_p(f, K) -> Literal[True] | None: - ... - -def dup_cyclotomic_p(f, K, irreducible=...) -> bool: - ... - -def dup_zz_cyclotomic_poly(n, K) -> list[Any]: - ... - -def dup_zz_cyclotomic_factor(f, K) -> list[list[Any]] | list[Any] | None: - ... - -def dup_zz_factor_sqf(f, K) -> tuple[Any, list[Any]] | tuple[Any, list[list[Any] | Any]]: - ... - -def dup_zz_factor(f, K) -> tuple[Any, list[Any]] | tuple[Any, list[tuple[list[Any] | Any, Literal[1]]]]: - ... - -def dmp_zz_wang_non_divisors(E, cs, ct, K) -> list[Any] | None: - ... - -def dmp_zz_wang_test_points(f, T, ct, A, u, K) -> tuple[Any, list[Any] | Any, list[Any | list[list[Any]] | list[Any]]]: - ... - -def dmp_zz_wang_lead_coeffs(f, T, cs, E, H, A, u, K) -> tuple[Any, list[Any], list[Any]] | tuple[list[Any], list[Any], list[Any]]: - ... - -def dup_zz_diophantine(F, m, p, K) -> list[list[Any] | Any]: - ... - -def dmp_zz_diophantine(F, c, A, d, p, u, K) -> list[list[Any]] | list[Any | list[list[Any]]]: - ... - -def dmp_zz_wang_hensel_lifting(f, H, LC, A, p, u, K) -> list[Any]: - ... - -def dmp_zz_wang(f, u, K, mod=..., seed=...) -> list[Any]: - ... - -def dmp_zz_factor(f, u, K) -> tuple[Any, list[Any]] | tuple[Any, list[tuple[list[Any] | Any, Literal[1]]]]: - ... - -def dup_qq_i_factor(f, K0) -> tuple[Any, list[tuple[Any, Any]]]: - ... - -def dup_zz_i_factor(f, K0) -> tuple[Any, list[Any]]: - ... - -def dmp_qq_i_factor(f, u, K0) -> tuple[Any, list[tuple[Any | list[list[Any]], Any]]]: - ... - -def dmp_zz_i_factor(f, u, K0) -> tuple[Any, list[Any]]: - ... - -def dup_ext_factor(f, K) -> tuple[Any, list[Any]] | tuple[Any, list[tuple[Any | list[Any], Literal[1]]]] | tuple[Any, list[tuple[Any | list[Any], Any | int]]]: - ... - -def dmp_ext_factor(f, u, K) -> tuple[Any, list[Any]] | tuple[Any, list[tuple[Any | list[Any], Literal[1]]]] | tuple[Any, list[tuple[Any | list[Any], Any | int]]]: - ... - -def dup_gf_factor(f, K) -> tuple[Any, list[Any]]: - ... - -def dmp_gf_factor(f, u, K): - ... - -def dup_factor_list(f, K0) -> tuple[Any, list[Any]]: - ... - -def dup_factor_list_include(f, K) -> list[tuple[Any, Literal[1]]]: - ... - -def dmp_factor_list(f, u, K0) -> tuple[Any, list[Any]]: - ... - -def dmp_factor_list_include(f, u, K) -> list[tuple[Any, Literal[1]]] | list[tuple[list[list[Any]] | Any | list[Any], Literal[1]]]: - ... - -def dup_irreducible_p(f, K) -> bool: - ... - -def dmp_irreducible_p(f, u, K) -> bool: - ... - +def dup_trial_division(f, factors, K) -> list[Any]: ... +def dmp_trial_division(f, factors, u, K) -> list[Any]: ... +def dup_zz_mignotte_bound(f, K): ... +def dmp_zz_mignotte_bound(f, u, K): ... +def dup_zz_hensel_step(m, f, g, h, s, t, K) -> tuple[Any, Any, Any, Any]: ... +def dup_zz_hensel_lift(p, f, f_list, l, K) -> list[Any]: ... +def dup_zz_zassenhaus(f, K) -> list[Any]: ... +def dup_zz_irreducible_p(f, K) -> Literal[True] | None: ... +def dup_cyclotomic_p(f, K, irreducible=...) -> bool: ... +def dup_zz_cyclotomic_poly(n, K) -> list[Any]: ... +def dup_zz_cyclotomic_factor(f, K) -> list[list[Any]] | list[Any] | None: ... +def dup_zz_factor_sqf(f, K) -> tuple[Any, list[Any]] | tuple[Any, list[list[Any] | Any]]: ... +def dup_zz_factor(f, K) -> tuple[Any, list[Any]] | tuple[Any, list[tuple[list[Any] | Any, Literal[1]]]]: ... +def dmp_zz_wang_non_divisors(E, cs, ct, K) -> list[Any] | None: ... +def dmp_zz_wang_test_points(f, T, ct, A, u, K) -> tuple[Any, list[Any] | Any, list[Any | list[list[Any]] | list[Any]]]: ... +def dmp_zz_wang_lead_coeffs( + f, T, cs, E, H, A, u, K +) -> tuple[Any, list[Any], list[Any]] | tuple[list[Any], list[Any], list[Any]]: ... +def dup_zz_diophantine(F, m, p, K) -> list[list[Any] | Any]: ... +def dmp_zz_diophantine(F, c, A, d, p, u, K) -> list[list[Any]] | list[Any | list[list[Any]]]: ... +def dmp_zz_wang_hensel_lifting(f, H, LC, A, p, u, K) -> list[Any]: ... +def dmp_zz_wang(f, u, K, mod=..., seed=...) -> list[Any]: ... +def dmp_zz_factor(f, u, K) -> tuple[Any, list[Any]] | tuple[Any, list[tuple[list[Any] | Any, Literal[1]]]]: ... +def dup_qq_i_factor(f, K0) -> tuple[Any, list[tuple[Any, Any]]]: ... +def dup_zz_i_factor(f, K0) -> tuple[Any, list[Any]]: ... +def dmp_qq_i_factor(f, u, K0) -> tuple[Any, list[tuple[Any | list[list[Any]], Any]]]: ... +def dmp_zz_i_factor(f, u, K0) -> tuple[Any, list[Any]]: ... +def dup_ext_factor( + f, K +) -> ( + tuple[Any, list[Any]] + | tuple[Any, list[tuple[Any | list[Any], Literal[1]]]] + | tuple[Any, list[tuple[Any | list[Any], Any | int]]] +): ... +def dmp_ext_factor( + f, u, K +) -> ( + tuple[Any, list[Any]] + | tuple[Any, list[tuple[Any | list[Any], Literal[1]]]] + | tuple[Any, list[tuple[Any | list[Any], Any | int]]] +): ... +def dup_gf_factor(f, K) -> tuple[Any, list[Any]]: ... +def dmp_gf_factor(f, u, K): ... +def dup_factor_list(f, K0) -> tuple[Any, list[Any]]: ... +def dup_factor_list_include(f, K) -> list[tuple[Any, Literal[1]]]: ... +def dmp_factor_list(f, u, K0) -> tuple[Any, list[Any]]: ... +def dmp_factor_list_include( + f, u, K +) -> list[tuple[Any, Literal[1]]] | list[tuple[list[list[Any]] | Any | list[Any], Literal[1]]]: ... +def dup_irreducible_p(f, K) -> bool: ... +def dmp_irreducible_p(f, u, K) -> bool: ... diff --git a/stubs/sympy-stubs/polys/fglmtools.pyi b/stubs/sympy-stubs/polys/fglmtools.pyi index bd77952d..528e6019 100644 --- a/stubs/sympy-stubs/polys/fglmtools.pyi +++ b/stubs/sympy-stubs/polys/fglmtools.pyi @@ -1,5 +1,3 @@ from typing import Any -def matrix_fglm(F, ring, O_to) -> list[Any]: - ... - +def matrix_fglm(F, ring, O_to) -> list[Any]: ... diff --git a/stubs/sympy-stubs/polys/fields.pyi b/stubs/sympy-stubs/polys/fields.pyi index e3b1a24f..a1fd06b6 100644 --- a/stubs/sympy-stubs/polys/fields.pyi +++ b/stubs/sympy-stubs/polys/fields.pyi @@ -8,171 +8,68 @@ from sympy.printing.defaults import DefaultPrinting from sympy.utilities import public @public -def field(symbols, domain, order=...) -> Any: - ... - +def field(symbols, domain, order=...) -> Any: ... @public -def xfield(symbols, domain, order=...) -> tuple[FracField | Any, Any]: - ... - +def xfield(symbols, domain, order=...) -> tuple[FracField | Any, Any]: ... @public -def vfield(symbols, domain, order=...) -> FracField | Any: - ... - +def vfield(symbols, domain, order=...) -> FracField | Any: ... @public -def sfield(exprs, *symbols, **options) -> tuple[FracField | Any, Any] | tuple[FracField | Any, list[Any]]: - ... +def sfield(exprs, *symbols, **options) -> tuple[FracField | Any, Any] | tuple[FracField | Any, list[Any]]: ... _field_cache: dict[Any, Any] = ... + class FracField(DefaultPrinting): - def __new__(cls, symbols, domain, order=...) -> Self | Any: - ... - - def __getnewargs__(self) -> tuple[Any, Any, Any]: - ... - - def __hash__(self) -> int: - ... - - def index(self, gen): - ... - - def __eq__(self, other) -> bool: - ... - - def __ne__(self, other) -> bool: - ... - - def raw_new(self, numer, denom=...): - ... - - def new(self, numer, denom=...): - ... - - def domain_new(self, element): - ... - - def ground_new(self, element): - ... - - def field_new(self, element) -> FracElement: - ... - + def __new__(cls, symbols, domain, order=...) -> Self | Any: ... + def __getnewargs__(self) -> tuple[Any, Any, Any]: ... + def __hash__(self) -> int: ... + def index(self, gen): ... + def __eq__(self, other) -> bool: ... + def __ne__(self, other) -> bool: ... + def raw_new(self, numer, denom=...): ... + def new(self, numer, denom=...): ... + def domain_new(self, element): ... + def ground_new(self, element): ... + def field_new(self, element) -> FracElement: ... + __call__ = ... - def from_expr(self, expr): - ... - - def to_domain(self) -> Any: - ... - - def to_ring(self) -> PolyRing | Any: - ... - + def from_expr(self, expr): ... + def to_domain(self) -> Any: ... + def to_ring(self) -> PolyRing | Any: ... +class FracElement(DomainElement, DefaultPrinting, CantSympify): # type: ignore + def __init__(self, numer, denom=...) -> None: ... + def raw_new(f, numer, denom) -> Self: ... + def new(f, numer, denom) -> Self: ... + def to_poly(f) -> Any: ... + def parent(self): ... + def __getnewargs__(self) -> tuple[Any, Any, Any]: ... -class FracElement(DomainElement, DefaultPrinting, CantSympify): # type: ignore - def __init__(self, numer, denom=...) -> None: - ... - - def raw_new(f, numer, denom) -> Self: - ... - - def new(f, numer, denom) -> Self: - ... - - def to_poly(f) -> Any: - ... - - def parent(self): - ... - - def __getnewargs__(self) -> tuple[Any, Any, Any]: - ... - _hash = ... - def __hash__(self) -> int: - ... - - def copy(self) -> Self: - ... - - def set_field(self, new_field) -> Self: - ... - - def as_expr(self, *symbols): - ... - - def __eq__(f, g) -> bool: - ... - - def __ne__(f, g) -> bool: - ... - - def __bool__(f) -> bool: - ... - - def sort_key(self) -> tuple[Any, Any]: - ... - - def __lt__(f1, f2) -> bool: - ... - - def __le__(f1, f2) -> bool: - ... - - def __gt__(f1, f2) -> bool: - ... - - def __ge__(f1, f2) -> bool: - ... - - def __pos__(f) -> Self: - ... - - def __neg__(f) -> Self: - ... - - def __add__(f, g) -> Self | FracElement | NotImplementedType | PolyElement: - ... - - def __radd__(f, c) -> Self | NotImplementedType: - ... - - def __sub__(f, g) -> Self | FracElement | NotImplementedType: - ... - - def __rsub__(f, c) -> Self | NotImplementedType: - ... - - def __mul__(f, g) -> Self | FracElement | NotImplementedType: - ... - - def __rmul__(f, c) -> Self | NotImplementedType: - ... - - def __truediv__(f, g) -> Self | FracElement | NotImplementedType: - ... - - def __rtruediv__(f, c) -> Self | NotImplementedType: - ... - - def __pow__(f, n) -> Self: - ... - - def diff(f, x) -> Self: - ... - - def __call__(f, *values): - ... - - def evaluate(f, x, a=...): - ... - - def subs(f, x, a=...) -> Self: - ... - - def compose(f, x, a=...): - ... - - - + def __hash__(self) -> int: ... + def copy(self) -> Self: ... + def set_field(self, new_field) -> Self: ... + def as_expr(self, *symbols): ... + def __eq__(f, g) -> bool: ... + def __ne__(f, g) -> bool: ... + def __bool__(f) -> bool: ... + def sort_key(self) -> tuple[Any, Any]: ... + def __lt__(f1, f2) -> bool: ... + def __le__(f1, f2) -> bool: ... + def __gt__(f1, f2) -> bool: ... + def __ge__(f1, f2) -> bool: ... + def __pos__(f) -> Self: ... + def __neg__(f) -> Self: ... + def __add__(f, g) -> Self | FracElement | NotImplementedType | PolyElement: ... + def __radd__(f, c) -> Self | NotImplementedType: ... + def __sub__(f, g) -> Self | FracElement | NotImplementedType: ... + def __rsub__(f, c) -> Self | NotImplementedType: ... + def __mul__(f, g) -> Self | FracElement | NotImplementedType: ... + def __rmul__(f, c) -> Self | NotImplementedType: ... + def __truediv__(f, g) -> Self | FracElement | NotImplementedType: ... + def __rtruediv__(f, c) -> Self | NotImplementedType: ... + def __pow__(f, n) -> Self: ... + def diff(f, x) -> Self: ... + def __call__(f, *values): ... + def evaluate(f, x, a=...): ... + def subs(f, x, a=...) -> Self: ... + def compose(f, x, a=...): ... diff --git a/stubs/sympy-stubs/polys/galoistools.pyi b/stubs/sympy-stubs/polys/galoistools.pyi index 0de68302..1658f3c5 100644 --- a/stubs/sympy-stubs/polys/galoistools.pyi +++ b/stubs/sympy-stubs/polys/galoistools.pyi @@ -1,214 +1,78 @@ from typing import Any, Literal -def gf_crt(U, M, K=...): - ... - -def gf_crt1(M, K) -> tuple[float, list[Any], list[Any]]: - ... - -def gf_crt2(U, M, p, E, S, K): - ... - -def gf_int(a, p): - ... - -def gf_degree(f) -> int: - ... - -def gf_LC(f, K): - ... - -def gf_TC(f, K): - ... - -def gf_strip(f): - ... - -def gf_trunc(f, p): - ... - -def gf_normal(f, p, K): - ... - -def gf_from_dict(f, p, K): - ... - -def gf_to_dict(f, p, symmetric=...) -> dict[Any, Any]: - ... - -def gf_from_int_poly(f, p): - ... - -def gf_to_int_poly(f, p, symmetric=...) -> list[Any]: - ... - -def gf_neg(f, p, K) -> list[Any]: - ... - -def gf_add_ground(f, a, p, K) -> list[Any]: - ... - -def gf_sub_ground(f, a, p, K) -> list[Any]: - ... - -def gf_mul_ground(f, a, p, K) -> list[Any]: - ... - -def gf_quo_ground(f, a, p, K) -> list[Any]: - ... - -def gf_add(f, g, p, K): - ... - -def gf_sub(f, g, p, K) -> list[Any]: - ... - -def gf_mul(f, g, p, K): - ... - -def gf_sqr(f, p, K): - ... - -def gf_add_mul(f, g, h, p, K): - ... - -def gf_sub_mul(f, g, h, p, K) -> list[Any]: - ... - -def gf_expand(F, p, K) -> list[Any]: - ... - -def gf_div(f, g, p, K) -> tuple[list[Any], Any]: - ... - -def gf_rem(f, g, p, K): - ... - -def gf_quo(f, g, p, K) -> list[Any]: - ... - -def gf_exquo(f, g, p, K) -> list[Any]: - ... - -def gf_lshift(f, n, K): - ... - -def gf_rshift(f, n, K) -> tuple[Any, list[Any]] | tuple[Any, Any]: - ... - -def gf_pow(f, n, p, K) -> list[Any]: - ... - -def gf_frobenius_monomial_base(g, p, K) -> list[Any] | list[int]: - ... - -def gf_frobenius_map(f, g, b, p, K) -> list[Any]: - ... - -def gf_pow_mod(f, n, g, p, K) -> list[Any]: - ... - -def gf_gcd(f, g, p, K) -> list[Any]: - ... - -def gf_lcm(f, g, p, K) -> list[Any]: - ... - -def gf_cofactors(f, g, p, K) -> tuple[list[Any], list[Any], list[Any]] | tuple[list[Any], list[Any] | Any, list[Any] | Any]: - ... - -def gf_gcdex(f, g, p, K) -> tuple[list[Any], list[Any], list[Any]]: - ... - -def gf_monic(f, p, K) -> tuple[Any, list[Any]]: - ... - -def gf_diff(f, p, K): - ... - -def gf_eval(f, a, p, K): - ... - -def gf_multi_eval(f, A, p, K) -> list[Any]: - ... - -def gf_compose(f, g, p, K) -> list[Any]: - ... - -def gf_compose_mod(g, h, f, p, K) -> list[Any]: - ... - -def gf_trace_map(a, b, c, n, f, p, K) -> tuple[list[Any] | Any, Any]: - ... - -def gf_random(n, p, K) -> list[Any]: - ... - -def gf_irreducible(n, p, K) -> list[Any]: - ... - -def gf_irred_p_ben_or(f, p, K) -> bool: - ... - -def gf_irred_p_rabin(f, p, K) -> bool: - ... +def gf_crt(U, M, K=...): ... +def gf_crt1(M, K) -> tuple[float, list[Any], list[Any]]: ... +def gf_crt2(U, M, p, E, S, K): ... +def gf_int(a, p): ... +def gf_degree(f) -> int: ... +def gf_LC(f, K): ... +def gf_TC(f, K): ... +def gf_strip(f): ... +def gf_trunc(f, p): ... +def gf_normal(f, p, K): ... +def gf_from_dict(f, p, K): ... +def gf_to_dict(f, p, symmetric=...) -> dict[Any, Any]: ... +def gf_from_int_poly(f, p): ... +def gf_to_int_poly(f, p, symmetric=...) -> list[Any]: ... +def gf_neg(f, p, K) -> list[Any]: ... +def gf_add_ground(f, a, p, K) -> list[Any]: ... +def gf_sub_ground(f, a, p, K) -> list[Any]: ... +def gf_mul_ground(f, a, p, K) -> list[Any]: ... +def gf_quo_ground(f, a, p, K) -> list[Any]: ... +def gf_add(f, g, p, K): ... +def gf_sub(f, g, p, K) -> list[Any]: ... +def gf_mul(f, g, p, K): ... +def gf_sqr(f, p, K): ... +def gf_add_mul(f, g, h, p, K): ... +def gf_sub_mul(f, g, h, p, K) -> list[Any]: ... +def gf_expand(F, p, K) -> list[Any]: ... +def gf_div(f, g, p, K) -> tuple[list[Any], Any]: ... +def gf_rem(f, g, p, K): ... +def gf_quo(f, g, p, K) -> list[Any]: ... +def gf_exquo(f, g, p, K) -> list[Any]: ... +def gf_lshift(f, n, K): ... +def gf_rshift(f, n, K) -> tuple[Any, list[Any]] | tuple[Any, Any]: ... +def gf_pow(f, n, p, K) -> list[Any]: ... +def gf_frobenius_monomial_base(g, p, K) -> list[Any] | list[int]: ... +def gf_frobenius_map(f, g, b, p, K) -> list[Any]: ... +def gf_pow_mod(f, n, g, p, K) -> list[Any]: ... +def gf_gcd(f, g, p, K) -> list[Any]: ... +def gf_lcm(f, g, p, K) -> list[Any]: ... +def gf_cofactors(f, g, p, K) -> tuple[list[Any], list[Any], list[Any]] | tuple[list[Any], list[Any] | Any, list[Any] | Any]: ... +def gf_gcdex(f, g, p, K) -> tuple[list[Any], list[Any], list[Any]]: ... +def gf_monic(f, p, K) -> tuple[Any, list[Any]]: ... +def gf_diff(f, p, K): ... +def gf_eval(f, a, p, K): ... +def gf_multi_eval(f, A, p, K) -> list[Any]: ... +def gf_compose(f, g, p, K) -> list[Any]: ... +def gf_compose_mod(g, h, f, p, K) -> list[Any]: ... +def gf_trace_map(a, b, c, n, f, p, K) -> tuple[list[Any] | Any, Any]: ... +def gf_random(n, p, K) -> list[Any]: ... +def gf_irreducible(n, p, K) -> list[Any]: ... +def gf_irred_p_ben_or(f, p, K) -> bool: ... +def gf_irred_p_rabin(f, p, K) -> bool: ... _irred_methods = ... -def gf_irreducible_p(f, p, K) -> bool: - ... -def gf_sqf_p(f, p, K) -> bool: - ... - -def gf_sqf_part(f, p, K) -> list[Any]: - ... - -def gf_sqf_list(f, p, K, all=...) -> tuple[Any, list[Any]]: - ... - -def gf_Qmatrix(f, p, K) -> list[list[Any]]: - ... - -def gf_Qbasis(Q, p, K) -> list[Any]: - ... - -def gf_berlekamp(f, p, K) -> list[Any]: - ... - -def gf_ddf_zassenhaus(f, p, K) -> list[Any]: - ... - -def gf_edf_zassenhaus(f, n, p, K) -> list[Any]: - ... - -def gf_ddf_shoup(f, p, K) -> list[Any]: - ... - -def gf_edf_shoup(f, n, p, K) -> list[Any]: - ... - -def gf_zassenhaus(f, p, K) -> list[Any]: - ... - -def gf_shoup(f, p, K) -> list[Any]: - ... +def gf_irreducible_p(f, p, K) -> bool: ... +def gf_sqf_p(f, p, K) -> bool: ... +def gf_sqf_part(f, p, K) -> list[Any]: ... +def gf_sqf_list(f, p, K, all=...) -> tuple[Any, list[Any]]: ... +def gf_Qmatrix(f, p, K) -> list[list[Any]]: ... +def gf_Qbasis(Q, p, K) -> list[Any]: ... +def gf_berlekamp(f, p, K) -> list[Any]: ... +def gf_ddf_zassenhaus(f, p, K) -> list[Any]: ... +def gf_edf_zassenhaus(f, n, p, K) -> list[Any]: ... +def gf_ddf_shoup(f, p, K) -> list[Any]: ... +def gf_edf_shoup(f, n, p, K) -> list[Any]: ... +def gf_zassenhaus(f, p, K) -> list[Any]: ... +def gf_shoup(f, p, K) -> list[Any]: ... _factor_methods = ... -def gf_factor_sqf(f, p, K, method=...) -> tuple[Any, list[Any]]: - ... - -def gf_factor(f, p, K) -> tuple[Any, list[Any]]: - ... - -def gf_value(f, a) -> Literal[0]: - ... - -def linear_congruence(a, b, m) -> list[int] | list[Any]: - ... - -def csolve_prime(f, p, e=...) -> list[int] | list[Any]: - ... - -def gf_csolve(f, n) -> list[Any]: - ... +def gf_factor_sqf(f, p, K, method=...) -> tuple[Any, list[Any]]: ... +def gf_factor(f, p, K) -> tuple[Any, list[Any]]: ... +def gf_value(f, a) -> Literal[0]: ... +def linear_congruence(a, b, m) -> list[int] | list[Any]: ... +def csolve_prime(f, p, e=...) -> list[int] | list[Any]: ... +def gf_csolve(f, n) -> list[Any]: ... diff --git a/stubs/sympy-stubs/polys/groebnertools.pyi b/stubs/sympy-stubs/polys/groebnertools.pyi index 3290eafa..f82508b8 100644 --- a/stubs/sympy-stubs/polys/groebnertools.pyi +++ b/stubs/sympy-stubs/polys/groebnertools.pyi @@ -1,80 +1,30 @@ from typing import Any, Literal -def groebner(seq, ring, method=...) -> list[Any]: - ... - -def spoly(p1, p2, ring): - ... - -def Sign(f): - ... - -def Polyn(f): - ... - -def Num(f): - ... - -def sig(monomial, index) -> tuple[Any, Any]: - ... - -def lbp(signature, polynomial, number) -> tuple[Any, Any, Any]: - ... - -def sig_cmp(u, v, order) -> Literal[-1, 1]: - ... - -def sig_key(s, order) -> tuple[Any, Any]: - ... - -def sig_mult(s, m) -> tuple[Any, Any]: - ... - -def lbp_sub(f, g) -> tuple[Any, Any, Any]: - ... - -def lbp_mul_term(f, cx) -> tuple[Any, Any, Any]: - ... - -def lbp_cmp(f, g) -> Literal[-1, 1]: - ... - -def lbp_key(f) -> tuple[tuple[Any, Any], Any]: - ... - -def critical_pair(f, g, ring) -> tuple[Any, tuple[tuple[Any, ...], Any] | None, Any, Any, tuple[tuple[Any, ...], Any] | None, Any]: - ... - -def cp_cmp(c, d) -> Literal[-1, 1]: - ... - -def cp_key(c, ring) -> tuple[tuple[tuple[Any, Any], Any], tuple[tuple[Any, Any], Any]]: - ... - -def s_poly(cp) -> tuple[Any, Any, Any]: - ... - -def is_rewritable_or_comparable(sign, num, B) -> bool: - ... - -def f5_reduce(f, B) -> tuple[Any, Any, Any]: - ... - -def red_groebner(G, ring) -> list[Any]: - ... - -def is_groebner(G, ring) -> bool: - ... - -def is_minimal(G, ring) -> bool: - ... - -def is_reduced(G, ring) -> bool: - ... - -def groebner_lcm(f, g): - ... - -def groebner_gcd(f, g): - ... - +def groebner(seq, ring, method=...) -> list[Any]: ... +def spoly(p1, p2, ring): ... +def Sign(f): ... +def Polyn(f): ... +def Num(f): ... +def sig(monomial, index) -> tuple[Any, Any]: ... +def lbp(signature, polynomial, number) -> tuple[Any, Any, Any]: ... +def sig_cmp(u, v, order) -> Literal[-1, 1]: ... +def sig_key(s, order) -> tuple[Any, Any]: ... +def sig_mult(s, m) -> tuple[Any, Any]: ... +def lbp_sub(f, g) -> tuple[Any, Any, Any]: ... +def lbp_mul_term(f, cx) -> tuple[Any, Any, Any]: ... +def lbp_cmp(f, g) -> Literal[-1, 1]: ... +def lbp_key(f) -> tuple[tuple[Any, Any], Any]: ... +def critical_pair( + f, g, ring +) -> tuple[Any, tuple[tuple[Any, ...], Any] | None, Any, Any, tuple[tuple[Any, ...], Any] | None, Any]: ... +def cp_cmp(c, d) -> Literal[-1, 1]: ... +def cp_key(c, ring) -> tuple[tuple[tuple[Any, Any], Any], tuple[tuple[Any, Any], Any]]: ... +def s_poly(cp) -> tuple[Any, Any, Any]: ... +def is_rewritable_or_comparable(sign, num, B) -> bool: ... +def f5_reduce(f, B) -> tuple[Any, Any, Any]: ... +def red_groebner(G, ring) -> list[Any]: ... +def is_groebner(G, ring) -> bool: ... +def is_minimal(G, ring) -> bool: ... +def is_reduced(G, ring) -> bool: ... +def groebner_lcm(f, g): ... +def groebner_gcd(f, g): ... diff --git a/stubs/sympy-stubs/polys/heuristicgcd.pyi b/stubs/sympy-stubs/polys/heuristicgcd.pyi index 9bd98e39..fe856fa4 100644 --- a/stubs/sympy-stubs/polys/heuristicgcd.pyi +++ b/stubs/sympy-stubs/polys/heuristicgcd.pyi @@ -1,6 +1,5 @@ from typing import Any HEU_GCD_MAX = ... -def heugcd(f, g) -> tuple[Any, Any, Any]: - ... +def heugcd(f, g) -> tuple[Any, Any, Any]: ... diff --git a/stubs/sympy-stubs/polys/matrices/__init__.pyi b/stubs/sympy-stubs/polys/matrices/__init__.pyi index edab0ccb..0f431ceb 100644 --- a/stubs/sympy-stubs/polys/matrices/__init__.pyi +++ b/stubs/sympy-stubs/polys/matrices/__init__.pyi @@ -1,3 +1,3 @@ from sympy.polys.matrices.domainmatrix import DM, DomainMatrix -__all__ = ['DomainMatrix', 'DM'] +__all__ = ["DomainMatrix", "DM"] diff --git a/stubs/sympy-stubs/polys/matrices/ddm.pyi b/stubs/sympy-stubs/polys/matrices/ddm.pyi index 46b528b6..e481e7df 100644 --- a/stubs/sympy-stubs/polys/matrices/ddm.pyi +++ b/stubs/sympy-stubs/polys/matrices/ddm.pyi @@ -7,164 +7,58 @@ from sympy.utilities.decorator import doctest_depends_on class DDM(list): fmt = ... - def __init__(self, rowslist, shape, domain) -> None: - ... - - def getitem(self, i, j): - ... - - def setitem(self, i, j, value) -> None: - ... - - def extract_slice(self, slice1, slice2) -> DDM: - ... - - def extract(self, rows, cols) -> DDM: - ... - - def to_list(self) -> list[Any]: - ... - - def to_list_flat(self) -> list[Any]: - ... - - def flatiter(self) -> chain[Any]: - ... - - def flat(self) -> list[Any]: - ... - - def to_dok(self) -> dict[tuple[int, int], Any]: - ... - - def to_ddm(self) -> Self: - ... - - def to_sdm(self) -> SDM: - ... - - def convert_to(self, K) -> DDM: - ... - - def __str__(self) -> str: - ... - - def __repr__(self) -> str: - ... - - def __eq__(self, other) -> bool: - ... - - def __ne__(self, other) -> bool: - ... - + def __init__(self, rowslist, shape, domain) -> None: ... + def getitem(self, i, j): ... + def setitem(self, i, j, value) -> None: ... + def extract_slice(self, slice1, slice2) -> DDM: ... + def extract(self, rows, cols) -> DDM: ... + def to_list(self) -> list[Any]: ... + def to_list_flat(self) -> list[Any]: ... + def flatiter(self) -> chain[Any]: ... + def flat(self) -> list[Any]: ... + def to_dok(self) -> dict[tuple[int, int], Any]: ... + def to_ddm(self) -> Self: ... + def to_sdm(self) -> SDM: ... + def convert_to(self, K) -> DDM: ... + def __str__(self) -> str: ... + def __repr__(self) -> str: ... + def __eq__(self, other) -> bool: ... + def __ne__(self, other) -> bool: ... @classmethod - def zeros(cls, shape, domain) -> DDM: - ... - + def zeros(cls, shape, domain) -> DDM: ... @classmethod - def ones(cls, shape, domain) -> DDM: - ... - + def ones(cls, shape, domain) -> DDM: ... @classmethod - def eye(cls, size, domain) -> DDM: - ... - - def copy(self) -> DDM: - ... - - def transpose(self) -> DDM: - ... - - def __add__(a, b) -> NotImplementedType | DDM: - ... - - def __sub__(a, b) -> NotImplementedType | DDM: - ... - - def __neg__(a) -> DDM: - ... - - def __mul__(a, b) -> DDM | NotImplementedType: - ... - - def __rmul__(a, b) -> DDM | NotImplementedType: - ... - - def __matmul__(a, b) -> DDM | NotImplementedType: - ... - - def add(a, b) -> DDM: - ... - - def sub(a, b) -> DDM: - ... - - def neg(a) -> DDM: - ... - - def mul(a, b) -> DDM: - ... - - def rmul(a, b) -> DDM: - ... - - def matmul(a, b) -> DDM: - ... - - def mul_elementwise(a, b) -> DDM: - ... - - def hstack(A, *B) -> DDM: - ... - - def vstack(A, *B) -> DDM: - ... - - def applyfunc(self, func, domain) -> DDM: - ... - - def scc(a) -> list[Any]: - ... - - def rref(a) -> tuple[DDM, list[Any]]: - ... - - def nullspace(a) -> tuple[DDM, list[Any]]: - ... - - def particular(a) -> DDM: - ... - - def det(a): - ... - - def inv(a) -> DDM: - ... - - def lu(a) -> tuple[DDM, DDM, list[Any]]: - ... - - def lu_solve(a, b) -> DDM: - ... - - def charpoly(a) -> list[Any]: - ... - - def is_zero_matrix(self) -> bool: - ... - - def is_upper(self) -> bool: - ... - - def is_lower(self) -> bool: - ... - - def lll(A, delta=...): - ... - - def lll_transform(A, delta=...) -> tuple[Any, Any | None]: - ... - - - + def eye(cls, size, domain) -> DDM: ... + def copy(self) -> DDM: ... + def transpose(self) -> DDM: ... + def __add__(a, b) -> NotImplementedType | DDM: ... + def __sub__(a, b) -> NotImplementedType | DDM: ... + def __neg__(a) -> DDM: ... + def __mul__(a, b) -> DDM | NotImplementedType: ... + def __rmul__(a, b) -> DDM | NotImplementedType: ... + def __matmul__(a, b) -> DDM | NotImplementedType: ... + def add(a, b) -> DDM: ... + def sub(a, b) -> DDM: ... + def neg(a) -> DDM: ... + def mul(a, b) -> DDM: ... + def rmul(a, b) -> DDM: ... + def matmul(a, b) -> DDM: ... + def mul_elementwise(a, b) -> DDM: ... + def hstack(A, *B) -> DDM: ... + def vstack(A, *B) -> DDM: ... + def applyfunc(self, func, domain) -> DDM: ... + def scc(a) -> list[Any]: ... + def rref(a) -> tuple[DDM, list[Any]]: ... + def nullspace(a) -> tuple[DDM, list[Any]]: ... + def particular(a) -> DDM: ... + def det(a): ... + def inv(a) -> DDM: ... + def lu(a) -> tuple[DDM, DDM, list[Any]]: ... + def lu_solve(a, b) -> DDM: ... + def charpoly(a) -> list[Any]: ... + def is_zero_matrix(self) -> bool: ... + def is_upper(self) -> bool: ... + def is_lower(self) -> bool: ... + def lll(A, delta=...): ... + def lll_transform(A, delta=...) -> tuple[Any, Any | None]: ... diff --git a/stubs/sympy-stubs/polys/matrices/dense.pyi b/stubs/sympy-stubs/polys/matrices/dense.pyi index 8e181c75..ef574f46 100644 --- a/stubs/sympy-stubs/polys/matrices/dense.pyi +++ b/stubs/sympy-stubs/polys/matrices/dense.pyi @@ -2,47 +2,20 @@ from typing import Any, Sequence, TypeVar from sympy.polys.matrices._typing import RingElement -T = TypeVar('T') -R = TypeVar('R', bound=RingElement) -def ddm_transpose(matrix: Sequence[Sequence[T]]) -> list[list[T]]: - ... - -def ddm_iadd(a: list[list[R]], b: Sequence[Sequence[R]]) -> None: - ... - -def ddm_isub(a: list[list[R]], b: Sequence[Sequence[R]]) -> None: - ... - -def ddm_ineg(a: list[list[R]]) -> None: - ... - -def ddm_imul(a: list[list[R]], b: R) -> None: - ... - -def ddm_irmul(a: list[list[R]], b: R) -> None: - ... - -def ddm_imatmul(a: list[list[R]], b: Sequence[Sequence[R]], c: Sequence[Sequence[R]]) -> None: - ... - -def ddm_irref(a, _partial_pivot=...) -> list[Any]: - ... - -def ddm_idet(a, K): - ... - -def ddm_iinv(ainv, a, K) -> None: - ... - -def ddm_ilu_split(L, U, K) -> list[Any]: - ... - -def ddm_ilu(a) -> list[Any]: - ... - -def ddm_ilu_solve(x, L, U, swaps, b) -> None: - ... - -def ddm_berk(M, K) -> list[list[Any]]: - ... - +T = TypeVar("T") +R = TypeVar("R", bound=RingElement) + +def ddm_transpose(matrix: Sequence[Sequence[T]]) -> list[list[T]]: ... +def ddm_iadd(a: list[list[R]], b: Sequence[Sequence[R]]) -> None: ... +def ddm_isub(a: list[list[R]], b: Sequence[Sequence[R]]) -> None: ... +def ddm_ineg(a: list[list[R]]) -> None: ... +def ddm_imul(a: list[list[R]], b: R) -> None: ... +def ddm_irmul(a: list[list[R]], b: R) -> None: ... +def ddm_imatmul(a: list[list[R]], b: Sequence[Sequence[R]], c: Sequence[Sequence[R]]) -> None: ... +def ddm_irref(a, _partial_pivot=...) -> list[Any]: ... +def ddm_idet(a, K): ... +def ddm_iinv(ainv, a, K) -> None: ... +def ddm_ilu_split(L, U, K) -> list[Any]: ... +def ddm_ilu(a) -> list[Any]: ... +def ddm_ilu_solve(x, L, U, swaps, b) -> None: ... +def ddm_berk(M, K) -> list[list[Any]]: ... diff --git a/stubs/sympy-stubs/polys/matrices/domainmatrix.pyi b/stubs/sympy-stubs/polys/matrices/domainmatrix.pyi index c9d2192c..59122d1c 100644 --- a/stubs/sympy-stubs/polys/matrices/domainmatrix.pyi +++ b/stubs/sympy-stubs/polys/matrices/domainmatrix.pyi @@ -8,233 +8,92 @@ from sympy.polys.matrices.domainscalar import DomainScalar from sympy.polys.matrices.sdm import SDM from sympy.utilities.decorator import doctest_depends_on -def DM(rows, domain) -> DomainMatrix: - ... +def DM(rows, domain) -> DomainMatrix: ... class DomainMatrix: rep: tUnion[SDM, DDM] shape: tTuple[int, int] domain: Domain - def __new__(cls, rows, shape, domain, *, fmt=...) -> Self: - ... - - def __getnewargs__(self) -> tuple[list[Any] | dict[Any, Any], tTuple[int, int], Any]: - ... - - def __getitem__(self, key) -> DomainScalar | Self: - ... - - def getitem_sympy(self, i, j): - ... - - def extract(self, rowslist, colslist) -> Self: - ... - - def __setitem__(self, key, value) -> None: - ... - + def __new__(cls, rows, shape, domain, *, fmt=...) -> Self: ... + def __getnewargs__(self) -> tuple[list[Any] | dict[Any, Any], tTuple[int, int], Any]: ... + def __getitem__(self, key) -> DomainScalar | Self: ... + def getitem_sympy(self, i, j): ... + def extract(self, rowslist, colslist) -> Self: ... + def __setitem__(self, key, value) -> None: ... @classmethod - def from_rep(cls, rep) -> Self: - ... - + def from_rep(cls, rep) -> Self: ... @classmethod - def from_list(cls, rows, domain) -> DomainMatrix: - ... - + def from_list(cls, rows, domain) -> DomainMatrix: ... @classmethod - def from_list_sympy(cls, nrows, ncols, rows, **kwargs) -> DomainMatrix: - ... - + def from_list_sympy(cls, nrows, ncols, rows, **kwargs) -> DomainMatrix: ... @classmethod - def from_dict_sympy(cls, nrows, ncols, elemsdict, **kwargs) -> DomainMatrix: - ... - + def from_dict_sympy(cls, nrows, ncols, elemsdict, **kwargs) -> DomainMatrix: ... @classmethod - def from_Matrix(cls, M, fmt=..., **kwargs): - ... - + def from_Matrix(cls, M, fmt=..., **kwargs): ... @classmethod - def get_domain(cls, items_sympy, **kwargs) -> tuple[Any, Any]: - ... - - def copy(self) -> Self: - ... - - def convert_to(self, K) -> Self: - ... - - def to_sympy(self) -> Self: - ... - - def to_field(self) -> Self: - ... - - def to_sparse(self) -> Self: - ... - - def to_dense(self) -> Self: - ... - - def unify(self, *others, fmt=...) -> tuple[Any, ...]: - ... - - def to_Matrix(self) -> MutableDenseMatrix: - ... - - def to_list(self) -> list[Any]: - ... - - def to_list_flat(self) -> list[Any]: - ... - - def to_dok(self) -> dict[tuple[int, int], Any] | dict[tuple[Any, Any], Any]: - ... - - def __repr__(self) -> str: - ... - - def transpose(self) -> Self: - ... - - def flat(self) -> list[Any]: - ... - + def get_domain(cls, items_sympy, **kwargs) -> tuple[Any, Any]: ... + def copy(self) -> Self: ... + def convert_to(self, K) -> Self: ... + def to_sympy(self) -> Self: ... + def to_field(self) -> Self: ... + def to_sparse(self) -> Self: ... + def to_dense(self) -> Self: ... + def unify(self, *others, fmt=...) -> tuple[Any, ...]: ... + def to_Matrix(self) -> MutableDenseMatrix: ... + def to_list(self) -> list[Any]: ... + def to_list_flat(self) -> list[Any]: ... + def to_dok(self) -> dict[tuple[int, int], Any] | dict[tuple[Any, Any], Any]: ... + def __repr__(self) -> str: ... + def transpose(self) -> Self: ... + def flat(self) -> list[Any]: ... @property - def is_zero_matrix(self) -> bool: - ... - + def is_zero_matrix(self) -> bool: ... @property - def is_upper(self) -> bool: - ... - + def is_upper(self) -> bool: ... @property - def is_lower(self) -> bool: - ... - + def is_lower(self) -> bool: ... @property - def is_square(self) -> bool: - ... - - def rank(self) -> int: - ... - - def hstack(A, *B) -> DomainMatrix: - ... - - def vstack(A, *B) -> DomainMatrix: - ... - - def applyfunc(self, func, domain=...) -> Self: - ... - - def __add__(A, B) -> NotImplementedType: - ... - - def __sub__(A, B) -> NotImplementedType: - ... - - def __neg__(A) -> Self: - ... - - def __mul__(A, B) -> DomainMatrix | Self | NotImplementedType: - ... - - def __rmul__(A, B) -> DomainMatrix | Self | NotImplementedType: - ... - - def __pow__(A, n) -> NotImplementedType | Self: - ... - - def add(A, B) -> Self: - ... - - def sub(A, B) -> Self: - ... - - def neg(A) -> Self: - ... - - def mul(A, b) -> Self: - ... - - def rmul(A, b) -> Self: - ... - - def matmul(A, B) -> Self: - ... - - def scalarmul(A, lamda) -> DomainMatrix | Self: - ... - - def rscalarmul(A, lamda) -> DomainMatrix | Self: - ... - - def mul_elementwise(A, B) -> Self: - ... - - def __truediv__(A, lamda) -> NotImplementedType: - ... - - def pow(A, n) -> Self: - ... - - def scc(self) -> list[Any]: - ... - - def rref(self) -> tuple[Self, tuple[Any, ...]]: - ... - - def columnspace(self) -> Self: - ... - - def rowspace(self) -> Self: - ... - - def nullspace(self) -> Self: - ... - - def inv(self) -> Self: - ... - - def det(self): - ... - - def lu(self) -> tuple[Self, Self, list[Any]]: - ... - - def lu_solve(self, rhs) -> Self: - ... - - def charpoly(self) -> list[Any]: - ... - + def is_square(self) -> bool: ... + def rank(self) -> int: ... + def hstack(A, *B) -> DomainMatrix: ... + def vstack(A, *B) -> DomainMatrix: ... + def applyfunc(self, func, domain=...) -> Self: ... + def __add__(A, B) -> NotImplementedType: ... + def __sub__(A, B) -> NotImplementedType: ... + def __neg__(A) -> Self: ... + def __mul__(A, B) -> DomainMatrix | Self | NotImplementedType: ... + def __rmul__(A, B) -> DomainMatrix | Self | NotImplementedType: ... + def __pow__(A, n) -> NotImplementedType | Self: ... + def add(A, B) -> Self: ... + def sub(A, B) -> Self: ... + def neg(A) -> Self: ... + def mul(A, b) -> Self: ... + def rmul(A, b) -> Self: ... + def matmul(A, B) -> Self: ... + def scalarmul(A, lamda) -> DomainMatrix | Self: ... + def rscalarmul(A, lamda) -> DomainMatrix | Self: ... + def mul_elementwise(A, B) -> Self: ... + def __truediv__(A, lamda) -> NotImplementedType: ... + def pow(A, n) -> Self: ... + def scc(self) -> list[Any]: ... + def rref(self) -> tuple[Self, tuple[Any, ...]]: ... + def columnspace(self) -> Self: ... + def rowspace(self) -> Self: ... + def nullspace(self) -> Self: ... + def inv(self) -> Self: ... + def det(self): ... + def lu(self) -> tuple[Self, Self, list[Any]]: ... + def lu_solve(self, rhs) -> Self: ... + def charpoly(self) -> list[Any]: ... @classmethod - def eye(cls, shape, domain) -> Self: - ... - + def eye(cls, shape, domain) -> Self: ... @classmethod - def diag(cls, diagonal, domain, shape=...) -> Self: - ... - + def diag(cls, diagonal, domain, shape=...) -> Self: ... @classmethod - def zeros(cls, shape, domain, *, fmt=...) -> Self: - ... - + def zeros(cls, shape, domain, *, fmt=...) -> Self: ... @classmethod - def ones(cls, shape, domain) -> Self: - ... - - def __eq__(A, B) -> bool: - ... - - def unify_eq(A, B) -> Literal[False]: - ... - - def lll(A, delta=...) -> DomainMatrix: - ... - - def lll_transform(A, delta=...) -> tuple[DomainMatrix, DomainMatrix]: - ... - - - + def ones(cls, shape, domain) -> Self: ... + def __eq__(A, B) -> bool: ... + def unify_eq(A, B) -> Literal[False]: ... + def lll(A, delta=...) -> DomainMatrix: ... + def lll_transform(A, delta=...) -> tuple[DomainMatrix, DomainMatrix]: ... diff --git a/stubs/sympy-stubs/polys/matrices/domainscalar.pyi b/stubs/sympy-stubs/polys/matrices/domainscalar.pyi index d6ba687d..1468e3bb 100644 --- a/stubs/sympy-stubs/polys/matrices/domainscalar.pyi +++ b/stubs/sympy-stubs/polys/matrices/domainscalar.pyi @@ -2,64 +2,24 @@ from types import NotImplementedType from typing import Any, Self class DomainScalar: - def __new__(cls, element, domain) -> Self: - ... - + def __new__(cls, element, domain) -> Self: ... @classmethod - def new(cls, element, domain) -> Self: - ... - - def __repr__(self) -> str: - ... - + def new(cls, element, domain) -> Self: ... + def __repr__(self) -> str: ... @classmethod - def from_sympy(cls, expr) -> Self: - ... - - def to_sympy(self): - ... - - def to_domain(self, domain) -> Self: - ... - - def convert_to(self, domain) -> Self: - ... - - def unify(self, other) -> tuple[Self, Any]: - ... - - def __add__(self, other) -> NotImplementedType | Self: - ... - - def __sub__(self, other) -> NotImplementedType | Self: - ... - - def __mul__(self, other) -> NotImplementedType | Self: - ... - - def __floordiv__(self, other) -> NotImplementedType | Self: - ... - - def __mod__(self, other) -> NotImplementedType | Self: - ... - - def __divmod__(self, other) -> NotImplementedType | tuple[Self, Self]: - ... - - def __pow__(self, n) -> NotImplementedType | Self: - ... - - def __pos__(self) -> Self: - ... - - def __eq__(self, other) -> bool: - ... - - def is_zero(self): - ... - - def is_one(self): - ... - - - + def from_sympy(cls, expr) -> Self: ... + def to_sympy(self): ... + def to_domain(self, domain) -> Self: ... + def convert_to(self, domain) -> Self: ... + def unify(self, other) -> tuple[Self, Any]: ... + def __add__(self, other) -> NotImplementedType | Self: ... + def __sub__(self, other) -> NotImplementedType | Self: ... + def __mul__(self, other) -> NotImplementedType | Self: ... + def __floordiv__(self, other) -> NotImplementedType | Self: ... + def __mod__(self, other) -> NotImplementedType | Self: ... + def __divmod__(self, other) -> NotImplementedType | tuple[Self, Self]: ... + def __pow__(self, n) -> NotImplementedType | Self: ... + def __pos__(self) -> Self: ... + def __eq__(self, other) -> bool: ... + def is_zero(self): ... + def is_one(self): ... diff --git a/stubs/sympy-stubs/polys/matrices/eigen.pyi b/stubs/sympy-stubs/polys/matrices/eigen.pyi index 59099373..92d52a40 100644 --- a/stubs/sympy-stubs/polys/matrices/eigen.pyi +++ b/stubs/sympy-stubs/polys/matrices/eigen.pyi @@ -1,8 +1,4 @@ from typing import Any -def dom_eigenvects(A, l=...) -> tuple[list[Any], list[Any]]: - ... - -def dom_eigenvects_to_sympy(rational_eigenvects, algebraic_eigenvects, Matrix, **kwargs) -> list[Any]: - ... - +def dom_eigenvects(A, l=...) -> tuple[list[Any], list[Any]]: ... +def dom_eigenvects_to_sympy(rational_eigenvects, algebraic_eigenvects, Matrix, **kwargs) -> list[Any]: ... diff --git a/stubs/sympy-stubs/polys/matrices/linsolve.pyi b/stubs/sympy-stubs/polys/matrices/linsolve.pyi index 550d1474..3842193e 100644 --- a/stubs/sympy-stubs/polys/matrices/linsolve.pyi +++ b/stubs/sympy-stubs/polys/matrices/linsolve.pyi @@ -1,5 +1,3 @@ from sympy.polys.matrices.sdm import SDM -def sympy_dict_to_dm(eqs_coeffs, eqs_rhs, syms) -> SDM: - ... - +def sympy_dict_to_dm(eqs_coeffs, eqs_rhs, syms) -> SDM: ... diff --git a/stubs/sympy-stubs/polys/matrices/lll.pyi b/stubs/sympy-stubs/polys/matrices/lll.pyi index 5372c57d..188560b2 100644 --- a/stubs/sympy-stubs/polys/matrices/lll.pyi +++ b/stubs/sympy-stubs/polys/matrices/lll.pyi @@ -1,8 +1,4 @@ from typing import Any -def ddm_lll(x, delta=...): - ... - -def ddm_lll_transform(x, delta=...) -> tuple[Any, Any | None]: - ... - +def ddm_lll(x, delta=...): ... +def ddm_lll_transform(x, delta=...) -> tuple[Any, Any | None]: ... diff --git a/stubs/sympy-stubs/polys/matrices/normalforms.pyi b/stubs/sympy-stubs/polys/matrices/normalforms.pyi index ba812814..777cc5d6 100644 --- a/stubs/sympy-stubs/polys/matrices/normalforms.pyi +++ b/stubs/sympy-stubs/polys/matrices/normalforms.pyi @@ -3,15 +3,7 @@ from typing import Any from sympy.polys.matrices.domainmatrix import DomainMatrix from sympy.polys.matrices.domainscalar import DomainScalar -def smith_normal_form(m) -> DomainMatrix: - ... - -def add_columns(m, i, j, a, b, c, d) -> None: - ... - -def invariant_factors(m) -> tuple[()] | tuple[Any, ...]: - ... - -def hermite_normal_form(A, *, D=..., check_rank=...) -> DomainMatrix | DomainScalar: - ... - +def smith_normal_form(m) -> DomainMatrix: ... +def add_columns(m, i, j, a, b, c, d) -> None: ... +def invariant_factors(m) -> tuple[()] | tuple[Any, ...]: ... +def hermite_normal_form(A, *, D=..., check_rank=...) -> DomainMatrix | DomainScalar: ... diff --git a/stubs/sympy-stubs/polys/matrices/sdm.pyi b/stubs/sympy-stubs/polys/matrices/sdm.pyi index 16d81f48..5ed6cfb2 100644 --- a/stubs/sympy-stubs/polys/matrices/sdm.pyi +++ b/stubs/sympy-stubs/polys/matrices/sdm.pyi @@ -6,189 +6,70 @@ from sympy.utilities.decorator import doctest_depends_on class SDM(dict): fmt = ... - def __init__(self, elemsdict, shape, domain) -> None: - ... - - def getitem(self, i, j): - ... - - def setitem(self, i, j, value) -> None: - ... - - def extract_slice(self, slice1, slice2) -> Self: - ... - - def extract(self, rows, cols) -> Self: - ... - - def __str__(self) -> str: - ... - - def __repr__(self) -> str: - ... - + def __init__(self, elemsdict, shape, domain) -> None: ... + def getitem(self, i, j): ... + def setitem(self, i, j, value) -> None: ... + def extract_slice(self, slice1, slice2) -> Self: ... + def extract(self, rows, cols) -> Self: ... + def __str__(self) -> str: ... + def __repr__(self) -> str: ... @classmethod - def new(cls, sdm, shape, domain) -> Self: - ... - - def copy(A) -> Self: - ... - + def new(cls, sdm, shape, domain) -> Self: ... + def copy(A) -> Self: ... @classmethod - def from_list(cls, ddm, shape, domain) -> Self: - ... - + def from_list(cls, ddm, shape, domain) -> Self: ... @classmethod - def from_ddm(cls, ddm) -> Self: - ... - - def to_list(M) -> list[Any]: - ... - - def to_list_flat(M): - ... - - def to_dok(M) -> dict[tuple[Any, Any], Any]: - ... - - def to_ddm(M) -> DDM: - ... - - def to_sdm(M) -> Self: - ... - + def from_ddm(cls, ddm) -> Self: ... + def to_list(M) -> list[Any]: ... + def to_list_flat(M): ... + def to_dok(M) -> dict[tuple[Any, Any], Any]: ... + def to_ddm(M) -> DDM: ... + def to_sdm(M) -> Self: ... @classmethod - def zeros(cls, shape, domain) -> Self: - ... - + def zeros(cls, shape, domain) -> Self: ... @classmethod - def ones(cls, shape, domain) -> Self: - ... - + def ones(cls, shape, domain) -> Self: ... @classmethod - def eye(cls, shape, domain) -> Self: - ... - + def eye(cls, shape, domain) -> Self: ... @classmethod - def diag(cls, diagonal, domain, shape) -> Self: - ... - - def transpose(M) -> Self: - ... - - def __add__(A, B) -> NotImplementedType | Self: - ... - - def __sub__(A, B) -> NotImplementedType | Self: - ... - - def __neg__(A) -> Self: - ... - - def __mul__(A, B) -> Self | NotImplementedType: - ... - - def __rmul__(a, b) -> Self | NotImplementedType: - ... - - def matmul(A, B) -> Self: - ... - - def mul(A, b) -> Self: - ... - - def rmul(A, b) -> Self: - ... - - def mul_elementwise(A, B) -> Self: - ... - - def add(A, B) -> Self: - ... - - def sub(A, B) -> Self: - ... - - def neg(A) -> Self: - ... - - def convert_to(A, K) -> Self: - ... - - def scc(A) -> list[Any]: - ... - - def rref(A) -> tuple[Self, list[Any]]: - ... - - def inv(A) -> Self: - ... - - def det(A): - ... - - def lu(A) -> tuple[Self, Self, list[Any]]: - ... - - def lu_solve(A, b) -> Self: - ... - - def nullspace(A) -> tuple[Self, list[int]]: - ... - - def particular(A) -> Self: - ... - - def hstack(A, *B) -> Self: - ... - - def vstack(A, *B) -> Self: - ... - - def applyfunc(self, func, domain) -> Self: - ... - - def charpoly(A) -> list[Any]: - ... - - def is_zero_matrix(self) -> bool: - ... - - def is_upper(self) -> bool: - ... - - def is_lower(self) -> bool: - ... - - def lll(A, delta=...) -> Self: - ... - - def lll_transform(A, delta=...) -> tuple[Self, Self]: - ... - - - -def binop_dict(A, B, fab, fa, fb) -> dict[Any, Any]: - ... - -def unop_dict(A, f) -> dict[Any, Any]: - ... - -def sdm_transpose(M) -> dict[Any, Any]: - ... - -def sdm_matmul(A, B, K, m, o) -> dict[Any, Any]: - ... - -def sdm_matmul_exraw(A, B, K, m, o) -> dict[Any, Any]: - ... - -def sdm_irref(A) -> tuple[dict[int, Any], list[Any], dict[Any, set[int]]]: - ... - -def sdm_nullspace_from_rref(A, one, ncols, pivots, nonzero_cols) -> tuple[list[Any], list[int]]: - ... - -def sdm_particular_from_rref(A, ncols, pivots) -> dict[Any, Any]: - ... + def diag(cls, diagonal, domain, shape) -> Self: ... + def transpose(M) -> Self: ... + def __add__(A, B) -> NotImplementedType | Self: ... + def __sub__(A, B) -> NotImplementedType | Self: ... + def __neg__(A) -> Self: ... + def __mul__(A, B) -> Self | NotImplementedType: ... + def __rmul__(a, b) -> Self | NotImplementedType: ... + def matmul(A, B) -> Self: ... + def mul(A, b) -> Self: ... + def rmul(A, b) -> Self: ... + def mul_elementwise(A, B) -> Self: ... + def add(A, B) -> Self: ... + def sub(A, B) -> Self: ... + def neg(A) -> Self: ... + def convert_to(A, K) -> Self: ... + def scc(A) -> list[Any]: ... + def rref(A) -> tuple[Self, list[Any]]: ... + def inv(A) -> Self: ... + def det(A): ... + def lu(A) -> tuple[Self, Self, list[Any]]: ... + def lu_solve(A, b) -> Self: ... + def nullspace(A) -> tuple[Self, list[int]]: ... + def particular(A) -> Self: ... + def hstack(A, *B) -> Self: ... + def vstack(A, *B) -> Self: ... + def applyfunc(self, func, domain) -> Self: ... + def charpoly(A) -> list[Any]: ... + def is_zero_matrix(self) -> bool: ... + def is_upper(self) -> bool: ... + def is_lower(self) -> bool: ... + def lll(A, delta=...) -> Self: ... + def lll_transform(A, delta=...) -> tuple[Self, Self]: ... +def binop_dict(A, B, fab, fa, fb) -> dict[Any, Any]: ... +def unop_dict(A, f) -> dict[Any, Any]: ... +def sdm_transpose(M) -> dict[Any, Any]: ... +def sdm_matmul(A, B, K, m, o) -> dict[Any, Any]: ... +def sdm_matmul_exraw(A, B, K, m, o) -> dict[Any, Any]: ... +def sdm_irref(A) -> tuple[dict[int, Any], list[Any], dict[Any, set[int]]]: ... +def sdm_nullspace_from_rref(A, one, ncols, pivots, nonzero_cols) -> tuple[list[Any], list[int]]: ... +def sdm_particular_from_rref(A, ncols, pivots) -> dict[Any, Any]: ... diff --git a/stubs/sympy-stubs/polys/monomials.pyi b/stubs/sympy-stubs/polys/monomials.pyi index 7656a53c..531ae9fe 100644 --- a/stubs/sympy-stubs/polys/monomials.pyi +++ b/stubs/sympy-stubs/polys/monomials.pyi @@ -5,120 +5,47 @@ from sympy.series.order import Order from sympy.utilities import public @public -def itermonomials(variables, max_degrees, min_degrees=...) -> Generator[Any | Order, Any, None]: - ... - -def monomial_count(V, N): - ... - -def monomial_mul(A, B) -> tuple[Any, ...]: - ... - -def monomial_div(A, B) -> tuple[Any, ...] | None: - ... - -def monomial_ldiv(A, B) -> tuple[Any, ...]: - ... - -def monomial_pow(A, n) -> tuple[Any, ...]: - ... - -def monomial_gcd(A, B) -> tuple[Any, ...]: - ... - -def monomial_lcm(A, B) -> tuple[Any, ...]: - ... - -def monomial_divides(A, B) -> bool: - ... - -def monomial_max(*monoms) -> tuple[Any, ...]: - ... - -def monomial_min(*monoms) -> tuple[Any, ...]: - ... - -def monomial_deg(M) -> int: - ... - -def term_div(a, b, domain) -> tuple[tuple[Any, ...], Any] | None: - ... +def itermonomials(variables, max_degrees, min_degrees=...) -> Generator[Any | Order, Any, None]: ... +def monomial_count(V, N): ... +def monomial_mul(A, B) -> tuple[Any, ...]: ... +def monomial_div(A, B) -> tuple[Any, ...] | None: ... +def monomial_ldiv(A, B) -> tuple[Any, ...]: ... +def monomial_pow(A, n) -> tuple[Any, ...]: ... +def monomial_gcd(A, B) -> tuple[Any, ...]: ... +def monomial_lcm(A, B) -> tuple[Any, ...]: ... +def monomial_divides(A, B) -> bool: ... +def monomial_max(*monoms) -> tuple[Any, ...]: ... +def monomial_min(*monoms) -> tuple[Any, ...]: ... +def monomial_deg(M) -> int: ... +def term_div(a, b, domain) -> tuple[tuple[Any, ...], Any] | None: ... class MonomialOps: - def __init__(self, ngens) -> None: - ... - - def mul(self): - ... - - def pow(self): - ... - - def mulpow(self): - ... - - def ldiv(self): - ... - - def div(self): - ... - - def lcm(self): - ... - - def gcd(self): - ... - - + def __init__(self, ngens) -> None: ... + def mul(self): ... + def pow(self): ... + def mulpow(self): ... + def ldiv(self): ... + def div(self): ... + def lcm(self): ... + def gcd(self): ... @public class Monomial(PicklableWithSlots): __slots__ = ... - def __init__(self, monom, gens=...) -> None: - ... - - def rebuild(self, exponents, gens=...) -> Self: - ... - - def __len__(self) -> int: - ... - - def __iter__(self) -> Iterator[int]: - ... - - def __getitem__(self, item): - ... - - def __hash__(self) -> int: - ... - - def __str__(self) -> str: - ... - - def as_expr(self, *gens) -> Order: - ... - - def __eq__(self, other) -> bool: - ... - - def __ne__(self, other) -> bool: - ... - - def __mul__(self, other) -> Self: - ... - - def __truediv__(self, other) -> Self: - ... - - __floordiv__ = ... - def __pow__(self, other) -> Self: - ... - - def gcd(self, other) -> Self: - ... - - def lcm(self, other) -> Self: - ... - - + def __init__(self, monom, gens=...) -> None: ... + def rebuild(self, exponents, gens=...) -> Self: ... + def __len__(self) -> int: ... + def __iter__(self) -> Iterator[int]: ... + def __getitem__(self, item): ... + def __hash__(self) -> int: ... + def __str__(self) -> str: ... + def as_expr(self, *gens) -> Order: ... + def __eq__(self, other) -> bool: ... + def __ne__(self, other) -> bool: ... + def __mul__(self, other) -> Self: ... + def __truediv__(self, other) -> Self: ... + __floordiv__ = ... + def __pow__(self, other) -> Self: ... + def gcd(self, other) -> Self: ... + def lcm(self, other) -> Self: ... diff --git a/stubs/sympy-stubs/polys/numberfields/__init__.pyi b/stubs/sympy-stubs/polys/numberfields/__init__.pyi index 3a910f73..3ac89d6d 100644 --- a/stubs/sympy-stubs/polys/numberfields/__init__.pyi +++ b/stubs/sympy-stubs/polys/numberfields/__init__.pyi @@ -5,4 +5,15 @@ from sympy.polys.numberfields.primes import prime_decomp, prime_valuation from sympy.polys.numberfields.subfield import field_isomorphism, primitive_element, to_number_field from sympy.polys.numberfields.utilities import isolate -__all__ = ['minpoly', 'minimal_polynomial', 'field_isomorphism', 'primitive_element', 'to_number_field', 'isolate', 'round_two', 'prime_decomp', 'prime_valuation', 'galois_group'] +__all__ = [ + "minpoly", + "minimal_polynomial", + "field_isomorphism", + "primitive_element", + "to_number_field", + "isolate", + "round_two", + "prime_decomp", + "prime_valuation", + "galois_group", +] diff --git a/stubs/sympy-stubs/polys/numberfields/basis.pyi b/stubs/sympy-stubs/polys/numberfields/basis.pyi index 0924510c..eef98ea3 100644 --- a/stubs/sympy-stubs/polys/numberfields/basis.pyi +++ b/stubs/sympy-stubs/polys/numberfields/basis.pyi @@ -3,10 +3,6 @@ from typing import Any from sympy.polys.numberfields.modules import Submodule from sympy.utilities.decorator import public -def nilradical_mod_p(H, p, q=...): - ... - +def nilradical_mod_p(H, p, q=...): ... @public -def round_two(T, radicals=...) -> tuple[Submodule | Any, Any]: - ... - +def round_two(T, radicals=...) -> tuple[Submodule | Any, Any]: ... diff --git a/stubs/sympy-stubs/polys/numberfields/galois_resolvents.pyi b/stubs/sympy-stubs/polys/numberfields/galois_resolvents.pyi index 33ab240b..ed565c57 100644 --- a/stubs/sympy-stubs/polys/numberfields/galois_resolvents.pyi +++ b/stubs/sympy-stubs/polys/numberfields/galois_resolvents.pyi @@ -1,52 +1,30 @@ from typing import Any, Literal, LiteralString -class GaloisGroupException(Exception): - ... - - -class ResolventException(GaloisGroupException): - ... - +class GaloisGroupException(Exception): ... +class ResolventException(GaloisGroupException): ... class Resolvent: - def __init__(self, F, X, s) -> None: - ... - - def get_prec(self, M, target=...) -> int | Any: - ... - - def approximate_roots_of_poly(self, T, target=...) -> list[Any]: - ... - + def __init__(self, F, X, s) -> None: ... + def get_prec(self, M, target=...) -> int | Any: ... + def approximate_roots_of_poly(self, T, target=...) -> list[Any]: ... @staticmethod - def round_mpf(a) -> int | Any: - ... - - def round_roots_to_integers_for_poly(self, T) -> dict[int, int | Any]: - ... - - def eval_for_poly(self, T, find_integer_root=...) -> tuple[list[Any], int | Any | None, int | None]: - ... - - - -def wrap(text, width=...) -> LiteralString | Literal['']: - ... - -def s_vars(n) -> Any: - ... - -def sparse_symmetrize_resolvent_coeffs(F, X, s, verbose=...) -> tuple[list[Any], list[Any]]: - ... - -def define_resolvents() -> dict[tuple[Literal[4], Literal[0]] | tuple[Literal[4], Literal[1]] | tuple[Literal[5], Literal[1]] | tuple[Literal[6], Literal[1]] | tuple[Literal[6], Literal[2]], Any]: - ... - -def generate_lambda_lookup(verbose=..., trial_run=...) -> str: - ... - -def get_resolvent_by_lookup(T, number) -> list[Any]: - ... + def round_mpf(a) -> int | Any: ... + def round_roots_to_integers_for_poly(self, T) -> dict[int, int | Any]: ... + def eval_for_poly(self, T, find_integer_root=...) -> tuple[list[Any], int | Any | None, int | None]: ... + +def wrap(text, width=...) -> LiteralString | Literal[""]: ... +def s_vars(n) -> Any: ... +def sparse_symmetrize_resolvent_coeffs(F, X, s, verbose=...) -> tuple[list[Any], list[Any]]: ... +def define_resolvents() -> dict[ + tuple[Literal[4], Literal[0]] + | tuple[Literal[4], Literal[1]] + | tuple[Literal[5], Literal[1]] + | tuple[Literal[6], Literal[1]] + | tuple[Literal[6], Literal[2]], + Any, +]: ... +def generate_lambda_lookup(verbose=..., trial_run=...) -> str: ... +def get_resolvent_by_lookup(T, number) -> list[Any]: ... if __name__ == "__main__": verbose = ... diff --git a/stubs/sympy-stubs/polys/numberfields/galoisgroups.pyi b/stubs/sympy-stubs/polys/numberfields/galoisgroups.pyi index 24c27edb..4fa64335 100644 --- a/stubs/sympy-stubs/polys/numberfields/galoisgroups.pyi +++ b/stubs/sympy-stubs/polys/numberfields/galoisgroups.pyi @@ -3,17 +3,9 @@ from typing import Any from sympy.polys.numberfields.galois_resolvents import GaloisGroupException from sympy.utilities import public -class MaxTriesException(GaloisGroupException): - ... - - -def tschirnhausen_transformation(T, max_coeff=..., max_tries=..., history=..., fixed_order=...) -> tuple[Any, Any]: - ... - -def has_square_disc(T) -> bool: - ... +class MaxTriesException(GaloisGroupException): ... +def tschirnhausen_transformation(T, max_coeff=..., max_tries=..., history=..., fixed_order=...) -> tuple[Any, Any]: ... +def has_square_disc(T) -> bool: ... @public -def galois_group(f, *gens, by_name=..., max_tries=..., randomize=..., **args) -> Any: - ... - +def galois_group(f, *gens, by_name=..., max_tries=..., randomize=..., **args) -> Any: ... diff --git a/stubs/sympy-stubs/polys/numberfields/minpoly.pyi b/stubs/sympy-stubs/polys/numberfields/minpoly.pyi index 24104ae2..32fb6137 100644 --- a/stubs/sympy-stubs/polys/numberfields/minpoly.pyi +++ b/stubs/sympy-stubs/polys/numberfields/minpoly.pyi @@ -3,10 +3,6 @@ from typing import Any from sympy.utilities import public @public -def minimal_polynomial(ex, x=..., compose=..., polys=..., domain=...) -> Any: - ... - +def minimal_polynomial(ex, x=..., compose=..., polys=..., domain=...) -> Any: ... @public -def minpoly(ex, x=..., compose=..., polys=..., domain=...) -> Any: - ... - +def minpoly(ex, x=..., compose=..., polys=..., domain=...) -> Any: ... diff --git a/stubs/sympy-stubs/polys/numberfields/modules.pyi b/stubs/sympy-stubs/polys/numberfields/modules.pyi index 482a7a13..8170fa4b 100644 --- a/stubs/sympy-stubs/polys/numberfields/modules.pyi +++ b/stubs/sympy-stubs/polys/numberfields/modules.pyi @@ -5,367 +5,154 @@ from sympy.polys.matrices.domainmatrix import DomainMatrix from sympy.polys.polyclasses import ANP from sympy.polys.polyutils import IntegerPowerable -def to_col(coeffs) -> DomainMatrix: - ... +def to_col(coeffs) -> DomainMatrix: ... class Module: @property - def n(self): - ... - - def mult_tab(self): - ... - - @property - def parent(self) -> None: - ... - - def represent(self, elt): - ... - - def ancestors(self, include_self=...) -> list[Any]: - ... - - def power_basis_ancestor(self) -> PowerBasis | None: - ... - - def nearest_common_ancestor(self, other) -> None: - ... - - @property - def number_field(self) -> Any | None: - ... - - def is_compat_col(self, col) -> Literal[False]: - ... - - def __call__(self, spec, denom=...) -> PowerBasisElement | ModuleElement: - ... - - def starts_with_unity(self): - ... - - def basis_elements(self) -> list[PowerBasisElement | ModuleElement]: - ... - - def zero(self) -> PowerBasisElement | NotImplementedType | ModuleElement: - ... - - def one(self): - ... - - def element_from_rational(self, a): - ... - - def submodule_from_gens(self, gens, hnf=..., hnf_modulus=...) -> Submodule: - ... - - def submodule_from_matrix(self, B, denom=...) -> Submodule: - ... - - def whole_submodule(self) -> Submodule: - ... - - def endomorphism_ring(self) -> EndomorphismRing: - ... - - + def n(self): ... + def mult_tab(self): ... + @property + def parent(self) -> None: ... + def represent(self, elt): ... + def ancestors(self, include_self=...) -> list[Any]: ... + def power_basis_ancestor(self) -> PowerBasis | None: ... + def nearest_common_ancestor(self, other) -> None: ... + @property + def number_field(self) -> Any | None: ... + def is_compat_col(self, col) -> Literal[False]: ... + def __call__(self, spec, denom=...) -> PowerBasisElement | ModuleElement: ... + def starts_with_unity(self): ... + def basis_elements(self) -> list[PowerBasisElement | ModuleElement]: ... + def zero(self) -> PowerBasisElement | NotImplementedType | ModuleElement: ... + def one(self): ... + def element_from_rational(self, a): ... + def submodule_from_gens(self, gens, hnf=..., hnf_modulus=...) -> Submodule: ... + def submodule_from_matrix(self, B, denom=...) -> Submodule: ... + def whole_submodule(self) -> Submodule: ... + def endomorphism_ring(self) -> EndomorphismRing: ... class PowerBasis(Module): - def __init__(self, T) -> None: - ... - - @property - def number_field(self) -> Any | None: - ... - - def __repr__(self) -> str: - ... - - def __eq__(self, other) -> bool: - ... - - @property - def n(self): - ... - - def mult_tab(self) -> dict[Any, Any] | None: - ... - - def compute_mult_tab(self) -> None: - ... - - def represent(self, elt): - ... - - def starts_with_unity(self) -> Literal[True]: - ... - - def element_from_rational(self, a): - ... - - def element_from_poly(self, f) -> PowerBasisElement | NotImplementedType | ModuleElement: - ... - - def element_from_ANP(self, a) -> PowerBasisElement | NotImplementedType | ModuleElement: - ... - - def element_from_alg_num(self, a) -> PowerBasisElement | NotImplementedType | ModuleElement: - ... - - + def __init__(self, T) -> None: ... + @property + def number_field(self) -> Any | None: ... + def __repr__(self) -> str: ... + def __eq__(self, other) -> bool: ... + @property + def n(self): ... + def mult_tab(self) -> dict[Any, Any] | None: ... + def compute_mult_tab(self) -> None: ... + def represent(self, elt): ... + def starts_with_unity(self) -> Literal[True]: ... + def element_from_rational(self, a): ... + def element_from_poly(self, f) -> PowerBasisElement | NotImplementedType | ModuleElement: ... + def element_from_ANP(self, a) -> PowerBasisElement | NotImplementedType | ModuleElement: ... + def element_from_alg_num(self, a) -> PowerBasisElement | NotImplementedType | ModuleElement: ... class Submodule(Module, IntegerPowerable): - def __init__(self, parent, matrix, denom=..., mult_tab=...) -> None: - ... - - def __repr__(self) -> str: - ... - - def reduced(self) -> Self: - ... - - def discard_before(self, r) -> Submodule: - ... - + def __init__(self, parent, matrix, denom=..., mult_tab=...) -> None: ... + def __repr__(self) -> str: ... + def reduced(self) -> Self: ... + def discard_before(self, r) -> Submodule: ... @property - def n(self): - ... - - def mult_tab(self) -> dict[Any, Any] | None: - ... - - def compute_mult_tab(self) -> None: - ... - + def n(self): ... + def mult_tab(self) -> dict[Any, Any] | None: ... + def compute_mult_tab(self) -> None: ... @property - def parent(self) -> Any: - ... - + def parent(self) -> Any: ... @property - def matrix(self) -> Any: - ... - + def matrix(self) -> Any: ... @property - def coeffs(self): - ... - + def coeffs(self): ... @property - def denom(self) -> int: - ... - + def denom(self) -> int: ... @property - def QQ_matrix(self): - ... - - def starts_with_unity(self) -> bool: - ... - - def is_sq_maxrank_HNF(self) -> bool: - ... - - def is_power_basis_submodule(self) -> bool: - ... - - def element_from_rational(self, a): - ... - - def basis_element_pullbacks(self) -> list[PowerBasisElement | ModuleElement]: - ... - - def represent(self, elt): - ... - - def is_compat_submodule(self, other) -> Literal[False]: - ... - - def __eq__(self, other) -> bool: - ... - - def add(self, other, hnf=..., hnf_modulus=...): - ... - - def __add__(self, other) -> NotImplementedType: - ... - - __radd__ = ... - def mul(self, other, hnf=..., hnf_modulus=...) -> Self | Submodule | NotImplementedType: - ... - - def __mul__(self, other) -> Self | Submodule | NotImplementedType: - ... - - __rmul__ = ... - def reduce_element(self, elt): - ... - + def QQ_matrix(self): ... + def starts_with_unity(self) -> bool: ... + def is_sq_maxrank_HNF(self) -> bool: ... + def is_power_basis_submodule(self) -> bool: ... + def element_from_rational(self, a): ... + def basis_element_pullbacks(self) -> list[PowerBasisElement | ModuleElement]: ... + def represent(self, elt): ... + def is_compat_submodule(self, other) -> Literal[False]: ... + def __eq__(self, other) -> bool: ... + def add(self, other, hnf=..., hnf_modulus=...): ... + def __add__(self, other) -> NotImplementedType: ... + __radd__ = ... + def mul(self, other, hnf=..., hnf_modulus=...) -> Self | Submodule | NotImplementedType: ... + def __mul__(self, other) -> Self | Submodule | NotImplementedType: ... -def is_sq_maxrank_HNF(dm) -> bool: - ... + __rmul__ = ... + def reduce_element(self, elt): ... -def make_mod_elt(module, col, denom=...) -> PowerBasisElement | ModuleElement: - ... +def is_sq_maxrank_HNF(dm) -> bool: ... +def make_mod_elt(module, col, denom=...) -> PowerBasisElement | ModuleElement: ... class ModuleElement(IntegerPowerable): - def __init__(self, module, col, denom=...) -> None: - ... - - def __repr__(self) -> str: - ... - - def reduced(self) -> Self: - ... - - def reduced_mod_p(self, p) -> PowerBasisElement | ModuleElement: - ... - + def __init__(self, module, col, denom=...) -> None: ... + def __repr__(self) -> str: ... + def reduced(self) -> Self: ... + def reduced_mod_p(self, p) -> PowerBasisElement | ModuleElement: ... @classmethod - def from_int_list(cls, module, coeffs, denom=...) -> Self: - ... - + def from_int_list(cls, module, coeffs, denom=...) -> Self: ... @property - def n(self): - ... - - def __len__(self): - ... - - def column(self, domain=...): - ... - + def n(self): ... + def __len__(self): ... + def column(self, domain=...): ... @property - def coeffs(self): - ... - + def coeffs(self): ... @property - def QQ_col(self): - ... - - def to_parent(self) -> PowerBasisElement | ModuleElement: - ... - - def to_ancestor(self, anc) -> Self: - ... - - def over_power_basis(self) -> Self | PowerBasisElement | ModuleElement: - ... - - def is_compat(self, other) -> Literal[False]: - ... - - def unify(self, other) -> tuple[Self, Any] | tuple[Self | Any, Any]: - ... - - def __eq__(self, other) -> bool: - ... - - def equiv(self, other) -> bool: - ... - - def __add__(self, other) -> Self | NotImplementedType: - ... - + def QQ_col(self): ... + def to_parent(self) -> PowerBasisElement | ModuleElement: ... + def to_ancestor(self, anc) -> Self: ... + def over_power_basis(self) -> Self | PowerBasisElement | ModuleElement: ... + def is_compat(self, other) -> Literal[False]: ... + def unify(self, other) -> tuple[Self, Any] | tuple[Self | Any, Any]: ... + def __eq__(self, other) -> bool: ... + def equiv(self, other) -> bool: ... + def __add__(self, other) -> Self | NotImplementedType: ... + __radd__ = ... - def __neg__(self) -> Self | NotImplementedType | PowerBasisElement | ModuleElement: - ... - - def __sub__(self, other): - ... - - def __rsub__(self, other): - ... - - def __mul__(self, other) -> Self | NotImplementedType | PowerBasisElement | ModuleElement: - ... - - __rmul__ = ... - def __floordiv__(self, a) -> Any | NotImplementedType: - ... - - def __rfloordiv__(self, a): - ... - - def __mod__(self, m) -> NotImplementedType: - ... - + def __neg__(self) -> Self | NotImplementedType | PowerBasisElement | ModuleElement: ... + def __sub__(self, other): ... + def __rsub__(self, other): ... + def __mul__(self, other) -> Self | NotImplementedType | PowerBasisElement | ModuleElement: ... + __rmul__ = ... + def __floordiv__(self, a) -> Any | NotImplementedType: ... + def __rfloordiv__(self, a): ... + def __mod__(self, m) -> NotImplementedType: ... class PowerBasisElement(ModuleElement): @property - def T(self): - ... - - def numerator(self, x=...) -> Any: - ... - - def poly(self, x=...) -> Any: - ... - + def T(self): ... + def numerator(self, x=...) -> Any: ... + def poly(self, x=...) -> Any: ... @property - def is_rational(self): - ... - + def is_rational(self): ... @property - def generator(self): - ... - - def as_expr(self, x=...) -> Any: - ... - - def norm(self, T=...): - ... - - def inverse(self): - ... - - def __rfloordiv__(self, a): - ... - - def to_ANP(self) -> ANP: - ... - - def to_alg_num(self): - ... - - + def generator(self): ... + def as_expr(self, x=...) -> Any: ... + def norm(self, T=...): ... + def inverse(self): ... + def __rfloordiv__(self, a): ... + def to_ANP(self) -> ANP: ... + def to_alg_num(self): ... class ModuleHomomorphism: - def __init__(self, domain, codomain, mapping) -> None: - ... - - def matrix(self, modulus=...) -> DomainMatrix: - ... - - def kernel(self, modulus=...): - ... - - + def __init__(self, domain, codomain, mapping) -> None: ... + def matrix(self, modulus=...) -> DomainMatrix: ... + def kernel(self, modulus=...): ... class ModuleEndomorphism(ModuleHomomorphism): - def __init__(self, domain, mapping) -> None: - ... - - + def __init__(self, domain, mapping) -> None: ... class InnerEndomorphism(ModuleEndomorphism): - def __init__(self, domain, multiplier) -> None: - ... - - + def __init__(self, domain, multiplier) -> None: ... class EndomorphismRing: - def __init__(self, domain) -> None: - ... - - def inner_endomorphism(self, multiplier) -> InnerEndomorphism: - ... - - def represent(self, element) -> DomainMatrix: - ... - - - -def find_min_poly(alpha, domain, x=..., powers=...) -> Any | None: - ... + def __init__(self, domain) -> None: ... + def inner_endomorphism(self, multiplier) -> InnerEndomorphism: ... + def represent(self, element) -> DomainMatrix: ... +def find_min_poly(alpha, domain, x=..., powers=...) -> Any | None: ... diff --git a/stubs/sympy-stubs/polys/numberfields/primes.pyi b/stubs/sympy-stubs/polys/numberfields/primes.pyi index da27f44f..72b854ce 100644 --- a/stubs/sympy-stubs/polys/numberfields/primes.pyi +++ b/stubs/sympy-stubs/polys/numberfields/primes.pyi @@ -4,58 +4,27 @@ from sympy.polys.polyutils import IntegerPowerable from sympy.utilities.decorator import public class PrimeIdeal(IntegerPowerable): - def __init__(self, ZK, p, alpha, f, e=...) -> None: - ... - - def __str__(self) -> str: - ... - + def __init__(self, ZK, p, alpha, f, e=...) -> None: ... + def __str__(self) -> str: ... @property - def is_inert(self): - ... - - def repr(self, field_gen=..., just_gens=...) -> str: - ... - - def __repr__(self) -> str: - ... - - def as_submodule(self): - ... - - def __eq__(self, other) -> bool: - ... - - def __add__(self, other): - ... - + def is_inert(self): ... + def repr(self, field_gen=..., just_gens=...) -> str: ... + def __repr__(self) -> str: ... + def as_submodule(self): ... + def __eq__(self, other) -> bool: ... + def __add__(self, other): ... + __radd__ = ... - def __mul__(self, other): - ... - - __rmul__ = ... - def test_factor(self): - ... - - def valuation(self, I) -> Any: - ... - - def reduce_element(self, elt): - ... - - def reduce_ANP(self, a): - ... - - def reduce_alg_num(self, a): - ... - + def __mul__(self, other): ... + __rmul__ = ... + def test_factor(self): ... + def valuation(self, I) -> Any: ... + def reduce_element(self, elt): ... + def reduce_ANP(self, a): ... + def reduce_alg_num(self, a): ... @public -def prime_valuation(I, P) -> int: - ... - +def prime_valuation(I, P) -> int: ... @public -def prime_decomp(p, T=..., ZK=..., dK=..., radical=...) -> list[PrimeIdeal] | list[Any]: - ... - +def prime_decomp(p, T=..., ZK=..., dK=..., radical=...) -> list[PrimeIdeal] | list[Any]: ... diff --git a/stubs/sympy-stubs/polys/numberfields/subfield.pyi b/stubs/sympy-stubs/polys/numberfields/subfield.pyi index 54d6aedd..4dd0d9ef 100644 --- a/stubs/sympy-stubs/polys/numberfields/subfield.pyi +++ b/stubs/sympy-stubs/polys/numberfields/subfield.pyi @@ -3,24 +3,12 @@ from typing import Any from sympy.core.numbers import AlgebraicNumber from sympy.utilities import public -def is_isomorphism_possible(a, b) -> bool: - ... - -def field_isomorphism_pslq(a, b) -> list[Any] | None: - ... - -def field_isomorphism_factor(a, b) -> Any | None: - ... - +def is_isomorphism_possible(a, b) -> bool: ... +def field_isomorphism_pslq(a, b) -> list[Any] | None: ... +def field_isomorphism_factor(a, b) -> Any | None: ... @public -def field_isomorphism(a, b, *, fast=...) -> list[Any] | Any | None: - ... - +def field_isomorphism(a, b, *, fast=...) -> list[Any] | Any | None: ... @public -def primitive_element(extension, x=..., *, ex=..., polys=...) -> tuple[Any, list[int]] | tuple[Any, list[int], list[Any]]: - ... - +def primitive_element(extension, x=..., *, ex=..., polys=...) -> tuple[Any, list[int]] | tuple[Any, list[int], list[Any]]: ... @public -def to_number_field(extension, theta=..., *, gen=..., alias=...) -> AlgebraicNumber: - ... - +def to_number_field(extension, theta=..., *, gen=..., alias=...) -> AlgebraicNumber: ... diff --git a/stubs/sympy-stubs/polys/numberfields/utilities.pyi b/stubs/sympy-stubs/polys/numberfields/utilities.pyi index bd7aada9..2f16fb29 100644 --- a/stubs/sympy-stubs/polys/numberfields/utilities.pyi +++ b/stubs/sympy-stubs/polys/numberfields/utilities.pyi @@ -2,49 +2,22 @@ from typing import Any, Generator, Literal, NoReturn from sympy.utilities.decorator import public -def is_rat(c) -> Any | Literal[True]: - ... - -def is_int(c) -> Any | Literal[True]: - ... - -def get_num_denom(c) -> tuple[Any, Any]: - ... - +def is_rat(c) -> Any | Literal[True]: ... +def is_int(c) -> Any | Literal[True]: ... +def get_num_denom(c) -> tuple[Any, Any]: ... @public -def extract_fundamental_discriminant(a) -> tuple[dict[Any, Any], dict[int, int]] | tuple[dict[Any, Any], dict[Any, Any]]: - ... - +def extract_fundamental_discriminant(a) -> tuple[dict[Any, Any], dict[int, int]] | tuple[dict[Any, Any], dict[Any, Any]]: ... @public class AlgIntPowers: - def __init__(self, T, modulus=...) -> None: - ... - - def red(self, exp): - ... - - def __rmod__(self, other): - ... - - def compute_up_through(self, e) -> None: - ... - - def get(self, e) -> list[int] | list[Any]: - ... - - def __getitem__(self, item) -> list[int] | list[Any]: - ... - - + def __init__(self, T, modulus=...) -> None: ... + def red(self, exp): ... + def __rmod__(self, other): ... + def compute_up_through(self, e) -> None: ... + def get(self, e) -> list[int] | list[Any]: ... + def __getitem__(self, item) -> list[int] | list[Any]: ... @public -def coeff_search(m, R) -> Generator[Any, Any, NoReturn]: - ... - -def supplement_a_subspace(M): - ... - +def coeff_search(m, R) -> Generator[Any, Any, NoReturn]: ... +def supplement_a_subspace(M): ... @public -def isolate(alg, eps=..., fast=...) -> tuple[Any, Any]: - ... - +def isolate(alg, eps=..., fast=...) -> tuple[Any, Any]: ... diff --git a/stubs/sympy-stubs/polys/orderings.pyi b/stubs/sympy-stubs/polys/orderings.pyi index 488eda52..a0eb5522 100644 --- a/stubs/sympy-stubs/polys/orderings.pyi +++ b/stubs/sympy-stubs/polys/orderings.pyi @@ -1,101 +1,52 @@ from typing import Any, Callable __all__ = ["lex", "grlex", "grevlex", "ilex", "igrlex", "igrevlex"] + class MonomialOrder: alias: str | None = ... is_global: bool | None = ... is_default = ... - def __repr__(self) -> str: - ... - - def __str__(self) -> str: - ... - - def __call__(self, monomial): - ... - - def __eq__(self, other) -> bool: - ... - - def __hash__(self) -> int: - ... - - def __ne__(self, other) -> bool: - ... - - + def __repr__(self) -> str: ... + def __str__(self) -> str: ... + def __call__(self, monomial): ... + def __eq__(self, other) -> bool: ... + def __hash__(self) -> int: ... + def __ne__(self, other) -> bool: ... class LexOrder(MonomialOrder): alias = ... is_global = ... is_default = ... - def __call__(self, monomial): - ... - - + def __call__(self, monomial): ... class GradedLexOrder(MonomialOrder): alias = ... is_global = ... - def __call__(self, monomial) -> tuple[int, Any]: - ... - - + def __call__(self, monomial) -> tuple[int, Any]: ... class ReversedGradedLexOrder(MonomialOrder): alias = ... is_global = ... - def __call__(self, monomial) -> tuple[int, tuple[Any, ...]]: - ... - - + def __call__(self, monomial) -> tuple[int, tuple[Any, ...]]: ... class ProductOrder(MonomialOrder): - def __init__(self, *args) -> None: - ... - - def __call__(self, monomial) -> tuple[Any, ...]: - ... - - def __repr__(self) -> str: - ... - - def __str__(self) -> str: - ... - - def __eq__(self, other) -> bool: - ... - - def __hash__(self) -> int: - ... - + def __init__(self, *args) -> None: ... + def __call__(self, monomial) -> tuple[Any, ...]: ... + def __repr__(self) -> str: ... + def __str__(self) -> str: ... + def __eq__(self, other) -> bool: ... + def __hash__(self) -> int: ... @property - def is_global(self) -> bool | None: - ... - - + def is_global(self) -> bool | None: ... class InverseOrder(MonomialOrder): - def __init__(self, O) -> None: - ... - - def __str__(self) -> str: - ... - - def __call__(self, monomial) -> tuple[Any, ...]: - ... - + def __init__(self, O) -> None: ... + def __str__(self) -> str: ... + def __call__(self, monomial) -> tuple[Any, ...]: ... @property - def is_global(self) -> bool | None: - ... - - def __eq__(self, other) -> bool: - ... - - def __hash__(self) -> int: - ... - - + def is_global(self) -> bool | None: ... + def __eq__(self, other) -> bool: ... + def __hash__(self) -> int: ... lex = ... grlex = ... @@ -104,21 +55,12 @@ ilex = ... igrlex = ... igrevlex = ... _monomial_key = ... -def monomial_key(order=..., gens=...) -> Callable[..., Any] | LexOrder: - ... -class _ItemGetter: - def __init__(self, seq) -> None: - ... - - def __call__(self, m) -> tuple[Any, ...]: - ... - - def __eq__(self, other) -> bool: - ... - +def monomial_key(order=..., gens=...) -> Callable[..., Any] | LexOrder: ... +class _ItemGetter: + def __init__(self, seq) -> None: ... + def __call__(self, m) -> tuple[Any, ...]: ... + def __eq__(self, other) -> bool: ... -def build_product_order(arg, gens) -> ProductOrder: - ... - +def build_product_order(arg, gens) -> ProductOrder: ... diff --git a/stubs/sympy-stubs/polys/orthopolys.pyi b/stubs/sympy-stubs/polys/orthopolys.pyi index ec9e1b10..ba654785 100644 --- a/stubs/sympy-stubs/polys/orthopolys.pyi +++ b/stubs/sympy-stubs/polys/orthopolys.pyi @@ -2,67 +2,29 @@ from typing import Any from sympy.utilities import public -def dup_jacobi(n, a, b, K) -> list[Any]: - ... - +def dup_jacobi(n, a, b, K) -> list[Any]: ... @public -def jacobi_poly(n, a, b, x=..., polys=...): - ... - -def dup_gegenbauer(n, a, K) -> list[Any]: - ... - -def gegenbauer_poly(n, a, x=..., polys=...): - ... - -def dup_chebyshevt(n, K) -> list[Any]: - ... - -def dup_chebyshevu(n, K) -> list[Any]: - ... - +def jacobi_poly(n, a, b, x=..., polys=...): ... +def dup_gegenbauer(n, a, K) -> list[Any]: ... +def gegenbauer_poly(n, a, x=..., polys=...): ... +def dup_chebyshevt(n, K) -> list[Any]: ... +def dup_chebyshevu(n, K) -> list[Any]: ... @public -def chebyshevt_poly(n, x=..., polys=...): - ... - +def chebyshevt_poly(n, x=..., polys=...): ... @public -def chebyshevu_poly(n, x=..., polys=...): - ... - -def dup_hermite(n, K) -> list[Any]: - ... - -def dup_hermite_prob(n, K) -> list[Any]: - ... - +def chebyshevu_poly(n, x=..., polys=...): ... +def dup_hermite(n, K) -> list[Any]: ... +def dup_hermite_prob(n, K) -> list[Any]: ... @public -def hermite_poly(n, x=..., polys=...): - ... - +def hermite_poly(n, x=..., polys=...): ... @public -def hermite_prob_poly(n, x=..., polys=...): - ... - -def dup_legendre(n, K) -> list[Any]: - ... - +def hermite_prob_poly(n, x=..., polys=...): ... +def dup_legendre(n, K) -> list[Any]: ... @public -def legendre_poly(n, x=..., polys=...): - ... - -def dup_laguerre(n, alpha, K) -> list[Any]: - ... - +def legendre_poly(n, x=..., polys=...): ... +def dup_laguerre(n, alpha, K) -> list[Any]: ... @public -def laguerre_poly(n, x=..., alpha=..., polys=...): - ... - -def dup_spherical_bessel_fn(n, K) -> list[Any]: - ... - -def dup_spherical_bessel_fn_minus(n, K) -> list[Any]: - ... - -def spherical_bessel_fn(n, x=..., polys=...): - ... - +def laguerre_poly(n, x=..., alpha=..., polys=...): ... +def dup_spherical_bessel_fn(n, K) -> list[Any]: ... +def dup_spherical_bessel_fn_minus(n, K) -> list[Any]: ... +def spherical_bessel_fn(n, x=..., polys=...): ... diff --git a/stubs/sympy-stubs/polys/partfrac.pyi b/stubs/sympy-stubs/polys/partfrac.pyi index de77e59a..1aba364e 100644 --- a/stubs/sympy-stubs/polys/partfrac.pyi +++ b/stubs/sympy-stubs/polys/partfrac.pyi @@ -4,23 +4,11 @@ from sympy.utilities import public, xthreaded @xthreaded @public -def apart(f, x=..., full=..., **options) -> Any: - ... - -def apart_undetermined_coeffs(P, Q): - ... - -def apart_full_decomposition(P, Q) -> Any: - ... - +def apart(f, x=..., full=..., **options) -> Any: ... +def apart_undetermined_coeffs(P, Q): ... +def apart_full_decomposition(P, Q) -> Any: ... @public -def apart_list(f, x=..., dummies=..., **options) -> tuple[Any, Any, list[Any]]: - ... - -def apart_list_full_decomposition(P, Q, dummygen) -> list[Any]: - ... - +def apart_list(f, x=..., dummies=..., **options) -> tuple[Any, Any, list[Any]]: ... +def apart_list_full_decomposition(P, Q, dummygen) -> list[Any]: ... @public -def assemble_partfrac_list(partial_list): - ... - +def assemble_partfrac_list(partial_list): ... diff --git a/stubs/sympy-stubs/polys/polyclasses.pyi b/stubs/sympy-stubs/polys/polyclasses.pyi index cc75a5e9..c28b8311 100644 --- a/stubs/sympy-stubs/polys/polyclasses.pyi +++ b/stubs/sympy-stubs/polys/polyclasses.pyi @@ -7,735 +7,316 @@ from sympy.polys.domains import Domain from sympy.polys.polyutils import PicklableWithSlots class GenericPoly(PicklableWithSlots): - def ground_to_ring(f): - ... - - def ground_to_field(f): - ... - - def ground_to_exact(f): - ... - + def ground_to_ring(f): ... + def ground_to_field(f): ... + def ground_to_exact(f): ... - -def init_normal_DMP(rep, lev, dom) -> DMP: - ... +def init_normal_DMP(rep, lev, dom) -> DMP: ... class DMP(PicklableWithSlots, CantSympify): __slots__ = ... - def __init__(self, rep, dom, lev=..., ring=...) -> None: - ... - - def __repr__(f) -> str: - ... - - def __hash__(f) -> int: - ... - - def unify(f, g) -> tuple[Any, Any, Callable[..., Any | DMP], list[Any] | Any | list[list[Any]], list[Any] | Any | list[list[Any]]] | tuple[Any, Any, Callable[..., Any | DMP], Any | list[list[Any]], Any | list[list[Any]]]: - ... - - def per(f, rep, dom=..., kill=..., ring=...) -> DMP: - ... - + def __init__(self, rep, dom, lev=..., ring=...) -> None: ... + def __repr__(f) -> str: ... + def __hash__(f) -> int: ... + def unify( + f, g + ) -> ( + tuple[Any, Any, Callable[..., Any | DMP], list[Any] | Any | list[list[Any]], list[Any] | Any | list[list[Any]]] + | tuple[Any, Any, Callable[..., Any | DMP], Any | list[list[Any]], Any | list[list[Any]]] + ): ... + def per(f, rep, dom=..., kill=..., ring=...) -> DMP: ... @classmethod - def zero(cls, lev, dom, ring=...) -> DMP: - ... - + def zero(cls, lev, dom, ring=...) -> DMP: ... @classmethod - def one(cls, lev, dom, ring=...) -> DMP: - ... - + def one(cls, lev, dom, ring=...) -> DMP: ... @classmethod - def from_list(cls, rep, lev, dom) -> Self: - ... - + def from_list(cls, rep, lev, dom) -> Self: ... @classmethod - def from_sympy_list(cls, rep, lev, dom) -> Self: - ... - - def to_dict(f, zero=...) -> dict[tuple[Literal[0]], Any] | dict[Any, Any]: - ... - - def to_sympy_dict(f, zero=...) -> dict[tuple[Literal[0]], Any] | dict[Any, Any]: - ... - - def to_list(f) -> list[Any] | list[list[Any]]: - ... - - def to_sympy_list(f) -> list[Any]: - ... - - def to_tuple(f) -> tuple[Any, ...]: - ... - + def from_sympy_list(cls, rep, lev, dom) -> Self: ... + def to_dict(f, zero=...) -> dict[tuple[Literal[0]], Any] | dict[Any, Any]: ... + def to_sympy_dict(f, zero=...) -> dict[tuple[Literal[0]], Any] | dict[Any, Any]: ... + def to_list(f) -> list[Any] | list[list[Any]]: ... + def to_sympy_list(f) -> list[Any]: ... + def to_tuple(f) -> tuple[Any, ...]: ... @classmethod - def from_dict(cls, rep, lev, dom) -> Self: - ... - + def from_dict(cls, rep, lev, dom) -> Self: ... @classmethod - def from_monoms_coeffs(cls, monoms, coeffs, lev, dom, ring=...) -> DMP: - ... - - def to_ring(f) -> Self | DMP: - ... - - def to_field(f) -> Self | DMP: - ... - - def to_exact(f) -> Self | DMP: - ... - - def convert(f, dom) -> Self | DMP: - ... - - def slice(f, m, n, j=...) -> DMP: - ... - - def coeffs(f, order=...) -> list[Any]: - ... - - def monoms(f, order=...) -> list[Any]: - ... - - def terms(f, order=...) -> list[tuple[Any, Any]] | list[Any]: - ... - - def all_coeffs(f) -> list[Any] | list[list[Any]]: - ... - - def all_monoms(f) -> list[tuple[Literal[0]]] | list[tuple[Any | int]]: - ... - - def all_terms(f) -> list[tuple[tuple[Literal[0]], Any]] | list[tuple[tuple[Any | int], list[Any]]]: - ... - - def lift(f) -> DMP: - ... - - def deflate(f) -> tuple[Any | tuple[Any, ...], Any | DMP]: - ... - - def inject(f, front=...) -> Self: - ... - - def eject(f, dom, front=...) -> Self: - ... - - def exclude(f) -> tuple[list[Any], Self]: - ... - - def permute(f, P) -> DMP: - ... - - def terms_gcd(f) -> tuple[Any | tuple[Any, ...], Any | DMP]: - ... - - def add_ground(f, c) -> DMP: - ... - - def sub_ground(f, c) -> DMP: - ... - - def mul_ground(f, c) -> DMP: - ... - - def quo_ground(f, c) -> DMP: - ... - - def exquo_ground(f, c) -> DMP: - ... - - def abs(f) -> DMP: - ... - - def neg(f) -> DMP: - ... - - def add(f, g) -> DMP: - ... - - def sub(f, g) -> DMP: - ... - - def mul(f, g) -> DMP: - ... - - def sqr(f) -> DMP: - ... - - def pow(f, n) -> DMP: - ... - - def pdiv(f, g) -> tuple[Any | DMP, Any | DMP]: - ... - - def prem(f, g) -> DMP: - ... - - def pquo(f, g) -> DMP: - ... - - def pexquo(f, g) -> DMP: - ... - - def div(f, g) -> tuple[Any | DMP, Any | DMP]: - ... - - def rem(f, g) -> DMP: - ... - - def quo(f, g) -> DMP: - ... - - def exquo(f, g) -> DMP: - ... - - def degree(f, j=...) -> int: - ... - - def degree_list(f) -> tuple[Any, ...]: - ... - - def total_degree(f) -> int: - ... - - def homogenize(f, s) -> DMP: - ... - - def homogeneous_order(f) -> int | None: - ... - - def LC(f): - ... - - def TC(f): - ... - - def nth(f, *N): - ... - - def max_norm(f): - ... - - def l1_norm(f) -> int: - ... - - def l2_norm_squared(f) -> int: - ... - - def clear_denoms(f) -> tuple[Any, Any | DMP]: - ... - - def integrate(f, m=..., j=...) -> DMP: - ... - - def diff(f, m=..., j=...) -> DMP: - ... - - def eval(f, a, j=...) -> DMP: - ... - - def half_gcdex(f, g) -> tuple[Any | DMP, Any | DMP]: - ... - - def gcdex(f, g) -> tuple[Any | DMP, Any | DMP, Any | DMP]: - ... - - def invert(f, g) -> DMP: - ... - - def revert(f, n) -> DMP: - ... - - def subresultants(f, g) -> list[Any | DMP]: - ... - - def resultant(f, g, includePRS=...) -> tuple[Any | DMP, list[Any | DMP]] | DMP: - ... - - def discriminant(f) -> DMP: - ... - - def cofactors(f, g) -> tuple[Any | DMP, Any | DMP, Any | DMP]: - ... - - def gcd(f, g) -> DMP: - ... - - def lcm(f, g) -> DMP: - ... - - def cancel(f, g, include=...) -> tuple[Any | DMP, Any | DMP] | tuple[Any | list[Any], Any | list[Any], Any | DMP, Any | DMP]: - ... - - def trunc(f, p) -> DMP: - ... - - def monic(f) -> DMP: - ... - - def content(f): - ... - - def primitive(f) -> tuple[Any, Any | DMP]: - ... - - def compose(f, g) -> DMP: - ... - - def decompose(f) -> list[Any | DMP]: - ... - - def shift(f, a) -> DMP: - ... - - def transform(f, p, q) -> DMP: - ... - - def sturm(f) -> list[Any | DMP]: - ... - - def cauchy_upper_bound(f): - ... - - def cauchy_lower_bound(f): - ... - - def mignotte_sep_bound_squared(f): - ... - - def gff_list(f) -> list[tuple[Any | DMP, Any]]: - ... - - def norm(f) -> DMP: - ... - - def sqf_norm(f) -> tuple[int, Any | DMP, Any | DMP]: - ... - - def sqf_part(f) -> DMP: - ... - - def sqf_list(f, all=...) -> tuple[Any, list[tuple[Any | DMP, Any]]]: - ... - - def sqf_list_include(f, all=...) -> list[tuple[Any | DMP, Literal[1]]]: - ... - - def factor_list(f) -> tuple[Any, list[tuple[Any | DMP, Any]]]: - ... - - def factor_list_include(f) -> list[tuple[Any | DMP, Any | Literal[1]]]: - ... - - def intervals(f, all=..., eps=..., inf=..., sup=..., fast=..., sqf=...) -> list[Any] | list[tuple[tuple[Any, Any], Any, Any] | tuple[Any, Any]] | list[tuple[Any, Any] | tuple[Any | list[Any], tuple[Any, Any, Any, Any]]] | list[Any] | tuple[list[tuple[tuple[Any | list[Any], Any | tuple[Any, Any, Any, Any]], Any]], list[tuple[tuple[Any, Any], Any]]] | tuple[list[Any] | list[tuple[Any, Any] | tuple[Any | list[Any], tuple[Any, Any, Any, Any]]] | list[Any], Any]: - ... - - def refine_root(f, s, t, eps=..., steps=..., fast=...) -> tuple[Any, Any] | tuple[Any | list[Any], Any | tuple[Any, Any, Any, Any]]: - ... - - def count_real_roots(f, inf=..., sup=...) -> int: - ... - - def count_complex_roots(f, inf=..., sup=...) -> int: - ... - + def from_monoms_coeffs(cls, monoms, coeffs, lev, dom, ring=...) -> DMP: ... + def to_ring(f) -> Self | DMP: ... + def to_field(f) -> Self | DMP: ... + def to_exact(f) -> Self | DMP: ... + def convert(f, dom) -> Self | DMP: ... + def slice(f, m, n, j=...) -> DMP: ... + def coeffs(f, order=...) -> list[Any]: ... + def monoms(f, order=...) -> list[Any]: ... + def terms(f, order=...) -> list[tuple[Any, Any]] | list[Any]: ... + def all_coeffs(f) -> list[Any] | list[list[Any]]: ... + def all_monoms(f) -> list[tuple[Literal[0]]] | list[tuple[Any | int]]: ... + def all_terms(f) -> list[tuple[tuple[Literal[0]], Any]] | list[tuple[tuple[Any | int], list[Any]]]: ... + def lift(f) -> DMP: ... + def deflate(f) -> tuple[Any | tuple[Any, ...], Any | DMP]: ... + def inject(f, front=...) -> Self: ... + def eject(f, dom, front=...) -> Self: ... + def exclude(f) -> tuple[list[Any], Self]: ... + def permute(f, P) -> DMP: ... + def terms_gcd(f) -> tuple[Any | tuple[Any, ...], Any | DMP]: ... + def add_ground(f, c) -> DMP: ... + def sub_ground(f, c) -> DMP: ... + def mul_ground(f, c) -> DMP: ... + def quo_ground(f, c) -> DMP: ... + def exquo_ground(f, c) -> DMP: ... + def abs(f) -> DMP: ... + def neg(f) -> DMP: ... + def add(f, g) -> DMP: ... + def sub(f, g) -> DMP: ... + def mul(f, g) -> DMP: ... + def sqr(f) -> DMP: ... + def pow(f, n) -> DMP: ... + def pdiv(f, g) -> tuple[Any | DMP, Any | DMP]: ... + def prem(f, g) -> DMP: ... + def pquo(f, g) -> DMP: ... + def pexquo(f, g) -> DMP: ... + def div(f, g) -> tuple[Any | DMP, Any | DMP]: ... + def rem(f, g) -> DMP: ... + def quo(f, g) -> DMP: ... + def exquo(f, g) -> DMP: ... + def degree(f, j=...) -> int: ... + def degree_list(f) -> tuple[Any, ...]: ... + def total_degree(f) -> int: ... + def homogenize(f, s) -> DMP: ... + def homogeneous_order(f) -> int | None: ... + def LC(f): ... + def TC(f): ... + def nth(f, *N): ... + def max_norm(f): ... + def l1_norm(f) -> int: ... + def l2_norm_squared(f) -> int: ... + def clear_denoms(f) -> tuple[Any, Any | DMP]: ... + def integrate(f, m=..., j=...) -> DMP: ... + def diff(f, m=..., j=...) -> DMP: ... + def eval(f, a, j=...) -> DMP: ... + def half_gcdex(f, g) -> tuple[Any | DMP, Any | DMP]: ... + def gcdex(f, g) -> tuple[Any | DMP, Any | DMP, Any | DMP]: ... + def invert(f, g) -> DMP: ... + def revert(f, n) -> DMP: ... + def subresultants(f, g) -> list[Any | DMP]: ... + def resultant(f, g, includePRS=...) -> tuple[Any | DMP, list[Any | DMP]] | DMP: ... + def discriminant(f) -> DMP: ... + def cofactors(f, g) -> tuple[Any | DMP, Any | DMP, Any | DMP]: ... + def gcd(f, g) -> DMP: ... + def lcm(f, g) -> DMP: ... + def cancel( + f, g, include=... + ) -> tuple[Any | DMP, Any | DMP] | tuple[Any | list[Any], Any | list[Any], Any | DMP, Any | DMP]: ... + def trunc(f, p) -> DMP: ... + def monic(f) -> DMP: ... + def content(f): ... + def primitive(f) -> tuple[Any, Any | DMP]: ... + def compose(f, g) -> DMP: ... + def decompose(f) -> list[Any | DMP]: ... + def shift(f, a) -> DMP: ... + def transform(f, p, q) -> DMP: ... + def sturm(f) -> list[Any | DMP]: ... + def cauchy_upper_bound(f): ... + def cauchy_lower_bound(f): ... + def mignotte_sep_bound_squared(f): ... + def gff_list(f) -> list[tuple[Any | DMP, Any]]: ... + def norm(f) -> DMP: ... + def sqf_norm(f) -> tuple[int, Any | DMP, Any | DMP]: ... + def sqf_part(f) -> DMP: ... + def sqf_list(f, all=...) -> tuple[Any, list[tuple[Any | DMP, Any]]]: ... + def sqf_list_include(f, all=...) -> list[tuple[Any | DMP, Literal[1]]]: ... + def factor_list(f) -> tuple[Any, list[tuple[Any | DMP, Any]]]: ... + def factor_list_include(f) -> list[tuple[Any | DMP, Any | Literal[1]]]: ... + def intervals( + f, all=..., eps=..., inf=..., sup=..., fast=..., sqf=... + ) -> ( + list[Any] + | list[tuple[tuple[Any, Any], Any, Any] | tuple[Any, Any]] + | list[tuple[Any, Any] | tuple[Any | list[Any], tuple[Any, Any, Any, Any]]] + | list[Any] + | tuple[list[tuple[tuple[Any | list[Any], Any | tuple[Any, Any, Any, Any]], Any]], list[tuple[tuple[Any, Any], Any]]] + | tuple[list[Any] | list[tuple[Any, Any] | tuple[Any | list[Any], tuple[Any, Any, Any, Any]]] | list[Any], Any] + ): ... + def refine_root( + f, s, t, eps=..., steps=..., fast=... + ) -> tuple[Any, Any] | tuple[Any | list[Any], Any | tuple[Any, Any, Any, Any]]: ... + def count_real_roots(f, inf=..., sup=...) -> int: ... + def count_complex_roots(f, inf=..., sup=...) -> int: ... @property - def is_zero(f) -> bool: - ... - + def is_zero(f) -> bool: ... @property - def is_one(f) -> bool: - ... - + def is_one(f) -> bool: ... @property - def is_ground(f) -> bool: - ... - + def is_ground(f) -> bool: ... @property - def is_sqf(f) -> bool: - ... - + def is_sqf(f) -> bool: ... @property - def is_monic(f): - ... - + def is_monic(f): ... @property - def is_primitive(f): - ... - + def is_primitive(f): ... @property - def is_linear(f) -> bool: - ... - + def is_linear(f) -> bool: ... @property - def is_quadratic(f) -> bool: - ... - + def is_quadratic(f) -> bool: ... @property - def is_monomial(f) -> bool: - ... - + def is_monomial(f) -> bool: ... @property - def is_homogeneous(f) -> bool: - ... - + def is_homogeneous(f) -> bool: ... @property - def is_irreducible(f) -> bool: - ... - + def is_irreducible(f) -> bool: ... @property - def is_cyclotomic(f) -> bool: - ... - - def __abs__(f) -> DMP: - ... - - def __neg__(f) -> DMP: - ... - - def __add__(f, g) -> NotImplementedType | DMP: - ... - - def __radd__(f, g) -> NotImplementedType | DMP: - ... - - def __sub__(f, g) -> NotImplementedType | DMP: - ... - - def __rsub__(f, g) -> NotImplementedType | DMP: - ... - - def __mul__(f, g) -> DMP | NotImplementedType: - ... - - def __truediv__(f, g) -> DMP | NotImplementedType: - ... - - def __rtruediv__(f, g) -> DMP | NotImplementedType: - ... - - def __rmul__(f, g) -> DMP | NotImplementedType: - ... - - def __pow__(f, n) -> DMP: - ... - - def __divmod__(f, g) -> tuple[Any | DMP, Any | DMP]: - ... - - def __mod__(f, g) -> DMP: - ... - - def __floordiv__(f, g) -> DMP | NotImplementedType: - ... - - def __eq__(f, g) -> bool: - ... - - def __ne__(f, g) -> bool: - ... - - def eq(f, g, strict=...) -> bool: - ... - - def ne(f, g, strict=...) -> bool: - ... - - def __lt__(f, g) -> bool: - ... - - def __le__(f, g) -> bool: - ... - - def __gt__(f, g) -> bool: - ... - - def __ge__(f, g) -> bool: - ... - - def __bool__(f) -> bool: - ... - - + def is_cyclotomic(f) -> bool: ... + def __abs__(f) -> DMP: ... + def __neg__(f) -> DMP: ... + def __add__(f, g) -> NotImplementedType | DMP: ... + def __radd__(f, g) -> NotImplementedType | DMP: ... + def __sub__(f, g) -> NotImplementedType | DMP: ... + def __rsub__(f, g) -> NotImplementedType | DMP: ... + def __mul__(f, g) -> DMP | NotImplementedType: ... + def __truediv__(f, g) -> DMP | NotImplementedType: ... + def __rtruediv__(f, g) -> DMP | NotImplementedType: ... + def __rmul__(f, g) -> DMP | NotImplementedType: ... + def __pow__(f, n) -> DMP: ... + def __divmod__(f, g) -> tuple[Any | DMP, Any | DMP]: ... + def __mod__(f, g) -> DMP: ... + def __floordiv__(f, g) -> DMP | NotImplementedType: ... + def __eq__(f, g) -> bool: ... + def __ne__(f, g) -> bool: ... + def eq(f, g, strict=...) -> bool: ... + def ne(f, g, strict=...) -> bool: ... + def __lt__(f, g) -> bool: ... + def __le__(f, g) -> bool: ... + def __gt__(f, g) -> bool: ... + def __ge__(f, g) -> bool: ... + def __bool__(f) -> bool: ... -def init_normal_DMF(num, den, lev, dom) -> DMF: - ... +def init_normal_DMF(num, den, lev, dom) -> DMF: ... class DMF(PicklableWithSlots, CantSympify): __slots__ = ... - def __init__(self, rep, dom, lev=..., ring=...) -> None: - ... - + def __init__(self, rep, dom, lev=..., ring=...) -> None: ... @classmethod - def new(cls, rep, dom, lev=..., ring=...) -> Self: - ... - - def __repr__(f) -> str: - ... - - def __hash__(f) -> int: - ... - - def poly_unify(f, g) -> tuple[Any, Any, Callable[..., Any | Self], tuple[Any | list[Any], Any | list[Any]], list[Any] | Any | list[list[Any]]] | tuple[Any, Any, Callable[..., Any | Self], tuple[Any | list[list[Any]], Any | list[list[Any]]], Any | list[list[Any]]]: - ... - - def frac_unify(f, g) -> tuple[Any, Any, Callable[..., Any | Self], tuple[Any | list[Any], Any | list[Any]], tuple[Any | list[Any], Any | list[Any]]] | tuple[Any, Any, Callable[..., Any | Self], tuple[Any | list[list[Any]], Any | list[list[Any]]], tuple[Any | list[list[Any]], Any | list[list[Any]]]]: - ... - - def per(f, num, den, cancel=..., kill=..., ring=...) -> Self: - ... - - def half_per(f, rep, kill=...) -> DMP: - ... - + def new(cls, rep, dom, lev=..., ring=...) -> Self: ... + def __repr__(f) -> str: ... + def __hash__(f) -> int: ... + def poly_unify( + f, g + ) -> ( + tuple[Any, Any, Callable[..., Any | Self], tuple[Any | list[Any], Any | list[Any]], list[Any] | Any | list[list[Any]]] + | tuple[Any, Any, Callable[..., Any | Self], tuple[Any | list[list[Any]], Any | list[list[Any]]], Any | list[list[Any]]] + ): ... + def frac_unify(f, g) -> ( + tuple[ + Any, Any, Callable[..., Any | Self], tuple[Any | list[Any], Any | list[Any]], tuple[Any | list[Any], Any | list[Any]] + ] + | tuple[ + Any, + Any, + Callable[..., Any | Self], + tuple[Any | list[list[Any]], Any | list[list[Any]]], + tuple[Any | list[list[Any]], Any | list[list[Any]]], + ] + ): ... + def per(f, num, den, cancel=..., kill=..., ring=...) -> Self: ... + def half_per(f, rep, kill=...) -> DMP: ... @classmethod - def zero(cls, lev, dom, ring=...) -> Self: - ... - + def zero(cls, lev, dom, ring=...) -> Self: ... @classmethod - def one(cls, lev, dom, ring=...) -> Self: - ... - - def numer(f) -> DMP: - ... - - def denom(f) -> DMP: - ... - - def cancel(f) -> Self: - ... - - def neg(f) -> Self: - ... - - def add(f, g) -> Self: - ... - - def sub(f, g) -> Self: - ... - - def mul(f, g) -> Self: - ... - - def pow(f, n) -> Self: - ... - - def quo(f, g) -> Self: - ... - + def one(cls, lev, dom, ring=...) -> Self: ... + def numer(f) -> DMP: ... + def denom(f) -> DMP: ... + def cancel(f) -> Self: ... + def neg(f) -> Self: ... + def add(f, g) -> Self: ... + def sub(f, g) -> Self: ... + def mul(f, g) -> Self: ... + def pow(f, n) -> Self: ... + def quo(f, g) -> Self: ... + exquo = ... - def invert(f, check=...) -> Self: - ... - + def invert(f, check=...) -> Self: ... @property - def is_zero(f) -> bool: - ... - + def is_zero(f) -> bool: ... @property - def is_one(f) -> bool: - ... - - def __neg__(f) -> Self: - ... - - def __add__(f, g) -> Self | NotImplementedType: - ... - - def __radd__(f, g) -> Self | NotImplementedType: - ... - - def __sub__(f, g) -> Self | NotImplementedType: - ... - - def __rsub__(f, g) -> DMF | NotImplementedType: - ... - - def __mul__(f, g) -> Self | NotImplementedType: - ... - - def __rmul__(f, g) -> Self | NotImplementedType: - ... - - def __pow__(f, n) -> Self: - ... - - def __truediv__(f, g) -> Self | NotImplementedType: - ... - - def __rtruediv__(self, g): - ... - - def __eq__(f, g) -> bool: - ... - - def __ne__(f, g) -> bool: - ... - - def __lt__(f, g) -> bool: - ... - - def __le__(f, g) -> bool: - ... - - def __gt__(f, g) -> bool: - ... - - def __ge__(f, g) -> bool: - ... - - def __bool__(f) -> bool: - ... - - + def is_one(f) -> bool: ... + def __neg__(f) -> Self: ... + def __add__(f, g) -> Self | NotImplementedType: ... + def __radd__(f, g) -> Self | NotImplementedType: ... + def __sub__(f, g) -> Self | NotImplementedType: ... + def __rsub__(f, g) -> DMF | NotImplementedType: ... + def __mul__(f, g) -> Self | NotImplementedType: ... + def __rmul__(f, g) -> Self | NotImplementedType: ... + def __pow__(f, n) -> Self: ... + def __truediv__(f, g) -> Self | NotImplementedType: ... + def __rtruediv__(self, g): ... + def __eq__(f, g) -> bool: ... + def __ne__(f, g) -> bool: ... + def __lt__(f, g) -> bool: ... + def __le__(f, g) -> bool: ... + def __gt__(f, g) -> bool: ... + def __ge__(f, g) -> bool: ... + def __bool__(f) -> bool: ... -def init_normal_ANP(rep, mod, dom) -> ANP: - ... +def init_normal_ANP(rep, mod, dom) -> ANP: ... class ANP(PicklableWithSlots, CantSympify): __slots__ = ... - def __init__(self, rep, mod, dom) -> None: - ... - - def __repr__(f) -> str: - ... - - def __hash__(f) -> int: - ... - - def unify(f, g) -> tuple[Any, Callable[..., ANP], list[Any] | Any, list[Any] | Any, list[Any] | Any | list[list[Any]]] | tuple[Any, Callable[..., ANP], Any, Any, Any | list[Any] | list[list[Any]]]: - ... - - def per(f, rep, mod=..., dom=...) -> ANP: - ... - + def __init__(self, rep, mod, dom) -> None: ... + def __repr__(f) -> str: ... + def __hash__(f) -> int: ... + def unify( + f, g + ) -> ( + tuple[Any, Callable[..., ANP], list[Any] | Any, list[Any] | Any, list[Any] | Any | list[list[Any]]] + | tuple[Any, Callable[..., ANP], Any, Any, Any | list[Any] | list[list[Any]]] + ): ... + def per(f, rep, mod=..., dom=...) -> ANP: ... @classmethod - def zero(cls, mod, dom) -> ANP: - ... - + def zero(cls, mod, dom) -> ANP: ... @classmethod - def one(cls, mod, dom) -> ANP: - ... - - def to_dict(f) -> dict[tuple[Literal[0]], Any] | dict[Any, Any]: - ... - - def to_sympy_dict(f) -> dict[tuple[Literal[0]], Any] | dict[Any, Any]: - ... - - def to_list(f) -> list[Any]: - ... - - def to_sympy_list(f) -> list[Any]: - ... - - def to_tuple(f) -> tuple[Any, ...]: - ... - + def one(cls, mod, dom) -> ANP: ... + def to_dict(f) -> dict[tuple[Literal[0]], Any] | dict[Any, Any]: ... + def to_sympy_dict(f) -> dict[tuple[Literal[0]], Any] | dict[Any, Any]: ... + def to_list(f) -> list[Any]: ... + def to_sympy_list(f) -> list[Any]: ... + def to_tuple(f) -> tuple[Any, ...]: ... @classmethod - def from_list(cls, rep, mod, dom) -> ANP: - ... - - def neg(f) -> ANP: - ... - - def add(f, g) -> ANP: - ... - - def sub(f, g) -> ANP: - ... - - def mul(f, g) -> ANP: - ... - - def pow(f, n) -> ANP: - ... - - def div(f, g) -> tuple[ANP, ANP]: - ... - - def rem(f, g) -> ANP: - ... - - def quo(f, g) -> ANP: - ... - + def from_list(cls, rep, mod, dom) -> ANP: ... + def neg(f) -> ANP: ... + def add(f, g) -> ANP: ... + def sub(f, g) -> ANP: ... + def mul(f, g) -> ANP: ... + def pow(f, n) -> ANP: ... + def div(f, g) -> tuple[ANP, ANP]: ... + def rem(f, g) -> ANP: ... + def quo(f, g) -> ANP: ... + exquo = ... - def LC(f): - ... - - def TC(f): - ... - + def LC(f): ... + def TC(f): ... @property - def is_zero(f) -> bool: - ... - + def is_zero(f) -> bool: ... @property - def is_one(f) -> bool: - ... - + def is_one(f) -> bool: ... @property - def is_ground(f) -> bool: - ... - - def __pos__(f) -> Self: - ... - - def __neg__(f) -> ANP: - ... - - def __add__(f, g) -> ANP | NotImplementedType: - ... - - def __radd__(f, g) -> ANP | NotImplementedType: - ... - - def __sub__(f, g) -> ANP | NotImplementedType: - ... - - def __rsub__(f, g) -> ANP | NotImplementedType: - ... - - def __mul__(f, g) -> ANP | NotImplementedType: - ... - - def __rmul__(f, g) -> ANP | NotImplementedType: - ... - - def __pow__(f, n) -> ANP: - ... - - def __divmod__(f, g) -> tuple[ANP, ANP]: - ... - - def __mod__(f, g) -> ANP: - ... - - def __truediv__(f, g) -> ANP | NotImplementedType: - ... - - def __eq__(f, g) -> bool: - ... - - def __ne__(f, g) -> bool: - ... - - def __lt__(f, g) -> bool: - ... - - def __le__(f, g) -> bool: - ... - - def __gt__(f, g) -> bool: - ... - - def __ge__(f, g) -> bool: - ... - - def __bool__(f) -> bool: - ... - - - + def is_ground(f) -> bool: ... + def __pos__(f) -> Self: ... + def __neg__(f) -> ANP: ... + def __add__(f, g) -> ANP | NotImplementedType: ... + def __radd__(f, g) -> ANP | NotImplementedType: ... + def __sub__(f, g) -> ANP | NotImplementedType: ... + def __rsub__(f, g) -> ANP | NotImplementedType: ... + def __mul__(f, g) -> ANP | NotImplementedType: ... + def __rmul__(f, g) -> ANP | NotImplementedType: ... + def __pow__(f, n) -> ANP: ... + def __divmod__(f, g) -> tuple[ANP, ANP]: ... + def __mod__(f, g) -> ANP: ... + def __truediv__(f, g) -> ANP | NotImplementedType: ... + def __eq__(f, g) -> bool: ... + def __ne__(f, g) -> bool: ... + def __lt__(f, g) -> bool: ... + def __le__(f, g) -> bool: ... + def __gt__(f, g) -> bool: ... + def __ge__(f, g) -> bool: ... + def __bool__(f) -> bool: ... diff --git a/stubs/sympy-stubs/polys/polyconfig.pyi b/stubs/sympy-stubs/polys/polyconfig.pyi index 0b0da36e..813dad29 100644 --- a/stubs/sympy-stubs/polys/polyconfig.pyi +++ b/stubs/sympy-stubs/polys/polyconfig.pyi @@ -3,16 +3,9 @@ from typing import Any, Generator _default_config = ... _current_config = ... -@contextmanager -def using(**kwargs) -> Generator[None, Any, None]: - ... - -def setup(key, value=...) -> None: - ... - -def query(key): - ... - -def configure() -> None: - ... +@contextmanager +def using(**kwargs) -> Generator[None, Any, None]: ... +def setup(key, value=...) -> None: ... +def query(key): ... +def configure() -> None: ... diff --git a/stubs/sympy-stubs/polys/polyerrors.pyi b/stubs/sympy-stubs/polys/polyerrors.pyi index f229d04e..778c14d0 100644 --- a/stubs/sympy-stubs/polys/polyerrors.pyi +++ b/stubs/sympy-stubs/polys/polyerrors.pyi @@ -4,164 +4,91 @@ from sympy.utilities import public @public class BasePolynomialError(Exception): - def new(self, *args): - ... - - + def new(self, *args): ... @public class ExactQuotientFailed(BasePolynomialError): - def __init__(self, f, g, dom=...) -> None: - ... - - def __str__(self) -> str: - ... - - def new(self, f, g) -> Self: - ... - - + def __init__(self, f, g, dom=...) -> None: ... + def __str__(self) -> str: ... + def new(self, f, g) -> Self: ... @public class PolynomialDivisionFailed(BasePolynomialError): - def __init__(self, f, g, domain) -> None: - ... - - def __str__(self) -> str: - ... - - + def __init__(self, f, g, domain) -> None: ... + def __str__(self) -> str: ... @public class OperationNotSupported(BasePolynomialError): - def __init__(self, poly, func) -> None: - ... - - def __str__(self) -> str: - ... - - + def __init__(self, poly, func) -> None: ... + def __str__(self) -> str: ... @public -class HeuristicGCDFailed(BasePolynomialError): - ... - - -class ModularGCDFailed(BasePolynomialError): - ... +class HeuristicGCDFailed(BasePolynomialError): ... +class ModularGCDFailed(BasePolynomialError): ... @public -class HomomorphismFailed(BasePolynomialError): - ... - +class HomomorphismFailed(BasePolynomialError): ... @public -class IsomorphismFailed(BasePolynomialError): - ... - +class IsomorphismFailed(BasePolynomialError): ... @public -class ExtraneousFactors(BasePolynomialError): - ... - +class ExtraneousFactors(BasePolynomialError): ... @public -class EvaluationFailed(BasePolynomialError): - ... - +class EvaluationFailed(BasePolynomialError): ... @public -class RefinementFailed(BasePolynomialError): - ... - - -class CoercionFailed(BasePolynomialError): - ... +class RefinementFailed(BasePolynomialError): ... +class CoercionFailed(BasePolynomialError): ... @public -class NotInvertible(BasePolynomialError): - ... - +class NotInvertible(BasePolynomialError): ... @public -class NotReversible(BasePolynomialError): - ... - +class NotReversible(BasePolynomialError): ... @public -class NotAlgebraic(BasePolynomialError): - ... - +class NotAlgebraic(BasePolynomialError): ... @public -class DomainError(BasePolynomialError): - ... - +class DomainError(BasePolynomialError): ... @public -class PolynomialError(BasePolynomialError): - ... - +class PolynomialError(BasePolynomialError): ... @public -class UnificationFailed(BasePolynomialError): - ... - +class UnificationFailed(BasePolynomialError): ... @public -class UnsolvableFactorError(BasePolynomialError): - ... - +class UnsolvableFactorError(BasePolynomialError): ... @public -class GeneratorsError(BasePolynomialError): - ... - +class GeneratorsError(BasePolynomialError): ... @public -class GeneratorsNeeded(GeneratorsError): - ... - +class GeneratorsNeeded(GeneratorsError): ... @public class ComputationFailed(BasePolynomialError): - def __init__(self, func, nargs, exc) -> None: - ... - - def __str__(self) -> str: - ... - - + def __init__(self, func, nargs, exc) -> None: ... + def __str__(self) -> str: ... @public -class UnivariatePolynomialError(PolynomialError): - ... - +class UnivariatePolynomialError(PolynomialError): ... @public -class MultivariatePolynomialError(PolynomialError): - ... - +class MultivariatePolynomialError(PolynomialError): ... @public class PolificationFailed(PolynomialError): - def __init__(self, opt, origs, exprs, seq=...) -> None: - ... - - def __str__(self) -> str: - ... - - + def __init__(self, opt, origs, exprs, seq=...) -> None: ... + def __str__(self) -> str: ... @public -class OptionError(BasePolynomialError): - ... - +class OptionError(BasePolynomialError): ... @public -class FlagError(OptionError): - ... - - +class FlagError(OptionError): ... diff --git a/stubs/sympy-stubs/polys/polyfuncs.pyi b/stubs/sympy-stubs/polys/polyfuncs.pyi index 8ff19cf3..88fc1af4 100644 --- a/stubs/sympy-stubs/polys/polyfuncs.pyi +++ b/stubs/sympy-stubs/polys/polyfuncs.pyi @@ -3,22 +3,12 @@ from typing import Any from sympy.utilities import public @public -def symmetrize(F, *gens, **args) -> list[Any] | tuple[Any | list[Any], list[tuple[Any, Any]]]: - ... - +def symmetrize(F, *gens, **args) -> list[Any] | tuple[Any | list[Any], list[tuple[Any, Any]]]: ... @public -def horner(f, *gens, **args): - ... - +def horner(f, *gens, **args): ... @public -def interpolate(data, x) -> Any: - ... - +def interpolate(data, x) -> Any: ... @public -def rational_interpolate(data, degnum, X=...) -> float: - ... - +def rational_interpolate(data, degnum, X=...) -> float: ... @public -def viete(f, roots=..., *gens, **args) -> list[Any]: - ... - +def viete(f, roots=..., *gens, **args) -> list[Any]: ... diff --git a/stubs/sympy-stubs/polys/polymatrix.pyi b/stubs/sympy-stubs/polys/polymatrix.pyi index f7b1d162..bb581d0c 100644 --- a/stubs/sympy-stubs/polys/polymatrix.pyi +++ b/stubs/sympy-stubs/polys/polymatrix.pyi @@ -2,98 +2,41 @@ from types import NotImplementedType from typing import Any, Self class MutablePolyDenseMatrix: - def __new__(cls, *args, ring=...) -> Self: - ... - + def __new__(cls, *args, ring=...) -> Self: ... @classmethod - def from_list(cls, rows, cols, items, gens, ring) -> Self: - ... - + def from_list(cls, rows, cols, items, gens, ring) -> Self: ... @classmethod - def from_dm(cls, dm) -> Self: - ... - - def to_Matrix(self): - ... - + def from_dm(cls, dm) -> Self: ... + def to_Matrix(self): ... @classmethod - def from_Matrix(cls, other, *gens, ring=...) -> Self: - ... - - def set_gens(self, gens) -> Self: - ... - - def __repr__(self) -> str: - ... - + def from_Matrix(cls, other, *gens, ring=...) -> Self: ... + def set_gens(self, gens) -> Self: ... + def __repr__(self) -> str: ... @property - def shape(self): - ... - + def shape(self): ... @property - def rows(self): - ... - + def rows(self): ... @property - def cols(self): - ... - - def __len__(self): - ... - - def __getitem__(self, key) -> list[Any] | Any | Self: - ... - - def __eq__(self, other) -> bool: - ... - - def __add__(self, other) -> Self | NotImplementedType: - ... - - def __sub__(self, other) -> Self | NotImplementedType: - ... - - def __mul__(self, other) -> Self | NotImplementedType: - ... - - def __rmul__(self, other) -> Self | NotImplementedType: - ... - - def __truediv__(self, other) -> NotImplementedType | Self: - ... - - def __neg__(self) -> Self: - ... - - def transpose(self) -> Self: - ... - - def row_join(self, other) -> Self: - ... - - def col_join(self, other) -> Self: - ... - - def applyfunc(self, func) -> Self: - ... - + def cols(self): ... + def __len__(self): ... + def __getitem__(self, key) -> list[Any] | Any | Self: ... + def __eq__(self, other) -> bool: ... + def __add__(self, other) -> Self | NotImplementedType: ... + def __sub__(self, other) -> Self | NotImplementedType: ... + def __mul__(self, other) -> Self | NotImplementedType: ... + def __rmul__(self, other) -> Self | NotImplementedType: ... + def __truediv__(self, other) -> NotImplementedType | Self: ... + def __neg__(self) -> Self: ... + def transpose(self) -> Self: ... + def row_join(self, other) -> Self: ... + def col_join(self, other) -> Self: ... + def applyfunc(self, func) -> Self: ... @classmethod - def eye(cls, n, gens) -> Self: - ... - + def eye(cls, n, gens) -> Self: ... @classmethod - def zeros(cls, m, n, gens) -> Self: - ... - - def rref(self, simplify=..., normalize_last=...) -> tuple[Self, Any]: - ... - - def nullspace(self) -> list[Self]: - ... - - def rank(self): - ... - - + def zeros(cls, m, n, gens) -> Self: ... + def rref(self, simplify=..., normalize_last=...) -> tuple[Self, Any]: ... + def nullspace(self) -> list[Self]: ... + def rank(self): ... PolyMatrix = MutablePolyMatrix = MutablePolyDenseMatrix diff --git a/stubs/sympy-stubs/polys/polyoptions.pyi b/stubs/sympy-stubs/polys/polyoptions.pyi index a1ae121b..e2526015 100644 --- a/stubs/sympy-stubs/polys/polyoptions.pyi +++ b/stubs/sympy-stubs/polys/polyoptions.pyi @@ -7,6 +7,7 @@ from sympy.polys.orderings import LexOrder from sympy.utilities import public __all__ = ["Options"] + class Option: option: str | None = ... is_Flag = ... @@ -15,86 +16,51 @@ class Option: after: list[str] = ... before: list[str] = ... @classmethod - def default(cls) -> None: - ... - + def default(cls) -> None: ... @classmethod - def preprocess(cls, option) -> None: - ... - + def preprocess(cls, option) -> None: ... @classmethod - def postprocess(cls, options) -> None: - ... - - + def postprocess(cls, options) -> None: ... class Flag(Option): is_Flag = ... - class BooleanOption(Option): @classmethod - def preprocess(cls, value) -> bool: - ... - - + def preprocess(cls, value) -> bool: ... class OptionType(type): - def __init__(cls, *args, **kwargs) -> None: - ... - - + def __init__(cls, *args, **kwargs) -> None: ... @public class Options(dict): __order__ = ... __options__: dict[str, type[Option]] = ... - def __init__(self, gens, args, flags=..., strict=...) -> None: - ... - - def clone(self, updates=...) -> Self: - ... - - def __setattr__(self, attr, value) -> None: - ... - + def __init__(self, gens, args, flags=..., strict=...) -> None: ... + def clone(self, updates=...) -> Self: ... + def __setattr__(self, attr, value) -> None: ... @property - def args(self) -> dict[Any, Any]: - ... - + def args(self) -> dict[Any, Any]: ... @property - def options(self) -> dict[Any, Any]: - ... - + def options(self) -> dict[Any, Any]: ... @property - def flags(self) -> dict[Any, Any]: - ... - - + def flags(self) -> dict[Any, Any]: ... class Expand(BooleanOption, metaclass=OptionType): option = ... requires: list[str] = ... excludes: list[str] = ... @classmethod - def default(cls) -> Literal[True]: - ... - - + def default(cls) -> Literal[True]: ... class Gens(Option, metaclass=OptionType): option = ... requires: list[str] = ... excludes: list[str] = ... @classmethod - def default(cls) -> tuple[()]: - ... - + def default(cls) -> tuple[()]: ... @classmethod - def preprocess(cls, gens) -> tuple[Basic, ...]: - ... - - + def preprocess(cls, gens) -> tuple[Basic, ...]: ... class Wrt(Option, metaclass=OptionType): option = ... @@ -102,61 +68,44 @@ class Wrt(Option, metaclass=OptionType): excludes: list[str] = ... _re_split = ... @classmethod - def preprocess(cls, wrt) -> list[str] | list[Any] | list[str | Any]: - ... - - + def preprocess(cls, wrt) -> list[str] | list[Any] | list[str | Any]: ... class Sort(Option, metaclass=OptionType): option = ... requires: list[str] = ... excludes: list[str] = ... @classmethod - def default(cls) -> list[Any]: - ... - + def default(cls) -> list[Any]: ... @classmethod - def preprocess(cls, sort) -> list[str]: - ... - - + def preprocess(cls, sort) -> list[str]: ... class Order(Option, metaclass=OptionType): option = ... requires: list[str] = ... excludes: list[str] = ... @classmethod - def default(cls) -> LexOrder: - ... - + def default(cls) -> LexOrder: ... @classmethod - def preprocess(cls, order) -> Callable[..., Any] | LexOrder: - ... - - + def preprocess(cls, order) -> Callable[..., Any] | LexOrder: ... class Field(BooleanOption, metaclass=OptionType): option = ... requires: list[str] = ... excludes = ... - class Greedy(BooleanOption, metaclass=OptionType): option = ... requires: list[str] = ... excludes = ... - class Composite(BooleanOption, metaclass=OptionType): option = ... @classmethod - def default(cls) -> None: - ... - + def default(cls) -> None: ... + requires: list[str] = ... excludes = ... - class Domain(Option, metaclass=OptionType): option = ... requires: list[str] = ... @@ -169,172 +118,107 @@ class Domain(Option, metaclass=OptionType): _re_fraction = ... _re_algebraic = ... @classmethod - def preprocess(cls, domain) -> Any | GaussianIntegerRing | GaussianRationalField: - ... - + def preprocess(cls, domain) -> Any | GaussianIntegerRing | GaussianRationalField: ... @classmethod - def postprocess(cls, options) -> None: - ... - - + def postprocess(cls, options) -> None: ... class Split(BooleanOption, metaclass=OptionType): option = ... requires: list[str] = ... excludes = ... @classmethod - def postprocess(cls, options) -> None: - ... - - + def postprocess(cls, options) -> None: ... class Gaussian(BooleanOption, metaclass=OptionType): option = ... requires: list[str] = ... excludes = ... @classmethod - def postprocess(cls, options) -> None: - ... - - + def postprocess(cls, options) -> None: ... class Extension(Option, metaclass=OptionType): option = ... requires: list[str] = ... excludes = ... @classmethod - def preprocess(cls, extension) -> bool | set[Any] | None: - ... - + def preprocess(cls, extension) -> bool | set[Any] | None: ... @classmethod - def postprocess(cls, options) -> None: - ... - - + def postprocess(cls, options) -> None: ... class Modulus(Option, metaclass=OptionType): option = ... requires: list[str] = ... excludes = ... @classmethod - def preprocess(cls, modulus) -> int: - ... - + def preprocess(cls, modulus) -> int: ... @classmethod - def postprocess(cls, options) -> None: - ... - - + def postprocess(cls, options) -> None: ... class Symmetric(BooleanOption, metaclass=OptionType): option = ... requires = ... excludes = ... - class Strict(BooleanOption, metaclass=OptionType): option = ... @classmethod - def default(cls) -> Literal[True]: - ... - - + def default(cls) -> Literal[True]: ... class Auto(BooleanOption, Flag, metaclass=OptionType): option = ... after = ... @classmethod - def default(cls) -> Literal[True]: - ... - + def default(cls) -> Literal[True]: ... @classmethod - def postprocess(cls, options) -> None: - ... - - + def postprocess(cls, options) -> None: ... class Frac(BooleanOption, Flag, metaclass=OptionType): option = ... @classmethod - def default(cls) -> Literal[False]: - ... - - + def default(cls) -> Literal[False]: ... class Formal(BooleanOption, Flag, metaclass=OptionType): option = ... @classmethod - def default(cls) -> Literal[False]: - ... - - + def default(cls) -> Literal[False]: ... class Polys(BooleanOption, Flag, metaclass=OptionType): option = ... - class Include(BooleanOption, Flag, metaclass=OptionType): option = ... @classmethod - def default(cls) -> Literal[False]: - ... - - + def default(cls) -> Literal[False]: ... class All(BooleanOption, Flag, metaclass=OptionType): option = ... @classmethod - def default(cls) -> Literal[False]: - ... - - + def default(cls) -> Literal[False]: ... class Gen(Flag, metaclass=OptionType): option = ... @classmethod - def default(cls) -> Literal[0]: - ... - + def default(cls) -> Literal[0]: ... @classmethod - def preprocess(cls, gen) -> Basic | int: - ... - - + def preprocess(cls, gen) -> Basic | int: ... class Series(BooleanOption, Flag, metaclass=OptionType): option = ... @classmethod - def default(cls) -> Literal[False]: - ... - - + def default(cls) -> Literal[False]: ... class Symbols(Flag, metaclass=OptionType): option = ... @classmethod - def default(cls) -> Generator[Symbol | Any, Any, NoReturn]: - ... - + def default(cls) -> Generator[Symbol | Any, Any, NoReturn]: ... @classmethod - def preprocess(cls, symbols): - ... - - + def preprocess(cls, symbols): ... class Method(Flag, metaclass=OptionType): option = ... @classmethod - def preprocess(cls, method) -> str: - ... - - - -def build_options(gens, args=...) -> Any: - ... - -def allowed_flags(args, flags) -> None: - ... - -def set_defaults(options, **defaults) -> dict[Any, Any]: - ... + def preprocess(cls, method) -> str: ... +def build_options(gens, args=...) -> Any: ... +def allowed_flags(args, flags) -> None: ... +def set_defaults(options, **defaults) -> dict[Any, Any]: ... diff --git a/stubs/sympy-stubs/polys/polyquinticconst.pyi b/stubs/sympy-stubs/polys/polyquinticconst.pyi index c0a14679..3e24177f 100644 --- a/stubs/sympy-stubs/polys/polyquinticconst.pyi +++ b/stubs/sympy-stubs/polys/polyquinticconst.pyi @@ -3,50 +3,25 @@ from typing import Any from sympy.utilities import public x = ... + @public class PolyQuintic: - def __init__(self, poly) -> None: - ... - + def __init__(self, poly) -> None: ... @property - def f20(self) -> Any: - ... - + def f20(self) -> Any: ... @property - def b(self) -> tuple[list[Any], list[int], list[int], list[int], list[int]]: - ... - + def b(self) -> tuple[list[Any], list[int], list[int], list[int], list[int]]: ... @property - def o(self) -> list[int]: - ... - + def o(self) -> list[int]: ... @property - def a(self) -> list[int]: - ... - + def a(self) -> list[int]: ... @property - def c(self) -> list[int]: - ... - + def c(self) -> list[int]: ... @property - def F(self): - ... - - def l0(self, theta): - ... - - def T(self, theta, d) -> list[int]: - ... - - def order(self, theta, d): - ... - - def uv(self, theta, d) -> tuple[Any, Any]: - ... - + def F(self): ... + def l0(self, theta): ... + def T(self, theta, d) -> list[int]: ... + def order(self, theta, d): ... + def uv(self, theta, d) -> tuple[Any, Any]: ... @property - def zeta(self) -> list[Any]: - ... - - - + def zeta(self) -> list[Any]: ... diff --git a/stubs/sympy-stubs/polys/polyroots.pyi b/stubs/sympy-stubs/polys/polyroots.pyi index 1ed8e509..db666640 100644 --- a/stubs/sympy-stubs/polys/polyroots.pyi +++ b/stubs/sympy-stubs/polys/polyroots.pyi @@ -4,34 +4,28 @@ from sympy.functions.elementary.piecewise import Piecewise from sympy.utilities import public z = ... -def roots_linear(f) -> list[Any]: - ... - -def roots_quadratic(f) -> list[Any]: - ... - -def roots_cubic(f, trig=...) -> list[Any]: - ... - -def roots_quartic(f) -> Any | list[Any] | list[Any | Piecewise]: - ... - -def roots_binomial(f) -> list[Any]: - ... - -def roots_cyclotomic(f, factor=...) -> list[Any]: - ... - -def roots_quintic(f) -> list[Any]: - ... - -def preprocess_roots(poly) -> tuple[Any, Any]: - ... +def roots_linear(f) -> list[Any]: ... +def roots_quadratic(f) -> list[Any]: ... +def roots_cubic(f, trig=...) -> list[Any]: ... +def roots_quartic(f) -> Any | list[Any] | list[Any | Piecewise]: ... +def roots_binomial(f) -> list[Any]: ... +def roots_cyclotomic(f, factor=...) -> list[Any]: ... +def roots_quintic(f) -> list[Any]: ... +def preprocess_roots(poly) -> tuple[Any, Any]: ... @public -def roots(f, *gens, auto=..., cubics=..., trig=..., quartics=..., quintics=..., multiple=..., filter=..., predicate=..., strict=..., **flags): - ... - -def root_factors(f, *gens, filter=..., **args) -> list[Any]: - ... - +def roots( + f, + *gens, + auto=..., + cubics=..., + trig=..., + quartics=..., + quintics=..., + multiple=..., + filter=..., + predicate=..., + strict=..., + **flags, +): ... +def root_factors(f, *gens, filter=..., **args) -> list[Any]: ... diff --git a/stubs/sympy-stubs/polys/polytools.pyi b/stubs/sympy-stubs/polys/polytools.pyi index eff66331..5666a78f 100644 --- a/stubs/sympy-stubs/polys/polytools.pyi +++ b/stubs/sympy-stubs/polys/polytools.pyi @@ -15,876 +15,398 @@ from sympy.core.relational import Equality, Ne, Relational from sympy.series.order import Order from sympy.utilities import public -def _polifyit(func) -> _Wrapped[..., Any, ..., Any]: - ... - +def _polifyit(func) -> _Wrapped[..., Any, ..., Any]: ... @public class Poly(Basic): __slots__ = ... is_commutative = ... is_Poly = ... _op_priority = ... - def __new__(cls, rep, *gens, **args) -> Self: - ... - + def __new__(cls, rep, *gens, **args) -> Self: ... @classmethod - def new(cls, rep, *gens) -> Self: - ... - + def new(cls, rep, *gens) -> Self: ... @property - def expr(self) -> Order: - ... - + def expr(self) -> Order: ... @property - def args(self) -> tuple[Any | Order, ...]: - ... - + def args(self) -> tuple[Any | Order, ...]: ... @classmethod - def from_dict(cls, rep, *gens, **args) -> Self: - ... - + def from_dict(cls, rep, *gens, **args) -> Self: ... @classmethod - def from_list(cls, rep, *gens, **args) -> Self: - ... - + def from_list(cls, rep, *gens, **args) -> Self: ... @classmethod - def from_poly(cls, rep, *gens, **args) -> Self: - ... - + def from_poly(cls, rep, *gens, **args) -> Self: ... @classmethod - def from_expr(cls, rep, *gens, **args) -> Self: - ... - - def __hash__(self) -> int: - ... - + def from_expr(cls, rep, *gens, **args) -> Self: ... + def __hash__(self) -> int: ... @property - def free_symbols(self) -> set[Any]: - ... - + def free_symbols(self) -> set[Any]: ... @property - def free_symbols_in_domain(self) -> set[Any]: - ... - + def free_symbols_in_domain(self) -> set[Any]: ... @property - def gen(self): - ... - + def gen(self): ... @property - def domain(self): - ... - + def domain(self): ... @property - def zero(self) -> Self: - ... - + def zero(self) -> Self: ... @property - def one(self) -> Self: - ... - + def one(self) -> Self: ... @property - def unit(self) -> Self: - ... - - def unify(f, g) -> tuple[Any | Self, Any | Self]: - ... - - def per(f, rep, gens=..., remove=...) -> Self: - ... - - def set_domain(f, domain) -> Self: - ... - - def get_domain(f): - ... - - def set_modulus(f, modulus) -> Self: - ... - - def get_modulus(f) -> Integer: - ... - - def exclude(f) -> Self: - ... - - def replace(f, x, y=..., **_ignore) -> Self: - ... - - def match(f, *args, **kwargs): - ... - - def reorder(f, *gens, **args) -> Self: - ... - - def ltrim(f, gen) -> Self: - ... - - def has_only_gens(f, *gens) -> bool: - ... - - def to_ring(f) -> Self: - ... - - def to_field(f) -> Self: - ... - - def to_exact(f) -> Self: - ... - - def retract(f, field=...) -> Self: - ... - - def slice(f, x, m, n=...) -> Self: - ... - - def coeffs(f, order=...) -> list[Any]: - ... - - def monoms(f, order=...): - ... - - def terms(f, order=...) -> list[tuple[Any, Any]]: - ... - - def all_coeffs(f) -> list[Any]: - ... - - def all_monoms(f): - ... - - def all_terms(f) -> list[tuple[Any, Any]]: - ... - - def termwise(f, func, *gens, **args) -> Self: - ... - - def length(f) -> int: - ... - - def as_dict(f, native=..., zero=...): - ... - - def as_list(f, native=...): - ... - - def as_expr(f, *gens) -> Order: - ... - - def as_poly(self, *gens, **args) -> Any | None: - ... - - def lift(f) -> Self: - ... - - def deflate(f) -> tuple[Any, Any | Self]: - ... - - def inject(f, front=...) -> Self: - ... - - def eject(f, *gens) -> Self: - ... - - def terms_gcd(f) -> tuple[Any, Any | Self]: - ... - - def add_ground(f, coeff) -> Self: - ... - - def sub_ground(f, coeff) -> Self: - ... - - def mul_ground(f, coeff) -> Self: - ... - - def quo_ground(f, coeff) -> Self: - ... - - def exquo_ground(f, coeff) -> Self: - ... - - def abs(f) -> Self: - ... - - def neg(f) -> Self: - ... - - def add(f, g) -> Self: - ... - - def sub(f, g) -> Self: - ... - - def mul(f, g) -> Self: - ... - - def sqr(f) -> Self: - ... - - def pow(f, n) -> Self: - ... - - def pdiv(f, g) -> tuple[Any | Self, Any | Self]: - ... - - def prem(f, g) -> Self: - ... - - def pquo(f, g) -> Self: - ... - - def pexquo(f, g) -> Self: - ... - - def div(f, g, auto=...) -> tuple[Any | Self, Any | Self]: - ... - - def rem(f, g, auto=...) -> Self: - ... - - def quo(f, g, auto=...) -> Self: - ... - - def exquo(f, g, auto=...) -> Self: - ... - - def degree(f, gen=...): - ... - - def degree_list(f): - ... - - def total_degree(f): - ... - - def homogenize(f, s) -> Self: - ... - - def homogeneous_order(f): - ... - - def LC(f, order=...): - ... - - def TC(f): - ... - - def EC(f, order=...): - ... - - def coeff_monomial(f, monom): - ... - - def nth(f, *N): - ... - - def coeff(f, x, n=..., right=...): - ... - - def LM(f, order=...) -> Any: - ... - - def EM(f, order=...) -> Any: - ... - - def LT(f, order=...) -> tuple[Any, Any]: - ... - - def ET(f, order=...) -> tuple[Any, Any]: - ... - - def max_norm(f): - ... - - def l1_norm(f): - ... - - def clear_denoms(self, convert=...) -> tuple[Any, Self] | tuple[Any, Any | Self]: - ... - - def rat_clear_denoms(self, g) -> tuple[Any | Self, Any | Self]: - ... - - def integrate(self, *specs, **args) -> Self: - ... - - def diff(f, *specs, **kwargs) -> Derivative | Self: - ... - + def unit(self) -> Self: ... + def unify(f, g) -> tuple[Any | Self, Any | Self]: ... + def per(f, rep, gens=..., remove=...) -> Self: ... + def set_domain(f, domain) -> Self: ... + def get_domain(f): ... + def set_modulus(f, modulus) -> Self: ... + def get_modulus(f) -> Integer: ... + def exclude(f) -> Self: ... + def replace(f, x, y=..., **_ignore) -> Self: ... + def match(f, *args, **kwargs): ... + def reorder(f, *gens, **args) -> Self: ... + def ltrim(f, gen) -> Self: ... + def has_only_gens(f, *gens) -> bool: ... + def to_ring(f) -> Self: ... + def to_field(f) -> Self: ... + def to_exact(f) -> Self: ... + def retract(f, field=...) -> Self: ... + def slice(f, x, m, n=...) -> Self: ... + def coeffs(f, order=...) -> list[Any]: ... + def monoms(f, order=...): ... + def terms(f, order=...) -> list[tuple[Any, Any]]: ... + def all_coeffs(f) -> list[Any]: ... + def all_monoms(f): ... + def all_terms(f) -> list[tuple[Any, Any]]: ... + def termwise(f, func, *gens, **args) -> Self: ... + def length(f) -> int: ... + def as_dict(f, native=..., zero=...): ... + def as_list(f, native=...): ... + def as_expr(f, *gens) -> Order: ... + def as_poly(self, *gens, **args) -> Any | None: ... + def lift(f) -> Self: ... + def deflate(f) -> tuple[Any, Any | Self]: ... + def inject(f, front=...) -> Self: ... + def eject(f, *gens) -> Self: ... + def terms_gcd(f) -> tuple[Any, Any | Self]: ... + def add_ground(f, coeff) -> Self: ... + def sub_ground(f, coeff) -> Self: ... + def mul_ground(f, coeff) -> Self: ... + def quo_ground(f, coeff) -> Self: ... + def exquo_ground(f, coeff) -> Self: ... + def abs(f) -> Self: ... + def neg(f) -> Self: ... + def add(f, g) -> Self: ... + def sub(f, g) -> Self: ... + def mul(f, g) -> Self: ... + def sqr(f) -> Self: ... + def pow(f, n) -> Self: ... + def pdiv(f, g) -> tuple[Any | Self, Any | Self]: ... + def prem(f, g) -> Self: ... + def pquo(f, g) -> Self: ... + def pexquo(f, g) -> Self: ... + def div(f, g, auto=...) -> tuple[Any | Self, Any | Self]: ... + def rem(f, g, auto=...) -> Self: ... + def quo(f, g, auto=...) -> Self: ... + def exquo(f, g, auto=...) -> Self: ... + def degree(f, gen=...): ... + def degree_list(f): ... + def total_degree(f): ... + def homogenize(f, s) -> Self: ... + def homogeneous_order(f): ... + def LC(f, order=...): ... + def TC(f): ... + def EC(f, order=...): ... + def coeff_monomial(f, monom): ... + def nth(f, *N): ... + def coeff(f, x, n=..., right=...): ... + def LM(f, order=...) -> Any: ... + def EM(f, order=...) -> Any: ... + def LT(f, order=...) -> tuple[Any, Any]: ... + def ET(f, order=...) -> tuple[Any, Any]: ... + def max_norm(f): ... + def l1_norm(f): ... + def clear_denoms(self, convert=...) -> tuple[Any, Self] | tuple[Any, Any | Self]: ... + def rat_clear_denoms(self, g) -> tuple[Any | Self, Any | Self]: ... + def integrate(self, *specs, **args) -> Self: ... + def diff(f, *specs, **kwargs) -> Derivative | Self: ... + _eval_derivative = ... - def eval(self, x, a=..., auto=...) -> Self: - ... - - def __call__(f, *values) -> Self: - ... - - def half_gcdex(f, g, auto=...) -> tuple[Any | Self, Any | Self]: - ... - - def gcdex(f, g, auto=...) -> tuple[Any | Self, Any | Self, Any | Self]: - ... - - def invert(f, g, auto=...) -> Self: - ... - - def revert(f, n) -> Self: - ... - - def subresultants(f, g) -> list[Any | Self]: - ... - - def resultant(f, g, includePRS=...) -> tuple[Any | Self, list[Any | Self]] | Self: - ... - - def discriminant(f) -> Self: - ... - - def dispersionset(f, g=...) -> set[int] | set[Any]: - ... - - def dispersion(f, g=...) -> int: - ... - - def cofactors(f, g) -> tuple[Any | Self, Any | Self, Any | Self]: - ... - - def gcd(f, g) -> Self: - ... - - def lcm(f, g) -> Self: - ... - - def trunc(f, p) -> Self: - ... - - def monic(self, auto=...) -> Self: - ... - - def content(f): - ... - - def primitive(f) -> tuple[Any, Any | Self]: - ... - - def compose(f, g) -> Self: - ... - - def decompose(f) -> list[Any | Self]: - ... - - def shift(f, a) -> Self: - ... - - def transform(f, p, q) -> Self: - ... - - def sturm(self, auto=...) -> list[Any | Self]: - ... - - def gff_list(f) -> list[tuple[Any | Self, Any]]: - ... - - def norm(f) -> Self: - ... - - def sqf_norm(f) -> tuple[Any, Any | Self, Any | Self]: - ... - - def sqf_part(f) -> Self: - ... - - def sqf_list(f, all=...) -> tuple[Any, list[tuple[Any | Self, Any]]]: - ... - - def sqf_list_include(f, all=...) -> list[tuple[Any | Self, Any]]: - ... - - def factor_list(f) -> tuple[Any, list[tuple[Self, Literal[1]]]] | tuple[Any, list[tuple[Any | Self, Any]]]: - ... - - def factor_list_include(f) -> list[tuple[Self, Literal[1]]] | list[tuple[Any | Self, Any]]: - ... - - def intervals(f, all=..., eps=..., inf=..., sup=..., fast=..., sqf=...) -> list[tuple[Any, Any]] | tuple[list[tuple[Any, Any]], list[tuple[Any, Any]]] | list[tuple[tuple[Any, Any], Any]] | tuple[list[tuple[tuple[Any, Any], Any]], list[tuple[tuple[Any, Any], Any]]]: - ... - - def refine_root(f, s, t, eps=..., steps=..., fast=..., check_sqf=...) -> tuple[Any, Any]: - ... - - def count_roots(f, inf=..., sup=...) -> Integer: - ... - - def root(f, index, radicals=...) -> Any: - ... - - def real_roots(f, multiple=..., radicals=...) -> list[list[Any]] | list[tuple[Any, int]]: - ... - - def all_roots(f, multiple=..., radicals=...) -> list[list[Any]] | list[tuple[Any, int]]: - ... - - def nroots(f, n=..., maxsteps=..., cleanup=...) -> list[Any]: - ... - - def ground_roots(f) -> dict[Any, Any]: - ... - - def nth_power_roots_poly(f, n) -> Self: - ... - - def same_root(f, a, b): - ... - - def cancel(f, g, include=...) -> tuple[Any, Any | Self, Any | Self] | tuple[Any | Self, ...]: - ... - - def make_monic_over_integers_by_scaling_roots(f) -> tuple[Self, Any] | tuple[Any | Self, Any]: - ... - - def galois_group(f, by_name=..., max_tries=..., randomize=...) -> tuple[PermutationGroup | Literal[S1TransitiveSubgroups.S1, S2TransitiveSubgroups.S2, S3TransitiveSubgroups.A3, S3TransitiveSubgroups.S3] | None, bool]: - ... - + def eval(self, x, a=..., auto=...) -> Self: ... + def __call__(f, *values) -> Self: ... + def half_gcdex(f, g, auto=...) -> tuple[Any | Self, Any | Self]: ... + def gcdex(f, g, auto=...) -> tuple[Any | Self, Any | Self, Any | Self]: ... + def invert(f, g, auto=...) -> Self: ... + def revert(f, n) -> Self: ... + def subresultants(f, g) -> list[Any | Self]: ... + def resultant(f, g, includePRS=...) -> tuple[Any | Self, list[Any | Self]] | Self: ... + def discriminant(f) -> Self: ... + def dispersionset(f, g=...) -> set[int] | set[Any]: ... + def dispersion(f, g=...) -> int: ... + def cofactors(f, g) -> tuple[Any | Self, Any | Self, Any | Self]: ... + def gcd(f, g) -> Self: ... + def lcm(f, g) -> Self: ... + def trunc(f, p) -> Self: ... + def monic(self, auto=...) -> Self: ... + def content(f): ... + def primitive(f) -> tuple[Any, Any | Self]: ... + def compose(f, g) -> Self: ... + def decompose(f) -> list[Any | Self]: ... + def shift(f, a) -> Self: ... + def transform(f, p, q) -> Self: ... + def sturm(self, auto=...) -> list[Any | Self]: ... + def gff_list(f) -> list[tuple[Any | Self, Any]]: ... + def norm(f) -> Self: ... + def sqf_norm(f) -> tuple[Any, Any | Self, Any | Self]: ... + def sqf_part(f) -> Self: ... + def sqf_list(f, all=...) -> tuple[Any, list[tuple[Any | Self, Any]]]: ... + def sqf_list_include(f, all=...) -> list[tuple[Any | Self, Any]]: ... + def factor_list(f) -> tuple[Any, list[tuple[Self, Literal[1]]]] | tuple[Any, list[tuple[Any | Self, Any]]]: ... + def factor_list_include(f) -> list[tuple[Self, Literal[1]]] | list[tuple[Any | Self, Any]]: ... + def intervals( + f, all=..., eps=..., inf=..., sup=..., fast=..., sqf=... + ) -> ( + list[tuple[Any, Any]] + | tuple[list[tuple[Any, Any]], list[tuple[Any, Any]]] + | list[tuple[tuple[Any, Any], Any]] + | tuple[list[tuple[tuple[Any, Any], Any]], list[tuple[tuple[Any, Any], Any]]] + ): ... + def refine_root(f, s, t, eps=..., steps=..., fast=..., check_sqf=...) -> tuple[Any, Any]: ... + def count_roots(f, inf=..., sup=...) -> Integer: ... + def root(f, index, radicals=...) -> Any: ... + def real_roots(f, multiple=..., radicals=...) -> list[list[Any]] | list[tuple[Any, int]]: ... + def all_roots(f, multiple=..., radicals=...) -> list[list[Any]] | list[tuple[Any, int]]: ... + def nroots(f, n=..., maxsteps=..., cleanup=...) -> list[Any]: ... + def ground_roots(f) -> dict[Any, Any]: ... + def nth_power_roots_poly(f, n) -> Self: ... + def same_root(f, a, b): ... + def cancel(f, g, include=...) -> tuple[Any, Any | Self, Any | Self] | tuple[Any | Self, ...]: ... + def make_monic_over_integers_by_scaling_roots(f) -> tuple[Self, Any] | tuple[Any | Self, Any]: ... + def galois_group(f, by_name=..., max_tries=..., randomize=...) -> tuple[ + PermutationGroup + | Literal[S1TransitiveSubgroups.S1, S2TransitiveSubgroups.S2, S3TransitiveSubgroups.A3, S3TransitiveSubgroups.S3] + | None, + bool, + ]: ... @property - def is_zero(f): - ... - + def is_zero(f): ... @property - def is_one(f): - ... - + def is_one(f): ... @property - def is_sqf(f): - ... - + def is_sqf(f): ... @property - def is_monic(f): - ... - + def is_monic(f): ... @property - def is_primitive(f): - ... - + def is_primitive(f): ... @property - def is_ground(f): - ... - + def is_ground(f): ... @property - def is_linear(f): - ... - + def is_linear(f): ... @property - def is_quadratic(f): - ... - + def is_quadratic(f): ... @property - def is_monomial(f): - ... - + def is_monomial(f): ... @property - def is_homogeneous(f): - ... - + def is_homogeneous(f): ... @property - def is_irreducible(f): - ... - + def is_irreducible(f): ... @property - def is_univariate(f) -> bool: - ... - + def is_univariate(f) -> bool: ... @property - def is_multivariate(f) -> bool: - ... - + def is_multivariate(f) -> bool: ... @property - def is_cyclotomic(f): - ... - - def __abs__(f) -> Self: - ... - - def __neg__(f) -> Self: - ... - + def is_cyclotomic(f): ... + def __abs__(f) -> Self: ... + def __neg__(f) -> Self: ... @_polifyit - def __add__(f, g) -> Self: - ... - + def __add__(f, g) -> Self: ... @_polifyit - def __radd__(f, g): - ... - + def __radd__(f, g): ... @_polifyit - def __sub__(f, g) -> Self: - ... - + def __sub__(f, g) -> Self: ... @_polifyit - def __rsub__(f, g): - ... - + def __rsub__(f, g): ... @_polifyit - def __mul__(f, g) -> Self: - ... - + def __mul__(f, g) -> Self: ... @_polifyit - def __rmul__(f, g): - ... - - @_sympifyit('n', NotImplemented) - def __pow__(f, n) -> Self | NotImplementedType: - ... - + def __rmul__(f, g): ... + @_sympifyit("n", NotImplemented) + def __pow__(f, n) -> Self | NotImplementedType: ... @_polifyit - def __divmod__(f, g) -> tuple[Any | Self, Any | Self]: - ... - + def __divmod__(f, g) -> tuple[Any | Self, Any | Self]: ... @_polifyit - def __rdivmod__(f, g): - ... - + def __rdivmod__(f, g): ... @_polifyit - def __mod__(f, g) -> Self: - ... - + def __mod__(f, g) -> Self: ... @_polifyit - def __rmod__(f, g): - ... - + def __rmod__(f, g): ... @_polifyit - def __floordiv__(f, g) -> Self: - ... - + def __floordiv__(f, g) -> Self: ... @_polifyit - def __rfloordiv__(f, g): - ... - - @_sympifyit('g', NotImplemented) - def __truediv__(f, g): - ... - - @_sympifyit('g', NotImplemented) - def __rtruediv__(f, g): - ... - - @_sympifyit('other', NotImplemented) - def __eq__(self, other) -> bool: - ... - - @_sympifyit('g', NotImplemented) - def __ne__(f, g) -> bool: - ... - - def __bool__(f) -> bool: - ... - - def eq(f, g, strict=...) -> Literal[False]: - ... - - def ne(f, g, strict=...) -> bool: - ... - - + def __rfloordiv__(f, g): ... + @_sympifyit("g", NotImplemented) + def __truediv__(f, g): ... + @_sympifyit("g", NotImplemented) + def __rtruediv__(f, g): ... + @_sympifyit("other", NotImplemented) + def __eq__(self, other) -> bool: ... + @_sympifyit("g", NotImplemented) + def __ne__(f, g) -> bool: ... + def __bool__(f) -> bool: ... + def eq(f, g, strict=...) -> Literal[False]: ... + def ne(f, g, strict=...) -> bool: ... @public class PurePoly(Poly): - def __hash__(self) -> int: - ... - + def __hash__(self) -> int: ... @property - def free_symbols(self): - ... - - @_sympifyit('other', NotImplemented) - def __eq__(self, other) -> bool: - ... - - + def free_symbols(self): ... + @_sympifyit("other", NotImplemented) + def __eq__(self, other) -> bool: ... @public -def poly_from_expr(expr, *gens, **args) -> tuple[Any, Any]: - ... - +def poly_from_expr(expr, *gens, **args) -> tuple[Any, Any]: ... @public -def parallel_poly_from_expr(exprs, *gens, **args) -> tuple[list[Any], Any]: - ... - +def parallel_poly_from_expr(exprs, *gens, **args) -> tuple[list[Any], Any]: ... @public -def degree(f, gen=...) -> Integer: - ... - +def degree(f, gen=...) -> Integer: ... @public -def total_degree(f, *gens) -> Integer: - ... - +def total_degree(f, *gens) -> Integer: ... @public -def degree_list(f, *gens, **args) -> tuple[Any | Integer, ...]: - ... - +def degree_list(f, *gens, **args) -> tuple[Any | Integer, ...]: ... @public -def LC(f, *gens, **args) -> Any: - ... - +def LC(f, *gens, **args) -> Any: ... @public -def LM(f, *gens, **args) -> Any: - ... - +def LM(f, *gens, **args) -> Any: ... @public -def LT(f, *gens, **args) -> Any: - ... - +def LT(f, *gens, **args) -> Any: ... @public -def pdiv(f, g, *gens, **args) -> tuple[Any, Any]: - ... - +def pdiv(f, g, *gens, **args) -> tuple[Any, Any]: ... @public -def prem(f, g, *gens, **args) -> Any: - ... - +def prem(f, g, *gens, **args) -> Any: ... @public -def pquo(f, g, *gens, **args) -> Any: - ... - +def pquo(f, g, *gens, **args) -> Any: ... @public -def pexquo(f, g, *gens, **args) -> Any: - ... - +def pexquo(f, g, *gens, **args) -> Any: ... @public -def div(f, g, *gens, **args) -> tuple[Any, Any]: - ... - +def div(f, g, *gens, **args) -> tuple[Any, Any]: ... @public -def rem(f, g, *gens, **args) -> Any: - ... - +def rem(f, g, *gens, **args) -> Any: ... @public -def quo(f, g, *gens, **args) -> Any: - ... - +def quo(f, g, *gens, **args) -> Any: ... @public -def exquo(f, g, *gens, **args) -> Any: - ... - +def exquo(f, g, *gens, **args) -> Any: ... @public -def half_gcdex(f, g, *gens, **args) -> tuple[Any, Any]: - ... - +def half_gcdex(f, g, *gens, **args) -> tuple[Any, Any]: ... @public -def gcdex(f, g, *gens, **args) -> tuple[Any, Any, Any]: - ... - +def gcdex(f, g, *gens, **args) -> tuple[Any, Any, Any]: ... @public -def invert(f, g, *gens, **args) -> Any: - ... - +def invert(f, g, *gens, **args) -> Any: ... @public -def subresultants(f, g, *gens, **args) -> list[Any] | Any: - ... - +def subresultants(f, g, *gens, **args) -> list[Any] | Any: ... @public -def resultant(f, g, *gens, includePRS=..., **args) -> tuple[Any, list[Any]] | Any | tuple[Any, Any]: - ... - +def resultant(f, g, *gens, includePRS=..., **args) -> tuple[Any, list[Any]] | Any | tuple[Any, Any]: ... @public -def discriminant(f, *gens, **args) -> Any: - ... - +def discriminant(f, *gens, **args) -> Any: ... @public -def cofactors(f, g, *gens, **args) -> tuple[Any, Any, Any]: - ... - +def cofactors(f, g, *gens, **args) -> tuple[Any, Any, Any]: ... @public -def gcd_list(seq, *gens, **args) -> Any: - ... - +def gcd_list(seq, *gens, **args) -> Any: ... @public -def gcd(f, g=..., *gens, **args) -> Any: - ... - +def gcd(f, g=..., *gens, **args) -> Any: ... @public -def lcm_list(seq, *gens, **args) -> Expr | Any: - ... - +def lcm_list(seq, *gens, **args) -> Expr | Any: ... @public -def lcm(f, g=..., *gens, **args) -> Any: - ... - +def lcm(f, g=..., *gens, **args) -> Any: ... @public -def terms_gcd(f, *gens, **args) -> Equality | Relational | Ne | Any | Add | Order | Mul: - ... - +def terms_gcd(f, *gens, **args) -> Equality | Relational | Ne | Any | Add | Order | Mul: ... @public -def trunc(f, p, *gens, **args) -> Any: - ... - +def trunc(f, p, *gens, **args) -> Any: ... @public -def monic(f, *gens, **args) -> Any: - ... - +def monic(f, *gens, **args) -> Any: ... @public -def content(f, *gens, **args) -> Any: - ... - +def content(f, *gens, **args) -> Any: ... @public -def primitive(f, *gens, **args) -> tuple[Any, Any]: - ... - +def primitive(f, *gens, **args) -> tuple[Any, Any]: ... @public -def compose(f, g, *gens, **args) -> Any: - ... - +def compose(f, g, *gens, **args) -> Any: ... @public -def decompose(f, *gens, **args) -> list[Any] | Any: - ... - +def decompose(f, *gens, **args) -> list[Any] | Any: ... @public -def sturm(f, *gens, **args) -> list[Any] | Any: - ... - +def sturm(f, *gens, **args) -> list[Any] | Any: ... @public -def gff_list(f, *gens, **args) -> list[tuple[Any, Any]] | Any: - ... - +def gff_list(f, *gens, **args) -> list[tuple[Any, Any]] | Any: ... @public -def gff(f, *gens, **args): - ... - +def gff(f, *gens, **args): ... @public -def sqf_norm(f, *gens, **args) -> tuple[Any | Integer, Any, Any]: - ... - +def sqf_norm(f, *gens, **args) -> tuple[Any | Integer, Any, Any]: ... @public -def sqf_part(f, *gens, **args) -> Any: - ... - -def to_rational_coeffs(f) -> tuple[Any | None, Any, None, Any | None] | tuple[None, None, Any | None, Any] | None: - ... - +def sqf_part(f, *gens, **args) -> Any: ... +def to_rational_coeffs(f) -> tuple[Any | None, Any, None, Any | None] | tuple[None, None, Any | None, Any] | None: ... @public -def sqf_list(f, *gens, **args) -> tuple[Any, list[tuple[Any, Any]] | list[Any]] | tuple[Any, list[tuple[Any, Any]] | list[Any], list[tuple[Any, Any]] | list[Any]]: - ... - +def sqf_list( + f, *gens, **args +) -> ( + tuple[Any, list[tuple[Any, Any]] | list[Any]] + | tuple[Any, list[tuple[Any, Any]] | list[Any], list[tuple[Any, Any]] | list[Any]] +): ... @public -def sqf(f, *gens, **args) -> Add | Order | Mul: - ... - +def sqf(f, *gens, **args) -> Add | Order | Mul: ... @public -def factor_list(f, *gens, **args) -> tuple[Any, list[tuple[Any, Any]] | list[Any]] | tuple[Any, list[tuple[Any, Any]] | list[Any], list[tuple[Any, Any]] | list[Any]]: - ... - +def factor_list( + f, *gens, **args +) -> ( + tuple[Any, list[tuple[Any, Any]] | list[Any]] + | tuple[Any, list[tuple[Any, Any]] | list[Any], list[tuple[Any, Any]] | list[Any]] +): ... @public -def factor(f, *gens, deep=..., **args) -> Add | Order | Mul | Expr | Any: - ... - +def factor(f, *gens, deep=..., **args) -> Add | Order | Mul | Expr | Any: ... @public -def intervals(F, all=..., eps=..., inf=..., sup=..., strict=..., fast=..., sqf=...) -> list[Any] | Any: - ... - +def intervals(F, all=..., eps=..., inf=..., sup=..., strict=..., fast=..., sqf=...) -> list[Any] | Any: ... @public -def refine_root(f, s, t, eps=..., steps=..., fast=..., check_sqf=...) -> Any: - ... - +def refine_root(f, s, t, eps=..., steps=..., fast=..., check_sqf=...) -> Any: ... @public -def count_roots(f, inf=..., sup=...) -> Any: - ... - +def count_roots(f, inf=..., sup=...) -> Any: ... @public -def real_roots(f, multiple=...) -> Any: - ... - +def real_roots(f, multiple=...) -> Any: ... @public -def nroots(f, n=..., maxsteps=..., cleanup=...) -> Any: - ... - +def nroots(f, n=..., maxsteps=..., cleanup=...) -> Any: ... @public -def ground_roots(f, *gens, **args) -> Any: - ... - +def ground_roots(f, *gens, **args) -> Any: ... @public -def nth_power_roots_poly(f, n, *gens, **args) -> Any: - ... - +def nth_power_roots_poly(f, n, *gens, **args) -> Any: ... @public -def cancel(f, *gens, _signsimp=..., **args): - ... - +def cancel(f, *gens, _signsimp=..., **args): ... @public -def reduced(f, G, *gens, **args) -> tuple[list[Any], Any]: - ... - +def reduced(f, G, *gens, **args) -> tuple[list[Any], Any]: ... @public -def groebner(F, *gens, **args) -> Any: - ... - +def groebner(F, *gens, **args) -> Any: ... @public -def is_zero_dimensional(F, *gens, **args) -> Any: - ... - +def is_zero_dimensional(F, *gens, **args) -> Any: ... @public class GroebnerBasis(Basic): - def __new__(cls, F, *gens, **args) -> Self: - ... - + def __new__(cls, F, *gens, **args) -> Self: ... @property - def args(self) -> tuple[Tuple, Tuple]: - ... - + def args(self) -> tuple[Tuple, Tuple]: ... @property - def exprs(self) -> list[Any]: - ... - + def exprs(self) -> list[Any]: ... @property - def polys(self) -> list[Any]: - ... - + def polys(self) -> list[Any]: ... @property - def gens(self): - ... - + def gens(self): ... @property - def domain(self): - ... - + def domain(self): ... @property - def order(self): - ... - - def __len__(self) -> int: - ... - - def __iter__(self) -> Iterator[Any]: - ... - - def __getitem__(self, item): - ... - - def __hash__(self) -> int: - ... - - def __eq__(self, other) -> bool: - ... - - def __ne__(self, other) -> bool: - ... - + def order(self): ... + def __len__(self) -> int: ... + def __iter__(self) -> Iterator[Any]: ... + def __getitem__(self, item): ... + def __hash__(self) -> int: ... + def __eq__(self, other) -> bool: ... + def __ne__(self, other) -> bool: ... @property - def is_zero_dimensional(self) -> bool: - ... - - def fglm(self, order) -> Self: - ... - - def reduce(self, expr, auto=...) -> tuple[list[Any], Any]: - ... - - def contains(self, poly): - ... - - + def is_zero_dimensional(self) -> bool: ... + def fglm(self, order) -> Self: ... + def reduce(self, expr, auto=...) -> tuple[list[Any], Any]: ... + def contains(self, poly): ... @public -def poly(expr, *gens, **args) -> Any: - ... - -def named_poly(n, f, K, name, x, polys): - ... - +def poly(expr, *gens, **args) -> Any: ... +def named_poly(n, f, K, name, x, polys): ... diff --git a/stubs/sympy-stubs/polys/polyutils.pyi b/stubs/sympy-stubs/polys/polyutils.pyi index 3f512445..b5c2e1cb 100644 --- a/stubs/sympy-stubs/polys/polyutils.pyi +++ b/stubs/sympy-stubs/polys/polyutils.pyi @@ -9,31 +9,19 @@ _max_order = ... _re_gen = ... illegal_types = ... finf = ... -def parallel_dict_from_expr(exprs, **args) -> tuple[list[Any], Any]: - ... -def dict_from_expr(expr, **args) -> tuple[Any, Any]: - ... - -def expr_from_dict(rep, *gens) -> Order: - ... +def parallel_dict_from_expr(exprs, **args) -> tuple[list[Any], Any]: ... +def dict_from_expr(expr, **args) -> tuple[Any, Any]: ... +def expr_from_dict(rep, *gens) -> Order: ... parallel_dict_from_basic = ... dict_from_basic = ... basic_from_dict = ... + class PicklableWithSlots: __slots__ = ... - def __getstate__(self, cls=...) -> dict[Any, Any]: - ... - - def __setstate__(self, d) -> None: - ... - - + def __getstate__(self, cls=...) -> dict[Any, Any]: ... + def __setstate__(self, d) -> None: ... class IntegerPowerable: - def __pow__(self, e, modulo=...) -> NotImplementedType | Self: - ... - - - + def __pow__(self, e, modulo=...) -> NotImplementedType | Self: ... diff --git a/stubs/sympy-stubs/polys/rationaltools.pyi b/stubs/sympy-stubs/polys/rationaltools.pyi index 59e0dda2..a864fa05 100644 --- a/stubs/sympy-stubs/polys/rationaltools.pyi +++ b/stubs/sympy-stubs/polys/rationaltools.pyi @@ -7,6 +7,4 @@ from sympy.series.order import Order from sympy.utilities import public @public -def together(expr, deep=..., fraction=...) -> Basic | Add | Order | Mul | Dict: - ... - +def together(expr, deep=..., fraction=...) -> Basic | Add | Order | Mul | Dict: ... diff --git a/stubs/sympy-stubs/polys/ring_series.pyi b/stubs/sympy-stubs/polys/ring_series.pyi index 8bfd59de..a1df248a 100644 --- a/stubs/sympy-stubs/polys/ring_series.pyi +++ b/stubs/sympy-stubs/polys/ring_series.pyi @@ -1,111 +1,41 @@ from typing import Any, Literal -def rs_trunc(p1, x, prec): - ... - -def rs_is_puiseux(p, x) -> bool: - ... - -def rs_puiseux(f, p, x, prec) -> tuple[Any, ...]: - ... - -def rs_puiseux2(f, p, q, x, prec): - ... - -def rs_mul(p1, p2, x, prec): - ... - -def rs_square(p1, x, prec): - ... - -def rs_pow(p1, n, x, prec) -> tuple[Any, ...] | Literal[1]: - ... - -def rs_subs(p, rules, x, prec): - ... - -def rs_series_inversion(p, x, prec) -> tuple[Any, ...]: - ... - -def rs_series_reversion(p, x, n, y): - ... - -def rs_series_from_list(p, c, x, prec, concur=...): - ... - -def rs_diff(p, x): - ... - -def rs_integrate(p, x): - ... - -def rs_fun(p, f, *args): - ... - -def mul_xin(p, i, n): - ... - -def pow_xin(p, i, n): - ... - -def rs_nth_root(p, n, x, prec) -> tuple[Any, ...] | Literal[1]: - ... - -def rs_log(p, x, prec) -> tuple[Any, ...]: - ... - -def rs_LambertW(p, x, prec) -> tuple[Any, ...]: - ... - -def rs_exp(p, x, prec) -> tuple[Any, ...]: - ... - -def rs_atan(p, x, prec) -> tuple[Any, ...]: - ... - -def rs_asin(p, x, prec) -> tuple[Any, ...]: - ... - -def rs_tan(p, x, prec) -> tuple[Any, ...]: - ... - -def rs_cot(p, x, prec) -> tuple[Any, ...]: - ... - -def rs_sin(p, x, prec) -> tuple[Any, ...]: - ... - -def rs_cos(p, x, prec) -> tuple[Any, ...]: - ... - -def rs_cos_sin(p, x, prec) -> tuple[Any, ...] | tuple[Any, Any]: - ... - -def rs_atanh(p, x, prec) -> tuple[Any, ...]: - ... - -def rs_sinh(p, x, prec) -> tuple[Any, ...]: - ... - -def rs_cosh(p, x, prec) -> tuple[Any, ...]: - ... - -def rs_tanh(p, x, prec) -> tuple[Any, ...]: - ... - -def rs_newton(p, x, prec): - ... - -def rs_hadamard_exp(p1, inverse=...): - ... - -def rs_compose_add(p1, p2): - ... +def rs_trunc(p1, x, prec): ... +def rs_is_puiseux(p, x) -> bool: ... +def rs_puiseux(f, p, x, prec) -> tuple[Any, ...]: ... +def rs_puiseux2(f, p, q, x, prec): ... +def rs_mul(p1, p2, x, prec): ... +def rs_square(p1, x, prec): ... +def rs_pow(p1, n, x, prec) -> tuple[Any, ...] | Literal[1]: ... +def rs_subs(p, rules, x, prec): ... +def rs_series_inversion(p, x, prec) -> tuple[Any, ...]: ... +def rs_series_reversion(p, x, n, y): ... +def rs_series_from_list(p, c, x, prec, concur=...): ... +def rs_diff(p, x): ... +def rs_integrate(p, x): ... +def rs_fun(p, f, *args): ... +def mul_xin(p, i, n): ... +def pow_xin(p, i, n): ... +def rs_nth_root(p, n, x, prec) -> tuple[Any, ...] | Literal[1]: ... +def rs_log(p, x, prec) -> tuple[Any, ...]: ... +def rs_LambertW(p, x, prec) -> tuple[Any, ...]: ... +def rs_exp(p, x, prec) -> tuple[Any, ...]: ... +def rs_atan(p, x, prec) -> tuple[Any, ...]: ... +def rs_asin(p, x, prec) -> tuple[Any, ...]: ... +def rs_tan(p, x, prec) -> tuple[Any, ...]: ... +def rs_cot(p, x, prec) -> tuple[Any, ...]: ... +def rs_sin(p, x, prec) -> tuple[Any, ...]: ... +def rs_cos(p, x, prec) -> tuple[Any, ...]: ... +def rs_cos_sin(p, x, prec) -> tuple[Any, ...] | tuple[Any, Any]: ... +def rs_atanh(p, x, prec) -> tuple[Any, ...]: ... +def rs_sinh(p, x, prec) -> tuple[Any, ...]: ... +def rs_cosh(p, x, prec) -> tuple[Any, ...]: ... +def rs_tanh(p, x, prec) -> tuple[Any, ...]: ... +def rs_newton(p, x, prec): ... +def rs_hadamard_exp(p1, inverse=...): ... +def rs_compose_add(p1, p2): ... _convert_func = ... -def rs_min_pow(expr, series_rs, a): - ... - -def rs_series(expr, a, prec): - ... +def rs_min_pow(expr, series_rs, a): ... +def rs_series(expr, a, prec): ... diff --git a/stubs/sympy-stubs/polys/rings.pyi b/stubs/sympy-stubs/polys/rings.pyi index 5f12e276..8e8edc3b 100644 --- a/stubs/sympy-stubs/polys/rings.pyi +++ b/stubs/sympy-stubs/polys/rings.pyi @@ -10,522 +10,205 @@ from sympy.series.order import Order from sympy.utilities import public @public -def ring(symbols, domain, order=...) -> Any: - ... - +def ring(symbols, domain, order=...) -> Any: ... @public -def xring(symbols, domain, order=...) -> tuple[PolyRing | Any, Any]: - ... - +def xring(symbols, domain, order=...) -> tuple[PolyRing | Any, Any]: ... @public -def vring(symbols, domain, order=...) -> PolyRing | Any: - ... - +def vring(symbols, domain, order=...) -> PolyRing | Any: ... @public -def sring(exprs, *symbols, **options) -> tuple[PolyRing | Any, Any] | tuple[PolyRing | Any, list[Any]]: - ... +def sring(exprs, *symbols, **options) -> tuple[PolyRing | Any, Any] | tuple[PolyRing | Any, list[Any]]: ... _ring_cache: dict[Any, Any] = ... + class PolyRing(DefaultPrinting, IPolys): - def __new__(cls, symbols, domain, order=...) -> Self | Any: - ... - - def __getnewargs__(self) -> tuple[Any, Any, Any]: - ... - - def __getstate__(self) -> dict[str, Any]: - ... - - def __hash__(self) -> int: - ... - - def __eq__(self, other) -> bool: - ... - - def __ne__(self, other) -> bool: - ... - - def clone(self, symbols=..., domain=..., order=...) -> Self: - ... - - def monomial_basis(self, i) -> tuple[Any, ...]: - ... - - @property - def zero(self): - ... - - @property - def one(self): - ... - - def domain_new(self, element, orig_domain=...): - ... - - def ground_new(self, coeff): - ... - - def term_new(self, monom, coeff): - ... - - def ring_new(self, element) -> PolyElement: - ... - - __call__ = ... - def from_dict(self, element, orig_domain=...): - ... - - def from_terms(self, element, orig_domain=...): - ... - - def from_list(self, element): - ... - - def from_expr(self, expr): - ... - - def index(self, gen) -> int: - ... - - def drop(self, *gens) -> Self: - ... - - def __getitem__(self, key) -> Self: - ... - - def to_ground(self) -> Self: - ... - - def to_domain(self) -> Any: - ... - - def to_field(self) -> FracField | Any: - ... - - @property - def is_univariate(self) -> bool: - ... - - @property - def is_multivariate(self) -> bool: - ... - - def add(self, *objs): - ... - - def mul(self, *objs): - ... - - def drop_to_ground(self, *gens) -> Self: - ... - - def compose(self, other) -> Self: - ... - - def add_gens(self, symbols) -> Self: - ... - - def symmetric_poly(self, n): - ... - + def __new__(cls, symbols, domain, order=...) -> Self | Any: ... + def __getnewargs__(self) -> tuple[Any, Any, Any]: ... + def __getstate__(self) -> dict[str, Any]: ... + def __hash__(self) -> int: ... + def __eq__(self, other) -> bool: ... + def __ne__(self, other) -> bool: ... + def clone(self, symbols=..., domain=..., order=...) -> Self: ... + def monomial_basis(self, i) -> tuple[Any, ...]: ... + @property + def zero(self): ... + @property + def one(self): ... + def domain_new(self, element, orig_domain=...): ... + def ground_new(self, coeff): ... + def term_new(self, monom, coeff): ... + def ring_new(self, element) -> PolyElement: ... + __call__ = ... + def from_dict(self, element, orig_domain=...): ... + def from_terms(self, element, orig_domain=...): ... + def from_list(self, element): ... + def from_expr(self, expr): ... + def index(self, gen) -> int: ... + def drop(self, *gens) -> Self: ... + def __getitem__(self, key) -> Self: ... + def to_ground(self) -> Self: ... + def to_domain(self) -> Any: ... + def to_field(self) -> FracField | Any: ... + @property + def is_univariate(self) -> bool: ... + @property + def is_multivariate(self) -> bool: ... + def add(self, *objs): ... + def mul(self, *objs): ... + def drop_to_ground(self, *gens) -> Self: ... + def compose(self, other) -> Self: ... + def add_gens(self, symbols) -> Self: ... + def symmetric_poly(self, n): ... class PolyElement(DomainElement, DefaultPrinting, CantSympify, dict): - def new(self, init) -> Self: - ... - - def parent(self): - ... - - def __getnewargs__(self) -> tuple[Any, list[tuple[Any, Any]]]: - ... - + def new(self, init) -> Self: ... + def parent(self): ... + def __getnewargs__(self) -> tuple[Any, list[tuple[Any, Any]]]: ... + _hash = ... - def __hash__(self) -> int: - ... - - def copy(self) -> Self: - ... - - def set_ring(self, new_ring) -> Self: - ... - - def as_expr(self, *symbols) -> Order: - ... - - def as_expr_dict(self) -> dict[Any, Any]: - ... - - def clear_denoms(self) -> tuple[Any, Self]: - ... - - def strip_zero(self) -> None: - ... - - def __eq__(p1, p2) -> bool: - ... - - def __ne__(p1, p2) -> bool: - ... - - def almosteq(p1, p2, tolerance=...) -> bool: - ... - - def sort_key(self) -> tuple[int, list[Any]]: - ... - - def __lt__(p1, p2) -> bool: - ... - - def __le__(p1, p2) -> bool: - ... - - def __gt__(p1, p2) -> bool: - ... - - def __ge__(p1, p2) -> bool: - ... - - def drop(self, gen): - ... - - def drop_to_ground(self, gen): - ... - - def to_dense(self) -> list[Any] | list[list[Any]]: - ... - - def to_dict(self) -> dict[Any, Any]: - ... - - def str(self, printer, precedence, exp_pattern, mul_symbol) -> LiteralString: - ... - + def __hash__(self) -> int: ... + def copy(self) -> Self: ... + def set_ring(self, new_ring) -> Self: ... + def as_expr(self, *symbols) -> Order: ... + def as_expr_dict(self) -> dict[Any, Any]: ... + def clear_denoms(self) -> tuple[Any, Self]: ... + def strip_zero(self) -> None: ... + def __eq__(p1, p2) -> bool: ... + def __ne__(p1, p2) -> bool: ... + def almosteq(p1, p2, tolerance=...) -> bool: ... + def sort_key(self) -> tuple[int, list[Any]]: ... + def __lt__(p1, p2) -> bool: ... + def __le__(p1, p2) -> bool: ... + def __gt__(p1, p2) -> bool: ... + def __ge__(p1, p2) -> bool: ... + def drop(self, gen): ... + def drop_to_ground(self, gen): ... + def to_dense(self) -> list[Any] | list[list[Any]]: ... + def to_dict(self) -> dict[Any, Any]: ... + def str(self, printer, precedence, exp_pattern, mul_symbol) -> LiteralString: ... @property - def is_generator(self) -> bool: - ... - + def is_generator(self) -> bool: ... @property - def is_ground(self) -> bool: - ... - + def is_ground(self) -> bool: ... @property - def is_monomial(self) -> bool: - ... - + def is_monomial(self) -> bool: ... @property - def is_term(self) -> bool: - ... - + def is_term(self) -> bool: ... @property - def is_negative(self): - ... - + def is_negative(self): ... @property - def is_positive(self): - ... - + def is_positive(self): ... @property - def is_nonnegative(self): - ... - + def is_nonnegative(self): ... @property - def is_nonpositive(self): - ... - + def is_nonpositive(self): ... @property - def is_zero(f) -> bool: - ... - + def is_zero(f) -> bool: ... @property - def is_one(f): - ... - + def is_one(f): ... @property - def is_monic(f): - ... - + def is_monic(f): ... @property - def is_primitive(f): - ... - + def is_primitive(f): ... @property - def is_linear(f) -> bool: - ... - + def is_linear(f) -> bool: ... @property - def is_quadratic(f) -> bool: - ... - + def is_quadratic(f) -> bool: ... @property - def is_squarefree(f) -> Literal[True]: - ... - + def is_squarefree(f) -> Literal[True]: ... @property - def is_irreducible(f) -> Literal[True]: - ... - + def is_irreducible(f) -> Literal[True]: ... @property - def is_cyclotomic(f): - ... - - def __neg__(self) -> Self: - ... - - def __pos__(self) -> Self: - ... - - def __add__(p1, p2) -> Self | PolyElement | NotImplementedType: - ... - - def __radd__(p1, n) -> Self | NotImplementedType: - ... - - def __sub__(p1, p2) -> Self | NotImplementedType: - ... - - def __rsub__(p1, n) -> NotImplementedType: - ... - - def __mul__(p1, p2) -> NotImplementedType: - ... - - def __rmul__(p1, p2) -> NotImplementedType: - ... - - def __pow__(self, n) -> Self: - ... - - def square(self): - ... - - def __divmod__(p1, p2) -> tuple[Any, Any] | tuple[list[Any], Any] | NotImplementedType | tuple[Self, Self]: - ... - - def __rdivmod__(p1, p2) -> NotImplementedType: - ... - - def __mod__(p1, p2) -> NotImplementedType | Self: - ... - - def __rmod__(p1, p2) -> NotImplementedType: - ... - - def __truediv__(p1, p2) -> list[Any] | NotImplementedType | Self: - ... - - def __rtruediv__(p1, p2) -> NotImplementedType: - ... - + def is_cyclotomic(f): ... + def __neg__(self) -> Self: ... + def __pos__(self) -> Self: ... + def __add__(p1, p2) -> Self | PolyElement | NotImplementedType: ... + def __radd__(p1, n) -> Self | NotImplementedType: ... + def __sub__(p1, p2) -> Self | NotImplementedType: ... + def __rsub__(p1, n) -> NotImplementedType: ... + def __mul__(p1, p2) -> NotImplementedType: ... + def __rmul__(p1, p2) -> NotImplementedType: ... + def __pow__(self, n) -> Self: ... + def square(self): ... + def __divmod__(p1, p2) -> tuple[Any, Any] | tuple[list[Any], Any] | NotImplementedType | tuple[Self, Self]: ... + def __rdivmod__(p1, p2) -> NotImplementedType: ... + def __mod__(p1, p2) -> NotImplementedType | Self: ... + def __rmod__(p1, p2) -> NotImplementedType: ... + def __truediv__(p1, p2) -> list[Any] | NotImplementedType | Self: ... + def __rtruediv__(p1, p2) -> NotImplementedType: ... + __floordiv__ = ... __rfloordiv__ = ... - def div(self, fv) -> tuple[Any, Any] | tuple[list[Any], Any]: - ... - - def rem(self, G): - ... - - def quo(f, G) -> list[Any]: - ... - - def exquo(f, G) -> list[Any]: - ... - - def degree(f, x=...) -> Literal[0]: - ... - - def degrees(f) -> tuple[Any, ...]: - ... - - def tail_degree(f, x=...) -> Literal[0]: - ... - - def tail_degrees(f) -> tuple[Any, ...]: - ... - - def leading_expv(self) -> None: - ... - - def coeff(self, element): - ... - - def const(self): - ... - - @property - def LC(self): - ... - - @property - def LM(self): - ... - - def leading_monom(self): - ... - - @property - def LT(self) -> tuple[Any, Any]: - ... - - def leading_term(self): - ... - - def coeffs(self, order=...) -> list[Any]: - ... - - def monoms(self, order=...) -> list[Any]: - ... - - def terms(self, order=...) -> list[Any]: - ... - - def itercoeffs(self) -> Iterator[Any]: - ... - - def itermonoms(self) -> Iterator[Any]: - ... - - def iterterms(self) -> Iterator[tuple[Any, Any]]: - ... - - def listcoeffs(self) -> list[Any]: - ... - - def listmonoms(self) -> list[Any]: - ... - - def listterms(self) -> list[tuple[Any, Any]]: - ... - - def imul_num(p, c) -> Self | None: - ... - - def content(f): - ... - - def primitive(f) -> tuple[Any, Self]: - ... - - def monic(f) -> Self: - ... - - def mul_ground(f, x) -> Self: - ... - - def mul_monom(f, monom) -> Self: - ... - - def mul_term(f, term) -> Self: - ... - - def quo_ground(f, x) -> Self: - ... - - def quo_term(f, term) -> Self: - ... - - def trunc_ground(f, p) -> Self: - ... - - rem_ground = ... - def extract_ground(self, g) -> tuple[Any, Self, Any]: - ... - - def max_norm(f): - ... - - def l1_norm(f) -> int: - ... - - def deflate(f, *G) -> tuple[tuple[Any, ...], list[Self]] | tuple[tuple[Any, ...], list[Any]]: - ... - - def inflate(f, J): - ... - - def lcm(self, g): - ... - - def gcd(f, g) -> Self: - ... - - def cofactors(f, g) -> tuple[Any, Any, Any] | tuple[Self, Self, Self]: - ... - - def cancel(self, g) -> tuple[Self, Any] | tuple[Any | Self | PolyElement, Any | Self | PolyElement]: - ... - - def canonical_unit(f): - ... - - def diff(f, x): - ... - - def __call__(f, *values): - ... - - def evaluate(self, x, a=...): - ... - - def subs(self, x, a=...) -> Self: - ... - - def symmetrize(self) -> tuple[Self, Any, list[Any]] | tuple[Any, Self | Any, list[tuple[Any, Any]]]: - ... - - def compose(f, x, a=...): - ... - - def pdiv(f, g): - ... - - def prem(f, g): - ... - - def pquo(f, g): - ... - - def pexquo(f, g): - ... - - def half_gcdex(f, g): - ... - - def gcdex(f, g): - ... - - def subresultants(f, g): - ... - - def resultant(f, g): - ... - - def discriminant(f): - ... - - def decompose(f): - ... - - def shift(f, a): - ... - - def sturm(f): - ... - - def gff_list(f): - ... - - def sqf_norm(f): - ... - - def sqf_part(f): - ... - - def sqf_list(f, all=...): - ... - - def factor_list(f): - ... - - + def div(self, fv) -> tuple[Any, Any] | tuple[list[Any], Any]: ... + def rem(self, G): ... + def quo(f, G) -> list[Any]: ... + def exquo(f, G) -> list[Any]: ... + def degree(f, x=...) -> Literal[0]: ... + def degrees(f) -> tuple[Any, ...]: ... + def tail_degree(f, x=...) -> Literal[0]: ... + def tail_degrees(f) -> tuple[Any, ...]: ... + def leading_expv(self) -> None: ... + def coeff(self, element): ... + def const(self): ... + @property + def LC(self): ... + @property + def LM(self): ... + def leading_monom(self): ... + @property + def LT(self) -> tuple[Any, Any]: ... + def leading_term(self): ... + def coeffs(self, order=...) -> list[Any]: ... + def monoms(self, order=...) -> list[Any]: ... + def terms(self, order=...) -> list[Any]: ... + def itercoeffs(self) -> Iterator[Any]: ... + def itermonoms(self) -> Iterator[Any]: ... + def iterterms(self) -> Iterator[tuple[Any, Any]]: ... + def listcoeffs(self) -> list[Any]: ... + def listmonoms(self) -> list[Any]: ... + def listterms(self) -> list[tuple[Any, Any]]: ... + def imul_num(p, c) -> Self | None: ... + def content(f): ... + def primitive(f) -> tuple[Any, Self]: ... + def monic(f) -> Self: ... + def mul_ground(f, x) -> Self: ... + def mul_monom(f, monom) -> Self: ... + def mul_term(f, term) -> Self: ... + def quo_ground(f, x) -> Self: ... + def quo_term(f, term) -> Self: ... + def trunc_ground(f, p) -> Self: ... + rem_ground = ... + def extract_ground(self, g) -> tuple[Any, Self, Any]: ... + def max_norm(f): ... + def l1_norm(f) -> int: ... + def deflate(f, *G) -> tuple[tuple[Any, ...], list[Self]] | tuple[tuple[Any, ...], list[Any]]: ... + def inflate(f, J): ... + def lcm(self, g): ... + def gcd(f, g) -> Self: ... + def cofactors(f, g) -> tuple[Any, Any, Any] | tuple[Self, Self, Self]: ... + def cancel(self, g) -> tuple[Self, Any] | tuple[Any | Self | PolyElement, Any | Self | PolyElement]: ... + def canonical_unit(f): ... + def diff(f, x): ... + def __call__(f, *values): ... + def evaluate(self, x, a=...): ... + def subs(self, x, a=...) -> Self: ... + def symmetrize(self) -> tuple[Self, Any, list[Any]] | tuple[Any, Self | Any, list[tuple[Any, Any]]]: ... + def compose(f, x, a=...): ... + def pdiv(f, g): ... + def prem(f, g): ... + def pquo(f, g): ... + def pexquo(f, g): ... + def half_gcdex(f, g): ... + def gcdex(f, g): ... + def subresultants(f, g): ... + def resultant(f, g): ... + def discriminant(f): ... + def decompose(f): ... + def shift(f, a): ... + def sturm(f): ... + def gff_list(f): ... + def sqf_norm(f): ... + def sqf_part(f): ... + def sqf_list(f, all=...): ... + def factor_list(f): ... diff --git a/stubs/sympy-stubs/polys/rootisolation.pyi b/stubs/sympy-stubs/polys/rootisolation.pyi index 7ede46a2..f0bdd159 100644 --- a/stubs/sympy-stubs/polys/rootisolation.pyi +++ b/stubs/sympy-stubs/polys/rootisolation.pyi @@ -1,55 +1,46 @@ from typing import Any, Literal, LiteralString, Self -def dup_sturm(f, K) -> list[Any | list[Any]]: - ... - -def dup_root_upper_bound(f, K) -> None: - ... - -def dup_root_lower_bound(f, K) -> None: - ... - -def dup_cauchy_upper_bound(f, K): - ... - -def dup_cauchy_lower_bound(f, K): - ... - -def dup_mignotte_sep_bound_squared(f, K): - ... - -def dup_step_refine_real_root(f, M, K, fast=...) -> tuple[Any, tuple[Any, Any, Any, Any]] | tuple[list[Any], tuple[Any, Any, Any, Any]] | tuple[list[Any] | Any, tuple[Any, Any, Any, Any]]: - ... - -def dup_inner_refine_real_root(f, M, K, eps=..., steps=..., disjoint=..., fast=..., mobius=...) -> tuple[Any, Any] | tuple[Any | list[Any], tuple[Any, Any, Any, Any]]: - ... - -def dup_outer_refine_real_root(f, s, t, K, eps=..., steps=..., disjoint=..., fast=...) -> tuple[Any, Any] | tuple[Any | list[Any], tuple[Any, Any, Any, Any]]: - ... - -def dup_refine_real_root(f, s, t, K, eps=..., steps=..., disjoint=..., fast=...) -> tuple[Any, Any] | tuple[Any | list[Any], Any | tuple[Any, Any, Any, Any]]: - ... - -def dup_inner_isolate_real_roots(f, K, eps=..., fast=...) -> list[Any] | list[tuple[Any, Any] | tuple[Any | list[Any], tuple[Any, Any, Any, Any]]]: - ... - -def dup_inner_isolate_positive_roots(f, K, eps=..., inf=..., sup=..., fast=..., mobius=...) -> list[Any] | list[tuple[Any, Any] | tuple[Any | list[Any], tuple[Any, Any, Any, Any]]]: - ... - -def dup_inner_isolate_negative_roots(f, K, inf=..., sup=..., eps=..., fast=..., mobius=...) -> list[Any] | list[tuple[Any, Any] | tuple[Any | list[Any], tuple[Any, Any, Any, Any]]]: - ... - -def dup_isolate_real_roots_sqf(f, K, eps=..., inf=..., sup=..., fast=..., blackbox=...) -> list[Any] | list[tuple[Any, Any] | tuple[Any | list[Any], tuple[Any, Any, Any, Any]]] | list[RealInterval]: - ... - -def dup_isolate_real_roots(f, K, eps=..., inf=..., sup=..., basis=..., fast=...) -> list[Any] | list[tuple[tuple[Any, Any], Any, Any] | tuple[Any, Any]]: - ... - -def dup_isolate_real_roots_list(polys, K, eps=..., inf=..., sup=..., strict=..., basis=..., fast=...) -> list[tuple[tuple[Any, Any], Any, Any] | tuple[tuple[Any, Any], dict[Any, Any]]]: - ... - -def dup_count_real_roots(f, K, inf=..., sup=...) -> int: - ... +def dup_sturm(f, K) -> list[Any | list[Any]]: ... +def dup_root_upper_bound(f, K) -> None: ... +def dup_root_lower_bound(f, K) -> None: ... +def dup_cauchy_upper_bound(f, K): ... +def dup_cauchy_lower_bound(f, K): ... +def dup_mignotte_sep_bound_squared(f, K): ... +def dup_step_refine_real_root( + f, M, K, fast=... +) -> ( + tuple[Any, tuple[Any, Any, Any, Any]] + | tuple[list[Any], tuple[Any, Any, Any, Any]] + | tuple[list[Any] | Any, tuple[Any, Any, Any, Any]] +): ... +def dup_inner_refine_real_root( + f, M, K, eps=..., steps=..., disjoint=..., fast=..., mobius=... +) -> tuple[Any, Any] | tuple[Any | list[Any], tuple[Any, Any, Any, Any]]: ... +def dup_outer_refine_real_root( + f, s, t, K, eps=..., steps=..., disjoint=..., fast=... +) -> tuple[Any, Any] | tuple[Any | list[Any], tuple[Any, Any, Any, Any]]: ... +def dup_refine_real_root( + f, s, t, K, eps=..., steps=..., disjoint=..., fast=... +) -> tuple[Any, Any] | tuple[Any | list[Any], Any | tuple[Any, Any, Any, Any]]: ... +def dup_inner_isolate_real_roots( + f, K, eps=..., fast=... +) -> list[Any] | list[tuple[Any, Any] | tuple[Any | list[Any], tuple[Any, Any, Any, Any]]]: ... +def dup_inner_isolate_positive_roots( + f, K, eps=..., inf=..., sup=..., fast=..., mobius=... +) -> list[Any] | list[tuple[Any, Any] | tuple[Any | list[Any], tuple[Any, Any, Any, Any]]]: ... +def dup_inner_isolate_negative_roots( + f, K, inf=..., sup=..., eps=..., fast=..., mobius=... +) -> list[Any] | list[tuple[Any, Any] | tuple[Any | list[Any], tuple[Any, Any, Any, Any]]]: ... +def dup_isolate_real_roots_sqf( + f, K, eps=..., inf=..., sup=..., fast=..., blackbox=... +) -> list[Any] | list[tuple[Any, Any] | tuple[Any | list[Any], tuple[Any, Any, Any, Any]]] | list[RealInterval]: ... +def dup_isolate_real_roots( + f, K, eps=..., inf=..., sup=..., basis=..., fast=... +) -> list[Any] | list[tuple[tuple[Any, Any], Any, Any] | tuple[Any, Any]]: ... +def dup_isolate_real_roots_list( + polys, K, eps=..., inf=..., sup=..., strict=..., basis=..., fast=... +) -> list[tuple[tuple[Any, Any], Any, Any] | tuple[tuple[Any, Any], dict[Any, Any]]]: ... +def dup_count_real_roots(f, K, inf=..., sup=...) -> int: ... OO = ... Q1 = ... @@ -63,152 +54,71 @@ A4 = ... _rules_simple = ... _rules_ambiguous = ... _values = ... -def dup_count_complex_roots(f, K, inf=..., sup=..., exclude=...) -> int: - ... - -def dup_isolate_complex_roots_sqf(f, K, eps=..., inf=..., sup=..., blackbox=...): - ... -def dup_isolate_all_roots_sqf(f, K, eps=..., inf=..., sup=..., fast=..., blackbox=...) -> tuple[list[Any] | list[tuple[Any, Any] | tuple[Any | list[Any], tuple[Any, Any, Any, Any]]] | list[RealInterval], Any]: - ... - -def dup_isolate_all_roots(f, K, eps=..., inf=..., sup=..., fast=...) -> tuple[list[tuple[tuple[Any | list[Any], Any | tuple[Any, Any, Any, Any]], Any]], list[tuple[tuple[Any, Any], Any]]]: - ... +def dup_count_complex_roots(f, K, inf=..., sup=..., exclude=...) -> int: ... +def dup_isolate_complex_roots_sqf(f, K, eps=..., inf=..., sup=..., blackbox=...): ... +def dup_isolate_all_roots_sqf( + f, K, eps=..., inf=..., sup=..., fast=..., blackbox=... +) -> tuple[list[Any] | list[tuple[Any, Any] | tuple[Any | list[Any], tuple[Any, Any, Any, Any]]] | list[RealInterval], Any]: ... +def dup_isolate_all_roots( + f, K, eps=..., inf=..., sup=..., fast=... +) -> tuple[list[tuple[tuple[Any | list[Any], Any | tuple[Any, Any, Any, Any]], Any]], list[tuple[tuple[Any, Any], Any]]]: ... class RealInterval: - def __init__(self, data, f, dom) -> None: - ... - - @property - def func(self) -> type[RealInterval]: - ... - - @property - def args(self) -> tuple[tuple[Any, ...] | Any, list[Any] | Any, Any]: - ... - - def __eq__(self, other) -> bool: - ... - - @property - def a(self): - ... - - @property - def b(self): - ... - - @property - def dx(self): - ... - - @property - def center(self): - ... - - @property - def max_denom(self): - ... - - def as_tuple(self) -> tuple[Any, Any]: - ... - - def __repr__(self) -> LiteralString: - ... - - def __contains__(self, item) -> Literal[False]: - ... - - def is_disjoint(self, other): - ... - - def refine_disjoint(self, other) -> tuple[Self | RealInterval, Any]: - ... - - def refine_size(self, dx) -> Self | RealInterval: - ... - - def refine_step(self, steps=...) -> Self | RealInterval: - ... - - def refine(self) -> Self | RealInterval: - ... - - + def __init__(self, data, f, dom) -> None: ... + @property + def func(self) -> type[RealInterval]: ... + @property + def args(self) -> tuple[tuple[Any, ...] | Any, list[Any] | Any, Any]: ... + def __eq__(self, other) -> bool: ... + @property + def a(self): ... + @property + def b(self): ... + @property + def dx(self): ... + @property + def center(self): ... + @property + def max_denom(self): ... + def as_tuple(self) -> tuple[Any, Any]: ... + def __repr__(self) -> LiteralString: ... + def __contains__(self, item) -> Literal[False]: ... + def is_disjoint(self, other): ... + def refine_disjoint(self, other) -> tuple[Self | RealInterval, Any]: ... + def refine_size(self, dx) -> Self | RealInterval: ... + def refine_step(self, steps=...) -> Self | RealInterval: ... + def refine(self) -> Self | RealInterval: ... class ComplexInterval: - def __init__(self, a, b, I, Q, F1, F2, f1, f2, dom, conj=...) -> None: - ... - - @property - def func(self) -> type[ComplexInterval]: - ... - - @property - def args(self) -> tuple[Any, Any, Any, Any, Any, Any, Any, Any, Any, bool]: - ... - - def __eq__(self, other) -> bool: - ... - - @property - def ax(self): - ... - - @property - def ay(self): - ... - - @property - def bx(self): - ... - - @property - def by(self): - ... - - @property - def dx(self): - ... - - @property - def dy(self): - ... - - @property - def center(self) -> tuple[Any, Any]: - ... - - @property - def max_denom(self): - ... - - def as_tuple(self) -> tuple[tuple[Any, Any], tuple[Any, Any]]: - ... - - def __repr__(self) -> LiteralString: - ... - - def conjugate(self) -> ComplexInterval: - ... - - def __contains__(self, item): - ... - - def is_disjoint(self, other) -> Literal[True]: - ... - - def refine_disjoint(self, other) -> tuple[Self | ComplexInterval, Any]: - ... - - def refine_size(self, dx, dy=...) -> Self | ComplexInterval: - ... - - def refine_step(self, steps=...) -> Self | ComplexInterval: - ... - - def refine(self) -> ComplexInterval: - ... - - - + def __init__(self, a, b, I, Q, F1, F2, f1, f2, dom, conj=...) -> None: ... + @property + def func(self) -> type[ComplexInterval]: ... + @property + def args(self) -> tuple[Any, Any, Any, Any, Any, Any, Any, Any, Any, bool]: ... + def __eq__(self, other) -> bool: ... + @property + def ax(self): ... + @property + def ay(self): ... + @property + def bx(self): ... + @property + def by(self): ... + @property + def dx(self): ... + @property + def dy(self): ... + @property + def center(self) -> tuple[Any, Any]: ... + @property + def max_denom(self): ... + def as_tuple(self) -> tuple[tuple[Any, Any], tuple[Any, Any]]: ... + def __repr__(self) -> LiteralString: ... + def conjugate(self) -> ComplexInterval: ... + def __contains__(self, item): ... + def is_disjoint(self, other) -> Literal[True]: ... + def refine_disjoint(self, other) -> tuple[Self | ComplexInterval, Any]: ... + def refine_size(self, dx, dy=...) -> Self | ComplexInterval: ... + def refine_step(self, steps=...) -> Self | ComplexInterval: ... + def refine(self) -> ComplexInterval: ... diff --git a/stubs/sympy-stubs/polys/rootoftools.pyi b/stubs/sympy-stubs/polys/rootoftools.pyi index 768aae23..9b4e1b65 100644 --- a/stubs/sympy-stubs/polys/rootoftools.pyi +++ b/stubs/sympy-stubs/polys/rootoftools.pyi @@ -5,35 +5,23 @@ from sympy.core.numbers import Integer from sympy.series.order import Order from sympy.utilities import public -__all__ = ['CRootOf'] -class _pure_key_dict: - def __init__(self) -> None: - ... - - def __getitem__(self, k): - ... - - def __setitem__(self, k, v) -> None: - ... - - def __contains__(self, k) -> bool: - ... - +__all__ = ["CRootOf"] +class _pure_key_dict: + def __init__(self) -> None: ... + def __getitem__(self, k): ... + def __setitem__(self, k, v) -> None: ... + def __contains__(self, k) -> bool: ... _reals_cache = ... _complexes_cache = ... -@public -def rootof(f, x, index=..., radicals=..., expand=...) -> Any: - ... +@public +def rootof(f, x, index=..., radicals=..., expand=...) -> Any: ... @public class RootOf(Expr): __slots__ = ... - def __new__(cls, f, x, index=..., radicals=..., expand=...) -> Any: - ... - - + def __new__(cls, f, x, index=..., radicals=..., expand=...) -> Any: ... @public class ComplexRootOf(RootOf): @@ -41,70 +29,36 @@ class ComplexRootOf(RootOf): is_complex = ... is_number = ... is_finite = ... - def __new__(cls, f, x, index=..., radicals=..., expand=...) -> Any: - ... - + def __new__(cls, f, x, index=..., radicals=..., expand=...) -> Any: ... @property - def expr(self): - ... - + def expr(self): ... @property - def args(self) -> tuple[Any, Any | Integer]: - ... - + def args(self) -> tuple[Any, Any | Integer]: ... @property - def free_symbols(self) -> set[Any]: - ... - + def free_symbols(self) -> set[Any]: ... @classmethod - def real_roots(cls, poly, radicals=...) -> list[Any]: - ... - + def real_roots(cls, poly, radicals=...) -> list[Any]: ... @classmethod - def all_roots(cls, poly, radicals=...) -> list[Any]: - ... - + def all_roots(cls, poly, radicals=...) -> list[Any]: ... @classmethod - def clear_cache(cls) -> None: - ... - - def eval_approx(self, n, return_mpmath=...): - ... - - def eval_rational(self, dx=..., dy=..., n=...): - ... - - + def clear_cache(cls) -> None: ... + def eval_approx(self, n, return_mpmath=...): ... + def eval_rational(self, dx=..., dy=..., n=...): ... CRootOf = ... + @public class RootSum(Expr): __slots__ = ... - def __new__(cls, expr, func=..., x=..., auto=..., quadratic=...): - ... - + def __new__(cls, expr, func=..., x=..., auto=..., quadratic=...): ... @classmethod - def new(cls, poly, func, auto=...) -> Self | Any: - ... - + def new(cls, poly, func, auto=...) -> Self | Any: ... @property - def expr(self): - ... - + def expr(self): ... @property - def args(self) -> tuple[Any, Any, Any]: - ... - + def args(self) -> tuple[Any, Any, Any]: ... @property - def free_symbols(self): - ... - + def free_symbols(self): ... @property - def is_commutative(self) -> Literal[True]: - ... - - def doit(self, **hints) -> Self | Order: - ... - - - + def is_commutative(self) -> Literal[True]: ... + def doit(self, **hints) -> Self | Order: ... diff --git a/stubs/sympy-stubs/polys/solvers.pyi b/stubs/sympy-stubs/polys/solvers.pyi index 303c24bc..ac2f0e2c 100644 --- a/stubs/sympy-stubs/polys/solvers.pyi +++ b/stubs/sympy-stubs/polys/solvers.pyi @@ -3,23 +3,12 @@ from typing import Any from sympy.matrices.dense import MutableDenseMatrix from sympy.polys.matrices.domainmatrix import DomainMatrix -class PolyNonlinearError(Exception): - ... - +class PolyNonlinearError(Exception): ... class RawMatrix(MutableDenseMatrix): _sympify = ... - def __init__(self, *args, **kwargs) -> None: - ... - - - -def eqs_to_matrix(eqs_coeffs, eqs_rhs, gens, domain) -> DomainMatrix: - ... - -def sympy_eqs_to_ring(eqs, symbols) -> tuple[Any, Any]: - ... - -def solve_lin_sys(eqs, ring, _raw=...) -> dict[Any, Any] | None: - ... + def __init__(self, *args, **kwargs) -> None: ... +def eqs_to_matrix(eqs_coeffs, eqs_rhs, gens, domain) -> DomainMatrix: ... +def sympy_eqs_to_ring(eqs, symbols) -> tuple[Any, Any]: ... +def solve_lin_sys(eqs, ring, _raw=...) -> dict[Any, Any] | None: ... diff --git a/stubs/sympy-stubs/polys/specialpolys.pyi b/stubs/sympy-stubs/polys/specialpolys.pyi index cbb20352..065c353c 100644 --- a/stubs/sympy-stubs/polys/specialpolys.pyi +++ b/stubs/sympy-stubs/polys/specialpolys.pyi @@ -4,46 +4,26 @@ from sympy.series.order import Order from sympy.utilities import public @public -def swinnerton_dyer_poly(n, x=..., polys=...) -> Any: - ... - +def swinnerton_dyer_poly(n, x=..., polys=...) -> Any: ... @public -def cyclotomic_poly(n, x=..., polys=...): - ... - +def cyclotomic_poly(n, x=..., polys=...): ... @public -def symmetric_poly(n, *gens, polys=...) -> Any | Order: - ... - +def symmetric_poly(n, *gens, polys=...) -> Any | Order: ... @public -def random_poly(x, n, inf, sup, domain=..., polys=...) -> Any: - ... - +def random_poly(x, n, inf, sup, domain=..., polys=...) -> Any: ... @public -def interpolating_poly(n, x, X=..., Y=...) -> Order: - ... - -def fateman_poly_F_1(n) -> tuple[Any, Any, Any]: - ... - -def dmp_fateman_poly_F_1(n, K) -> tuple[Any | list[Any] | list[list[Any]], Any | list[Any] | list[list[Any]], list[list[Any]] | Any | list[Any]]: - ... - -def fateman_poly_F_2(n) -> tuple[Any, Any, Any]: - ... - -def dmp_fateman_poly_F_2(n, K) -> tuple[Any | list[Any] | list[list[Any]], Any | list[Any] | list[list[Any]], Any | list[list[Any]]]: - ... - -def fateman_poly_F_3(n) -> tuple[Any, Any, Any]: - ... - -def dmp_fateman_poly_F_3(n, K) -> tuple[Any | list[Any] | list[list[Any]], Any | list[Any] | list[list[Any]], Any | list[list[Any]]]: - ... - -def f_polys() -> tuple[Any, Any, Any, Any, Any, Any, Any]: - ... - -def w_polys() -> tuple[Any, Any]: - ... - +def interpolating_poly(n, x, X=..., Y=...) -> Order: ... +def fateman_poly_F_1(n) -> tuple[Any, Any, Any]: ... +def dmp_fateman_poly_F_1( + n, K +) -> tuple[Any | list[Any] | list[list[Any]], Any | list[Any] | list[list[Any]], list[list[Any]] | Any | list[Any]]: ... +def fateman_poly_F_2(n) -> tuple[Any, Any, Any]: ... +def dmp_fateman_poly_F_2( + n, K +) -> tuple[Any | list[Any] | list[list[Any]], Any | list[Any] | list[list[Any]], Any | list[list[Any]]]: ... +def fateman_poly_F_3(n) -> tuple[Any, Any, Any]: ... +def dmp_fateman_poly_F_3( + n, K +) -> tuple[Any | list[Any] | list[list[Any]], Any | list[Any] | list[list[Any]], Any | list[list[Any]]]: ... +def f_polys() -> tuple[Any, Any, Any, Any, Any, Any, Any]: ... +def w_polys() -> tuple[Any, Any]: ... diff --git a/stubs/sympy-stubs/polys/sqfreetools.pyi b/stubs/sympy-stubs/polys/sqfreetools.pyi index b162f590..b06b520d 100644 --- a/stubs/sympy-stubs/polys/sqfreetools.pyi +++ b/stubs/sympy-stubs/polys/sqfreetools.pyi @@ -1,53 +1,61 @@ from typing import Any, Literal -def dup_sqf_p(f, K) -> bool: - ... - -def dmp_sqf_p(f, u, K) -> bool: - ... - -def dup_sqf_norm(f, K) -> tuple[int, Any | list[Any], tuple[Any, list[Any]] | Any | tuple[list[list[Any]], list[Any]] | tuple[list[list[Any]] | Any | list[Any], list[Any]] | list[list[Any]] | list[Any]]: - ... - -def dmp_sqf_norm(f, u, K) -> tuple[int, Any | list[Any], tuple[Any, list[Any]] | Any | tuple[list[list[Any]], list[Any]] | tuple[list[list[Any]] | Any | list[Any], list[Any]] | list[list[Any]] | list[Any]] | tuple[int, Any | list[Any] | list[list[Any]], tuple[Any, list[Any]] | Any | tuple[list[list[Any]], list[Any]] | tuple[list[list[Any]] | Any | list[Any], list[Any]] | list[list[Any]] | list[Any]]: - ... - -def dmp_norm(f, u, K) -> tuple[Any, list[Any]] | tuple[list[list[Any]], list[Any]] | tuple[list[list[Any]] | Any | list[Any], list[Any]] | list[list[Any]] | list[Any]: - ... - -def dup_gf_sqf_part(f, K): - ... - -def dmp_gf_sqf_part(f, u, K): - ... - -def dup_sqf_part(f, K) -> list[Any]: - ... - -def dmp_sqf_part(f, u, K) -> list[Any]: - ... - -def dup_gf_sqf_list(f, K, all=...) -> tuple[Any, list[Any]]: - ... - -def dmp_gf_sqf_list(f, u, K, all=...): - ... - -def dup_sqf_list(f, K, all=...) -> tuple[Any, list[Any]]: - ... - -def dup_sqf_list_include(f, K, all=...) -> list[tuple[list[Any], Literal[1]]] | list[tuple[Any, Literal[1]]]: - ... - -def dmp_sqf_list(f, u, K, all=...) -> tuple[Any, list[Any]]: - ... - -def dmp_sqf_list_include(f, u, K, all=...) -> list[tuple[list[Any], Literal[1]]] | list[tuple[Any, Literal[1]]] | list[tuple[list[list[Any]] | Any | list[Any], Literal[1]]]: - ... - -def dup_gff_list(f, K) -> list[Any]: - ... - -def dmp_gff_list(f, u, K) -> list[Any]: - ... - +def dup_sqf_p(f, K) -> bool: ... +def dmp_sqf_p(f, u, K) -> bool: ... +def dup_sqf_norm(f, K) -> tuple[ + int, + Any | list[Any], + tuple[Any, list[Any]] + | Any + | tuple[list[list[Any]], list[Any]] + | tuple[list[list[Any]] | Any | list[Any], list[Any]] + | list[list[Any]] + | list[Any], +]: ... +def dmp_sqf_norm(f, u, K) -> ( + tuple[ + int, + Any | list[Any], + tuple[Any, list[Any]] + | Any + | tuple[list[list[Any]], list[Any]] + | tuple[list[list[Any]] | Any | list[Any], list[Any]] + | list[list[Any]] + | list[Any], + ] + | tuple[ + int, + Any | list[Any] | list[list[Any]], + tuple[Any, list[Any]] + | Any + | tuple[list[list[Any]], list[Any]] + | tuple[list[list[Any]] | Any | list[Any], list[Any]] + | list[list[Any]] + | list[Any], + ] +): ... +def dmp_norm( + f, u, K +) -> ( + tuple[Any, list[Any]] + | tuple[list[list[Any]], list[Any]] + | tuple[list[list[Any]] | Any | list[Any], list[Any]] + | list[list[Any]] + | list[Any] +): ... +def dup_gf_sqf_part(f, K): ... +def dmp_gf_sqf_part(f, u, K): ... +def dup_sqf_part(f, K) -> list[Any]: ... +def dmp_sqf_part(f, u, K) -> list[Any]: ... +def dup_gf_sqf_list(f, K, all=...) -> tuple[Any, list[Any]]: ... +def dmp_gf_sqf_list(f, u, K, all=...): ... +def dup_sqf_list(f, K, all=...) -> tuple[Any, list[Any]]: ... +def dup_sqf_list_include(f, K, all=...) -> list[tuple[list[Any], Literal[1]]] | list[tuple[Any, Literal[1]]]: ... +def dmp_sqf_list(f, u, K, all=...) -> tuple[Any, list[Any]]: ... +def dmp_sqf_list_include( + f, u, K, all=... +) -> ( + list[tuple[list[Any], Literal[1]]] | list[tuple[Any, Literal[1]]] | list[tuple[list[list[Any]] | Any | list[Any], Literal[1]]] +): ... +def dup_gff_list(f, K) -> list[Any]: ... +def dmp_gff_list(f, u, K) -> list[Any]: ... diff --git a/stubs/sympy-stubs/printing/__init__.pyi b/stubs/sympy-stubs/printing/__init__.pyi index 833e6248..7cc86688 100644 --- a/stubs/sympy-stubs/printing/__init__.pyi +++ b/stubs/sympy-stubs/printing/__init__.pyi @@ -21,4 +21,46 @@ from sympy.printing.str import StrPrinter, sstr, sstrrepr from sympy.printing.tableform import TableForm from sympy.printing.tree import print_tree -__all__ = ['pager_print', 'pretty', 'pretty_print', 'pprint', 'pprint_use_unicode', 'pprint_try_use_unicode', 'latex', 'print_latex', 'multiline_latex', 'mathml', 'print_mathml', 'python', 'print_python', 'pycode', 'ccode', 'print_ccode', 'cxxcode', 'fcode', 'print_fcode', 'smtlib_code', 'glsl_code', 'print_glsl', 'rcode', 'print_rcode', 'jscode', 'print_jscode', 'julia_code', 'mathematica_code', 'octave_code', 'rust_code', 'print_gtk', 'preview', 'srepr', 'print_tree', 'StrPrinter', 'sstr', 'sstrrepr', 'TableForm', 'dotprint', 'maple_code', 'print_maple_code'] +__all__ = [ + "pager_print", + "pretty", + "pretty_print", + "pprint", + "pprint_use_unicode", + "pprint_try_use_unicode", + "latex", + "print_latex", + "multiline_latex", + "mathml", + "print_mathml", + "python", + "print_python", + "pycode", + "ccode", + "print_ccode", + "cxxcode", + "fcode", + "print_fcode", + "smtlib_code", + "glsl_code", + "print_glsl", + "rcode", + "print_rcode", + "jscode", + "print_jscode", + "julia_code", + "mathematica_code", + "octave_code", + "rust_code", + "print_gtk", + "preview", + "srepr", + "print_tree", + "StrPrinter", + "sstr", + "sstrrepr", + "TableForm", + "dotprint", + "maple_code", + "print_maple_code", +] diff --git a/stubs/sympy-stubs/printing/c.pyi b/stubs/sympy-stubs/printing/c.pyi index a633784e..3e28a9cf 100644 --- a/stubs/sympy-stubs/printing/c.pyi +++ b/stubs/sympy-stubs/printing/c.pyi @@ -9,8 +9,8 @@ known_functions_C89 = ... known_functions_C99 = ... reserved_words = ... reserved_words_c99 = ... -def get_math_macros() -> dict[Any | type[UndefinedFunction] | Pow, str]: - ... + +def get_math_macros() -> dict[Any | type[UndefinedFunction] | Pow, str]: ... class C89CodePrinter(CodePrinter): printmethod = ... @@ -28,16 +28,12 @@ class C89CodePrinter(CodePrinter): math_macros = ... _ns = ... _kf: dict[str, Any] = ... - def __init__(self, settings=...) -> None: - ... - - def indent_code(self, code) -> str | list[Any]: - ... - + def __init__(self, settings=...) -> None: ... + def indent_code(self, code) -> str | list[Any]: ... + _print_List = ... _print_union = ... - class C99CodePrinter(C89CodePrinter): standard = ... reserved_words = ... @@ -46,9 +42,6 @@ class C99CodePrinter(C89CodePrinter): _kf: dict[str, Any] = ... _prec_funcs = ... - -class C11CodePrinter(C99CodePrinter): - ... - +class C11CodePrinter(C99CodePrinter): ... c_code_printers = ... diff --git a/stubs/sympy-stubs/printing/codeprinter.pyi b/stubs/sympy-stubs/printing/codeprinter.pyi index f8a7c340..ccf933f4 100644 --- a/stubs/sympy-stubs/printing/codeprinter.pyi +++ b/stubs/sympy-stubs/printing/codeprinter.pyi @@ -4,28 +4,18 @@ from typing import Any from sympy.printing.str import StrPrinter class requires: - def __init__(self, **kwargs) -> None: - ... - - def __call__(self, method) -> _Wrapped[..., Any, ..., Any]: - ... - - - -class AssignmentError(Exception): - ... + def __init__(self, **kwargs) -> None: ... + def __call__(self, method) -> _Wrapped[..., Any, ..., Any]: ... +class AssignmentError(Exception): ... class CodePrinter(StrPrinter): _operators = ... _default_settings: dict[str, Any] = ... _rewriteable_functions = ... - def __init__(self, settings=...) -> None: - ... - - def doprint(self, expr, assign_to=...) -> str | tuple[set[tuple[Any, str]], set[Any], str]: - ... - + def __init__(self, settings=...) -> None: ... + def doprint(self, expr, assign_to=...) -> str | tuple[set[tuple[Any, str]], set[Any], str]: ... + _print_Expr = ... _print_Heaviside = ... _print_Basic = ... @@ -52,19 +42,8 @@ class CodePrinter(StrPrinter): _print_WildFunction = ... _print_Relational = ... - -def ccode(expr, assign_to=..., standard=..., **settings): - ... - -def print_ccode(expr, **settings) -> None: - ... - -def fcode(expr, assign_to=..., **settings) -> str | tuple[set[tuple[Any, str]], set[Any], str]: - ... - -def print_fcode(expr, **settings) -> None: - ... - -def cxxcode(expr, assign_to=..., standard=..., **settings): - ... - +def ccode(expr, assign_to=..., standard=..., **settings): ... +def print_ccode(expr, **settings) -> None: ... +def fcode(expr, assign_to=..., **settings) -> str | tuple[set[tuple[Any, str]], set[Any], str]: ... +def print_fcode(expr, **settings) -> None: ... +def cxxcode(expr, assign_to=..., standard=..., **settings): ... diff --git a/stubs/sympy-stubs/printing/conventions.pyi b/stubs/sympy-stubs/printing/conventions.pyi index 90ee9234..0db97420 100644 --- a/stubs/sympy-stubs/printing/conventions.pyi +++ b/stubs/sympy-stubs/printing/conventions.pyi @@ -1,9 +1,6 @@ from typing import Any _name_with_digits_p = ... -def split_super_sub(text) -> tuple[Any, list[Any], list[Any]] | tuple[Any | None, list[Any], list[Any]]: - ... - -def requires_partial(expr) -> bool: - ... +def split_super_sub(text) -> tuple[Any, list[Any], list[Any]] | tuple[Any | None, list[Any], list[Any]]: ... +def requires_partial(expr) -> bool: ... diff --git a/stubs/sympy-stubs/printing/cxx.pyi b/stubs/sympy-stubs/printing/cxx.pyi index e260e9ad..7b9e1953 100644 --- a/stubs/sympy-stubs/printing/cxx.pyi +++ b/stubs/sympy-stubs/printing/cxx.pyi @@ -2,30 +2,25 @@ from sympy.printing.c import C89CodePrinter, C99CodePrinter reserved = ... _math_functions = ... + class _CXXCodePrinterBase: printmethod = ... language = ... _ns = ... - def __init__(self, settings=...) -> None: - ... - - + def __init__(self, settings=...) -> None: ... class CXX98CodePrinter(_CXXCodePrinterBase, C89CodePrinter): standard = ... reserved_words = ... - class CXX11CodePrinter(_CXXCodePrinterBase, C99CodePrinter): standard = ... reserved_words = ... type_mappings = ... - class CXX17CodePrinter(_CXXCodePrinterBase, C99CodePrinter): standard = ... reserved_words = ... _kf = ... - cxx_code_printers = ... diff --git a/stubs/sympy-stubs/printing/dot.pyi b/stubs/sympy-stubs/printing/dot.pyi index 8206077b..97489494 100644 --- a/stubs/sympy-stubs/printing/dot.pyi +++ b/stubs/sympy-stubs/printing/dot.pyi @@ -1,25 +1,16 @@ from typing import Any -__all__ = ['dotprint'] +__all__ = ["dotprint"] default_styles = ... slotClasses = ... -def purestr(x, with_args=...) -> tuple[str | Any, tuple[()] | tuple[Any, ...]] | str: - ... -def styleof(expr, styles=...) -> dict[Any, Any]: - ... - -def attrprint(d, delimiter=...) -> str: - ... - -def dotnode(expr, styles=..., labelfunc=..., pos=..., repeat=...) -> str: - ... - -def dotedges(expr, atom=..., pos=..., repeat=...) -> list[Any] | list[str]: - ... +def purestr(x, with_args=...) -> tuple[str | Any, tuple[()] | tuple[Any, ...]] | str: ... +def styleof(expr, styles=...) -> dict[Any, Any]: ... +def attrprint(d, delimiter=...) -> str: ... +def dotnode(expr, styles=..., labelfunc=..., pos=..., repeat=...) -> str: ... +def dotedges(expr, atom=..., pos=..., repeat=...) -> list[Any] | list[str]: ... template = ... _graphstyle = ... -def dotprint(expr, styles=..., atom=..., maxdepth=..., repeat=..., labelfunc=..., **kwargs) -> str: - ... +def dotprint(expr, styles=..., atom=..., maxdepth=..., repeat=..., labelfunc=..., **kwargs) -> str: ... diff --git a/stubs/sympy-stubs/printing/fortran.pyi b/stubs/sympy-stubs/printing/fortran.pyi index dc857be6..41ee3e84 100644 --- a/stubs/sympy-stubs/printing/fortran.pyi +++ b/stubs/sympy-stubs/printing/fortran.pyi @@ -3,6 +3,7 @@ from typing import Any from sympy.printing.codeprinter import CodePrinter known_functions = ... + class FCodePrinter(CodePrinter): printmethod = ... language = ... @@ -12,11 +13,5 @@ class FCodePrinter(CodePrinter): _default_settings: dict[str, Any] = ... _operators = ... _relationals = ... - def __init__(self, settings=...) -> None: - ... - - def indent_code(self, code) -> str | list[Any]: - ... - - - + def __init__(self, settings=...) -> None: ... + def indent_code(self, code) -> str | list[Any]: ... diff --git a/stubs/sympy-stubs/printing/glsl.pyi b/stubs/sympy-stubs/printing/glsl.pyi index 3b2cbb3d..63944ce0 100644 --- a/stubs/sympy-stubs/printing/glsl.pyi +++ b/stubs/sympy-stubs/printing/glsl.pyi @@ -4,24 +4,17 @@ from sympy.core import Basic from sympy.printing.codeprinter import CodePrinter known_functions = ... + class GLSLPrinter(CodePrinter): _not_supported: set[Basic] = ... printmethod = ... language = ... _default_settings = ... - def __init__(self, settings=...) -> None: - ... - - def indent_code(self, code) -> str | list[Any]: - ... - + def __init__(self, settings=...) -> None: ... + def indent_code(self, code) -> str | list[Any]: ... + _print_tuple = ... _print_Tuple = ... - -def glsl_code(expr, assign_to=..., **settings) -> str | tuple[set[tuple[Any, str]], set[Any], str]: - ... - -def print_glsl(expr, **settings) -> None: - ... - +def glsl_code(expr, assign_to=..., **settings) -> str | tuple[set[tuple[Any, str]], set[Any], str]: ... +def print_glsl(expr, **settings) -> None: ... diff --git a/stubs/sympy-stubs/printing/gtk.pyi b/stubs/sympy-stubs/printing/gtk.pyi index f47daf54..1d24eea8 100644 --- a/stubs/sympy-stubs/printing/gtk.pyi +++ b/stubs/sympy-stubs/printing/gtk.pyi @@ -1,3 +1 @@ -def print_gtk(x, start_viewer=...) -> None: - ... - +def print_gtk(x, start_viewer=...) -> None: ... diff --git a/stubs/sympy-stubs/printing/jscode.pyi b/stubs/sympy-stubs/printing/jscode.pyi index 0ba7a592..f2d7c5e0 100644 --- a/stubs/sympy-stubs/printing/jscode.pyi +++ b/stubs/sympy-stubs/printing/jscode.pyi @@ -3,21 +3,13 @@ from typing import Any from sympy.printing.codeprinter import CodePrinter known_functions = ... + class JavascriptCodePrinter(CodePrinter): printmethod = ... language = ... _default_settings: dict[str, Any] = ... - def __init__(self, settings=...) -> None: - ... - - def indent_code(self, code) -> str | list[Any]: - ... - - - -def jscode(expr, assign_to=..., **settings) -> str | tuple[set[tuple[Any, str]], set[Any], str]: - ... - -def print_jscode(expr, **settings) -> None: - ... + def __init__(self, settings=...) -> None: ... + def indent_code(self, code) -> str | list[Any]: ... +def jscode(expr, assign_to=..., **settings) -> str | tuple[set[tuple[Any, str]], set[Any], str]: ... +def print_jscode(expr, **settings) -> None: ... diff --git a/stubs/sympy-stubs/printing/julia.pyi b/stubs/sympy-stubs/printing/julia.pyi index d392f623..ef66bc5f 100644 --- a/stubs/sympy-stubs/printing/julia.pyi +++ b/stubs/sympy-stubs/printing/julia.pyi @@ -4,23 +4,16 @@ from sympy.printing.codeprinter import CodePrinter known_fcns_src1 = ... known_fcns_src2 = ... + class JuliaCodePrinter(CodePrinter): printmethod = ... language = ... _operators = ... _default_settings: dict[str, Any] = ... - def __init__(self, settings=...) -> None: - ... - - _print_Tuple = ... - def indent_code(self, code) -> str | list[Any]: - ... - - + def __init__(self, settings=...) -> None: ... -def julia_code(expr, assign_to=..., **settings) -> str | tuple[set[tuple[Any, str]], set[Any], str]: - ... - -def print_julia_code(expr, **settings) -> None: - ... + _print_Tuple = ... + def indent_code(self, code) -> str | list[Any]: ... +def julia_code(expr, assign_to=..., **settings) -> str | tuple[set[tuple[Any, str]], set[Any], str]: ... +def print_julia_code(expr, **settings) -> None: ... diff --git a/stubs/sympy-stubs/printing/lambdarepr.pyi b/stubs/sympy-stubs/printing/lambdarepr.pyi index 8dcd4e77..3157b719 100644 --- a/stubs/sympy-stubs/printing/lambdarepr.pyi +++ b/stubs/sympy-stubs/printing/lambdarepr.pyi @@ -2,29 +2,21 @@ from typing import Any from sympy.printing.pycode import MpmathPrinter, PythonCodePrinter -__all__ = ['PythonCodePrinter', 'MpmathPrinter', 'NumPyPrinter', 'LambdaPrinter', 'NumPyPrinter', 'IntervalPrinter', 'lambdarepr'] +__all__ = ["PythonCodePrinter", "MpmathPrinter", "NumPyPrinter", "LambdaPrinter", "NumPyPrinter", "IntervalPrinter", "lambdarepr"] + class LambdaPrinter(PythonCodePrinter): printmethod = ... - class NumExprPrinter(LambdaPrinter): printmethod = ... _numexpr_functions = ... module = ... - def blacklisted(self, expr): - ... - + def blacklisted(self, expr): ... + _print_ImmutableDenseMatrix = ... _print_Dict = ... - def doprint(self, expr) -> str | tuple[set[tuple[Any, str]], set[Any], str]: - ... - - - -class IntervalPrinter(MpmathPrinter, LambdaPrinter): - ... - + def doprint(self, expr) -> str | tuple[set[tuple[Any, str]], set[Any], str]: ... -def lambdarepr(expr, **settings) -> str | tuple[set[tuple[Any, str]], set[Any], str]: - ... +class IntervalPrinter(MpmathPrinter, LambdaPrinter): ... +def lambdarepr(expr, **settings) -> str | tuple[set[tuple[Any, str]], set[Any], str]: ... diff --git a/stubs/sympy-stubs/printing/latex.pyi b/stubs/sympy-stubs/printing/latex.pyi index b8f6cf22..ad90152e 100644 --- a/stubs/sympy-stubs/printing/latex.pyi +++ b/stubs/sympy-stubs/printing/latex.pyi @@ -10,24 +10,17 @@ other_symbols = ... modifier_dict: dict[str, Callable[[str], str]] = ... greek_letters_set = ... _between_two_numbers_p = ... -def latex_escape(s: str) -> str: - ... + +def latex_escape(s: str) -> str: ... class LatexPrinter(Printer): printmethod = ... _default_settings: dict[str, Any] = ... - def __init__(self, settings=...) -> None: - ... - - def parenthesize(self, item, level, is_neg=..., strict=...) -> str: - ... - - def parenthesize_super(self, s) -> str: - ... - - def doprint(self, expr) -> str: - ... - + def __init__(self, settings=...) -> None: ... + def parenthesize(self, item, level, is_neg=..., strict=...) -> str: ... + def parenthesize_super(self, s) -> str: ... + def doprint(self, expr) -> str: ... + _print_BooleanTrue = ... _print_BooleanFalse = ... _print_Max = ... @@ -38,21 +31,10 @@ class LatexPrinter(Printer): _print_SeqAdd = ... _print_SeqMul = ... _print_IDFT = ... - def emptyPrinter(self, expr) -> str: - ... - - - -def translate(s: str) -> str: - ... + def emptyPrinter(self, expr) -> str: ... +def translate(s: str) -> str: ... @print_function(LatexPrinter) -def latex(expr, **settings) -> str: - ... - -def print_latex(expr, **settings) -> None: - ... - -def multiline_latex(lhs, rhs, terms_per_line=..., environment=..., use_dots=..., **settings) -> str: - ... - +def latex(expr, **settings) -> str: ... +def print_latex(expr, **settings) -> None: ... +def multiline_latex(lhs, rhs, terms_per_line=..., environment=..., use_dots=..., **settings) -> str: ... diff --git a/stubs/sympy-stubs/printing/maple.pyi b/stubs/sympy-stubs/printing/maple.pyi index e27dd888..9e455683 100644 --- a/stubs/sympy-stubs/printing/maple.pyi +++ b/stubs/sympy-stubs/printing/maple.pyi @@ -7,18 +7,12 @@ known_functions = ... number_symbols = ... spec_relational_ops = ... not_supported_symbol = ... + class MapleCodePrinter(CodePrinter): printmethod = ... language = ... _default_settings = ... - def __init__(self, settings=...) -> None: - ... - - - -def maple_code(expr, assign_to=..., **settings) -> str | tuple[set[tuple[Any, str]], set[Any], str]: - ... - -def print_maple_code(expr, **settings) -> None: - ... + def __init__(self, settings=...) -> None: ... +def maple_code(expr, assign_to=..., **settings) -> str | tuple[set[tuple[Any, str]], set[Any], str]: ... +def print_maple_code(expr, **settings) -> None: ... diff --git a/stubs/sympy-stubs/printing/mathematica.pyi b/stubs/sympy-stubs/printing/mathematica.pyi index d0e965fe..dcbfaa1f 100644 --- a/stubs/sympy-stubs/printing/mathematica.pyi +++ b/stubs/sympy-stubs/printing/mathematica.pyi @@ -4,20 +4,17 @@ from sympy.core import Basic, Expr, Float from sympy.printing.codeprinter import CodePrinter known_functions = ... + class MCodePrinter(CodePrinter): printmethod = ... language = ... _default_settings: dict[str, Any] = ... _number_symbols: set[tuple[Expr, Float]] = ... _not_supported: set[Basic] = ... - def __init__(self, settings=...) -> None: - ... - + def __init__(self, settings=...) -> None: ... + _print_tuple = ... _print_Tuple = ... _print_MinMaxBase = ... - -def mathematica_code(expr, **settings) -> str | tuple[set[tuple[Any, str]], set[Any], str]: - ... - +def mathematica_code(expr, **settings) -> str | tuple[set[tuple[Any, str]], set[Any], str]: ... diff --git a/stubs/sympy-stubs/printing/mathml.pyi b/stubs/sympy-stubs/printing/mathml.pyi index 3b67ecef..47fd9cf4 100644 --- a/stubs/sympy-stubs/printing/mathml.pyi +++ b/stubs/sympy-stubs/printing/mathml.pyi @@ -6,42 +6,27 @@ from sympy.printing.printer import Printer, print_function class MathMLPrinterBase(Printer): _default_settings: dict[str, Any] = ... def __init__(self, settings=...) -> None: - class RawText(Text): - ... - - - - def doprint(self, expr): - ... - - def apply_patch(self) -> None: - ... - - def restore_patch(self) -> None: - ... - + class RawText(Text): ... + def doprint(self, expr): ... + def apply_patch(self) -> None: ... + def restore_patch(self) -> None: ... class MathMLContentPrinter(MathMLPrinterBase): printmethod = ... - def mathml_tag(self, e) -> str: - ... - + def mathml_tag(self, e) -> str: ... + _print_MatrixSymbol = ... _print_RandomSymbol = ... _print_Implies = ... _print_Not = ... _print_Xor = ... - class MathMLPresentationPrinter(MathMLPrinterBase): printmethod = ... - def mathml_tag(self, e) -> str: - ... - - def parenthesize(self, item, level, strict=...) -> Element | str: - ... - + def mathml_tag(self, e) -> str: ... + def parenthesize(self, item, level, strict=...) -> Element | str: ... + _print_RandomSymbol = ... _print_Determinant = ... _print_frozenset = ... @@ -50,12 +35,8 @@ class MathMLPresentationPrinter(MathMLPrinterBase): _print_Max = ... _print_bell = ... - @print_function(MathMLPrinterBase) -def mathml(expr, printer=..., **settings): - ... - -def print_mathml(expr, printer=..., **settings) -> None: - ... +def mathml(expr, printer=..., **settings): ... +def print_mathml(expr, printer=..., **settings) -> None: ... MathMLPrinter = MathMLContentPrinter diff --git a/stubs/sympy-stubs/printing/numpy.pyi b/stubs/sympy-stubs/printing/numpy.pyi index 68adf262..180533f2 100644 --- a/stubs/sympy-stubs/printing/numpy.pyi +++ b/stubs/sympy-stubs/printing/numpy.pyi @@ -6,13 +6,13 @@ _known_functions_numpy = ... _known_constants_numpy = ... _numpy_known_functions = ... _numpy_known_constants = ... + class NumPyPrinter(ArrayPrinter, PythonCodePrinter): _module = ... _kf = ... _kc = ... - def __init__(self, settings=...) -> None: - ... - + def __init__(self, settings=...) -> None: ... + _add = ... _einsum = ... _transpose = ... @@ -23,39 +23,32 @@ class NumPyPrinter(ArrayPrinter, PythonCodePrinter): _print_fresnelc = ... _print_fresnels = ... - _known_functions_scipy_special = ... _known_constants_scipy_constants = ... _scipy_known_functions = ... _scipy_known_constants = ... + class SciPyPrinter(NumPyPrinter): _kf = ... _kc = ... - def __init__(self, settings=...) -> None: - ... - - _print_ImmutableSparseMatrix = ... + def __init__(self, settings=...) -> None: ... + _print_ImmutableSparseMatrix = ... _cupy_known_functions = ... _cupy_known_constants = ... + class CuPyPrinter(NumPyPrinter): _module = ... _kf = ... _kc = ... - def __init__(self, settings=...) -> None: - ... - - + def __init__(self, settings=...) -> None: ... _jax_known_functions = ... _jax_known_constants = ... + class JaxPrinter(NumPyPrinter): _module = ... _kf = ... _kc = ... - def __init__(self, settings=...) -> None: - ... - - - + def __init__(self, settings=...) -> None: ... diff --git a/stubs/sympy-stubs/printing/octave.pyi b/stubs/sympy-stubs/printing/octave.pyi index facf0e74..948e8de2 100644 --- a/stubs/sympy-stubs/printing/octave.pyi +++ b/stubs/sympy-stubs/printing/octave.pyi @@ -4,27 +4,20 @@ from sympy.printing.codeprinter import CodePrinter known_fcns_src1 = ... known_fcns_src2 = ... + class OctaveCodePrinter(CodePrinter): printmethod = ... language = ... _operators = ... _default_settings: dict[str, Any] = ... - def __init__(self, settings=...) -> None: - ... - + def __init__(self, settings=...) -> None: ... + _print_tuple = ... _print_Tuple = ... _print_List = ... _print_LambertW = ... _print_Min = ... - def indent_code(self, code) -> str | list[Any]: - ... - - - -def octave_code(expr, assign_to=..., **settings) -> str | tuple[set[tuple[Any, str]], set[Any], str]: - ... - -def print_octave_code(expr, **settings) -> None: - ... + def indent_code(self, code) -> str | list[Any]: ... +def octave_code(expr, assign_to=..., **settings) -> str | tuple[set[tuple[Any, str]], set[Any], str]: ... +def print_octave_code(expr, **settings) -> None: ... diff --git a/stubs/sympy-stubs/printing/precedence.pyi b/stubs/sympy-stubs/printing/precedence.pyi index 083c741d..84d84499 100644 --- a/stubs/sympy-stubs/printing/precedence.pyi +++ b/stubs/sympy-stubs/printing/precedence.pyi @@ -1,32 +1,18 @@ - PRECEDENCE = ... PRECEDENCE_VALUES = ... -def precedence_Mul(item) -> int: - ... - -def precedence_Rational(item) -> int: - ... - -def precedence_Integer(item) -> int: - ... - -def precedence_Float(item) -> int: - ... -def precedence_PolyElement(item) -> int: - ... - -def precedence_FracElement(item) -> int: - ... - -def precedence_UnevaluatedExpr(item) -> float: - ... +def precedence_Mul(item) -> int: ... +def precedence_Rational(item) -> int: ... +def precedence_Integer(item) -> int: ... +def precedence_Float(item) -> int: ... +def precedence_PolyElement(item) -> int: ... +def precedence_FracElement(item) -> int: ... +def precedence_UnevaluatedExpr(item) -> float: ... PRECEDENCE_FUNCTIONS = ... -def precedence(item) -> int: - ... + +def precedence(item) -> int: ... PRECEDENCE_TRADITIONAL = ... -def precedence_traditional(item) -> int: - ... +def precedence_traditional(item) -> int: ... diff --git a/stubs/sympy-stubs/printing/pretty/__init__.pyi b/stubs/sympy-stubs/printing/pretty/__init__.pyi index 410d44f1..6ca1c3f3 100644 --- a/stubs/sympy-stubs/printing/pretty/__init__.pyi +++ b/stubs/sympy-stubs/printing/pretty/__init__.pyi @@ -1,3 +1,3 @@ from sympy.printing.pretty.pretty import pager_print, pprint, pprint_try_use_unicode, pprint_use_unicode, pretty, pretty_print -__all__ = ['pretty', 'pretty_print', 'pprint', 'pprint_use_unicode', 'pprint_try_use_unicode', 'pager_print'] +__all__ = ["pretty", "pretty_print", "pprint", "pprint_use_unicode", "pprint_try_use_unicode", "pager_print"] diff --git a/stubs/sympy-stubs/printing/pretty/pretty.pyi b/stubs/sympy-stubs/printing/pretty/pretty.pyi index a4a60d64..eebdc438 100644 --- a/stubs/sympy-stubs/printing/pretty/pretty.pyi +++ b/stubs/sympy-stubs/printing/pretty/pretty.pyi @@ -3,18 +3,14 @@ from sympy.printing.printer import Printer, print_function pprint_use_unicode = ... pprint_try_use_unicode = ... + class PrettyPrinter(Printer): printmethod = ... _default_settings = ... - def __init__(self, settings=...) -> None: - ... - - def emptyPrinter(self, expr) -> prettyForm: - ... - - def doprint(self, expr): - ... - + def __init__(self, settings=...) -> None: ... + def emptyPrinter(self, expr) -> prettyForm: ... + def doprint(self, expr): ... + _print_RandomSymbol = ... _print_Infinity = ... _print_NegativeInfinity = ... @@ -28,20 +24,14 @@ class PrettyPrinter(Printer): _print_SeqPer = ... _print_SeqAdd = ... _print_SeqMul = ... - def join(self, delimiter, args) -> prettyForm: - ... - - _print_bell = ... + def join(self, delimiter, args) -> prettyForm: ... + _print_bell = ... @print_function(PrettyPrinter) -def pretty(expr, **settings): - ... - -def pretty_print(expr, **kwargs) -> None: - ... +def pretty(expr, **settings): ... +def pretty_print(expr, **kwargs) -> None: ... pprint = ... -def pager_print(expr, **settings) -> None: - ... +def pager_print(expr, **settings) -> None: ... diff --git a/stubs/sympy-stubs/printing/pretty/pretty_symbology.pyi b/stubs/sympy-stubs/printing/pretty/pretty_symbology.pyi index 94b4f5aa..a271129e 100644 --- a/stubs/sympy-stubs/printing/pretty/pretty_symbology.pyi +++ b/stubs/sympy-stubs/printing/pretty/pretty_symbology.pyi @@ -1,19 +1,15 @@ from typing import Any, LiteralString unicode_warnings = ... -def U(name) -> str | None: - ... -__all__ = ['greek_unicode', 'sub', 'sup', 'xsym', 'vobj', 'hobj', 'pretty_symbol', 'annotated'] -_use_unicode = ... -def pretty_use_unicode(flag=...) -> bool: - ... +def U(name) -> str | None: ... -def pretty_try_use_unicode() -> None: - ... +__all__ = ["greek_unicode", "sub", "sup", "xsym", "vobj", "hobj", "pretty_symbol", "annotated"] +_use_unicode = ... -def xstr(*args) -> str: - ... +def pretty_use_unicode(flag=...) -> bool: ... +def pretty_try_use_unicode() -> None: ... +def xstr(*args) -> str: ... g = ... G = ... @@ -48,39 +44,26 @@ TOP = ... BOT = ... _xobj_unicode = ... _xobj_ascii = ... -def xobj(symb, length): - ... -def vobj(symb, height) -> str: - ... - -def hobj(symb, width) -> str: - ... +def xobj(symb, length): ... +def vobj(symb, height) -> str: ... +def hobj(symb, width) -> str: ... root = ... VF = ... frac = ... _xsym = ... -def xsym(sym): - ... -atoms_table = ... -def pretty_atom(atom_name, default=..., printer=...) -> str | None: - ... +def xsym(sym): ... -def pretty_symbol(symb_name, bold_name=...) -> str: - ... +atoms_table = ... -def annotated(letter): - ... +def pretty_atom(atom_name, default=..., printer=...) -> str | None: ... +def pretty_symbol(symb_name, bold_name=...) -> str: ... +def annotated(letter): ... _remove_combining = ... -def is_combining(sym) -> bool: - ... - -def center_accent(string, accent): - ... - -def line_width(line) -> int: - ... +def is_combining(sym) -> bool: ... +def center_accent(string, accent): ... +def line_width(line) -> int: ... diff --git a/stubs/sympy-stubs/printing/pretty/stringpict.pyi b/stubs/sympy-stubs/printing/pretty/stringpict.pyi index 58a6103d..5c8e2607 100644 --- a/stubs/sympy-stubs/printing/pretty/stringpict.pyi +++ b/stubs/sympy-stubs/printing/pretty/stringpict.pyi @@ -2,101 +2,41 @@ from typing import Any, Literal, LiteralString, Self class stringPict: LINE = ... - def __init__(self, s, baseline=...) -> None: - ... - + def __init__(self, s, baseline=...) -> None: ... @staticmethod - def equalLengths(lines) -> list[str] | list[Any]: - ... - - def height(self) -> int: - ... - - def width(self) -> int: - ... - + def equalLengths(lines) -> list[str] | list[Any]: ... + def height(self) -> int: ... + def width(self) -> int: ... @staticmethod - def next(*args) -> tuple[str, Any]: - ... - - def right(self, *args) -> tuple[str, Any]: - ... - - def left(self, *args) -> tuple[str, Any]: - ... - + def next(*args) -> tuple[str, Any]: ... + def right(self, *args) -> tuple[str, Any]: ... + def left(self, *args) -> tuple[str, Any]: ... @staticmethod - def stack(*args) -> tuple[LiteralString, Any]: - ... - - def below(self, *args) -> tuple[LiteralString, int]: - ... - - def above(self, *args) -> tuple[LiteralString, int]: - ... - - def parens(self, left=..., right=..., ifascii_nougly=...) -> tuple[str, int]: - ... - - def leftslash(self) -> tuple[str, Any]: - ... - - def root(self, n=...): - ... - - def render(self, *args, **kwargs) -> str | Any | LiteralString: - ... - - def terminal_width(self) -> Any | Literal[0]: - ... - - def __eq__(self, o) -> bool: - ... - - def __hash__(self) -> int: - ... - - def __str__(self) -> str: - ... - - def __repr__(self) -> str: - ... - - def __getitem__(self, index): - ... - - def __len__(self) -> int: - ... - - + def stack(*args) -> tuple[LiteralString, Any]: ... + def below(self, *args) -> tuple[LiteralString, int]: ... + def above(self, *args) -> tuple[LiteralString, int]: ... + def parens(self, left=..., right=..., ifascii_nougly=...) -> tuple[str, int]: ... + def leftslash(self) -> tuple[str, Any]: ... + def root(self, n=...): ... + def render(self, *args, **kwargs) -> str | Any | LiteralString: ... + def terminal_width(self) -> Any | Literal[0]: ... + def __eq__(self, o) -> bool: ... + def __hash__(self) -> int: ... + def __str__(self) -> str: ... + def __repr__(self) -> str: ... + def __getitem__(self, index): ... + def __len__(self) -> int: ... class prettyForm(stringPict): - def __init__(self, s, baseline=..., binding=..., unicode=...) -> None: - ... - + def __init__(self, s, baseline=..., binding=..., unicode=...) -> None: ... @property - def unicode(self) -> Any: - ... - - def __add__(self, *others) -> prettyForm: - ... - - def __truediv__(self, den, slashed=...) -> prettyForm: - ... - - def __mul__(self, *others) -> Self | prettyForm: - ... - - def __repr__(self) -> str: - ... - - def __pow__(self, b) -> prettyForm: - ... - + def unicode(self) -> Any: ... + def __add__(self, *others) -> prettyForm: ... + def __truediv__(self, den, slashed=...) -> prettyForm: ... + def __mul__(self, *others) -> Self | prettyForm: ... + def __repr__(self) -> str: ... + def __pow__(self, b) -> prettyForm: ... + simpleFunctions = ... @staticmethod - def apply(function, *args) -> prettyForm: - ... - - - + def apply(function, *args) -> prettyForm: ... diff --git a/stubs/sympy-stubs/printing/preview.pyi b/stubs/sympy-stubs/printing/preview.pyi index 49b4025a..1e29e8cd 100644 --- a/stubs/sympy-stubs/printing/preview.pyi +++ b/stubs/sympy-stubs/printing/preview.pyi @@ -1,13 +1,22 @@ from sympy.utilities.decorator import doctest_depends_on __doctest_requires__ = ... -def system_default_viewer(fname, fmt) -> None: - ... - -def pyglet_viewer(fname, fmt) -> None: - ... - -@doctest_depends_on(exe=('latex', 'dvipng'), modules=('pyglet', ), disable_viewers=('evince', 'gimp', 'superior-dvi-viewer')) -def preview(expr, output=..., viewer=..., euler=..., packages=..., filename=..., outputbuffer=..., preamble=..., dvioptions=..., outputTexFile=..., extra_preamble=..., fontsize=..., **latex_settings) -> None: - ... +def system_default_viewer(fname, fmt) -> None: ... +def pyglet_viewer(fname, fmt) -> None: ... +@doctest_depends_on(exe=("latex", "dvipng"), modules=("pyglet",), disable_viewers=("evince", "gimp", "superior-dvi-viewer")) +def preview( + expr, + output=..., + viewer=..., + euler=..., + packages=..., + filename=..., + outputbuffer=..., + preamble=..., + dvioptions=..., + outputTexFile=..., + extra_preamble=..., + fontsize=..., + **latex_settings, +) -> None: ... diff --git a/stubs/sympy-stubs/printing/printer.pyi b/stubs/sympy-stubs/printing/printer.pyi index 2f4d4d92..adb6a14a 100644 --- a/stubs/sympy-stubs/printing/printer.pyi +++ b/stubs/sympy-stubs/printing/printer.pyi @@ -3,48 +3,25 @@ from contextlib import contextmanager from typing import Any, Callable, Generator, Type @contextmanager -def printer_context(printer, **kwargs) -> Generator[None, Any, None]: - ... +def printer_context(printer, **kwargs) -> Generator[None, Any, None]: ... class Printer: _global_settings: dict[str, Any] = ... _default_settings: dict[str, Any] = ... printmethod: str = ... - def __init__(self, settings=...) -> None: - ... - + def __init__(self, settings=...) -> None: ... @classmethod - def set_global_settings(cls, **settings) -> None: - ... - + def set_global_settings(cls, **settings) -> None: ... @property - def order(self) -> Any: - ... - - def doprint(self, expr) -> str: - ... - - def emptyPrinter(self, expr) -> str: - ... - - + def order(self) -> Any: ... + def doprint(self, expr) -> str: ... + def emptyPrinter(self, expr) -> str: ... class _PrintFunction: - def __init__(self, f, print_cls: Type[Printer]) -> None: - ... - - def __reduce__(self): - ... - - def __call__(self, *args, **kwargs): - ... - + def __init__(self, f, print_cls: Type[Printer]) -> None: ... + def __reduce__(self): ... + def __call__(self, *args, **kwargs): ... @property - def __signature__(self) -> inspect.Signature: - ... - - - -def print_function(print_cls) -> Callable[..., _PrintFunction]: - ... + def __signature__(self) -> inspect.Signature: ... +def print_function(print_cls) -> Callable[..., _PrintFunction]: ... diff --git a/stubs/sympy-stubs/printing/pycode.pyi b/stubs/sympy-stubs/printing/pycode.pyi index a75fd967..f2ccfeca 100644 --- a/stubs/sympy-stubs/printing/pycode.pyi +++ b/stubs/sympy-stubs/printing/pycode.pyi @@ -6,6 +6,7 @@ _kw = ... _known_functions = ... _known_functions_math = ... _known_constants_math = ... + class AbstractPythonCodePrinter(CodePrinter): printmethod = ... language = ... @@ -16,15 +17,11 @@ class AbstractPythonCodePrinter(CodePrinter): _kc = ... _operators = ... _default_settings = ... - def __init__(self, settings=...) -> None: - ... - - _print_ImmutableDenseMatrix = ... - + def __init__(self, settings=...) -> None: ... -class ArrayPrinter: - ... + _print_ImmutableDenseMatrix = ... +class ArrayPrinter: ... class PythonCodePrinter(AbstractPythonCodePrinter): _print_lowergamma = ... @@ -32,22 +29,18 @@ class PythonCodePrinter(AbstractPythonCodePrinter): _print_fresnelc = ... _print_fresnels = ... - -def pycode(expr, **settings) -> str | tuple[set[tuple[Any, str]], set[Any], str]: - ... +def pycode(expr, **settings) -> str | tuple[set[tuple[Any, str]], set[Any], str]: ... _not_in_mpmath = ... _in_mpmath = ... _known_functions_mpmath = ... _known_constants_mpmath = ... + class MpmathPrinter(PythonCodePrinter): printmethod = ... language = ... _kf = ... _kc = ... - class SymPyPrinter(AbstractPythonCodePrinter): language = ... - - diff --git a/stubs/sympy-stubs/printing/python.pyi b/stubs/sympy-stubs/printing/python.pyi index f24f9cd1..bb46fb79 100644 --- a/stubs/sympy-stubs/printing/python.pyi +++ b/stubs/sympy-stubs/printing/python.pyi @@ -2,15 +2,9 @@ from sympy.printing.repr import ReprPrinter from sympy.printing.str import StrPrinter STRPRINT = ... -class PythonPrinter(ReprPrinter, StrPrinter): - def __init__(self, settings=...) -> None: - ... - - -def python(expr, **settings) -> str: - ... - -def print_python(expr, **settings) -> None: - ... +class PythonPrinter(ReprPrinter, StrPrinter): + def __init__(self, settings=...) -> None: ... +def python(expr, **settings) -> str: ... +def print_python(expr, **settings) -> None: ... diff --git a/stubs/sympy-stubs/printing/rcode.pyi b/stubs/sympy-stubs/printing/rcode.pyi index 1d16842b..3b8b94c8 100644 --- a/stubs/sympy-stubs/printing/rcode.pyi +++ b/stubs/sympy-stubs/printing/rcode.pyi @@ -4,23 +4,15 @@ from sympy.printing.codeprinter import CodePrinter known_functions = ... reserved_words = ... + class RCodePrinter(CodePrinter): printmethod = ... language = ... _default_settings: dict[str, Any] = ... _operators = ... _relationals: dict[str, str] = ... - def __init__(self, settings=...) -> None: - ... - - def indent_code(self, code) -> str | list[Any]: - ... - - - -def rcode(expr, assign_to=..., **settings) -> str | tuple[set[tuple[Any, str]], set[Any], str]: - ... - -def print_rcode(expr, **settings) -> None: - ... + def __init__(self, settings=...) -> None: ... + def indent_code(self, code) -> str | list[Any]: ... +def rcode(expr, assign_to=..., **settings) -> str | tuple[set[tuple[Any, str]], set[Any], str]: ... +def print_rcode(expr, **settings) -> None: ... diff --git a/stubs/sympy-stubs/printing/repr.pyi b/stubs/sympy-stubs/printing/repr.pyi index 5dda41bd..a7a73c74 100644 --- a/stubs/sympy-stubs/printing/repr.pyi +++ b/stubs/sympy-stubs/printing/repr.pyi @@ -5,15 +5,8 @@ from sympy.printing.printer import Printer, print_function class ReprPrinter(Printer): printmethod = ... _default_settings: dict[str, Any] = ... - def reprify(self, args, sep): - ... - - def emptyPrinter(self, expr) -> str | LiteralString: - ... - - + def reprify(self, args, sep): ... + def emptyPrinter(self, expr) -> str | LiteralString: ... @print_function(ReprPrinter) -def srepr(expr, **settings) -> str: - ... - +def srepr(expr, **settings) -> str: ... diff --git a/stubs/sympy-stubs/printing/rust.pyi b/stubs/sympy-stubs/printing/rust.pyi index ae9611ec..275de23f 100644 --- a/stubs/sympy-stubs/printing/rust.pyi +++ b/stubs/sympy-stubs/printing/rust.pyi @@ -4,21 +4,13 @@ from sympy.printing.codeprinter import CodePrinter known_functions = ... reserved_words = ... + class RustCodePrinter(CodePrinter): printmethod = ... language = ... _default_settings: dict[str, Any] = ... - def __init__(self, settings=...) -> None: - ... - - def indent_code(self, code) -> str | list[Any]: - ... - - - -def rust_code(expr, assign_to=..., **settings) -> str | tuple[set[tuple[Any, str]], set[Any], str]: - ... - -def print_rust_code(expr, **settings) -> None: - ... + def __init__(self, settings=...) -> None: ... + def indent_code(self, code) -> str | list[Any]: ... +def rust_code(expr, assign_to=..., **settings) -> str | tuple[set[tuple[Any, str]], set[Any], str]: ... +def print_rust_code(expr, **settings) -> None: ... diff --git a/stubs/sympy-stubs/printing/str.pyi b/stubs/sympy-stubs/printing/str.pyi index e7f9ccca..ff9eba3b 100644 --- a/stubs/sympy-stubs/printing/str.pyi +++ b/stubs/sympy-stubs/printing/str.pyi @@ -6,28 +6,17 @@ class StrPrinter(Printer): printmethod = ... _default_settings: dict[str, Any] = ... _relationals: dict[str, str] = ... - def parenthesize(self, item, level, strict=...) -> str: - ... - - def stringify(self, args, sep, level=...): - ... - - def emptyPrinter(self, expr) -> str: - ... - + def parenthesize(self, item, level, strict=...) -> str: ... + def stringify(self, args, sep, level=...): ... + def emptyPrinter(self, expr) -> str: ... + _print_MatrixSymbol = ... _print_RandomSymbol = ... - @print_function(StrPrinter) -def sstr(expr, **settings) -> str: - ... - -class StrReprPrinter(StrPrinter): - ... +def sstr(expr, **settings) -> str: ... +class StrReprPrinter(StrPrinter): ... @print_function(StrReprPrinter) -def sstrrepr(expr, **settings) -> str: - ... - +def sstrrepr(expr, **settings) -> str: ... diff --git a/stubs/sympy-stubs/printing/tableform.pyi b/stubs/sympy-stubs/printing/tableform.pyi index fd94ee6e..c70d10a3 100644 --- a/stubs/sympy-stubs/printing/tableform.pyi +++ b/stubs/sympy-stubs/printing/tableform.pyi @@ -1,23 +1,9 @@ from sympy.matrices import Matrix class TableForm: - def __init__(self, data, **kwarg) -> None: - ... - - def __repr__(self): - ... - - def __str__(self) -> str: - ... - - def as_matrix(self) -> Matrix: - ... - - def as_str(self) -> str: - ... - - def as_latex(self): - ... - - - + def __init__(self, data, **kwarg) -> None: ... + def __repr__(self): ... + def __str__(self) -> str: ... + def as_matrix(self) -> Matrix: ... + def as_str(self) -> str: ... + def as_latex(self): ... diff --git a/stubs/sympy-stubs/printing/tensorflow.pyi b/stubs/sympy-stubs/printing/tensorflow.pyi index 2b22c946..7f7cc66f 100644 --- a/stubs/sympy-stubs/printing/tensorflow.pyi +++ b/stubs/sympy-stubs/printing/tensorflow.pyi @@ -3,13 +3,13 @@ from typing import Any from sympy.printing.pycode import AbstractPythonCodePrinter, ArrayPrinter tensorflow = ... + class TensorflowPrinter(ArrayPrinter, AbstractPythonCodePrinter): printmethod = ... mapping = ... _default_settings = ... - def __init__(self, settings=...) -> None: - ... - + def __init__(self, settings=...) -> None: ... + _print_Expr = ... _print_Application = ... _print_MatrixExpr = ... @@ -27,7 +27,4 @@ class TensorflowPrinter(ArrayPrinter, AbstractPythonCodePrinter): _ones = ... _zeros = ... - -def tensorflow_code(expr, **settings) -> str | tuple[set[tuple[Any, str]], set[Any], str]: - ... - +def tensorflow_code(expr, **settings) -> str | tuple[set[tuple[Any, str]], set[Any], str]: ... diff --git a/stubs/sympy-stubs/printing/tree.pyi b/stubs/sympy-stubs/printing/tree.pyi index f417e52a..95ecb77d 100644 --- a/stubs/sympy-stubs/printing/tree.pyi +++ b/stubs/sympy-stubs/printing/tree.pyi @@ -1,14 +1,6 @@ from typing import Literal -def pprint_nodes(subtrees) -> Literal['']: - ... - -def print_node(node, assumptions=...) -> str: - ... - -def tree(node, assumptions=...) -> str: - ... - -def print_tree(node, assumptions=...) -> None: - ... - +def pprint_nodes(subtrees) -> Literal[""]: ... +def print_node(node, assumptions=...) -> str: ... +def tree(node, assumptions=...) -> str: ... +def print_tree(node, assumptions=...) -> None: ... diff --git a/stubs/sympy-stubs/series/__init__.pyi b/stubs/sympy-stubs/series/__init__.pyi index ef720b39..ccea0018 100644 --- a/stubs/sympy-stubs/series/__init__.pyi +++ b/stubs/sympy-stubs/series/__init__.pyi @@ -12,4 +12,23 @@ from sympy.series.series import series EmptySequence = ... O = Order -__all__ = ['Order', 'O', 'limit', 'Limit', 'gruntz', 'series', 'approximants', 'residue', 'EmptySequence', 'SeqPer', 'SeqFormula', 'sequence', 'SeqAdd', 'SeqMul', 'fourier_series', 'fps', 'difference_delta', 'limit_seq'] +__all__ = [ + "Order", + "O", + "limit", + "Limit", + "gruntz", + "series", + "approximants", + "residue", + "EmptySequence", + "SeqPer", + "SeqFormula", + "sequence", + "SeqAdd", + "SeqMul", + "fourier_series", + "fps", + "difference_delta", + "limit_seq", +] diff --git a/stubs/sympy-stubs/series/approximants.pyi b/stubs/sympy-stubs/series/approximants.pyi index 1991ecfe..6e4eba4f 100644 --- a/stubs/sympy-stubs/series/approximants.pyi +++ b/stubs/sympy-stubs/series/approximants.pyi @@ -3,6 +3,4 @@ from typing import Any, Generator from sympy.utilities import public @public -def approximants(l, X=..., simplify=...) -> Generator[Any, Any, None]: - ... - +def approximants(l, X=..., simplify=...) -> Generator[Any, Any, None]: ... diff --git a/stubs/sympy-stubs/series/formal.pyi b/stubs/sympy-stubs/series/formal.pyi index 5ccff1ab..c23d9849 100644 --- a/stubs/sympy-stubs/series/formal.pyi +++ b/stubs/sympy-stubs/series/formal.pyi @@ -10,212 +10,112 @@ from sympy.series.sequences import SeqFormula, SeqPer from sympy.series.series_class import SeriesBase from sympy.sets.sets import FiniteSet, Interval -def rational_algorithm(f, x, k, order=..., full=...) -> tuple[Any, Any, int] | None: - ... - -def rational_independent(terms, x) -> list[Any]: - ... - -def simpleDE(f, x, g, order=...) -> Generator[tuple[Any, int], Any, None]: - ... - -def exp_re(DE, r, k): - ... - -def hyper_re(DE, r, k): - ... - -def rsolve_hypergeometric(f, x, P, Q, k, m) -> tuple[Any | Piecewise, Any, Any | type[UndefinedFunction] | Rational | Integer | Float | Order] | None: - ... - -def solve_de(f, x, DE, order, g, k) -> tuple[Any | Piecewise, Any, Any | type[UndefinedFunction] | Rational | Integer | Float | Order] | tuple[Any, Any, Any] | None: - ... - -def hyper_algorithm(f, x, k, order=...) -> tuple[Any | Piecewise, Any, Any | type[UndefinedFunction] | Rational | Integer | Float | Order] | tuple[Any, Any, Any] | None: - ... - -def compute_fps(f, x, x0=..., dir=..., hyper=..., order=..., rational=..., full=...) -> tuple[Any, Any, Any] | tuple[Any | SeqPer | SeqFormula, Any | SeqPer | SeqFormula, Any] | tuple[Any | SeqPer | SeqFormula, Any | None, Any] | None: - ... +def rational_algorithm(f, x, k, order=..., full=...) -> tuple[Any, Any, int] | None: ... +def rational_independent(terms, x) -> list[Any]: ... +def simpleDE(f, x, g, order=...) -> Generator[tuple[Any, int], Any, None]: ... +def exp_re(DE, r, k): ... +def hyper_re(DE, r, k): ... +def rsolve_hypergeometric( + f, x, P, Q, k, m +) -> tuple[Any | Piecewise, Any, Any | type[UndefinedFunction] | Rational | Integer | Float | Order] | None: ... +def solve_de( + f, x, DE, order, g, k +) -> ( + tuple[Any | Piecewise, Any, Any | type[UndefinedFunction] | Rational | Integer | Float | Order] | tuple[Any, Any, Any] | None +): ... +def hyper_algorithm( + f, x, k, order=... +) -> ( + tuple[Any | Piecewise, Any, Any | type[UndefinedFunction] | Rational | Integer | Float | Order] | tuple[Any, Any, Any] | None +): ... +def compute_fps( + f, x, x0=..., dir=..., hyper=..., order=..., rational=..., full=... +) -> ( + tuple[Any, Any, Any] + | tuple[Any | SeqPer | SeqFormula, Any | SeqPer | SeqFormula, Any] + | tuple[Any | SeqPer | SeqFormula, Any | None, Any] + | None +): ... class Coeff(Function): @classmethod - def eval(cls, p, x, n) -> None: - ... - - + def eval(cls, p, x, n) -> None: ... class FormalPowerSeries(SeriesBase): - def __new__(cls, *args) -> Self: - ... - - def __init__(self, *args) -> None: - ... - - @property - def function(self) -> Basic: - ... - - @property - def x(self) -> Basic: - ... - - @property - def x0(self) -> Basic: - ... - - @property - def dir(self) -> Basic: - ... - - @property - def ak(self): - ... - - @property - def xk(self): - ... - - @property - def ind(self): - ... - - @property - def interval(self) -> FiniteSet | Interval: - ... - - @property - def start(self): - ... - - @property - def stop(self): - ... - - @property - def length(self): - ... - - @property - def infinite(self): - ... - - def polynomial(self, n=...) -> Order: - ... - - def truncate(self, n=...) -> Generator[Any, Any, None]: - ... - - def zero_coeff(self): - ... - - def integrate(self, x=..., **kwargs) -> Equality | Relational | Ne | Self: - ... - - def product(self, other, x=..., n=...) -> Generator[Any, Any, None] | FormalPowerSeriesProduct: - ... - - def coeff_bell(self, n) -> SeqPer | SeqFormula: - ... - - def compose(self, other, x=..., n=...) -> Generator[Any, Any, None] | FormalPowerSeriesCompose: - ... - - def inverse(self, x=..., n=...) -> Generator[Any, Any, None] | FormalPowerSeriesInverse: - ... - - def __add__(self, other) -> Self | Order: - ... - - def __radd__(self, other) -> Self | Order: - ... - - def __neg__(self) -> Self: - ... - - def __sub__(self, other) -> Self | Order: - ... - - def __rsub__(self, other) -> FormalPowerSeries | Order: - ... - - def __mul__(self, other) -> Order | Self: - ... - - def __rmul__(self, other) -> Order | Self: - ... - - + def __new__(cls, *args) -> Self: ... + def __init__(self, *args) -> None: ... + @property + def function(self) -> Basic: ... + @property + def x(self) -> Basic: ... + @property + def x0(self) -> Basic: ... + @property + def dir(self) -> Basic: ... + @property + def ak(self): ... + @property + def xk(self): ... + @property + def ind(self): ... + @property + def interval(self) -> FiniteSet | Interval: ... + @property + def start(self): ... + @property + def stop(self): ... + @property + def length(self): ... + @property + def infinite(self): ... + def polynomial(self, n=...) -> Order: ... + def truncate(self, n=...) -> Generator[Any, Any, None]: ... + def zero_coeff(self): ... + def integrate(self, x=..., **kwargs) -> Equality | Relational | Ne | Self: ... + def product(self, other, x=..., n=...) -> Generator[Any, Any, None] | FormalPowerSeriesProduct: ... + def coeff_bell(self, n) -> SeqPer | SeqFormula: ... + def compose(self, other, x=..., n=...) -> Generator[Any, Any, None] | FormalPowerSeriesCompose: ... + def inverse(self, x=..., n=...) -> Generator[Any, Any, None] | FormalPowerSeriesInverse: ... + def __add__(self, other) -> Self | Order: ... + def __radd__(self, other) -> Self | Order: ... + def __neg__(self) -> Self: ... + def __sub__(self, other) -> Self | Order: ... + def __rsub__(self, other) -> FormalPowerSeries | Order: ... + def __mul__(self, other) -> Order | Self: ... + def __rmul__(self, other) -> Order | Self: ... class FiniteFormalPowerSeries(FormalPowerSeries): - def __init__(self, *args) -> None: - ... - - @property - def ffps(self) -> Basic: - ... - - @property - def gfps(self) -> Basic: - ... - - @property - def f(self): - ... - - @property - def g(self): - ... - - @property - def infinite(self): - ... - - def polynomial(self, n): - ... - - def truncate(self, n=...): - ... - - def integrate(self, x): - ... - - + def __init__(self, *args) -> None: ... + @property + def ffps(self) -> Basic: ... + @property + def gfps(self) -> Basic: ... + @property + def f(self): ... + @property + def g(self): ... + @property + def infinite(self): ... + def polynomial(self, n): ... + def truncate(self, n=...): ... + def integrate(self, x): ... class FormalPowerSeriesProduct(FiniteFormalPowerSeries): - def __init__(self, *args) -> None: - ... - + def __init__(self, *args) -> None: ... @property - def function(self): - ... - - + def function(self): ... class FormalPowerSeriesCompose(FiniteFormalPowerSeries): @property - def function(self): - ... - - + def function(self): ... class FormalPowerSeriesInverse(FiniteFormalPowerSeries): - def __init__(self, *args) -> None: - ... - + def __init__(self, *args) -> None: ... @property - def function(self): - ... - + def function(self): ... @property - def g(self): - ... - + def g(self): ... @property - def gfps(self): - ... - - - -def fps(f, x=..., x0=..., dir=..., hyper=..., order=..., rational=..., full=...) -> FormalPowerSeries: - ... + def gfps(self): ... +def fps(f, x=..., x0=..., dir=..., hyper=..., order=..., rational=..., full=...) -> FormalPowerSeries: ... diff --git a/stubs/sympy-stubs/series/fourier.pyi b/stubs/sympy-stubs/series/fourier.pyi index 9a96434d..34070a17 100644 --- a/stubs/sympy-stubs/series/fourier.pyi +++ b/stubs/sympy-stubs/series/fourier.pyi @@ -6,118 +6,53 @@ from sympy.series.sequences import SeqFormula from sympy.series.series_class import SeriesBase from sympy.sets.sets import FiniteSet, Interval -def fourier_cos_seq(func, limits, n) -> tuple[Any, Any | SeqFormula]: - ... - -def fourier_sin_seq(func, limits, n) -> SeqFormula: - ... - -def finite_check(f, x, L) -> tuple[Literal[False], Any] | tuple[Literal[True], Any]: - ... +def fourier_cos_seq(func, limits, n) -> tuple[Any, Any | SeqFormula]: ... +def fourier_sin_seq(func, limits, n) -> SeqFormula: ... +def finite_check(f, x, L) -> tuple[Literal[False], Any] | tuple[Literal[True], Any]: ... class FourierSeries(SeriesBase): - def __new__(cls, *args) -> Self: - ... - + def __new__(cls, *args) -> Self: ... @property - def function(self) -> Basic: - ... - + def function(self) -> Basic: ... @property - def x(self): - ... - + def x(self): ... @property - def period(self) -> tuple[Any, Any]: - ... - + def period(self) -> tuple[Any, Any]: ... @property - def a0(self): - ... - + def a0(self): ... @property - def an(self): - ... - + def an(self): ... @property - def bn(self): - ... - + def bn(self): ... @property - def interval(self) -> FiniteSet | Interval: - ... - + def interval(self) -> FiniteSet | Interval: ... @property - def start(self): - ... - + def start(self): ... @property - def stop(self): - ... - + def stop(self): ... @property - def length(self): - ... - + def length(self): ... @property - def L(self): - ... - - def truncate(self, n=...) -> Generator[Any, Any, None] | Order: - ... - - def sigma_approximation(self, n=...) -> Order: - ... - - def shift(self, s) -> Self: - ... - - def shiftx(self, s) -> Self: - ... - - def scale(self, s) -> Self: - ... - - def scalex(self, s) -> Self: - ... - - def __neg__(self) -> Self: - ... - - def __add__(self, other) -> Self | Order: - ... - - def __sub__(self, other) -> Self | Order: - ... - - + def L(self): ... + def truncate(self, n=...) -> Generator[Any, Any, None] | Order: ... + def sigma_approximation(self, n=...) -> Order: ... + def shift(self, s) -> Self: ... + def shiftx(self, s) -> Self: ... + def scale(self, s) -> Self: ... + def scalex(self, s) -> Self: ... + def __neg__(self) -> Self: ... + def __add__(self, other) -> Self | Order: ... + def __sub__(self, other) -> Self | Order: ... class FiniteFourierSeries(FourierSeries): - def __new__(cls, f, limits, exprs) -> Self: - ... - + def __new__(cls, f, limits, exprs) -> Self: ... @property - def interval(self) -> FiniteSet | Interval: - ... - + def interval(self) -> FiniteSet | Interval: ... @property - def length(self): - ... - - def shiftx(self, s) -> Self: - ... - - def scale(self, s) -> Self: - ... - - def scalex(self, s) -> Self: - ... - - def __add__(self, other) -> FourierSeries | Order | FiniteFourierSeries | None: - ... - - - -def fourier_series(f, limits=..., finite=...) -> FiniteFourierSeries | FourierSeries: - ... + def length(self): ... + def shiftx(self, s) -> Self: ... + def scale(self, s) -> Self: ... + def scalex(self, s) -> Self: ... + def __add__(self, other) -> FourierSeries | Order | FiniteFourierSeries | None: ... +def fourier_series(f, limits=..., finite=...) -> FiniteFourierSeries | FourierSeries: ... diff --git a/stubs/sympy-stubs/series/gruntz.pyi b/stubs/sympy-stubs/series/gruntz.pyi index 385442fe..88e96228 100644 --- a/stubs/sympy-stubs/series/gruntz.pyi +++ b/stubs/sympy-stubs/series/gruntz.pyi @@ -6,83 +6,52 @@ from sympy.core.function import UndefinedFunction from sympy.utilities.misc import debug_decorator as debug timeit = ... -def compare(a, b, x) -> Literal['<', '>', '=']: - ... -class SubsSet(dict): - def __init__(self) -> None: - ... - - def __repr__(self) -> str: - ... - - def __getitem__(self, key): - ... - - def do_subs(self, e): - ... - - def meets(self, s2) -> bool: - ... - - def union(self, s2, exps=...) -> tuple[SubsSet, Any | None]: - ... - - def copy(self) -> SubsSet: - ... - +def compare(a, b, x) -> Literal["<", ">", "="]: ... +class SubsSet(dict): + def __init__(self) -> None: ... + def __repr__(self) -> str: ... + def __getitem__(self, key): ... + def do_subs(self, e): ... + def meets(self, s2) -> bool: ... + def union(self, s2, exps=...) -> tuple[SubsSet, Any | None]: ... + def copy(self) -> SubsSet: ... @debug -def mrv(e, x) -> tuple[SubsSet, Basic] | tuple[SubsSet, Any] | tuple[Any, Basic] | tuple[Any, Any] | tuple[SubsSet, Any | Literal[1]] | tuple[Any, type[UndefinedFunction] | Any]: - ... - -def mrv_max3(f, expsf, g, expsg, union, expsboth, x) -> tuple[SubsSet, Any] | tuple[Any, Any]: - ... - -def mrv_max1(f, g, exps, x) -> tuple[SubsSet, Any] | tuple[Any, Any]: - ... - +def mrv( + e, x +) -> ( + tuple[SubsSet, Basic] + | tuple[SubsSet, Any] + | tuple[Any, Basic] + | tuple[Any, Any] + | tuple[SubsSet, Any | Literal[1]] + | tuple[Any, type[UndefinedFunction] | Any] +): ... +def mrv_max3(f, expsf, g, expsg, union, expsboth, x) -> tuple[SubsSet, Any] | tuple[Any, Any]: ... +def mrv_max1(f, g, exps, x) -> tuple[SubsSet, Any] | tuple[Any, Any]: ... @debug @cacheit @timeit -def sign(e, x) -> type[UndefinedFunction] | Literal[1, -1, 0]: - ... - +def sign(e, x) -> type[UndefinedFunction] | Literal[1, -1, 0]: ... @debug @timeit @cacheit -def limitinf(e, x): - ... - -def moveup2(s, x) -> SubsSet: - ... - -def moveup(l, x) -> list[Any]: - ... - +def limitinf(e, x): ... +def moveup2(s, x) -> SubsSet: ... +def moveup(l, x) -> list[Any]: ... @debug @timeit -def calculate_series(e, x, logx=...) -> bool | Basic: - ... - +def calculate_series(e, x, logx=...) -> bool | Basic: ... @debug @timeit @cacheit -def mrv_leadterm(e, x) -> tuple[Any, Any] | tuple[Basic | Any | type[UndefinedFunction] | Literal[1], Any]: - ... - +def mrv_leadterm(e, x) -> tuple[Any, Any] | tuple[Basic | Any | type[UndefinedFunction] | Literal[1], Any]: ... def build_expression_tree(Omega, rewrites) -> dict[Any, Any]: - class Node: - ... - - + class Node: ... @debug @timeit -def rewrite(e, Omega, x, wsym) -> tuple[Any, Any]: - ... - -def gruntz(e, z, z0, dir=...): - ... - +def rewrite(e, Omega, x, wsym) -> tuple[Any, Any]: ... +def gruntz(e, z, z0, dir=...): ... diff --git a/stubs/sympy-stubs/series/limits.pyi b/stubs/sympy-stubs/series/limits.pyi index 9176ba69..7fe1e69f 100644 --- a/stubs/sympy-stubs/series/limits.pyi +++ b/stubs/sympy-stubs/series/limits.pyi @@ -4,25 +4,12 @@ from sympy.core import Expr from sympy.core.basic import Basic from sympy.core.function import UndefinedFunction -def limit(e, z, z0, dir=...): - ... - -def heuristics(e, z, z0, dir): - ... +def limit(e, z, z0, dir=...): ... +def heuristics(e, z, z0, dir): ... class Limit(Expr): - def __new__(cls, e, z, z0, dir=...) -> Self: - ... - + def __new__(cls, e, z, z0, dir=...) -> Self: ... @property - def free_symbols(self) -> set[Basic]: - ... - - def pow_heuristics(self, e) -> type[UndefinedFunction] | None: - ... - - def doit(self, **hints): - ... - - - + def free_symbols(self) -> set[Basic]: ... + def pow_heuristics(self, e) -> type[UndefinedFunction] | None: ... + def doit(self, **hints): ... diff --git a/stubs/sympy-stubs/series/limitseq.pyi b/stubs/sympy-stubs/series/limitseq.pyi index 159ab84c..1466265c 100644 --- a/stubs/sympy-stubs/series/limitseq.pyi +++ b/stubs/sympy-stubs/series/limitseq.pyi @@ -2,12 +2,6 @@ from sympy.calculus.accumulationbounds import AccumulationBounds from sympy.core.basic import Basic from sympy.series.order import Order -def difference_delta(expr, n=..., step=...): - ... - -def dominant(expr, n) -> Basic | None: - ... - -def limit_seq(expr, n=..., trials=...) -> AccumulationBounds | Order | None: - ... - +def difference_delta(expr, n=..., step=...): ... +def dominant(expr, n) -> Basic | None: ... +def limit_seq(expr, n=..., trials=...) -> AccumulationBounds | Order | None: ... diff --git a/stubs/sympy-stubs/series/order.pyi b/stubs/sympy-stubs/series/order.pyi index 3f902432..85547d3b 100644 --- a/stubs/sympy-stubs/series/order.pyi +++ b/stubs/sympy-stubs/series/order.pyi @@ -8,44 +8,21 @@ class Order(Expr): is_Order = ... __slots__ = ... @cacheit - def __new__(cls, expr, *args, **kwargs): - ... - + def __new__(cls, expr, *args, **kwargs): ... @property - def expr(self) -> Basic: - ... - + def expr(self) -> Basic: ... @property - def variables(self) -> tuple[Any, ...] | tuple[()]: - ... - + def variables(self) -> tuple[Any, ...] | tuple[()]: ... @property - def point(self) -> tuple[Any, ...] | tuple[()]: - ... - + def point(self) -> tuple[Any, ...] | tuple[()]: ... @property - def free_symbols(self) -> set[Basic]: - ... - - def as_expr_variables(self, order_symbols) -> tuple[Basic, tuple[tuple[Any, Any] | Basic, ...]]: - ... - - def removeO(self): - ... - - def getO(self) -> Self: - ... - + def free_symbols(self) -> set[Basic]: ... + def as_expr_variables(self, order_symbols) -> tuple[Basic, tuple[tuple[Any, Any] | Basic, ...]]: ... + def removeO(self): ... + def getO(self) -> Self: ... @cacheit - def contains(self, expr): - ... - - def __contains__(self, other): - ... - - def __neg__(self) -> Self: - ... - - + def contains(self, expr): ... + def __contains__(self, other): ... + def __neg__(self) -> Self: ... O = Order diff --git a/stubs/sympy-stubs/series/sequences.pyi b/stubs/sympy-stubs/series/sequences.pyi index 0de53aff..11283aa0 100644 --- a/stubs/sympy-stubs/series/sequences.pyi +++ b/stubs/sympy-stubs/series/sequences.pyi @@ -12,240 +12,115 @@ class SeqBase(Basic): is_commutative = ... _op_priority = ... @property - def gen(self): - ... - + def gen(self): ... @property - def interval(self): - ... - + def interval(self): ... @property - def start(self): - ... - + def start(self): ... @property - def stop(self): - ... - + def stop(self): ... @property - def length(self): - ... - + def length(self): ... @property - def variables(self) -> tuple[()]: - ... - + def variables(self) -> tuple[()]: ... @property - def free_symbols(self) -> set[Basic]: - ... - + def free_symbols(self) -> set[Basic]: ... @cacheit - def coeff(self, pt): - ... - - def coeff_mul(self, other) -> Order: - ... - - def __add__(self, other) -> SeqAdd: - ... - - @call_highest_priority('__add__') - def __radd__(self, other): - ... - - def __sub__(self, other) -> SeqAdd: - ... - - @call_highest_priority('__sub__') - def __rsub__(self, other): - ... - - def __neg__(self) -> Order: - ... - - def __mul__(self, other) -> SeqMul: - ... - - @call_highest_priority('__mul__') - def __rmul__(self, other): - ... - - def __iter__(self) -> Generator[Any, Any, None]: - ... - - def __getitem__(self, index) -> list[Any] | None: - ... - - def find_linear_recurrence(self, n, d=..., gfvar=...) -> list[Any] | tuple[list[Any], None] | tuple[Any | list[Any], Any]: - ... - - + def coeff(self, pt): ... + def coeff_mul(self, other) -> Order: ... + def __add__(self, other) -> SeqAdd: ... + @call_highest_priority("__add__") + def __radd__(self, other): ... + def __sub__(self, other) -> SeqAdd: ... + @call_highest_priority("__sub__") + def __rsub__(self, other): ... + def __neg__(self) -> Order: ... + def __mul__(self, other) -> SeqMul: ... + @call_highest_priority("__mul__") + def __rmul__(self, other): ... + def __iter__(self) -> Generator[Any, Any, None]: ... + def __getitem__(self, index) -> list[Any] | None: ... + def find_linear_recurrence(self, n, d=..., gfvar=...) -> list[Any] | tuple[list[Any], None] | tuple[Any | list[Any], Any]: ... class EmptySequence(SeqBase, metaclass=Singleton): @property - def interval(self): - ... - - @property - def length(self): - ... - - def coeff_mul(self, coeff) -> Self: - ... - - def __iter__(self) -> Iterator[Any]: - ... - - + def interval(self): ... + @property + def length(self): ... + def coeff_mul(self, coeff) -> Self: ... + def __iter__(self) -> Iterator[Any]: ... class SeqExpr(SeqBase): @property - def gen(self) -> Basic: - ... - + def gen(self) -> Basic: ... @property - def interval(self) -> FiniteSet | Interval: - ... - + def interval(self) -> FiniteSet | Interval: ... @property - def start(self): - ... - + def start(self): ... @property - def stop(self): - ... - + def stop(self): ... @property - def length(self): - ... - + def length(self): ... @property - def variables(self) -> tuple[Any]: - ... - - + def variables(self) -> tuple[Any]: ... class SeqPer(SeqExpr): - def __new__(cls, periodical, limits=...) -> Self: - ... - - @property - def period(self) -> int: - ... - - @property - def periodical(self) -> Basic: - ... - - def coeff_mul(self, coeff) -> SeqPer: - ... - - + def __new__(cls, periodical, limits=...) -> Self: ... + @property + def period(self) -> int: ... + @property + def periodical(self) -> Basic: ... + def coeff_mul(self, coeff) -> SeqPer: ... class SeqFormula(SeqExpr): - def __new__(cls, formula, limits=...) -> Self: - ... - - @property - def formula(self) -> Basic: - ... - - def coeff_mul(self, coeff) -> SeqFormula: - ... - - def expand(self, *args, **kwargs) -> SeqFormula: - ... - - + def __new__(cls, formula, limits=...) -> Self: ... + @property + def formula(self) -> Basic: ... + def coeff_mul(self, coeff) -> SeqFormula: ... + def expand(self, *args, **kwargs) -> SeqFormula: ... class RecursiveSeq(SeqBase): - def __new__(cls, recurrence, yn, n, initial=..., start=...) -> Self: - ... - - @property - def recurrence(self) -> Eq | Relational | Ne: - ... - - @property - def yn(self) -> Basic: - ... - - @property - def y(self) -> type[Basic]: - ... - - @property - def n(self) -> Basic: - ... - - @property - def initial(self) -> Basic: - ... - - @property - def start(self) -> Basic: - ... - - @property - def stop(self): - ... - - @property - def interval(self) -> tuple[Basic, Any]: - ... - - def __iter__(self) -> Generator[Any, Any, NoReturn]: - ... - - + def __new__(cls, recurrence, yn, n, initial=..., start=...) -> Self: ... + @property + def recurrence(self) -> Eq | Relational | Ne: ... + @property + def yn(self) -> Basic: ... + @property + def y(self) -> type[Basic]: ... + @property + def n(self) -> Basic: ... + @property + def initial(self) -> Basic: ... + @property + def start(self) -> Basic: ... + @property + def stop(self): ... + @property + def interval(self) -> tuple[Basic, Any]: ... + def __iter__(self) -> Generator[Any, Any, NoReturn]: ... -def sequence(seq, limits=...) -> SeqPer | SeqFormula: - ... +def sequence(seq, limits=...) -> SeqPer | SeqFormula: ... class SeqExprOp(SeqBase): @property - def gen(self) -> tuple[Any, ...]: - ... - + def gen(self) -> tuple[Any, ...]: ... @property - def interval(self) -> FiniteSet | Intersection | Union | Complement: - ... - + def interval(self) -> FiniteSet | Intersection | Union | Complement: ... @property - def start(self): - ... - + def start(self): ... @property - def stop(self): - ... - + def stop(self): ... @property - def variables(self) -> tuple[Any, ...]: - ... - + def variables(self) -> tuple[Any, ...]: ... @property - def length(self): - ... - - + def length(self): ... class SeqAdd(SeqExprOp): - def __new__(cls, *args, **kwargs) -> SeqAdd | Self: - ... - + def __new__(cls, *args, **kwargs) -> SeqAdd | Self: ... @staticmethod - def reduce(args) -> SeqAdd: - ... - - + def reduce(args) -> SeqAdd: ... class SeqMul(SeqExprOp): - def __new__(cls, *args, **kwargs) -> SeqMul | Self: - ... - + def __new__(cls, *args, **kwargs) -> SeqMul | Self: ... @staticmethod - def reduce(args) -> SeqMul: - ... - - - + def reduce(args) -> SeqMul: ... diff --git a/stubs/sympy-stubs/series/series_class.pyi b/stubs/sympy-stubs/series/series_class.pyi index f8718be8..dc1d9ee5 100644 --- a/stubs/sympy-stubs/series/series_class.pyi +++ b/stubs/sympy-stubs/series/series_class.pyi @@ -6,38 +6,18 @@ from sympy.core.expr import Expr class SeriesBase(Expr): @property - def interval(self): - ... - + def interval(self): ... @property - def start(self): - ... - + def start(self): ... @property - def stop(self): - ... - + def stop(self): ... @property - def length(self): - ... - + def length(self): ... @property - def variables(self) -> tuple[()]: - ... - + def variables(self) -> tuple[()]: ... @property - def free_symbols(self) -> set[Basic]: - ... - + def free_symbols(self) -> set[Basic]: ... @cacheit - def term(self, pt): - ... - - def __iter__(self) -> Generator[Any, Any, None]: - ... - - def __getitem__(self, index) -> list[Any] | None: - ... - - - + def term(self, pt): ... + def __iter__(self) -> Generator[Any, Any, None]: ... + def __getitem__(self, index) -> list[Any] | None: ... diff --git a/stubs/sympy-stubs/sets/__init__.pyi b/stubs/sympy-stubs/sets/__init__.pyi index 81d26fc6..1a208028 100644 --- a/stubs/sympy-stubs/sets/__init__.pyi +++ b/stubs/sympy-stubs/sets/__init__.pyi @@ -26,4 +26,32 @@ Naturals0 = ... Rationals = ... Reals = ... UniversalSet = ... -__all__ = ['Set', 'Interval', 'Union', 'EmptySet', 'FiniteSet', 'ProductSet', 'Intersection', 'imageset', 'Complement', 'SymmetricDifference', 'DisjointUnion', 'ImageSet', 'Range', 'ComplexRegion', 'Reals', 'Contains', 'ConditionSet', 'Ordinal', 'OmegaPower', 'ord0', 'PowerSet', 'Reals', 'Naturals', 'Naturals0', 'UniversalSet', 'Integers', 'Rationals'] +__all__ = [ + "Set", + "Interval", + "Union", + "EmptySet", + "FiniteSet", + "ProductSet", + "Intersection", + "imageset", + "Complement", + "SymmetricDifference", + "DisjointUnion", + "ImageSet", + "Range", + "ComplexRegion", + "Reals", + "Contains", + "ConditionSet", + "Ordinal", + "OmegaPower", + "ord0", + "PowerSet", + "Reals", + "Naturals", + "Naturals0", + "UniversalSet", + "Integers", + "Rationals", +] diff --git a/stubs/sympy-stubs/sets/conditionset.pyi b/stubs/sympy-stubs/sets/conditionset.pyi index c1eec801..1e2c5613 100644 --- a/stubs/sympy-stubs/sets/conditionset.pyi +++ b/stubs/sympy-stubs/sets/conditionset.pyi @@ -4,23 +4,15 @@ from sympy.core.logic import And from sympy.sets.sets import Complement, FiniteSet, Intersection, Set, Union adummy = ... + class ConditionSet(Set): - def __new__(cls, sym, condition, base_set=...) -> Set | FiniteSet | Intersection | Union | Complement | Self: - ... - + def __new__(cls, sym, condition, base_set=...) -> Set | FiniteSet | Intersection | Union | Complement | Self: ... + sym = ... condition = ... base_set = ... @property - def free_symbols(self) -> Any: - ... - + def free_symbols(self) -> Any: ... @property - def bound_symbols(self) -> list[Any]: - ... - - def as_relational(self, other) -> And: - ... - - - + def bound_symbols(self) -> list[Any]: ... + def as_relational(self, other) -> And: ... diff --git a/stubs/sympy-stubs/sets/contains.pyi b/stubs/sympy-stubs/sets/contains.pyi index 6a9cd373..4692f804 100644 --- a/stubs/sympy-stubs/sets/contains.pyi +++ b/stubs/sympy-stubs/sets/contains.pyi @@ -6,15 +6,7 @@ from sympy.sets.sets import Set class Contains(BooleanFunction): @classmethod - def eval(cls, x, s) -> Set | None: - ... - + def eval(cls, x, s) -> Set | None: ... @property - def binary_symbols(self) -> set[Any | Basic]: - ... - - def as_set(self) -> Basic: - ... - - - + def binary_symbols(self) -> set[Any | Basic]: ... + def as_set(self) -> Basic: ... diff --git a/stubs/sympy-stubs/sets/fancysets.pyi b/stubs/sympy-stubs/sets/fancysets.pyi index 93885456..2c84496e 100644 --- a/stubs/sympy-stubs/sets/fancysets.pyi +++ b/stubs/sympy-stubs/sets/fancysets.pyi @@ -12,10 +12,7 @@ class Rationals(Set, metaclass=Singleton): _sup = ... is_empty = ... is_finite_set = ... - def __iter__(self) -> Generator[Any | Rational | Integer, Any, NoReturn]: - ... - - + def __iter__(self) -> Generator[Any | Rational | Integer, Any, NoReturn]: ... class Naturals(Set, metaclass=Singleton): is_iterable = ... @@ -23,188 +20,100 @@ class Naturals(Set, metaclass=Singleton): _sup = ... is_empty = ... is_finite_set = ... - def __iter__(self) -> Generator[Any, Any, NoReturn]: - ... - - def as_relational(self, x) -> And: - ... - - + def __iter__(self) -> Generator[Any, Any, NoReturn]: ... + def as_relational(self, x) -> And: ... class Naturals0(Naturals): _inf = ... - class Integers(Set, metaclass=Singleton): is_iterable = ... is_empty = ... is_finite_set = ... - def __iter__(self) -> Generator[Any, Any, NoReturn]: - ... - - def as_relational(self, x) -> And: - ... - - + def __iter__(self) -> Generator[Any, Any, NoReturn]: ... + def as_relational(self, x) -> And: ... class Reals(Interval, metaclass=Singleton): @property - def start(self): - ... - - @property - def end(self): - ... - - @property - def left_open(self) -> Literal[True]: - ... - - @property - def right_open(self) -> Literal[True]: - ... - - def __eq__(self, other) -> bool: - ... - - def __hash__(self) -> int: - ... - - + def start(self): ... + @property + def end(self): ... + @property + def left_open(self) -> Literal[True]: ... + @property + def right_open(self) -> Literal[True]: ... + def __eq__(self, other) -> bool: ... + def __hash__(self) -> int: ... class ImageSet(Set): - def __new__(cls, flambda, *sets) -> FiniteSet | Self: - ... - + def __new__(cls, flambda, *sets) -> FiniteSet | Self: ... + lamda = ... base_sets = ... @property - def base_set(self) -> Any | FiniteSet | ProductSet: - ... - - @property - def base_pset(self) -> FiniteSet | ProductSet: - ... - - def __iter__(self) -> Generator[Any, Any, None]: - ... - - @property - def is_iterable(self) -> bool: - ... - - def doit(self, **hints) -> Any | FiniteSet | Self: - ... - - + def base_set(self) -> Any | FiniteSet | ProductSet: ... + @property + def base_pset(self) -> FiniteSet | ProductSet: ... + def __iter__(self) -> Generator[Any, Any, None]: ... + @property + def is_iterable(self) -> bool: ... + def doit(self, **hints) -> Any | FiniteSet | Self: ... class Range(Set): - def __new__(cls, *args): - ... - + def __new__(cls, *args): ... + start = ... stop = ... step = ... @property - def reversed(self) -> Self: - ... - - def __iter__(self) -> Generator[Any, Any, None]: - ... - - @property - def is_iterable(self) -> bool: - ... - - def __len__(self) -> int: - ... - - @property - def size(self): - ... - - @property - def is_finite_set(self) -> Literal[True]: - ... - - @property - def is_empty(self) -> None: - ... - - def __bool__(self) -> bool: - ... - - def __getitem__(self, i): - ... - - def as_relational(self, x) -> And: - ... - - + def reversed(self) -> Self: ... + def __iter__(self) -> Generator[Any, Any, None]: ... + @property + def is_iterable(self) -> bool: ... + def __len__(self) -> int: ... + @property + def size(self): ... + @property + def is_finite_set(self) -> Literal[True]: ... + @property + def is_empty(self) -> None: ... + def __bool__(self) -> bool: ... + def __getitem__(self, i): ... + def as_relational(self, x) -> And: ... -def normalize_theta_set(theta) -> FiniteSet | Union | Interval: - ... +def normalize_theta_set(theta) -> FiniteSet | Union | Interval: ... class ComplexRegion(Set): is_ComplexRegion = ... - def __new__(cls, sets, polar=...) -> FiniteSet | CartesianComplexRegion | PolarComplexRegion: - ... - + def __new__(cls, sets, polar=...) -> FiniteSet | CartesianComplexRegion | PolarComplexRegion: ... @property - def sets(self) -> Basic: - ... - + def sets(self) -> Basic: ... @property - def psets(self) -> tuple[Basic] | tuple[Basic, ...]: - ... - + def psets(self) -> tuple[Basic] | tuple[Basic, ...]: ... @property - def a_interval(self) -> FiniteSet | Union: - ... - + def a_interval(self) -> FiniteSet | Union: ... @property - def b_interval(self) -> FiniteSet | Union: - ... - + def b_interval(self) -> FiniteSet | Union: ... @classmethod - def from_real(cls, sets) -> FiniteSet | CartesianComplexRegion: - ... - - + def from_real(cls, sets) -> FiniteSet | CartesianComplexRegion: ... class CartesianComplexRegion(ComplexRegion): polar = ... variables = ... - def __new__(cls, sets) -> FiniteSet | Self: - ... - + def __new__(cls, sets) -> FiniteSet | Self: ... @property - def expr(self): - ... - - + def expr(self): ... class PolarComplexRegion(ComplexRegion): polar = ... variables = ... - def __new__(cls, sets) -> Self: - ... - + def __new__(cls, sets) -> Self: ... @property - def expr(self): - ... - - + def expr(self): ... class Complexes(CartesianComplexRegion, metaclass=Singleton): is_empty = ... is_finite_set = ... @property - def sets(self) -> FiniteSet | ProductSet: - ... - - def __new__(cls) -> Self: - ... - - - + def sets(self) -> FiniteSet | ProductSet: ... + def __new__(cls) -> Self: ... diff --git a/stubs/sympy-stubs/sets/handlers/add.pyi b/stubs/sympy-stubs/sets/handlers/add.pyi index 6edc2033..ba1636ea 100644 --- a/stubs/sympy-stubs/sets/handlers/add.pyi +++ b/stubs/sympy-stubs/sets/handlers/add.pyi @@ -5,43 +5,24 @@ from sympy.sets.sets import FiniteSet _set_add = ... _set_sub = ... -@_set_add.register(Basic, Basic) -def _(x, y) -> None: - ... +@_set_add.register(Basic, Basic) +def _(x, y) -> None: ... @_set_add.register(Expr, Expr) -def _(x, y): - ... - +def _(x, y): ... @_set_add.register(Interval, Interval) -def _(x, y) -> FiniteSet | Interval: - ... - +def _(x, y) -> FiniteSet | Interval: ... @_set_add.register(Interval, Infinity) -def _(x, y) -> FiniteSet | Interval: - ... - +def _(x, y) -> FiniteSet | Interval: ... @_set_add.register(Interval, NegativeInfinity) -def _(x, y) -> FiniteSet | Interval: - ... - +def _(x, y) -> FiniteSet | Interval: ... @_set_sub.register(Basic, Basic) -def _(x, y) -> None: - ... - +def _(x, y) -> None: ... @_set_sub.register(Expr, Expr) -def _(x, y): - ... - +def _(x, y): ... @_set_sub.register(Interval, Interval) -def _(x, y) -> FiniteSet | Interval: - ... - +def _(x, y) -> FiniteSet | Interval: ... @_set_sub.register(Interval, Infinity) -def _(x, y) -> FiniteSet | Interval: - ... - +def _(x, y) -> FiniteSet | Interval: ... @_set_sub.register(Interval, NegativeInfinity) -def _(x, y) -> FiniteSet | Interval: - ... - +def _(x, y) -> FiniteSet | Interval: ... diff --git a/stubs/sympy-stubs/sets/handlers/functions.pyi b/stubs/sympy-stubs/sets/handlers/functions.pyi index fca2bf4d..0396c1f5 100644 --- a/stubs/sympy-stubs/sets/handlers/functions.pyi +++ b/stubs/sympy-stubs/sets/handlers/functions.pyi @@ -6,51 +6,28 @@ from sympy.sets.sets import Complement, EmptySet, Set FunctionUnion = ... _set_function = ... -@_set_function.register(FunctionClass, Set) -def _(f, x) -> None: - ... +@_set_function.register(FunctionClass, Set) +def _(f, x) -> None: ... @_set_function.register(FunctionUnion, FiniteSet) -def _(f, x) -> FiniteSet: - ... - +def _(f, x) -> FiniteSet: ... @_set_function.register(Lambda, Interval) -def _(f, x): - ... - +def _(f, x): ... @_set_function.register(FunctionClass, Interval) -def _(f, x) -> FiniteSet | Interval | ImageSet: - ... - +def _(f, x) -> FiniteSet | Interval | ImageSet: ... @_set_function.register(FunctionUnion, Union) -def _(f, x) -> FiniteSet | Union: - ... - +def _(f, x) -> FiniteSet | Union: ... @_set_function.register(FunctionUnion, Intersection) -def _(f, x) -> FiniteSet | Intersection | Union | Complement | ImageSet: - ... - +def _(f, x) -> FiniteSet | Intersection | Union | Complement | ImageSet: ... @_set_function.register(FunctionUnion, EmptySet) -def _(f, x): - ... - +def _(f, x): ... @_set_function.register(FunctionUnion, Set) -def _(f, x) -> FiniteSet | ImageSet: - ... - +def _(f, x) -> FiniteSet | ImageSet: ... @_set_function.register(FunctionUnion, Range) -def _(f, self) -> FiniteSet | Basic | ImageSet | None: - ... - +def _(f, self) -> FiniteSet | Basic | ImageSet | None: ... @_set_function.register(FunctionUnion, Integers) -def _(f, self) -> FiniteSet | ImageSet | None: - ... - +def _(f, self) -> FiniteSet | ImageSet | None: ... @_set_function.register(FunctionUnion, Naturals) -def _(f, self) -> Range | None: - ... - +def _(f, self) -> Range | None: ... @_set_function.register(FunctionUnion, Reals) -def _(f, self) -> None: - ... - +def _(f, self) -> None: ... diff --git a/stubs/sympy-stubs/sets/handlers/intersection.pyi b/stubs/sympy-stubs/sets/handlers/intersection.pyi index 724e7f99..d090c343 100644 --- a/stubs/sympy-stubs/sets/handlers/intersection.pyi +++ b/stubs/sympy-stubs/sets/handlers/intersection.pyi @@ -13,103 +13,56 @@ from sympy.sets.fancysets import ( from sympy.sets.sets import Complement, EmptySet, FiniteSet, Intersection, Interval, ProductSet, Set, Union, UniversalSet intersection_sets = ... -@intersection_sets.register(ConditionSet, ConditionSet) -def _(a, b) -> None: - ... +@intersection_sets.register(ConditionSet, ConditionSet) +def _(a, b) -> None: ... @intersection_sets.register(ConditionSet, Set) -def _(a, b) -> Set | FiniteSet | Intersection | Union | Complement | ConditionSet: - ... - +def _(a, b) -> Set | FiniteSet | Intersection | Union | Complement | ConditionSet: ... @intersection_sets.register(Naturals, Integers) -def _(a, b): - ... - +def _(a, b): ... @intersection_sets.register(Naturals, Naturals) -def _(a, b): - ... - +def _(a, b): ... @intersection_sets.register(Interval, Naturals) -def _(a, b): - ... - +def _(a, b): ... @intersection_sets.register(ComplexRegion, Set) -def _(self, other) -> FiniteSet | CartesianComplexRegion | PolarComplexRegion | ComplexRegion | Intersection | Union | Complement | None: - ... - +def _( + self, other +) -> FiniteSet | CartesianComplexRegion | PolarComplexRegion | ComplexRegion | Intersection | Union | Complement | None: ... @intersection_sets.register(Integers, Reals) -def _(a, b): - ... - +def _(a, b): ... @intersection_sets.register(Range, Interval) -def _(a, b) -> None: - ... - +def _(a, b) -> None: ... @intersection_sets.register(Range, Naturals) -def _(a, b): - ... - +def _(a, b): ... @intersection_sets.register(Range, Range) -def _(a, b) -> Range | None: - ... - +def _(a, b) -> Range | None: ... @intersection_sets.register(Range, Integers) -def _(a, b): - ... - +def _(a, b): ... @intersection_sets.register(Range, Rationals) -def _(a, b): - ... - +def _(a, b): ... @intersection_sets.register(ImageSet, Set) -def _(self, other): - ... - +def _(self, other): ... @intersection_sets.register(ProductSet, ProductSet) -def _(a, b) -> FiniteSet | ProductSet: - ... - +def _(a, b) -> FiniteSet | ProductSet: ... @intersection_sets.register(Interval, Interval) -def _(a, b) -> FiniteSet | Interval | None: - ... - +def _(a, b) -> FiniteSet | Interval | None: ... @intersection_sets.register(EmptySet, Set) -def _(a, b): - ... - +def _(a, b): ... @intersection_sets.register(UniversalSet, Set) -def _(a, b): - ... - +def _(a, b): ... @intersection_sets.register(FiniteSet, FiniteSet) -def _(a, b) -> FiniteSet: - ... - +def _(a, b) -> FiniteSet: ... @intersection_sets.register(FiniteSet, Set) -def _(a, b) -> FiniteSet | None: - ... - +def _(a, b) -> FiniteSet | None: ... @intersection_sets.register(Set, Set) -def _(a, b) -> None: - ... - +def _(a, b) -> None: ... @intersection_sets.register(Integers, Rationals) -def _(a, b): - ... - +def _(a, b): ... @intersection_sets.register(Naturals, Rationals) -def _(a, b): - ... - +def _(a, b): ... @intersection_sets.register(Rationals, Reals) -def _(a, b): - ... - +def _(a, b): ... @intersection_sets.register(Integers, Interval) -def _(a, b) -> None: - ... - +def _(a, b) -> None: ... @intersection_sets.register(Naturals, Interval) -def _(a, b) -> None: - ... - +def _(a, b) -> None: ... diff --git a/stubs/sympy-stubs/sets/handlers/issubset.pyi b/stubs/sympy-stubs/sets/handlers/issubset.pyi index 9650a7ac..d2f0fad1 100644 --- a/stubs/sympy-stubs/sets/handlers/issubset.pyi +++ b/stubs/sympy-stubs/sets/handlers/issubset.pyi @@ -5,67 +5,36 @@ from sympy.sets.sets import FiniteSet, Interval, ProductSet, Set, Union _inf_sets = ... is_subset_sets = ... -@is_subset_sets.register(Set, Set) -def _(a, b) -> None: - ... +@is_subset_sets.register(Set, Set) +def _(a, b) -> None: ... @is_subset_sets.register(Interval, Interval) -def _(a, b) -> Literal[False] | None: - ... - +def _(a, b) -> Literal[False] | None: ... @is_subset_sets.register(Interval, FiniteSet) -def _(a_interval, b_fs) -> Literal[False] | None: - ... - +def _(a_interval, b_fs) -> Literal[False] | None: ... @is_subset_sets.register(Interval, Union) -def _(a_interval, b_u) -> Literal[False] | None: - ... - +def _(a_interval, b_u) -> Literal[False] | None: ... @is_subset_sets.register(Range, Range) -def _(a, b) -> bool | None: - ... - +def _(a, b) -> bool | None: ... @is_subset_sets.register(Range, Interval) -def _(a_range, b_interval) -> bool | None: - ... - +def _(a_range, b_interval) -> bool | None: ... @is_subset_sets.register(Range, FiniteSet) -def _(a_range, b_finiteset) -> bool | None: - ... - +def _(a_range, b_finiteset) -> bool | None: ... @is_subset_sets.register(Interval, Range) -def _(a_interval, b_range) -> Literal[False] | None: - ... - +def _(a_interval, b_range) -> Literal[False] | None: ... @is_subset_sets.register(Interval, Rationals) -def _(a_interval, b_rationals) -> Literal[False] | None: - ... - +def _(a_interval, b_rationals) -> Literal[False] | None: ... @is_subset_sets.register(Range, Complexes) -def _(a, b) -> Literal[True]: - ... - +def _(a, b) -> Literal[True]: ... @is_subset_sets.register(Complexes, Interval) -def _(a, b) -> Literal[False]: - ... - +def _(a, b) -> Literal[False]: ... @is_subset_sets.register(Complexes, Range) -def _(a, b) -> Literal[False]: - ... - +def _(a, b) -> Literal[False]: ... @is_subset_sets.register(Complexes, Rationals) -def _(a, b) -> Literal[False]: - ... - +def _(a, b) -> Literal[False]: ... @is_subset_sets.register(Rationals, Reals) -def _(a, b) -> Literal[True]: - ... - +def _(a, b) -> Literal[True]: ... @is_subset_sets.register(Rationals, Range) -def _(a, b) -> Literal[False]: - ... - +def _(a, b) -> Literal[False]: ... @is_subset_sets.register(ProductSet, FiniteSet) -def _(a_ps, b_fs) -> bool | None: - ... - +def _(a_ps, b_fs) -> bool | None: ... diff --git a/stubs/sympy-stubs/sets/handlers/mul.pyi b/stubs/sympy-stubs/sets/handlers/mul.pyi index 48359bb7..4a5d5088 100644 --- a/stubs/sympy-stubs/sets/handlers/mul.pyi +++ b/stubs/sympy-stubs/sets/handlers/mul.pyi @@ -6,35 +6,20 @@ from sympy.sets.sets import FiniteSet, Interval, Set, Union _set_mul = ... _set_div = ... -@_set_mul.register(Basic, Basic) -def _(x, y) -> None: - ... +@_set_mul.register(Basic, Basic) +def _(x, y) -> None: ... @_set_mul.register(Set, Set) -def _(x, y) -> None: - ... - +def _(x, y) -> None: ... @_set_mul.register(Expr, Expr) -def _(x, y): - ... - +def _(x, y): ... @_set_mul.register(Interval, Interval) -def _(x, y) -> FiniteSet | Interval: - ... - +def _(x, y) -> FiniteSet | Interval: ... @_set_div.register(Basic, Basic) -def _(x, y) -> None: - ... - +def _(x, y) -> None: ... @_set_div.register(Expr, Expr) -def _(x, y): - ... - +def _(x, y): ... @_set_div.register(Set, Set) -def _(x, y) -> None: - ... - +def _(x, y) -> None: ... @_set_div.register(Interval, Interval) -def _(x, y) -> FiniteSet | Interval | Any | ImageSet | Union: - ... - +def _(x, y) -> FiniteSet | Interval | Any | ImageSet | Union: ... diff --git a/stubs/sympy-stubs/sets/handlers/power.pyi b/stubs/sympy-stubs/sets/handlers/power.pyi index dd13b22b..1bde8a13 100644 --- a/stubs/sympy-stubs/sets/handlers/power.pyi +++ b/stubs/sympy-stubs/sets/handlers/power.pyi @@ -4,31 +4,18 @@ from sympy.sets.fancysets import ImageSet from sympy.sets.sets import FiniteSet, Interval, Set, Union _set_pow = ... -@_set_pow.register(Basic, Basic) -def _(x, y) -> None: - ... +@_set_pow.register(Basic, Basic) +def _(x, y) -> None: ... @_set_pow.register(Set, Set) -def _(x, y) -> FiniteSet | ImageSet: - ... - +def _(x, y) -> FiniteSet | ImageSet: ... @_set_pow.register(Expr, Expr) -def _(x, y): - ... - +def _(x, y): ... @_set_pow.register(Interval, Zero) -def _(x, z) -> FiniteSet: - ... - +def _(x, z) -> FiniteSet: ... @_set_pow.register(Interval, Integer) -def _(x, exponent) -> FiniteSet | Interval | Union | None: - ... - +def _(x, exponent) -> FiniteSet | Interval | Union | None: ... @_set_pow.register(Interval, Infinity) -def _(b, e) -> FiniteSet | Interval: - ... - +def _(b, e) -> FiniteSet | Interval: ... @_set_pow.register(Interval, NegativeInfinity) -def _(b, e): - ... - +def _(b, e): ... diff --git a/stubs/sympy-stubs/sets/handlers/union.pyi b/stubs/sympy-stubs/sets/handlers/union.pyi index 2e801044..f0e4651b 100644 --- a/stubs/sympy-stubs/sets/handlers/union.pyi +++ b/stubs/sympy-stubs/sets/handlers/union.pyi @@ -13,75 +13,40 @@ from sympy.sets.fancysets import ( from sympy.sets.sets import EmptySet, FiniteSet, Interval, ProductSet, Set, UniversalSet union_sets = ... -@union_sets.register(Naturals0, Naturals) -def _(a, b): - ... +@union_sets.register(Naturals0, Naturals) +def _(a, b): ... @union_sets.register(Rationals, Naturals) -def _(a, b): - ... - +def _(a, b): ... @union_sets.register(Rationals, Naturals0) -def _(a, b): - ... - +def _(a, b): ... @union_sets.register(Reals, Naturals) -def _(a, b): - ... - +def _(a, b): ... @union_sets.register(Reals, Naturals0) -def _(a, b): - ... - +def _(a, b): ... @union_sets.register(Reals, Rationals) -def _(a, b): - ... - +def _(a, b): ... @union_sets.register(Integers, Set) -def _(a, b) -> None: - ... - +def _(a, b) -> None: ... @union_sets.register(ComplexRegion, Set) -def _(a, b) -> FiniteSet | CartesianComplexRegion | PolarComplexRegion | None: - ... - +def _(a, b) -> FiniteSet | CartesianComplexRegion | PolarComplexRegion | None: ... @union_sets.register(EmptySet, Set) -def _(a, b): - ... - +def _(a, b): ... @union_sets.register(UniversalSet, Set) -def _(a, b): - ... - +def _(a, b): ... @union_sets.register(ProductSet, ProductSet) -def _(a, b) -> None: - ... - +def _(a, b) -> None: ... @union_sets.register(ProductSet, Set) -def _(a, b) -> None: - ... - +def _(a, b) -> None: ... @union_sets.register(Interval, Interval) -def _(a, b) -> FiniteSet | Interval | None: - ... - +def _(a, b) -> FiniteSet | Interval | None: ... @union_sets.register(Interval, UniversalSet) -def _(a, b): - ... - +def _(a, b): ... @union_sets.register(Interval, Set) -def _(a, b) -> set[Any] | None: - ... - +def _(a, b) -> set[Any] | None: ... @union_sets.register(FiniteSet, FiniteSet) -def _(a, b) -> FiniteSet: - ... - +def _(a, b) -> FiniteSet: ... @union_sets.register(FiniteSet, Set) -def _(a, b) -> set[Any] | None: - ... - +def _(a, b) -> set[Any] | None: ... @union_sets.register(Set, Set) -def _(a, b) -> None: - ... - +def _(a, b) -> None: ... diff --git a/stubs/sympy-stubs/sets/ordinals.pyi b/stubs/sympy-stubs/sets/ordinals.pyi index 1ed98c48..9e93961a 100644 --- a/stubs/sympy-stubs/sets/ordinals.pyi +++ b/stubs/sympy-stubs/sets/ordinals.pyi @@ -4,112 +4,52 @@ from typing import Literal, Self from sympy.core import Basic class OmegaPower(Basic): - def __new__(cls, a, b) -> Self: - ... - + def __new__(cls, a, b) -> Self: ... @property - def exp(self) -> Basic: - ... - + def exp(self) -> Basic: ... @property - def mult(self) -> Basic: - ... - - def __eq__(self, other) -> bool: - ... - - def __hash__(self) -> int: - ... - - def __lt__(self, other) -> bool: - ... - - + def mult(self) -> Basic: ... + def __eq__(self, other) -> bool: ... + def __hash__(self) -> int: ... + def __lt__(self, other) -> bool: ... class Ordinal(Basic): - def __new__(cls, *terms) -> Self: - ... - + def __new__(cls, *terms) -> Self: ... @property - def terms(self) -> tuple[Basic, ...]: - ... - + def terms(self) -> tuple[Basic, ...]: ... @property - def leading_term(self) -> Basic: - ... - + def leading_term(self) -> Basic: ... @property - def trailing_term(self) -> Basic: - ... - + def trailing_term(self) -> Basic: ... @property - def is_successor_ordinal(self) -> Literal[False]: - ... - + def is_successor_ordinal(self) -> Literal[False]: ... @property - def is_limit_ordinal(self) -> bool: - ... - + def is_limit_ordinal(self) -> bool: ... @property - def degree(self): - ... - + def degree(self): ... @classmethod - def convert(cls, integer_value) -> OrdinalZero | Ordinal: - ... - - def __eq__(self, other) -> bool: - ... - - def __hash__(self) -> int: - ... - - def __lt__(self, other) -> bool: - ... - - def __le__(self, other) -> bool: - ... - - def __gt__(self, other) -> bool: - ... - - def __ge__(self, other) -> bool: - ... - - def __str__(self) -> str: - ... - - __repr__ = ... - def __add__(self, other) -> NotImplementedType | Self | Ordinal: - ... - - def __radd__(self, other) -> NotImplementedType | OrdinalZero | Ordinal: - ... - - def __mul__(self, other) -> NotImplementedType | OrdinalZero | Ordinal: - ... - - def __rmul__(self, other) -> NotImplementedType | OrdinalZero | Ordinal: - ... - - def __pow__(self, other) -> NotImplementedType | Ordinal: - ... - - + def convert(cls, integer_value) -> OrdinalZero | Ordinal: ... + def __eq__(self, other) -> bool: ... + def __hash__(self) -> int: ... + def __lt__(self, other) -> bool: ... + def __le__(self, other) -> bool: ... + def __gt__(self, other) -> bool: ... + def __ge__(self, other) -> bool: ... + def __str__(self) -> str: ... -class OrdinalZero(Ordinal): - ... + __repr__ = ... + def __add__(self, other) -> NotImplementedType | Self | Ordinal: ... + def __radd__(self, other) -> NotImplementedType | OrdinalZero | Ordinal: ... + def __mul__(self, other) -> NotImplementedType | OrdinalZero | Ordinal: ... + def __rmul__(self, other) -> NotImplementedType | OrdinalZero | Ordinal: ... + def __pow__(self, other) -> NotImplementedType | Ordinal: ... +class OrdinalZero(Ordinal): ... class OrdinalOmega(Ordinal): - def __new__(cls) -> Self: - ... - + def __new__(cls) -> Self: ... @property - def terms(self) -> tuple[OmegaPower]: - ... - - + def terms(self) -> tuple[OmegaPower]: ... ord0 = ... omega = ... diff --git a/stubs/sympy-stubs/sets/powerset.pyi b/stubs/sympy-stubs/sets/powerset.pyi index 0c4566b7..33bb42d8 100644 --- a/stubs/sympy-stubs/sets/powerset.pyi +++ b/stubs/sympy-stubs/sets/powerset.pyi @@ -4,22 +4,10 @@ from sympy.core.basic import Basic from sympy.sets.sets import Set, SetKind class PowerSet(Set): - def __new__(cls, arg, evaluate=...) -> Self: - ... - + def __new__(cls, arg, evaluate=...) -> Self: ... @property - def arg(self) -> Basic: - ... - - def __len__(self) -> Any: - ... - - def __iter__(self) -> Generator[Any, Any, None]: - ... - + def arg(self) -> Basic: ... + def __len__(self) -> Any: ... + def __iter__(self) -> Generator[Any, Any, None]: ... @property - def kind(self) -> SetKind: - ... - - - + def kind(self) -> SetKind: ... diff --git a/stubs/sympy-stubs/sets/setexpr.pyi b/stubs/sympy-stubs/sets/setexpr.pyi index fff060b6..282cfac0 100644 --- a/stubs/sympy-stubs/sets/setexpr.pyi +++ b/stubs/sympy-stubs/sets/setexpr.pyi @@ -5,59 +5,36 @@ from sympy.core.decorators import _sympifyit, call_highest_priority class SetExpr(Expr): _op_priority = ... - def __new__(cls, setarg) -> Self: - ... - - set = ... - @_sympifyit('other', NotImplemented) - @call_highest_priority('__radd__') - def __add__(self, other) -> SetExpr: - ... - - @_sympifyit('other', NotImplemented) - @call_highest_priority('__add__') - def __radd__(self, other) -> SetExpr: - ... - - @_sympifyit('other', NotImplemented) - @call_highest_priority('__rmul__') - def __mul__(self, other) -> SetExpr: - ... - - @_sympifyit('other', NotImplemented) - @call_highest_priority('__mul__') - def __rmul__(self, other) -> SetExpr: - ... - - @_sympifyit('other', NotImplemented) - @call_highest_priority('__rsub__') - def __sub__(self, other) -> SetExpr: - ... - - @_sympifyit('other', NotImplemented) - @call_highest_priority('__sub__') - def __rsub__(self, other) -> SetExpr: - ... - - @_sympifyit('other', NotImplemented) - @call_highest_priority('__rpow__') - def __pow__(self, other) -> SetExpr: - ... - - @_sympifyit('other', NotImplemented) - @call_highest_priority('__pow__') - def __rpow__(self, other) -> SetExpr: - ... - - @_sympifyit('other', NotImplemented) - @call_highest_priority('__rtruediv__') - def __truediv__(self, other) -> SetExpr: - ... - - @_sympifyit('other', NotImplemented) - @call_highest_priority('__truediv__') - def __rtruediv__(self, other) -> SetExpr: - ... - - + def __new__(cls, setarg) -> Self: ... + set = ... + @_sympifyit("other", NotImplemented) + @call_highest_priority("__radd__") + def __add__(self, other) -> SetExpr: ... + @_sympifyit("other", NotImplemented) + @call_highest_priority("__add__") + def __radd__(self, other) -> SetExpr: ... + @_sympifyit("other", NotImplemented) + @call_highest_priority("__rmul__") + def __mul__(self, other) -> SetExpr: ... + @_sympifyit("other", NotImplemented) + @call_highest_priority("__mul__") + def __rmul__(self, other) -> SetExpr: ... + @_sympifyit("other", NotImplemented) + @call_highest_priority("__rsub__") + def __sub__(self, other) -> SetExpr: ... + @_sympifyit("other", NotImplemented) + @call_highest_priority("__sub__") + def __rsub__(self, other) -> SetExpr: ... + @_sympifyit("other", NotImplemented) + @call_highest_priority("__rpow__") + def __pow__(self, other) -> SetExpr: ... + @_sympifyit("other", NotImplemented) + @call_highest_priority("__pow__") + def __rpow__(self, other) -> SetExpr: ... + @_sympifyit("other", NotImplemented) + @call_highest_priority("__rtruediv__") + def __truediv__(self, other) -> SetExpr: ... + @_sympifyit("other", NotImplemented) + @call_highest_priority("__truediv__") + def __rtruediv__(self, other) -> SetExpr: ... diff --git a/stubs/sympy-stubs/sets/sets.pyi b/stubs/sympy-stubs/sets/sets.pyi index bf4ff978..f0b9ce62 100644 --- a/stubs/sympy-stubs/sets/sets.pyi +++ b/stubs/sympy-stubs/sets/sets.pyi @@ -16,6 +16,7 @@ from sympy.sets.powerset import PowerSet from sympy.utilities.decorator import deprecated tfn = ... + @sympify_method_args class Set(Basic, EvalfMixin): __slots__ = ... @@ -33,479 +34,222 @@ class Set(Basic, EvalfMixin): is_empty: FuzzyBool = ... is_finite_set: FuzzyBool = ... @property - def is_EmptySet(self) -> None: - ... - - def union(self, other) -> FiniteSet | Union: - ... - - def intersect(self, other) -> FiniteSet | Intersection | Union | Complement: - ... - - def intersection(self, other) -> FiniteSet | Intersection | Union | Complement: - ... - - def is_disjoint(self, other): - ... - - def isdisjoint(self, other): - ... - - def complement(self, universe) -> Intersection | Complement: - ... - - def symmetric_difference(self, other) -> SymmetricDifference: - ... - - @property - def inf(self): - ... - - @property - def sup(self): - ... - - def contains(self, other) -> Contains: - ... - - def is_subset(self, other) -> bool | None: - ... - - def issubset(self, other) -> bool | None: - ... - - def is_proper_subset(self, other) -> bool | None: - ... - - def is_superset(self, other) -> bool | None: - ... - - def issuperset(self, other) -> bool | None: - ... - - def is_proper_superset(self, other) -> bool | None: - ... - - def powerset(self) -> PowerSet: - ... - - @property - def measure(self): - ... - - @property - def kind(self) -> SetKind: - ... - - @property - def boundary(self): - ... - - @property - def is_open(self) -> FuzzyBool: - ... - - @property - def is_closed(self): - ... - - @property - def closure(self): - ... - - @property - def interior(self): - ... - - @sympify_return([('other', 'Set')], NotImplemented) - def __add__(self, other) -> FiniteSet | Union: - ... - - @sympify_return([('other', 'Set')], NotImplemented) - def __or__(self, other) -> FiniteSet | Union: - ... - - @sympify_return([('other', 'Set')], NotImplemented) - def __and__(self, other) -> FiniteSet | Intersection | Union | Complement: - ... - - @sympify_return([('other', 'Set')], NotImplemented) - def __mul__(self, other) -> FiniteSet | ProductSet: - ... - - @sympify_return([('other', 'Set')], NotImplemented) - def __xor__(self, other) -> SymmetricDifference: - ... - - @sympify_return([('exp', Expr)], NotImplemented) - def __pow__(self, exp) -> FiniteSet | ProductSet: - ... - - @sympify_return([('other', 'Set')], NotImplemented) - def __sub__(self, other) -> Intersection | Complement: - ... - - def __contains__(self, other): - ... - - + def is_EmptySet(self) -> None: ... + def union(self, other) -> FiniteSet | Union: ... + def intersect(self, other) -> FiniteSet | Intersection | Union | Complement: ... + def intersection(self, other) -> FiniteSet | Intersection | Union | Complement: ... + def is_disjoint(self, other): ... + def isdisjoint(self, other): ... + def complement(self, universe) -> Intersection | Complement: ... + def symmetric_difference(self, other) -> SymmetricDifference: ... + @property + def inf(self): ... + @property + def sup(self): ... + def contains(self, other) -> Contains: ... + def is_subset(self, other) -> bool | None: ... + def issubset(self, other) -> bool | None: ... + def is_proper_subset(self, other) -> bool | None: ... + def is_superset(self, other) -> bool | None: ... + def issuperset(self, other) -> bool | None: ... + def is_proper_superset(self, other) -> bool | None: ... + def powerset(self) -> PowerSet: ... + @property + def measure(self): ... + @property + def kind(self) -> SetKind: ... + @property + def boundary(self): ... + @property + def is_open(self) -> FuzzyBool: ... + @property + def is_closed(self): ... + @property + def closure(self): ... + @property + def interior(self): ... + @sympify_return([("other", "Set")], NotImplemented) + def __add__(self, other) -> FiniteSet | Union: ... + @sympify_return([("other", "Set")], NotImplemented) + def __or__(self, other) -> FiniteSet | Union: ... + @sympify_return([("other", "Set")], NotImplemented) + def __and__(self, other) -> FiniteSet | Intersection | Union | Complement: ... + @sympify_return([("other", "Set")], NotImplemented) + def __mul__(self, other) -> FiniteSet | ProductSet: ... + @sympify_return([("other", "Set")], NotImplemented) + def __xor__(self, other) -> SymmetricDifference: ... + @sympify_return([("exp", Expr)], NotImplemented) + def __pow__(self, exp) -> FiniteSet | ProductSet: ... + @sympify_return([("other", "Set")], NotImplemented) + def __sub__(self, other) -> Intersection | Complement: ... + def __contains__(self, other): ... class ProductSet(Set): is_ProductSet = ... - def __new__(cls, *sets, **assumptions) -> FiniteSet | Self: - ... - - @property - def sets(self) -> tuple[Basic, ...]: - ... - - def flatten(self) -> FiniteSet | ProductSet: - ... - - def as_relational(self, *symbols) -> And: - ... - - @property - def is_iterable(self) -> bool: - ... - - def __iter__(self) -> Generator[tuple[()] | tuple[Any] | tuple[Any, Any] | Any, Any, None]: - ... - - @property - def is_empty(self) -> bool | None: - ... - - @property - def is_finite_set(self) -> bool | None: - ... - - def __len__(self) -> int: - ... - - def __bool__(self) -> bool: - ... - - + def __new__(cls, *sets, **assumptions) -> FiniteSet | Self: ... + @property + def sets(self) -> tuple[Basic, ...]: ... + def flatten(self) -> FiniteSet | ProductSet: ... + def as_relational(self, *symbols) -> And: ... + @property + def is_iterable(self) -> bool: ... + def __iter__(self) -> Generator[tuple[()] | tuple[Any] | tuple[Any, Any] | Any, Any, None]: ... + @property + def is_empty(self) -> bool | None: ... + @property + def is_finite_set(self) -> bool | None: ... + def __len__(self) -> int: ... + def __bool__(self) -> bool: ... class Interval(Set): is_Interval = ... - def __new__(cls, start, end, left_open=..., right_open=...) -> FiniteSet | Self: - ... - + def __new__(cls, start, end, left_open=..., right_open=...) -> FiniteSet | Self: ... @property - def start(self) -> Basic: - ... - + def start(self) -> Basic: ... @property - def end(self) -> Basic: - ... - + def end(self) -> Basic: ... @property - def left_open(self) -> Basic: - ... - + def left_open(self) -> Basic: ... @property - def right_open(self) -> Basic: - ... - + def right_open(self) -> Basic: ... @classmethod - def open(cls, a, b) -> Self: - ... - + def open(cls, a, b) -> Self: ... @classmethod - def Lopen(cls, a, b) -> Self: - ... - + def Lopen(cls, a, b) -> Self: ... @classmethod - def Ropen(cls, a, b) -> Self: - ... - - @property - def left(self) -> Basic: - ... - - @property - def right(self) -> Basic: - ... - - @property - def is_empty(self) -> bool | None: - ... - - @property - def is_finite_set(self): - ... - - def as_relational(self, x) -> And: - ... - - def to_mpi(self, prec=...) -> Any: - ... - - @property - def is_left_unbounded(self) -> NotImplementedType | bool: - ... - - @property - def is_right_unbounded(self) -> NotImplementedType | bool: - ... - - + def Ropen(cls, a, b) -> Self: ... + @property + def left(self) -> Basic: ... + @property + def right(self) -> Basic: ... + @property + def is_empty(self) -> bool | None: ... + @property + def is_finite_set(self): ... + def as_relational(self, x) -> And: ... + def to_mpi(self, prec=...) -> Any: ... + @property + def is_left_unbounded(self) -> NotImplementedType | bool: ... + @property + def is_right_unbounded(self) -> NotImplementedType | bool: ... class Union(Set, LatticeOp): is_Union = ... @property - def identity(self): - ... - - @property - def zero(self): - ... - - def __new__(cls, *args, **kwargs) -> FiniteSet | Union | Self: - ... - - @property - def args(self) -> tuple[Basic, ...]: - ... - - @property - def is_empty(self) -> bool | None: - ... - - @property - def is_finite_set(self) -> bool | None: - ... - - def is_subset(self, other) -> bool | None: - ... - - def as_relational(self, symbol) -> And | Or: - ... - - @property - def is_iterable(self) -> bool: - ... - - def __iter__(self) -> Generator[Any, Any, None]: - ... - - + def identity(self): ... + @property + def zero(self): ... + def __new__(cls, *args, **kwargs) -> FiniteSet | Union | Self: ... + @property + def args(self) -> tuple[Basic, ...]: ... + @property + def is_empty(self) -> bool | None: ... + @property + def is_finite_set(self) -> bool | None: ... + def is_subset(self, other) -> bool | None: ... + def as_relational(self, symbol) -> And | Or: ... + @property + def is_iterable(self) -> bool: ... + def __iter__(self) -> Generator[Any, Any, None]: ... class Intersection(Set, LatticeOp): is_Intersection = ... @property - def identity(self): - ... - - @property - def zero(self): - ... - - def __new__(cls, *args, **kwargs) -> FiniteSet | Intersection | Union | Complement | Self: - ... - - @property - def args(self) -> tuple[Basic, ...]: - ... - - @property - def is_iterable(self) -> bool: - ... - - @property - def is_finite_set(self) -> Literal[True] | None: - ... - - def __iter__(self) -> Generator[Any, Any, None]: - ... - - def as_relational(self, symbol) -> And: - ... - - + def identity(self): ... + @property + def zero(self): ... + def __new__(cls, *args, **kwargs) -> FiniteSet | Intersection | Union | Complement | Self: ... + @property + def args(self) -> tuple[Basic, ...]: ... + @property + def is_iterable(self) -> bool: ... + @property + def is_finite_set(self) -> Literal[True] | None: ... + def __iter__(self) -> Generator[Any, Any, None]: ... + def as_relational(self, symbol) -> And: ... class Complement(Set): is_Complement = ... - def __new__(cls, a, b, evaluate=...) -> Intersection | Complement | Self: - ... - + def __new__(cls, a, b, evaluate=...) -> Intersection | Complement | Self: ... @staticmethod - def reduce(A, B) -> Intersection | Complement: - ... - - def as_relational(self, symbol) -> And: - ... - - @property - def is_iterable(self) -> Literal[True] | None: - ... - - @property - def is_finite_set(self) -> bool | None: - ... - - def __iter__(self) -> Generator[Any, Any, None]: - ... - - + def reduce(A, B) -> Intersection | Complement: ... + def as_relational(self, symbol) -> And: ... + @property + def is_iterable(self) -> Literal[True] | None: ... + @property + def is_finite_set(self) -> bool | None: ... + def __iter__(self) -> Generator[Any, Any, None]: ... class EmptySet(Set, metaclass=Singleton): is_empty = ... is_finite_set = ... is_FiniteSet = ... @property - def is_EmptySet(self) -> Literal[True]: - ... - - def as_relational(self, symbol) -> BooleanFalse: - ... - - def __len__(self) -> Literal[0]: - ... - - def __iter__(self) -> Iterator[Any]: - ... - - + def is_EmptySet(self) -> Literal[True]: ... + def as_relational(self, symbol) -> BooleanFalse: ... + def __len__(self) -> Literal[0]: ... + def __iter__(self) -> Iterator[Any]: ... class UniversalSet(Set, metaclass=Singleton): is_UniversalSet = ... is_empty = ... is_finite_set = ... - def as_relational(self, symbol) -> BooleanTrue: - ... - - + def as_relational(self, symbol) -> BooleanTrue: ... class FiniteSet(Set): is_FiniteSet = ... is_iterable = ... is_empty = ... is_finite_set = ... - def __new__(cls, *args, **kwargs) -> Self: - ... - - def __iter__(self) -> Iterator[Basic]: - ... - - @property - def measure(self) -> Literal[0]: - ... - - def __len__(self) -> int: - ... - - def as_relational(self, symbol) -> Or: - ... - - def compare(self, other) -> int: - ... - - def __ge__(self, other) -> bool: - ... - - def __gt__(self, other) -> bool: - ... - - def __le__(self, other) -> bool: - ... - - def __lt__(self, other) -> bool: - ... - - def __eq__(self, other) -> bool: - ... - - __hash__: Callable[[Basic], Any] = ... + def __new__(cls, *args, **kwargs) -> Self: ... + def __iter__(self) -> Iterator[Basic]: ... + @property + def measure(self) -> Literal[0]: ... + def __len__(self) -> int: ... + def as_relational(self, symbol) -> Or: ... + def compare(self, other) -> int: ... + def __ge__(self, other) -> bool: ... + def __gt__(self, other) -> bool: ... + def __le__(self, other) -> bool: ... + def __lt__(self, other) -> bool: ... + def __eq__(self, other) -> bool: ... + __hash__: Callable[[Basic], Any] = ... class SymmetricDifference(Set): is_SymmetricDifference = ... - def __new__(cls, a, b, evaluate=...) -> SymmetricDifference | Self: - ... - + def __new__(cls, a, b, evaluate=...) -> SymmetricDifference | Self: ... @staticmethod - def reduce(A, B) -> SymmetricDifference: - ... - - def as_relational(self, symbol) -> BooleanFalse | Not | Xor: - ... - - @property - def is_iterable(self) -> Literal[True] | None: - ... - - def __iter__(self) -> Generator[Any, Any, None]: - ... - - + def reduce(A, B) -> SymmetricDifference: ... + def as_relational(self, symbol) -> BooleanFalse | Not | Xor: ... + @property + def is_iterable(self) -> Literal[True] | None: ... + def __iter__(self) -> Generator[Any, Any, None]: ... class DisjointUnion(Set): - def __new__(cls, *sets) -> Self: - ... - - @property - def sets(self) -> tuple[Basic, ...]: - ... - - @property - def is_empty(self) -> bool | None: - ... - - @property - def is_finite_set(self) -> bool | None: - ... - - @property - def is_iterable(self) -> bool: - ... - - def __iter__(self) -> Generator[Any, Any, None]: - ... - - def __len__(self) -> int: - ... - - - -def imageset(*args) -> Basic | ImageSet | FiniteSet: - ... - -def is_function_invertible_in_set(func, setv) -> Literal[True] | None: - ... - -def simplify_union(args) -> FiniteSet | Union: - ... - -def simplify_intersection(args) -> FiniteSet | Intersection | Union | Complement: - ... - -def set_add(x, y) -> Any | FiniteSet | ImageSet | Union: - ... - -def set_sub(x, y) -> Any | FiniteSet | ImageSet | Union: - ... - -def set_mul(x, y) -> Any | FiniteSet | ImageSet | Union: - ... - -def set_div(x, y) -> Any | FiniteSet | ImageSet | Union: - ... - -def set_pow(x, y) -> Any | FiniteSet | ImageSet | Union: - ... + def __new__(cls, *sets) -> Self: ... + @property + def sets(self) -> tuple[Basic, ...]: ... + @property + def is_empty(self) -> bool | None: ... + @property + def is_finite_set(self) -> bool | None: ... + @property + def is_iterable(self) -> bool: ... + def __iter__(self) -> Generator[Any, Any, None]: ... + def __len__(self) -> int: ... -def set_function(f, x): - ... +def imageset(*args) -> Basic | ImageSet | FiniteSet: ... +def is_function_invertible_in_set(func, setv) -> Literal[True] | None: ... +def simplify_union(args) -> FiniteSet | Union: ... +def simplify_intersection(args) -> FiniteSet | Intersection | Union | Complement: ... +def set_add(x, y) -> Any | FiniteSet | ImageSet | Union: ... +def set_sub(x, y) -> Any | FiniteSet | ImageSet | Union: ... +def set_mul(x, y) -> Any | FiniteSet | ImageSet | Union: ... +def set_div(x, y) -> Any | FiniteSet | ImageSet | Union: ... +def set_pow(x, y) -> Any | FiniteSet | ImageSet | Union: ... +def set_function(f, x): ... class SetKind(Kind): - def __new__(cls, element_kind=...) -> Self: - ... - - def __repr__(self) -> Literal['SetKind()']: - ... - - - + def __new__(cls, element_kind=...) -> Self: ... + def __repr__(self) -> Literal["SetKind()"]: ... diff --git a/stubs/sympy-stubs/simplify/__init__.pyi b/stubs/sympy-stubs/simplify/__init__.pyi index 916362cf..a0925662 100644 --- a/stubs/sympy-stubs/simplify/__init__.pyi +++ b/stubs/sympy-stubs/simplify/__init__.pyi @@ -22,4 +22,37 @@ from sympy.simplify.simplify import ( from sympy.simplify.sqrtdenest import sqrtdenest from sympy.simplify.trigsimp import exptrigsimp, trigsimp -__all__ = ['simplify', 'hypersimp', 'hypersimilar', 'logcombine', 'separatevars', 'posify', 'besselsimp', 'kroneckersimp', 'signsimp', 'nsimplify', 'FU', 'fu', 'sqrtdenest', 'cse', 'epath', 'EPath', 'hyperexpand', 'collect', 'rcollect', 'radsimp', 'collect_const', 'fraction', 'numer', 'denom', 'trigsimp', 'exptrigsimp', 'powsimp', 'powdenest', 'combsimp', 'gammasimp', 'ratsimp', 'ratsimpmodprime'] +__all__ = [ + "simplify", + "hypersimp", + "hypersimilar", + "logcombine", + "separatevars", + "posify", + "besselsimp", + "kroneckersimp", + "signsimp", + "nsimplify", + "FU", + "fu", + "sqrtdenest", + "cse", + "epath", + "EPath", + "hyperexpand", + "collect", + "rcollect", + "radsimp", + "collect_const", + "fraction", + "numer", + "denom", + "trigsimp", + "exptrigsimp", + "powsimp", + "powdenest", + "combsimp", + "gammasimp", + "ratsimp", + "ratsimpmodprime", +] diff --git a/stubs/sympy-stubs/simplify/combsimp.pyi b/stubs/sympy-stubs/simplify/combsimp.pyi index c23a3586..d2855a8c 100644 --- a/stubs/sympy-stubs/simplify/combsimp.pyi +++ b/stubs/sympy-stubs/simplify/combsimp.pyi @@ -2,7 +2,5 @@ from typing import Any from sympy.utilities.timeutils import timethis -@timethis('combsimp') -def combsimp(expr) -> Any: - ... - +@timethis("combsimp") +def combsimp(expr) -> Any: ... diff --git a/stubs/sympy-stubs/simplify/cse_main.pyi b/stubs/sympy-stubs/simplify/cse_main.pyi index ba3cfa86..f2586e70 100644 --- a/stubs/sympy-stubs/simplify/cse_main.pyi +++ b/stubs/sympy-stubs/simplify/cse_main.pyi @@ -4,71 +4,41 @@ from typing import Any from sympy.core.containers import OrderedSet basic_optimizations = ... -def reps_toposort(r) -> list[Any]: - ... -def cse_separate(r, e) -> list[list[Any]]: - ... - -def cse_release_variables(r, e) -> tuple[Any, Any] | tuple[list[Any], Any]: - ... - -def preprocess_for_cse(expr, optimizations): - ... - -def postprocess_for_cse(expr, optimizations): - ... +def reps_toposort(r) -> list[Any]: ... +def cse_separate(r, e) -> list[list[Any]]: ... +def cse_release_variables(r, e) -> tuple[Any, Any] | tuple[list[Any], Any]: ... +def preprocess_for_cse(expr, optimizations): ... +def postprocess_for_cse(expr, optimizations): ... class FuncArgTracker: - def __init__(self, funcs) -> None: - ... - - def get_args_in_value_order(self, argset) -> list[Any]: - ... - - def get_or_add_value_number(self, value): - ... - - def stop_arg_tracking(self, func_i) -> None: - ... - - def get_common_arg_candidates(self, argset, min_func_i=...) -> defaultdict[Any, int] | dict[Any, int]: - ... - - def get_subset_candidates(self, argset, restrict_to_funcset=...) -> OrderedSet: - ... - - def update_func_argset(self, func_i, new_argset) -> None: - ... - - + def __init__(self, funcs) -> None: ... + def get_args_in_value_order(self, argset) -> list[Any]: ... + def get_or_add_value_number(self, value): ... + def stop_arg_tracking(self, func_i) -> None: ... + def get_common_arg_candidates(self, argset, min_func_i=...) -> defaultdict[Any, int] | dict[Any, int]: ... + def get_subset_candidates(self, argset, restrict_to_funcset=...) -> OrderedSet: ... + def update_func_argset(self, func_i, new_argset) -> None: ... class Unevaluated: - def __init__(self, func, args) -> None: - ... - - def __str__(self) -> str: - ... - - def as_unevaluated_basic(self): - ... - + def __init__(self, func, args) -> None: ... + def __str__(self) -> str: ... + def as_unevaluated_basic(self): ... @property - def free_symbols(self) -> set[Any]: - ... - - __repr__ = ... + def free_symbols(self) -> set[Any]: ... + __repr__ = ... -def match_common_args(func_class, funcs, opt_subs) -> None: - ... - -def opt_cse(exprs, order=...) -> dict[Any, Any]: - ... - -def tree_cse(exprs, symbols, opt_subs=..., order=..., ignore=...) -> tuple[list[Any], list[Any]]: - ... - -def cse(exprs, symbols=..., optimizations=..., postprocess=..., order=..., ignore=..., list=...) -> tuple[Any, str] | tuple[Any, list[Any] | set[Any] | tuple[Any, ...]] | tuple[Any, dict[Any, Any]] | tuple[Any, Any] | tuple[list[Any], Any] | tuple[list[Any], list[Any]]: - ... - +def match_common_args(func_class, funcs, opt_subs) -> None: ... +def opt_cse(exprs, order=...) -> dict[Any, Any]: ... +def tree_cse(exprs, symbols, opt_subs=..., order=..., ignore=...) -> tuple[list[Any], list[Any]]: ... +def cse( + exprs, symbols=..., optimizations=..., postprocess=..., order=..., ignore=..., list=... +) -> ( + tuple[Any, str] + | tuple[Any, list[Any] | set[Any] | tuple[Any, ...]] + | tuple[Any, dict[Any, Any]] + | tuple[Any, Any] + | tuple[list[Any], Any] + | tuple[list[Any], list[Any]] +): ... diff --git a/stubs/sympy-stubs/simplify/cse_opts.pyi b/stubs/sympy-stubs/simplify/cse_opts.pyi index e7706984..4be25fbd 100644 --- a/stubs/sympy-stubs/simplify/cse_opts.pyi +++ b/stubs/sympy-stubs/simplify/cse_opts.pyi @@ -1,8 +1,4 @@ from sympy.core.basic import Basic -def sub_pre(e) -> Basic: - ... - -def sub_post(e): - ... - +def sub_pre(e) -> Basic: ... +def sub_post(e): ... diff --git a/stubs/sympy-stubs/simplify/epathtools.pyi b/stubs/sympy-stubs/simplify/epathtools.pyi index 5570070e..551b4ddd 100644 --- a/stubs/sympy-stubs/simplify/epathtools.pyi +++ b/stubs/sympy-stubs/simplify/epathtools.pyi @@ -4,20 +4,9 @@ from sympy.core.basic import Basic class EPath: __slots__ = ... - def __new__(cls, path) -> EPath | Self: - ... - - def __repr__(self) -> str: - ... - - def apply(self, expr, func, args=..., kwargs=...) -> Basic: - ... - - def select(self, expr) -> list[Any]: - ... - - - -def epath(path, expr=..., func=..., args=..., kwargs=...) -> EPath | list[Any] | Basic: - ... + def __new__(cls, path) -> EPath | Self: ... + def __repr__(self) -> str: ... + def apply(self, expr, func, args=..., kwargs=...) -> Basic: ... + def select(self, expr) -> list[Any]: ... +def epath(path, expr=..., func=..., args=..., kwargs=...) -> EPath | list[Any] | Basic: ... diff --git a/stubs/sympy-stubs/simplify/fu.pyi b/stubs/sympy-stubs/simplify/fu.pyi index 0e9c6e0b..dd24b317 100644 --- a/stubs/sympy-stubs/simplify/fu.pyi +++ b/stubs/sympy-stubs/simplify/fu.pyi @@ -3,80 +3,31 @@ from typing import Any, Callable, Literal from sympy import SYMPY_DEBUG from sympy.series.order import Order -def TR0(rv): - ... - -def TR1(rv): - ... - -def TR2(rv): - ... - -def TR2i(rv, half=...): - ... - -def TR3(rv): - ... - -def TR4(rv): - ... - -def TR5(rv, max=..., pow=...): - ... - -def TR6(rv, max=..., pow=...): - ... - -def TR7(rv): - ... - -def TR8(rv, first=...): - ... - -def TR9(rv): - ... - -def TR10(rv, first=...): - ... - -def TR10i(rv): - ... - -def TR11(rv, base=...): - ... - -def TR12(rv, first=...): - ... - -def TR12i(rv): - ... - -def TR13(rv): - ... - -def TRmorrie(rv): - ... - -def TR14(rv, first=...): - ... - -def TR15(rv, max=..., pow=...): - ... - -def TR16(rv, max=..., pow=...): - ... - -def TR111(rv): - ... - -def TR22(rv, max=..., pow=...): - ... - -def TRpower(rv): - ... - -def L(rv): - ... +def TR0(rv): ... +def TR1(rv): ... +def TR2(rv): ... +def TR2i(rv, half=...): ... +def TR3(rv): ... +def TR4(rv): ... +def TR5(rv, max=..., pow=...): ... +def TR6(rv, max=..., pow=...): ... +def TR7(rv): ... +def TR8(rv, first=...): ... +def TR9(rv): ... +def TR10(rv, first=...): ... +def TR10i(rv): ... +def TR11(rv, base=...): ... +def TR12(rv, first=...): ... +def TR12i(rv): ... +def TR13(rv): ... +def TRmorrie(rv): ... +def TR14(rv, first=...): ... +def TR15(rv, max=..., pow=...): ... +def TR16(rv, max=..., pow=...): ... +def TR111(rv): ... +def TR22(rv, max=..., pow=...): ... +def TRpower(rv): ... +def L(rv): ... if SYMPY_DEBUG: ... @@ -86,24 +37,15 @@ CTR3 = ... CTR4 = ... RL1 = ... RL2 = ... -def fu(rv, measure=...): - ... -def process_common_addends(rv, do, key2=..., key1=...) -> Order: - ... +def fu(rv, measure=...): ... +def process_common_addends(rv, do, key2=..., key1=...) -> Order: ... fufuncs = ... FU = ... _ROOT2 = ... -def trig_split(a, b, two=...): - ... - -def as_f_sign_1(e) -> tuple[Any, Any, Any] | tuple[Any | Order, Any | Order, Literal[1, -1]] | None: - ... - -def hyper_as_trig(rv) -> tuple[Any, Callable[..., Any]]: - ... - -def sincos_to_sum(expr): - ... +def trig_split(a, b, two=...): ... +def as_f_sign_1(e) -> tuple[Any, Any, Any] | tuple[Any | Order, Any | Order, Literal[1, -1]] | None: ... +def hyper_as_trig(rv) -> tuple[Any, Callable[..., Any]]: ... +def sincos_to_sum(expr): ... diff --git a/stubs/sympy-stubs/simplify/gammasimp.pyi b/stubs/sympy-stubs/simplify/gammasimp.pyi index dcb35693..a2134a71 100644 --- a/stubs/sympy-stubs/simplify/gammasimp.pyi +++ b/stubs/sympy-stubs/simplify/gammasimp.pyi @@ -3,13 +3,8 @@ from typing import Any from sympy.core import Function from sympy.series.order import Order -def gammasimp(expr) -> Any: - ... +def gammasimp(expr) -> Any: ... class _rf(Function): @classmethod - def eval(cls, a, b) -> Order | None: - ... - - - + def eval(cls, a, b) -> Order | None: ... diff --git a/stubs/sympy-stubs/simplify/hyperexpand.pyi b/stubs/sympy-stubs/simplify/hyperexpand.pyi index 6b4b0899..178c60f2 100644 --- a/stubs/sympy-stubs/simplify/hyperexpand.pyi +++ b/stubs/sympy-stubs/simplify/hyperexpand.pyi @@ -3,282 +3,131 @@ from typing import Any, Callable, Literal, Self from sympy.core import Expr from sympy.core.function import UndefinedFunction -def add_formulae(formulae) -> None: - ... - -def add_meijerg_formulae(formulae) -> None: - ... - -def make_simp(z) -> Callable[..., Any]: - ... - -def debug(*args) -> None: - ... +def add_formulae(formulae) -> None: ... +def add_meijerg_formulae(formulae) -> None: ... +def make_simp(z) -> Callable[..., Any]: ... +def debug(*args) -> None: ... class Hyper_Function(Expr): - def __new__(cls, ap, bq) -> Self: - ... - + def __new__(cls, ap, bq) -> Self: ... @property - def args(self) -> tuple[Any, Any]: - ... - + def args(self) -> tuple[Any, Any]: ... @property - def sizes(self) -> tuple[int, int]: - ... - + def sizes(self) -> tuple[int, int]: ... @property - def gamma(self) -> int: - ... - - def __call__(self, arg) -> type[UndefinedFunction]: - ... - - def build_invariants(self) -> tuple[int, tuple[tuple[Any, int], ...], tuple[tuple[Any, int], ...]]: - ... - - def difficulty(self, func) -> Literal[-1, 0]: - ... - - + def gamma(self) -> int: ... + def __call__(self, arg) -> type[UndefinedFunction]: ... + def build_invariants(self) -> tuple[int, tuple[tuple[Any, int], ...], tuple[tuple[Any, int], ...]]: ... + def difficulty(self, func) -> Literal[-1, 0]: ... class G_Function(Expr): - def __new__(cls, an, ap, bm, bq) -> Self: - ... - + def __new__(cls, an, ap, bm, bq) -> Self: ... @property - def args(self) -> tuple[Any, Any, Any, Any]: - ... - - def __call__(self, z) -> type[UndefinedFunction]: - ... - - def compute_buckets(self) -> tuple[dict[Any, list[Any]], ...]: - ... - + def args(self) -> tuple[Any, Any, Any, Any]: ... + def __call__(self, z) -> type[UndefinedFunction]: ... + def compute_buckets(self) -> tuple[dict[Any, list[Any]], ...]: ... @property - def signature(self) -> tuple[int, int, int, int]: - ... - - + def signature(self) -> tuple[int, int, int, int]: ... _x = ... + class Formula: - def __init__(self, func, z, res, symbols, B=..., C=..., M=...) -> None: - ... - + def __init__(self, func, z, res, symbols, B=..., C=..., M=...) -> None: ... @property - def closed_form(self): - ... - - def find_instantiations(self, func) -> list[Any]: - ... - - + def closed_form(self): ... + def find_instantiations(self, func) -> list[Any]: ... class FormulaCollection: - def __init__(self) -> None: - ... - - def lookup_origin(self, func) -> Formula | None: - ... - - + def __init__(self) -> None: ... + def lookup_origin(self, func) -> Formula | None: ... class MeijerFormula: - def __init__(self, an, ap, bm, bq, z, symbols, B, C, M, matcher) -> None: - ... - + def __init__(self, an, ap, bm, bq, z, symbols, B, C, M, matcher) -> None: ... @property - def closed_form(self): - ... - - def try_instantiate(self, func) -> MeijerFormula | None: - ... - - + def closed_form(self): ... + def try_instantiate(self, func) -> MeijerFormula | None: ... class MeijerFormulaCollection: - def __init__(self) -> None: - ... - - def lookup_origin(self, func) -> None: - ... - - + def __init__(self) -> None: ... + def lookup_origin(self, func) -> None: ... class Operator: - def apply(self, obj, op): - ... - - + def apply(self, obj, op): ... class MultOperator(Operator): - def __init__(self, p) -> None: - ... - - + def __init__(self, p) -> None: ... class ShiftA(Operator): - def __init__(self, ai) -> None: - ... - - def __str__(self) -> str: - ... - - + def __init__(self, ai) -> None: ... + def __str__(self) -> str: ... class ShiftB(Operator): - def __init__(self, bi) -> None: - ... - - def __str__(self) -> str: - ... - - + def __init__(self, bi) -> None: ... + def __str__(self) -> str: ... class UnShiftA(Operator): - def __init__(self, ap, bq, i, z) -> None: - ... - - def __str__(self) -> str: - ... - - + def __init__(self, ap, bq, i, z) -> None: ... + def __str__(self) -> str: ... class UnShiftB(Operator): - def __init__(self, ap, bq, i, z) -> None: - ... - - def __str__(self) -> str: - ... - - + def __init__(self, ap, bq, i, z) -> None: ... + def __str__(self) -> str: ... class MeijerShiftA(Operator): - def __init__(self, bi) -> None: - ... - - def __str__(self) -> str: - ... - - + def __init__(self, bi) -> None: ... + def __str__(self) -> str: ... class MeijerShiftB(Operator): - def __init__(self, bi) -> None: - ... - - def __str__(self) -> str: - ... - - + def __init__(self, bi) -> None: ... + def __str__(self) -> str: ... class MeijerShiftC(Operator): - def __init__(self, bi) -> None: - ... - - def __str__(self) -> str: - ... - - + def __init__(self, bi) -> None: ... + def __str__(self) -> str: ... class MeijerShiftD(Operator): - def __init__(self, bi) -> None: - ... - - def __str__(self) -> str: - ... - - + def __init__(self, bi) -> None: ... + def __str__(self) -> str: ... class MeijerUnShiftA(Operator): - def __init__(self, an, ap, bm, bq, i, z) -> None: - ... - - def __str__(self) -> str: - ... - - + def __init__(self, an, ap, bm, bq, i, z) -> None: ... + def __str__(self) -> str: ... class MeijerUnShiftB(Operator): - def __init__(self, an, ap, bm, bq, i, z) -> None: - ... - - def __str__(self) -> str: - ... - - + def __init__(self, an, ap, bm, bq, i, z) -> None: ... + def __str__(self) -> str: ... class MeijerUnShiftC(Operator): - def __init__(self, an, ap, bm, bq, i, z) -> None: - ... - - def __str__(self) -> str: - ... - - + def __init__(self, an, ap, bm, bq, i, z) -> None: ... + def __str__(self) -> str: ... class MeijerUnShiftD(Operator): - def __init__(self, an, ap, bm, bq, i, z) -> None: - ... - - def __str__(self) -> str: - ... - - + def __init__(self, an, ap, bm, bq, i, z) -> None: ... + def __str__(self) -> str: ... class ReduceOrder(Operator): - def __new__(cls, ai, bj) -> Self | None: - ... - + def __new__(cls, ai, bj) -> Self | None: ... @classmethod - def meijer_minus(cls, b, a) -> Self | None: - ... - + def meijer_minus(cls, b, a) -> Self | None: ... @classmethod - def meijer_plus(cls, a, b) -> Self | None: - ... - - def __str__(self) -> str: - ... - - - -def reduce_order(func) -> tuple[Hyper_Function, list[Any]]: - ... - -def reduce_order_meijer(func) -> tuple[G_Function, list[Any]]: - ... - -def make_derivative_operator(M, z) -> Callable[..., Any]: - ... - -def apply_operators(obj, ops, op): - ... - -def devise_plan(target, origin, z) -> list[Any]: - ... - -def try_shifted_sum(func, z) -> tuple[Hyper_Function, list[Any], Any | int] | None: - ... - -def try_polynomial(func, z) -> None: - ... - -def try_lerchphi(func) -> Formula | None: - ... - -def build_hypergeometric_formula(func) -> Formula: - ... - -def hyperexpand_special(ap, bq, z) -> type[UndefinedFunction]: - ... + def meijer_plus(cls, a, b) -> Self | None: ... + def __str__(self) -> str: ... + +def reduce_order(func) -> tuple[Hyper_Function, list[Any]]: ... +def reduce_order_meijer(func) -> tuple[G_Function, list[Any]]: ... +def make_derivative_operator(M, z) -> Callable[..., Any]: ... +def apply_operators(obj, ops, op): ... +def devise_plan(target, origin, z) -> list[Any]: ... +def try_shifted_sum(func, z) -> tuple[Hyper_Function, list[Any], Any | int] | None: ... +def try_polynomial(func, z) -> None: ... +def try_lerchphi(func) -> Formula | None: ... +def build_hypergeometric_formula(func) -> Formula: ... +def hyperexpand_special(ap, bq, z) -> type[UndefinedFunction]: ... _collection = ... -def devise_plan_meijer(fro, to, z) -> list[Any]: - ... + +def devise_plan_meijer(fro, to, z) -> list[Any]: ... _meijercollection = ... -def hyperexpand(f, allow_hyper=..., rewrite=..., place=...): - ... +def hyperexpand(f, allow_hyper=..., rewrite=..., place=...): ... diff --git a/stubs/sympy-stubs/simplify/powsimp.pyi b/stubs/sympy-stubs/simplify/powsimp.pyi index 5042cdf5..ae4142c4 100644 --- a/stubs/sympy-stubs/simplify/powsimp.pyi +++ b/stubs/sympy-stubs/simplify/powsimp.pyi @@ -1,9 +1,6 @@ from sympy.core.basic import Basic -def powsimp(expr, deep=..., combine=..., force=..., measure=...): - ... - -def powdenest(eq, force=..., polar=...) -> bool | Basic: - ... +def powsimp(expr, deep=..., combine=..., force=..., measure=...): ... +def powdenest(eq, force=..., polar=...) -> bool | Basic: ... _y = ... diff --git a/stubs/sympy-stubs/simplify/radsimp.pyi b/stubs/sympy-stubs/simplify/radsimp.pyi index a8dbdfff..086620c8 100644 --- a/stubs/sympy-stubs/simplify/radsimp.pyi +++ b/stubs/sympy-stubs/simplify/radsimp.pyi @@ -3,48 +3,22 @@ from typing import Any from sympy.core.add import Add from sympy.series.order import Order -def collect(expr, syms, func=..., evaluate=..., exact=..., distribute_order_term=...): - ... - -def rcollect(expr, *vars): - ... - -def collect_sqrt(expr, evaluate=...) -> tuple[tuple[Any | Order, ...], int]: - ... - -def collect_abs(expr): - ... - -def collect_const(expr, *vars, Numbers=...) -> Add | Order: - ... - -def radsimp(expr, symbolic=..., max_terms=...): - ... - -def rad_rationalize(num, den) -> tuple[Any, Any]: - ... - -def fraction(expr, exact=...) -> tuple[Any | Order, Any | Order]: - ... - -def numer(expr) -> Order: - ... - -def denom(expr) -> Order: - ... - -def fraction_expand(expr, **hints): - ... - -def numer_expand(expr, **hints): - ... - -def denom_expand(expr, **hints): - ... +def collect(expr, syms, func=..., evaluate=..., exact=..., distribute_order_term=...): ... +def rcollect(expr, *vars): ... +def collect_sqrt(expr, evaluate=...) -> tuple[tuple[Any | Order, ...], int]: ... +def collect_abs(expr): ... +def collect_const(expr, *vars, Numbers=...) -> Add | Order: ... +def radsimp(expr, symbolic=..., max_terms=...): ... +def rad_rationalize(num, den) -> tuple[Any, Any]: ... +def fraction(expr, exact=...) -> tuple[Any | Order, Any | Order]: ... +def numer(expr) -> Order: ... +def denom(expr) -> Order: ... +def fraction_expand(expr, **hints): ... +def numer_expand(expr, **hints): ... +def denom_expand(expr, **hints): ... expand_numer = ... expand_denom = ... expand_fraction = ... -def split_surds(expr) -> tuple[Any, Any | Order, Any | Order]: - ... +def split_surds(expr) -> tuple[Any, Any | Order, Any | Order]: ... diff --git a/stubs/sympy-stubs/simplify/ratsimp.pyi b/stubs/sympy-stubs/simplify/ratsimp.pyi index 54cf9859..7c05561a 100644 --- a/stubs/sympy-stubs/simplify/ratsimp.pyi +++ b/stubs/sympy-stubs/simplify/ratsimp.pyi @@ -1,8 +1,4 @@ from typing import Any -def ratsimp(expr) -> Any: - ... - -def ratsimpmodprime(expr, G, *gens, quick=..., polynomial=..., **args) -> Any: - ... - +def ratsimp(expr) -> Any: ... +def ratsimpmodprime(expr, G, *gens, quick=..., polynomial=..., **args) -> Any: ... diff --git a/stubs/sympy-stubs/simplify/simplify.pyi b/stubs/sympy-stubs/simplify/simplify.pyi index 2b790380..c8570e3a 100644 --- a/stubs/sympy-stubs/simplify/simplify.pyi +++ b/stubs/sympy-stubs/simplify/simplify.pyi @@ -12,68 +12,31 @@ from sympy.core.symbol import Dummy from sympy.functions.elementary.complexes import Abs from sympy.series.order import Order -def separatevars(expr, symbols=..., dict=..., force=...) -> dict[str, Any] | dict[Any, list[Any]] | Order | Abs | type[UndefinedFunction] | Any | None: - ... - -def posify(eq) -> tuple[Any, dict[Any, Any]] | tuple[Any, dict[Dummy, Any]]: - ... - -def hypersimp(f, k) -> None: - ... - -def hypersimilar(f, g, k): - ... - -def signsimp(expr, evaluate=...) -> Expr | Relational | Order | Eq | Ne | Add | tuple[Any, dict[Any, Any]]: - ... - -def simplify(expr, ratio=..., measure=..., rational=..., inverse=..., doit=..., **kwargs): - ... - -def sum_simplify(s, **kwargs) -> Order: - ... - -def sum_combine(s_t) -> Order: - ... - -def factor_sum(self, limits=..., radical=..., clear=..., fraction=..., sign=...) -> Basic | Any | Add | Order | Mul: - ... - -def sum_add(self, other, method=...) -> Basic | Any | Add | Order | Mul: - ... - -def product_simplify(s, **kwargs) -> Order: - ... - -def product_mul(self, other, method=...) -> Equality | Relational | Ne | Product | Order: - ... - -def logcombine(expr, force=...): - ... - -def inversecombine(expr): - ... - -def kroneckersimp(expr) -> None: - ... - -def besselsimp(expr): - ... - -def nthroot(expr, n, max_len=..., prec=...) -> Mul | Pow | Order | Add | None: - ... - -def nsimplify(expr, constants=..., tolerance=..., full=..., rational=..., rational_conversion=...): - ... - -def clear_coefficients(expr, rhs=...) -> tuple[Any, Any] | tuple[Any | Expr | Relational | Order | Eq | Ne | Add | tuple[Any, dict[Any, Any]], Any]: - ... - -def nc_simplify(expr, deep=...): - ... - -def dotprodsimp(expr, withsimp=...) -> tuple[Any | Basic, bool] | Any | Basic: - ... +def separatevars( + expr, symbols=..., dict=..., force=... +) -> dict[str, Any] | dict[Any, list[Any]] | Order | Abs | type[UndefinedFunction] | Any | None: ... +def posify(eq) -> tuple[Any, dict[Any, Any]] | tuple[Any, dict[Dummy, Any]]: ... +def hypersimp(f, k) -> None: ... +def hypersimilar(f, g, k): ... +def signsimp(expr, evaluate=...) -> Expr | Relational | Order | Eq | Ne | Add | tuple[Any, dict[Any, Any]]: ... +def simplify(expr, ratio=..., measure=..., rational=..., inverse=..., doit=..., **kwargs): ... +def sum_simplify(s, **kwargs) -> Order: ... +def sum_combine(s_t) -> Order: ... +def factor_sum(self, limits=..., radical=..., clear=..., fraction=..., sign=...) -> Basic | Any | Add | Order | Mul: ... +def sum_add(self, other, method=...) -> Basic | Any | Add | Order | Mul: ... +def product_simplify(s, **kwargs) -> Order: ... +def product_mul(self, other, method=...) -> Equality | Relational | Ne | Product | Order: ... +def logcombine(expr, force=...): ... +def inversecombine(expr): ... +def kroneckersimp(expr) -> None: ... +def besselsimp(expr): ... +def nthroot(expr, n, max_len=..., prec=...) -> Mul | Pow | Order | Add | None: ... +def nsimplify(expr, constants=..., tolerance=..., full=..., rational=..., rational_conversion=...): ... +def clear_coefficients( + expr, rhs=... +) -> tuple[Any, Any] | tuple[Any | Expr | Relational | Order | Eq | Ne | Add | tuple[Any, dict[Any, Any]], Any]: ... +def nc_simplify(expr, deep=...): ... +def dotprodsimp(expr, withsimp=...) -> tuple[Any | Basic, bool] | Any | Basic: ... bottom_up = ... walk = ... diff --git a/stubs/sympy-stubs/simplify/sqrtdenest.pyi b/stubs/sympy-stubs/simplify/sqrtdenest.pyi index c4f89974..69fa5f4d 100644 --- a/stubs/sympy-stubs/simplify/sqrtdenest.pyi +++ b/stubs/sympy-stubs/simplify/sqrtdenest.pyi @@ -5,22 +5,11 @@ from sympy.core.mul import Mul from sympy.core.power import Pow from sympy.series.order import Order -def is_sqrt(expr) -> bool: - ... +def is_sqrt(expr) -> bool: ... +def sqrt_depth(p) -> Literal[1, 0]: ... +def is_algebraic(p) -> bool: ... +def sqrtdenest(expr, max_iter=...) -> Mul | Pow | Order | Add | None: ... -def sqrt_depth(p) -> Literal[1, 0]: - ... - -def is_algebraic(p) -> bool: - ... - -def sqrtdenest(expr, max_iter=...) -> Mul | Pow | Order | Add | None: - ... - -class SqrtdenestStopIteration(StopIteration): - ... - - -def sqrt_biquadratic_denest(expr, a, b, r, d2) -> None: - ... +class SqrtdenestStopIteration(StopIteration): ... +def sqrt_biquadratic_denest(expr, a, b, r, d2) -> None: ... diff --git a/stubs/sympy-stubs/simplify/trigsimp.pyi b/stubs/sympy-stubs/simplify/trigsimp.pyi index 2a241b8f..917b1f62 100644 --- a/stubs/sympy-stubs/simplify/trigsimp.pyi +++ b/stubs/sympy-stubs/simplify/trigsimp.pyi @@ -3,23 +3,17 @@ from typing import Any from sympy.core.basic import Basic from sympy.series.order import Order -def trigsimp_groebner(expr, hints=..., quick=..., order=..., polynomial=...) -> Order | Any: - ... +def trigsimp_groebner(expr, hints=..., quick=..., order=..., polynomial=...) -> Order | Any: ... _trigs = ... -def trigsimp(expr, inverse=..., **opts) -> Any: - ... -def exptrigsimp(expr) -> Order: - ... - -def trigsimp_old(expr, *, first=..., **opts): - ... +def trigsimp(expr, inverse=..., **opts) -> Any: ... +def exptrigsimp(expr) -> Order: ... +def trigsimp_old(expr, *, first=..., **opts): ... _trigpat = ... _idn = ... _midn = ... _one = ... -def futrig(e, *, hyper=..., **kwargs) -> Basic | Order: - ... +def futrig(e, *, hyper=..., **kwargs) -> Basic | Order: ... diff --git a/stubs/sympy-stubs/solvers/__init__.pyi b/stubs/sympy-stubs/solvers/__init__.pyi index a2d4d36b..71548427 100644 --- a/stubs/sympy-stubs/solvers/__init__.pyi +++ b/stubs/sympy-stubs/solvers/__init__.pyi @@ -29,4 +29,47 @@ from sympy.solvers.solvers import ( from sympy.solvers.solveset import linear_eq_to_matrix, linsolve, nonlinsolve, solveset, substitution Complexes = ... -__all__ = ['solve', 'solve_linear_system', 'solve_linear_system_LU', 'solve_undetermined_coeffs', 'nsolve', 'solve_linear', 'checksol', 'det_quick', 'inv_quick', 'check_assumptions', 'failing_assumptions', 'diophantine', 'rsolve', 'rsolve_poly', 'rsolve_ratio', 'rsolve_hyper', 'checkodesol', 'classify_ode', 'dsolve', 'homogeneous_order', 'solve_poly_system', 'solve_triangulated', 'pde_separate', 'pde_separate_add', 'pde_separate_mul', 'pdsolve', 'classify_pde', 'checkpdesol', 'ode_order', 'reduce_inequalities', 'reduce_abs_inequality', 'reduce_abs_inequalities', 'solve_poly_inequality', 'solve_rational_inequalities', 'solve_univariate_inequality', 'decompogen', 'solveset', 'linsolve', 'linear_eq_to_matrix', 'nonlinsolve', 'substitution', 'Complexes'] +__all__ = [ + "solve", + "solve_linear_system", + "solve_linear_system_LU", + "solve_undetermined_coeffs", + "nsolve", + "solve_linear", + "checksol", + "det_quick", + "inv_quick", + "check_assumptions", + "failing_assumptions", + "diophantine", + "rsolve", + "rsolve_poly", + "rsolve_ratio", + "rsolve_hyper", + "checkodesol", + "classify_ode", + "dsolve", + "homogeneous_order", + "solve_poly_system", + "solve_triangulated", + "pde_separate", + "pde_separate_add", + "pde_separate_mul", + "pdsolve", + "classify_pde", + "checkpdesol", + "ode_order", + "reduce_inequalities", + "reduce_abs_inequality", + "reduce_abs_inequalities", + "solve_poly_inequality", + "solve_rational_inequalities", + "solve_univariate_inequality", + "decompogen", + "solveset", + "linsolve", + "linear_eq_to_matrix", + "nonlinsolve", + "substitution", + "Complexes", +] diff --git a/stubs/sympy-stubs/solvers/bivariate.pyi b/stubs/sympy-stubs/solvers/bivariate.pyi index 88546b6d..c4570a47 100644 --- a/stubs/sympy-stubs/solvers/bivariate.pyi +++ b/stubs/sympy-stubs/solvers/bivariate.pyi @@ -3,6 +3,6 @@ from typing import Any from sympy.core.symbol import Dummy from sympy.series.order import Order -def bivariate_type(f, x, y, *, first=...) -> tuple[Any, Any, Any] | tuple[Any, Any | Order, Dummy] | tuple[Any, Any, Dummy] | None: - ... - +def bivariate_type( + f, x, y, *, first=... +) -> tuple[Any, Any, Any] | tuple[Any, Any | Order, Dummy] | tuple[Any, Any, Dummy] | None: ... diff --git a/stubs/sympy-stubs/solvers/decompogen.pyi b/stubs/sympy-stubs/solvers/decompogen.pyi index 84ecbd33..4d1a9335 100644 --- a/stubs/sympy-stubs/solvers/decompogen.pyi +++ b/stubs/sympy-stubs/solvers/decompogen.pyi @@ -5,9 +5,5 @@ from sympy.core.function import Function from sympy.core.power import Pow from sympy.functions.elementary.miscellaneous import Max, Min -def decompogen(f, symbol) -> list[Expr] | list[Function | Pow] | list[Min | Max] | Any: - ... - -def compogen(g_s, symbol): - ... - +def decompogen(f, symbol) -> list[Expr] | list[Function | Pow] | list[Min | Max] | Any: ... +def compogen(g_s, symbol): ... diff --git a/stubs/sympy-stubs/solvers/deutils.pyi b/stubs/sympy-stubs/solvers/deutils.pyi index eb75fc43..46310d36 100644 --- a/stubs/sympy-stubs/solvers/deutils.pyi +++ b/stubs/sympy-stubs/solvers/deutils.pyi @@ -1,4 +1 @@ - -def ode_order(expr, func) -> int: - ... - +def ode_order(expr, func) -> int: ... diff --git a/stubs/sympy-stubs/solvers/diophantine/__init__.pyi b/stubs/sympy-stubs/solvers/diophantine/__init__.pyi index fb598652..c692d2de 100644 --- a/stubs/sympy-stubs/solvers/diophantine/__init__.pyi +++ b/stubs/sympy-stubs/solvers/diophantine/__init__.pyi @@ -1,3 +1,3 @@ from sympy.solvers.diophantine.diophantine import classify_diop, diop_solve, diophantine -__all__ = ['diophantine', 'classify_diop', 'diop_solve'] +__all__ = ["diophantine", "classify_diop", "diop_solve"] diff --git a/stubs/sympy-stubs/solvers/diophantine/diophantine.pyi b/stubs/sympy-stubs/solvers/diophantine/diophantine.pyi index 7a79ced8..a2cfd5fb 100644 --- a/stubs/sympy-stubs/solvers/diophantine/diophantine.pyi +++ b/stubs/sympy-stubs/solvers/diophantine/diophantine.pyi @@ -6,290 +6,171 @@ from sympy.core.function import UndefinedFunction from sympy.matrices.dense import MutableDenseMatrix from sympy.series.order import Order -__all__ = ['diophantine', 'classify_diop'] -class DiophantineSolutionSet(set): - def __init__(self, symbols_seq, parameters) -> None: - ... - - def add(self, solution) -> None: - ... - - def update(self, *solutions) -> None: - ... - - def dict_iterator(self) -> Generator[dict[Any, Any], Any, None]: - ... - - def subs(self, *args, **kwargs) -> DiophantineSolutionSet: - ... - - def __call__(self, *args) -> DiophantineSolutionSet: - ... - +__all__ = ["diophantine", "classify_diop"] +class DiophantineSolutionSet(set): + def __init__(self, symbols_seq, parameters) -> None: ... + def add(self, solution) -> None: ... + def update(self, *solutions) -> None: ... + def dict_iterator(self) -> Generator[dict[Any, Any], Any, None]: ... + def subs(self, *args, **kwargs) -> DiophantineSolutionSet: ... + def __call__(self, *args) -> DiophantineSolutionSet: ... class DiophantineEquationType: name: str = ... - def __init__(self, equation, free_symbols=...) -> None: - ... - - def matches(self) -> Literal[False]: - ... - + def __init__(self, equation, free_symbols=...) -> None: ... + def matches(self) -> Literal[False]: ... @property - def n_parameters(self) -> int: - ... - + def n_parameters(self) -> int: ... @property - def parameters(self) -> Any: - ... - - def solve(self, parameters=..., limit=...) -> DiophantineSolutionSet: - ... - - def pre_solve(self, parameters=...) -> None: - ... - - + def parameters(self) -> Any: ... + def solve(self, parameters=..., limit=...) -> DiophantineSolutionSet: ... + def pre_solve(self, parameters=...) -> None: ... class Univariate(DiophantineEquationType): name = ... - def matches(self) -> bool: - ... - - def solve(self, parameters=..., limit=...) -> DiophantineSolutionSet: - ... - - + def matches(self) -> bool: ... + def solve(self, parameters=..., limit=...) -> DiophantineSolutionSet: ... class Linear(DiophantineEquationType): name = ... - def matches(self) -> Any: - ... - - def solve(self, parameters=..., limit=...) -> DiophantineSolutionSet: - ... - - + def matches(self) -> Any: ... + def solve(self, parameters=..., limit=...) -> DiophantineSolutionSet: ... class BinaryQuadratic(DiophantineEquationType): name = ... - def matches(self) -> Any | bool: - ... - - def solve(self, parameters=..., limit=...) -> DiophantineSolutionSet: - ... - - + def matches(self) -> Any | bool: ... + def solve(self, parameters=..., limit=...) -> DiophantineSolutionSet: ... class InhomogeneousTernaryQuadratic(DiophantineEquationType): name = ... - def matches(self) -> bool: - ... - - + def matches(self) -> bool: ... class HomogeneousTernaryQuadraticNormal(DiophantineEquationType): name = ... - def matches(self) -> bool: - ... - - def solve(self, parameters=..., limit=...) -> DiophantineSolutionSet: - ... - - + def matches(self) -> bool: ... + def solve(self, parameters=..., limit=...) -> DiophantineSolutionSet: ... class HomogeneousTernaryQuadratic(DiophantineEquationType): name = ... - def matches(self) -> bool: - ... - - def solve(self, parameters=..., limit=...) -> DiophantineSolutionSet: - ... - - + def matches(self) -> bool: ... + def solve(self, parameters=..., limit=...) -> DiophantineSolutionSet: ... class InhomogeneousGeneralQuadratic(DiophantineEquationType): name = ... - def matches(self) -> bool: - ... - - + def matches(self) -> bool: ... class HomogeneousGeneralQuadratic(DiophantineEquationType): name = ... - def matches(self) -> bool: - ... - - + def matches(self) -> bool: ... class GeneralSumOfSquares(DiophantineEquationType): name = ... - def matches(self) -> bool: - ... - - def solve(self, parameters=..., limit=...) -> DiophantineSolutionSet: - ... - - + def matches(self) -> bool: ... + def solve(self, parameters=..., limit=...) -> DiophantineSolutionSet: ... class GeneralPythagorean(DiophantineEquationType): name = ... - def matches(self) -> Literal[False]: - ... - + def matches(self) -> Literal[False]: ... @property - def n_parameters(self) -> int: - ... - - def solve(self, parameters=..., limit=...) -> DiophantineSolutionSet: - ... - - + def n_parameters(self) -> int: ... + def solve(self, parameters=..., limit=...) -> DiophantineSolutionSet: ... class CubicThue(DiophantineEquationType): name = ... - def matches(self) -> Any | bool: - ... - - + def matches(self) -> Any | bool: ... class GeneralSumOfEvenPowers(DiophantineEquationType): name = ... - def matches(self) -> bool: - ... - - def solve(self, parameters=..., limit=...) -> DiophantineSolutionSet: - ... - - + def matches(self) -> bool: ... + def solve(self, parameters=..., limit=...) -> DiophantineSolutionSet: ... all_diop_classes = ... diop_known = ... -def diophantine(eq, param=..., syms=..., permute=...): - ... - -def merge_solution(var, var_t, solution) -> tuple[()] | tuple[Any, ...]: - ... - -def diop_solve(eq, param=...) -> tuple[None, ...] | set[Any] | tuple[None, None, None] | tuple[Any, Any, Any] | tuple[Any, ...] | tuple[Any | None, Any | None, Any | None] | set[tuple[int]] | None: - ... - -def classify_diop(eq, _dict=...) -> tuple[Any, dict[Any, Any] | Any, Any]: - ... - -def diop_linear(eq, param=...) -> tuple[None, ...] | None: - ... - -def base_solution_linear(c, a, b, t=...) -> tuple[Any, Any] | tuple[Literal[0], Literal[0]] | tuple[None, None]: - ... - -def diop_univariate(eq) -> set[tuple[int]] | None: - ... - -def divisible(a, b) -> bool: - ... - -def diop_quadratic(eq, param=...) -> set[Any] | None: - ... - -def is_solution_quad(var, coeff, u, v) -> NotImplementedType | bool: - ... - -def diop_DN(D, N, t=...): - ... - -def cornacchia(a, b, m) -> set[Any] | None: - ... - -def PQa(P_0, Q_0, D) -> Generator[tuple[Any, Any, type[UndefinedFunction] | Any, Any, Any, Any], Any, NoReturn]: - ... -def diop_bf_DN(D, N, t=...) -> list[tuple[Literal[0], Literal[0]]] | list[tuple[Literal[0], Any]] | list[tuple[Any, Any]] | list[Any]: - ... - -def equivalent(u, v, r, s, D, N) -> bool: - ... - -def length(P, Q, D) -> int: - ... - -def transformation_to_DN(eq) -> tuple[Any, Any] | tuple[MutableDenseMatrix, MutableDenseMatrix] | None: - ... - -def find_DN(eq) -> tuple[Any, Any] | None: - ... - -def check_param(x, y, a, params) -> DiophantineSolutionSet | None: - ... - -def diop_ternary_quadratic(eq, parameterize=...) -> tuple[None, None, None] | tuple[Any, Any, Any] | tuple[Any, ...] | tuple[Any | None, Any | None, Any | None] | None: - ... - -def transformation_to_normal(eq) -> MutableDenseMatrix | None: - ... - -def parametrize_ternary_quadratic(eq) -> tuple[None, None, None] | tuple[Any, Any, Any] | tuple[Any, ...] | None: - ... - -def diop_ternary_quadratic_normal(eq, parameterize=...) -> tuple[None, None, None] | tuple[Any, Any, Any] | tuple[Any, ...] | tuple[Any | None, Any | None, Any | None] | None: - ... - -def sqf_normal(a, b, c, steps=...) -> tuple[tuple[Any | Order, ...], tuple[Any, ...], tuple[Any, Any, Any]] | tuple[Any, Any, Any]: - ... - -def square_factor(a) -> Order: - ... - -def reconstruct(A, B, z): - ... - -def ldescent(A, B) -> tuple[Any, Any, Any] | tuple[Literal[1], Literal[1], Literal[0]] | tuple[Literal[1], Literal[0], Literal[1]] | tuple[Any, ...] | None: - ... - -def descent(A, B) -> tuple[Any, Any, Any] | tuple[Literal[1], Literal[0], Literal[1]] | tuple[Literal[1], Literal[1], Literal[0]] | tuple[Literal[0], Literal[1], Literal[1]] | tuple[Any, ...]: - ... - -def gaussian_reduce(w, a, b) -> tuple[Any, Any | int]: - ... - -def dot(u, v, w, a, b): - ... - -def norm(u, w, a, b) -> Pow: - ... - -def holzer(x, y, z, a, b, c) -> tuple[int, ...]: - ... - -def diop_general_pythagorean(eq, param=...) -> None: - ... - -def diop_general_sum_of_squares(eq, limit=...) -> set[Any] | None: - ... - -def diop_general_sum_of_even_powers(eq, limit=...) -> set[Any] | None: - ... - -def partition(n, k=..., zeros=...) -> Generator[tuple[Any, ...] | Any, Any, None]: - ... - -def prime_as_sum_of_two_squares(p) -> tuple[int, int] | None: - ... - -def sum_of_three_squares(n) -> tuple[Literal[0], Literal[0], Literal[0]] | tuple[Any, ...] | tuple[Any, Literal[0], Literal[0]] | None: - ... - -def sum_of_four_squares(n) -> tuple[Literal[0], Literal[0], Literal[0], Literal[0]] | tuple[Any, ...]: - ... - -def power_representation(n, p, k, zeros=...) -> Generator[tuple[Any, ...] | tuple[Literal[0], ...] | tuple[int] | tuple[Any] | tuple[int, int] | None, Any, None]: - ... +def diophantine(eq, param=..., syms=..., permute=...): ... +def merge_solution(var, var_t, solution) -> tuple[()] | tuple[Any, ...]: ... +def diop_solve( + eq, param=... +) -> ( + tuple[None, ...] + | set[Any] + | tuple[None, None, None] + | tuple[Any, Any, Any] + | tuple[Any, ...] + | tuple[Any | None, Any | None, Any | None] + | set[tuple[int]] + | None +): ... +def classify_diop(eq, _dict=...) -> tuple[Any, dict[Any, Any] | Any, Any]: ... +def diop_linear(eq, param=...) -> tuple[None, ...] | None: ... +def base_solution_linear(c, a, b, t=...) -> tuple[Any, Any] | tuple[Literal[0], Literal[0]] | tuple[None, None]: ... +def diop_univariate(eq) -> set[tuple[int]] | None: ... +def divisible(a, b) -> bool: ... +def diop_quadratic(eq, param=...) -> set[Any] | None: ... +def is_solution_quad(var, coeff, u, v) -> NotImplementedType | bool: ... +def diop_DN(D, N, t=...): ... +def cornacchia(a, b, m) -> set[Any] | None: ... +def PQa(P_0, Q_0, D) -> Generator[tuple[Any, Any, type[UndefinedFunction] | Any, Any, Any, Any], Any, NoReturn]: ... +def diop_bf_DN( + D, N, t=... +) -> list[tuple[Literal[0], Literal[0]]] | list[tuple[Literal[0], Any]] | list[tuple[Any, Any]] | list[Any]: ... +def equivalent(u, v, r, s, D, N) -> bool: ... +def length(P, Q, D) -> int: ... +def transformation_to_DN(eq) -> tuple[Any, Any] | tuple[MutableDenseMatrix, MutableDenseMatrix] | None: ... +def find_DN(eq) -> tuple[Any, Any] | None: ... +def check_param(x, y, a, params) -> DiophantineSolutionSet | None: ... +def diop_ternary_quadratic( + eq, parameterize=... +) -> tuple[None, None, None] | tuple[Any, Any, Any] | tuple[Any, ...] | tuple[Any | None, Any | None, Any | None] | None: ... +def transformation_to_normal(eq) -> MutableDenseMatrix | None: ... +def parametrize_ternary_quadratic(eq) -> tuple[None, None, None] | tuple[Any, Any, Any] | tuple[Any, ...] | None: ... +def diop_ternary_quadratic_normal( + eq, parameterize=... +) -> tuple[None, None, None] | tuple[Any, Any, Any] | tuple[Any, ...] | tuple[Any | None, Any | None, Any | None] | None: ... +def sqf_normal( + a, b, c, steps=... +) -> tuple[tuple[Any | Order, ...], tuple[Any, ...], tuple[Any, Any, Any]] | tuple[Any, Any, Any]: ... +def square_factor(a) -> Order: ... +def reconstruct(A, B, z): ... +def ldescent( + A, B +) -> ( + tuple[Any, Any, Any] + | tuple[Literal[1], Literal[1], Literal[0]] + | tuple[Literal[1], Literal[0], Literal[1]] + | tuple[Any, ...] + | None +): ... +def descent( + A, B +) -> ( + tuple[Any, Any, Any] + | tuple[Literal[1], Literal[0], Literal[1]] + | tuple[Literal[1], Literal[1], Literal[0]] + | tuple[Literal[0], Literal[1], Literal[1]] + | tuple[Any, ...] +): ... +def gaussian_reduce(w, a, b) -> tuple[Any, Any | int]: ... +def dot(u, v, w, a, b): ... +def norm(u, w, a, b) -> Pow: ... +def holzer(x, y, z, a, b, c) -> tuple[int, ...]: ... +def diop_general_pythagorean(eq, param=...) -> None: ... +def diop_general_sum_of_squares(eq, limit=...) -> set[Any] | None: ... +def diop_general_sum_of_even_powers(eq, limit=...) -> set[Any] | None: ... +def partition(n, k=..., zeros=...) -> Generator[tuple[Any, ...] | Any, Any, None]: ... +def prime_as_sum_of_two_squares(p) -> tuple[int, int] | None: ... +def sum_of_three_squares( + n, +) -> tuple[Literal[0], Literal[0], Literal[0]] | tuple[Any, ...] | tuple[Any, Literal[0], Literal[0]] | None: ... +def sum_of_four_squares(n) -> tuple[Literal[0], Literal[0], Literal[0], Literal[0]] | tuple[Any, ...]: ... +def power_representation( + n, p, k, zeros=... +) -> Generator[tuple[Any, ...] | tuple[Literal[0], ...] | tuple[int] | tuple[Any] | tuple[int, int] | None, Any, None]: ... sum_of_powers = ... -def pow_rep_recursive(n_i, k, n_remaining, terms, p) -> Generator[tuple[Any, ...] | Any, Any, None]: - ... - -def sum_of_squares(n, k, zeros=...) -> Generator[tuple[Any, ...] | tuple[Literal[0], ...] | tuple[int] | tuple[Any] | tuple[int, int] | None, Any, None]: - ... +def pow_rep_recursive(n_i, k, n_remaining, terms, p) -> Generator[tuple[Any, ...] | Any, Any, None]: ... +def sum_of_squares( + n, k, zeros=... +) -> Generator[tuple[Any, ...] | tuple[Literal[0], ...] | tuple[int] | tuple[Any] | tuple[int, int] | None, Any, None]: ... diff --git a/stubs/sympy-stubs/solvers/inequalities.pyi b/stubs/sympy-stubs/solvers/inequalities.pyi index 3e39ae93..0c077edb 100644 --- a/stubs/sympy-stubs/solvers/inequalities.pyi +++ b/stubs/sympy-stubs/solvers/inequalities.pyi @@ -3,27 +3,11 @@ from typing import Any from sympy.core.logic import And from sympy.sets.sets import FiniteSet, Union -def solve_poly_inequality(poly, rel) -> list[Any]: - ... - -def solve_poly_inequalities(polys) -> FiniteSet | Union: - ... - -def solve_rational_inequalities(eqs): - ... - -def reduce_rational_inequalities(exprs, gen, relational=...): - ... - -def reduce_abs_inequality(expr, rel, gen): - ... - -def reduce_abs_inequalities(exprs, gen) -> And: - ... - -def solve_univariate_inequality(expr, gen, relational=..., domain=..., continuous=...): - ... - -def reduce_inequalities(inequalities, symbols=...) -> And: - ... - +def solve_poly_inequality(poly, rel) -> list[Any]: ... +def solve_poly_inequalities(polys) -> FiniteSet | Union: ... +def solve_rational_inequalities(eqs): ... +def reduce_rational_inequalities(exprs, gen, relational=...): ... +def reduce_abs_inequality(expr, rel, gen): ... +def reduce_abs_inequalities(exprs, gen) -> And: ... +def solve_univariate_inequality(expr, gen, relational=..., domain=..., continuous=...): ... +def reduce_inequalities(inequalities, symbols=...) -> And: ... diff --git a/stubs/sympy-stubs/solvers/ode/__init__.pyi b/stubs/sympy-stubs/solvers/ode/__init__.pyi index 80774852..67c29923 100644 --- a/stubs/sympy-stubs/solvers/ode/__init__.pyi +++ b/stubs/sympy-stubs/solvers/ode/__init__.pyi @@ -3,4 +3,16 @@ from sympy.solvers.ode.ode import allhints, checkinfsol, classify_ode, constants from sympy.solvers.ode.subscheck import checkodesol from sympy.solvers.ode.systems import canonical_odes, linear_ode_to_matrix, linodesolve -__all__ = ['allhints', 'checkinfsol', 'checkodesol', 'classify_ode', 'constantsimp', 'dsolve', 'homogeneous_order', 'infinitesimals', 'canonical_odes', 'linear_ode_to_matrix', 'linodesolve'] +__all__ = [ + "allhints", + "checkinfsol", + "checkodesol", + "classify_ode", + "constantsimp", + "dsolve", + "homogeneous_order", + "infinitesimals", + "canonical_odes", + "linear_ode_to_matrix", + "linodesolve", +] diff --git a/stubs/sympy-stubs/solvers/ode/hypergeometric.pyi b/stubs/sympy-stubs/solvers/ode/hypergeometric.pyi index 08774b85..35e0c1d5 100644 --- a/stubs/sympy-stubs/solvers/ode/hypergeometric.pyi +++ b/stubs/sympy-stubs/solvers/ode/hypergeometric.pyi @@ -2,18 +2,8 @@ from typing import Any, Literal from sympy.core.relational import Eq, Ne, Relational -def match_2nd_hypergeometric(eq, func) -> list[Any]: - ... - -def equivalence_hypergeometric(A, B, func) -> dict[str, Any] | None: - ... - -def match_2nd_2F1_hypergeometric(I, k, sing_point, func) -> dict[str, Any]: - ... - -def equivalence(max_num_pow, dem_pow) -> Literal['2F1'] | None: - ... - -def get_sol_2F1_hypergeometric(eq, func, match_object) -> Eq | Relational | Ne | None: - ... - +def match_2nd_hypergeometric(eq, func) -> list[Any]: ... +def equivalence_hypergeometric(A, B, func) -> dict[str, Any] | None: ... +def match_2nd_2F1_hypergeometric(I, k, sing_point, func) -> dict[str, Any]: ... +def equivalence(max_num_pow, dem_pow) -> Literal["2F1"] | None: ... +def get_sol_2F1_hypergeometric(eq, func, match_object) -> Eq | Relational | Ne | None: ... diff --git a/stubs/sympy-stubs/solvers/ode/lie_group.pyi b/stubs/sympy-stubs/solvers/ode/lie_group.pyi index c536d03d..a7557f4b 100644 --- a/stubs/sympy-stubs/solvers/ode/lie_group.pyi +++ b/stubs/sympy-stubs/solvers/ode/lie_group.pyi @@ -5,33 +5,14 @@ from sympy.core.function import UndefinedFunction from sympy.core.symbol import Symbol lie_heuristics = ... -def infinitesimals(eq, func=..., order=..., hint=..., match=...) -> list[Any] | Any: - ... - -def lie_heuristic_abaco1_simple(match, comp=...): - ... - -def lie_heuristic_abaco1_product(match, comp=...) -> list[dict[UndefinedFunction | Any, Any]] | list[Any] | None: - ... - -def lie_heuristic_bivariate(match, comp=...) -> list[dict[UndefinedFunction | Any, Any | Symbol | Basic]] | None: - ... - -def lie_heuristic_chi(match, comp=...) -> list[dict[UndefinedFunction | Any, Any]] | None: - ... - -def lie_heuristic_function_sum(match, comp=...) -> list[dict[UndefinedFunction | Any, Any]] | list[Any] | None: - ... - -def lie_heuristic_abaco2_similar(match, comp=...) -> list[dict[UndefinedFunction | Any, Any]] | None: - ... - -def lie_heuristic_abaco2_unique_unknown(match, comp=...) -> list[dict[UndefinedFunction | Any, Any]] | None: - ... - -def lie_heuristic_abaco2_unique_general(match, comp=...) -> list[dict[UndefinedFunction | Any, Any]] | None: - ... - -def lie_heuristic_linear(match, comp=...) -> list[dict[UndefinedFunction | Any, Any]] | None: - ... +def infinitesimals(eq, func=..., order=..., hint=..., match=...) -> list[Any] | Any: ... +def lie_heuristic_abaco1_simple(match, comp=...): ... +def lie_heuristic_abaco1_product(match, comp=...) -> list[dict[UndefinedFunction | Any, Any]] | list[Any] | None: ... +def lie_heuristic_bivariate(match, comp=...) -> list[dict[UndefinedFunction | Any, Any | Symbol | Basic]] | None: ... +def lie_heuristic_chi(match, comp=...) -> list[dict[UndefinedFunction | Any, Any]] | None: ... +def lie_heuristic_function_sum(match, comp=...) -> list[dict[UndefinedFunction | Any, Any]] | list[Any] | None: ... +def lie_heuristic_abaco2_similar(match, comp=...) -> list[dict[UndefinedFunction | Any, Any]] | None: ... +def lie_heuristic_abaco2_unique_unknown(match, comp=...) -> list[dict[UndefinedFunction | Any, Any]] | None: ... +def lie_heuristic_abaco2_unique_general(match, comp=...) -> list[dict[UndefinedFunction | Any, Any]] | None: ... +def lie_heuristic_linear(match, comp=...) -> list[dict[UndefinedFunction | Any, Any]] | None: ... diff --git a/stubs/sympy-stubs/solvers/ode/ode.pyi b/stubs/sympy-stubs/solvers/ode/ode.pyi index 829f6975..21dab371 100644 --- a/stubs/sympy-stubs/solvers/ode/ode.pyi +++ b/stubs/sympy-stubs/solvers/ode/ode.pyi @@ -7,74 +7,65 @@ from sympy.core.relational import Eq, Equality, Ne, Relational from sympy.core.symbol import Symbol allhints = ... -def get_numbered_constants(eq, num=..., start=..., prefix=...) -> Symbol | tuple[Symbol | Any, ...]: - ... - -def iter_numbered_constants(eq, start=..., prefix=...) -> Generator[Symbol | Any, Any, NoReturn]: - ... - -def dsolve(eq, func=..., hint=..., simplify=..., ics=..., xi=..., eta=..., x0=..., n=..., **kwargs) -> list[Any] | Any | dict[Any, Any] | Equality | Basic | list[list[Any] | Any] | list[list[list[Any] | Any] | Any] | list[Equality]: - ... - -def solve_ics(sols, funcs, constants, ics): - ... - -def classify_ode(eq, func=..., dict=..., ics=..., *, prep=..., xi=..., eta=..., n=..., **kwargs): - ... - -def classify_sysode(eq, funcs=..., **kwargs) -> dict[str, int]: - ... - -def check_linear_2eq_order1(eq, func, func_coef) -> Literal['type6', 'type7'] | None: - ... - -def check_nonlinear_2eq_order1(eq, func, func_coef) -> Literal['type5', 'type1', 'type2', 'type3', 'type4'] | None: - ... - -def check_nonlinear_2eq_order2(eq, func, func_coef) -> None: - ... - -def check_nonlinear_3eq_order1(eq, func, func_coef): - ... - -def check_nonlinear_3eq_order2(eq, func, func_coef) -> None: - ... +def get_numbered_constants(eq, num=..., start=..., prefix=...) -> Symbol | tuple[Symbol | Any, ...]: ... +def iter_numbered_constants(eq, start=..., prefix=...) -> Generator[Symbol | Any, Any, NoReturn]: ... +def dsolve( + eq, func=..., hint=..., simplify=..., ics=..., xi=..., eta=..., x0=..., n=..., **kwargs +) -> ( + list[Any] + | Any + | dict[Any, Any] + | Equality + | Basic + | list[list[Any] | Any] + | list[list[list[Any] | Any] | Any] + | list[Equality] +): ... +def solve_ics(sols, funcs, constants, ics): ... +def classify_ode(eq, func=..., dict=..., ics=..., *, prep=..., xi=..., eta=..., n=..., **kwargs): ... +def classify_sysode(eq, funcs=..., **kwargs) -> dict[str, int]: ... +def check_linear_2eq_order1(eq, func, func_coef) -> Literal["type6", "type7"] | None: ... +def check_nonlinear_2eq_order1(eq, func, func_coef) -> Literal["type5", "type1", "type2", "type3", "type4"] | None: ... +def check_nonlinear_2eq_order2(eq, func, func_coef) -> None: ... +def check_nonlinear_3eq_order1(eq, func, func_coef): ... +def check_nonlinear_3eq_order2(eq, func, func_coef) -> None: ... @vectorize(0) -def odesimp(ode, eq, func, hint) -> list[Eq | Any | Relational | Ne] | list[list[Any] | Any] | Eq | Relational | Ne | list[list[Eq | Any | Relational | Ne] | list[list[Any] | Any] | Any]: - ... - -def ode_sol_simplicity(sol, func, trysolving=...) -> int: - ... - +def odesimp( + ode, eq, func, hint +) -> ( + list[Eq | Any | Relational | Ne] + | list[list[Any] | Any] + | Eq + | Relational + | Ne + | list[list[Eq | Any | Relational | Ne] | list[list[Any] | Any] | Any] +): ... +def ode_sol_simplicity(sol, func, trysolving=...) -> int: ... @vectorize(0) -def constantsimp(expr, constants) -> list[list[Any] | Any] | Eq | Relational | Ne | Add | Basic | Any: - ... - -def constant_renumber(expr, variables=..., newconstants=...) -> list[Any] | set[Any] | tuple[Any, ...] | Tuple | Basic | Eq | Relational | Ne: - ... - -def homogeneous_order(eq, *symbols) -> Any | None: - ... - -def ode_2nd_power_series_ordinary(eq, func, order, match) -> Eq | Relational | Ne: - ... - -def ode_2nd_power_series_regular(eq, func, order, match) -> Eq | Relational | Ne | None: - ... - -def ode_1st_power_series(eq, func, order, match) -> Eq | Relational | Ne: - ... - -def checkinfsol(eq, infinitesimals, func=..., order=...) -> list[Any]: - ... - -def sysode_linear_2eq_order1(match_) -> list[Eq | Any | Relational | Ne]: - ... - -def sysode_nonlinear_2eq_order1(match_) -> set[Eq] | list[Any] | set[Any]: - ... - -def sysode_nonlinear_3eq_order1(match_) -> list[Any | Basic] | list[Any | list[Any] | dict[Any, Any] | Equality | Basic | list[list[Any] | Any] | list[list[list[Any] | Any] | Any] | list[Equality]]: - ... - +def constantsimp(expr, constants) -> list[list[Any] | Any] | Eq | Relational | Ne | Add | Basic | Any: ... +def constant_renumber( + expr, variables=..., newconstants=... +) -> list[Any] | set[Any] | tuple[Any, ...] | Tuple | Basic | Eq | Relational | Ne: ... +def homogeneous_order(eq, *symbols) -> Any | None: ... +def ode_2nd_power_series_ordinary(eq, func, order, match) -> Eq | Relational | Ne: ... +def ode_2nd_power_series_regular(eq, func, order, match) -> Eq | Relational | Ne | None: ... +def ode_1st_power_series(eq, func, order, match) -> Eq | Relational | Ne: ... +def checkinfsol(eq, infinitesimals, func=..., order=...) -> list[Any]: ... +def sysode_linear_2eq_order1(match_) -> list[Eq | Any | Relational | Ne]: ... +def sysode_nonlinear_2eq_order1(match_) -> set[Eq] | list[Any] | set[Any]: ... +def sysode_nonlinear_3eq_order1( + match_, +) -> ( + list[Any | Basic] + | list[ + Any + | list[Any] + | dict[Any, Any] + | Equality + | Basic + | list[list[Any] | Any] + | list[list[list[Any] | Any] | Any] + | list[Equality] + ] +): ... diff --git a/stubs/sympy-stubs/solvers/ode/riccati.pyi b/stubs/sympy-stubs/solvers/ode/riccati.pyi index c4dce373..f9995d14 100644 --- a/stubs/sympy-stubs/solvers/ode/riccati.pyi +++ b/stubs/sympy-stubs/solvers/ode/riccati.pyi @@ -2,72 +2,26 @@ from typing import Any, Literal from sympy.core.relational import Eq, Ne, Relational -def riccati_normal(w, x, b1, b2): - ... - -def riccati_inverse_normal(y, x, b1, b2, bp=...): - ... - -def riccati_reduced(eq, f, x) -> Literal[False]: - ... - -def linsolve_dict(eq, syms) -> dict[Any, Any]: - ... - -def match_riccati(eq, f, x) -> tuple[Literal[False], list[Any]] | tuple[Literal[True], list[Any]]: - ... - -def val_at_inf(num, den, x): - ... - -def check_necessary_conds(val_inf, muls) -> bool: - ... - -def inverse_transform_poly(num, den, x): - ... - -def limit_at_inf(num, den, x) -> Literal[0]: - ... - -def construct_c_case_1(num, den, x, pole) -> list[list[Any]]: - ... - -def construct_c_case_2(num, den, x, pole, mul) -> list[list[int]] | list[int]: - ... - -def construct_c_case_3() -> list[list[int]]: - ... - -def construct_c(num, den, x, poles, muls) -> list[Any]: - ... - -def construct_d_case_4(ser, N) -> list[list[int]] | list[int]: - ... - -def construct_d_case_5(ser) -> list[list[int]] | list[int]: - ... - -def construct_d_case_6(num, den, x) -> list[list[Any]]: - ... - -def construct_d(num, den, x, val_inf) -> list[list[int]] | list[int] | list[list[Any]]: - ... - -def rational_laurent_series(num, den, x, r, m, n) -> dict[Any, Any]: - ... - -def compute_m_ybar(x, poles, choice, N) -> tuple[Any, Any]: - ... - -def solve_aux_eq(numa, dena, numy, deny, x, m) -> tuple[Any, dict[Any, Any], Literal[True]] | tuple[Any, Any, Any]: - ... - -def remove_redundant_sols(sol1, sol2, x) -> None: - ... - -def get_gen_sol_from_part_sol(part_sols, a, x) -> list[Any]: - ... - -def solve_riccati(fx, x, b0, b1, b2, gensol=...) -> list[Eq | Any | Relational | Ne]: - ... - +def riccati_normal(w, x, b1, b2): ... +def riccati_inverse_normal(y, x, b1, b2, bp=...): ... +def riccati_reduced(eq, f, x) -> Literal[False]: ... +def linsolve_dict(eq, syms) -> dict[Any, Any]: ... +def match_riccati(eq, f, x) -> tuple[Literal[False], list[Any]] | tuple[Literal[True], list[Any]]: ... +def val_at_inf(num, den, x): ... +def check_necessary_conds(val_inf, muls) -> bool: ... +def inverse_transform_poly(num, den, x): ... +def limit_at_inf(num, den, x) -> Literal[0]: ... +def construct_c_case_1(num, den, x, pole) -> list[list[Any]]: ... +def construct_c_case_2(num, den, x, pole, mul) -> list[list[int]] | list[int]: ... +def construct_c_case_3() -> list[list[int]]: ... +def construct_c(num, den, x, poles, muls) -> list[Any]: ... +def construct_d_case_4(ser, N) -> list[list[int]] | list[int]: ... +def construct_d_case_5(ser) -> list[list[int]] | list[int]: ... +def construct_d_case_6(num, den, x) -> list[list[Any]]: ... +def construct_d(num, den, x, val_inf) -> list[list[int]] | list[int] | list[list[Any]]: ... +def rational_laurent_series(num, den, x, r, m, n) -> dict[Any, Any]: ... +def compute_m_ybar(x, poles, choice, N) -> tuple[Any, Any]: ... +def solve_aux_eq(numa, dena, numy, deny, x, m) -> tuple[Any, dict[Any, Any], Literal[True]] | tuple[Any, Any, Any]: ... +def remove_redundant_sols(sol1, sol2, x) -> None: ... +def get_gen_sol_from_part_sol(part_sols, a, x) -> list[Any]: ... +def solve_riccati(fx, x, b0, b1, b2, gensol=...) -> list[Eq | Any | Relational | Ne]: ... diff --git a/stubs/sympy-stubs/solvers/ode/single.pyi b/stubs/sympy-stubs/solvers/ode/single.pyi index abc1d5d1..fc29ef56 100644 --- a/stubs/sympy-stubs/solvers/ode/single.pyi +++ b/stubs/sympy-stubs/solvers/ode/single.pyi @@ -7,9 +7,7 @@ from sympy.core.relational import Equality from sympy.core.symbol import Symbol from sympy.series.order import Order -class ODEMatchError(NotImplementedError): - ... - +class ODEMatchError(NotImplementedError): ... class SingleODEProblem: eq: Expr = ... @@ -19,39 +17,20 @@ class SingleODEProblem: _eq_expanded: Expr = ... _eq_preprocessed: Expr = ... _eq_high_order_free = ... - def __init__(self, eq, func, sym, prep=..., **kwargs) -> None: - ... - + def __init__(self, eq, func, sym, prep=..., **kwargs) -> None: ... @cached_property - def order(self) -> int: - ... - + def order(self) -> int: ... @cached_property - def eq_preprocessed(self) -> Expr: - ... - + def eq_preprocessed(self) -> Expr: ... @cached_property - def eq_high_order_free(self) -> Expr: - ... - + def eq_high_order_free(self) -> Expr: ... @cached_property - def eq_expanded(self) -> Expr: - ... - - def get_numbered_constants(self, num=..., start=..., prefix=...) -> list[Symbol]: - ... - - def iter_numbered_constants(self, start=..., prefix=...) -> Iterator[Symbol]: - ... - + def eq_expanded(self) -> Expr: ... + def get_numbered_constants(self, num=..., start=..., prefix=...) -> list[Symbol]: ... + def iter_numbered_constants(self, start=..., prefix=...) -> Iterator[Symbol]: ... @cached_property - def is_autonomous(self) -> bool: - ... - - def get_linear_coefficients(self, eq, func, order) -> dict[int, Any | Order] | None: - ... - - + def is_autonomous(self) -> bool: ... + def get_linear_coefficients(self, eq, func, order) -> dict[int, Any | Order] | None: ... class SingleODESolver: hint: ClassVar[str] @@ -59,174 +38,135 @@ class SingleODESolver: ode_problem: SingleODEProblem = ... _matched: bool | None = ... order: list | None = ... - def __init__(self, ode_problem) -> None: - ... - - def matches(self) -> bool: - ... - - def get_general_solution(self, *, simplify: bool = ...) -> list[Equality]: - ... - - + def __init__(self, ode_problem) -> None: ... + def matches(self) -> bool: ... + def get_general_solution(self, *, simplify: bool = ...) -> list[Equality]: ... class SinglePatternODESolver(SingleODESolver): - def wilds(self): - ... - - def wilds_match(self) -> list[Any]: - ... - - + def wilds(self): ... + def wilds_match(self) -> list[Any]: ... class NthAlgebraic(SingleODESolver): hint = ... has_integral = ... _diffx_stored: dict[Symbol, type[Function]] = ... - class FirstExact(SinglePatternODESolver): hint = ... has_integral = ... order = ... - class FirstLinear(SinglePatternODESolver): hint = ... has_integral = ... order = ... - class AlmostLinear(SinglePatternODESolver): hint = ... has_integral = ... order = ... - class Bernoulli(SinglePatternODESolver): hint = ... has_integral = ... order = ... - class Factorable(SingleODESolver): hint = ... has_integral = ... - class RiccatiSpecial(SinglePatternODESolver): hint = ... has_integral = ... order = ... - class RationalRiccati(SinglePatternODESolver): has_integral = ... hint = ... order = ... - class SecondNonlinearAutonomousConserved(SinglePatternODESolver): hint = ... has_integral = ... order = ... - class Liouville(SinglePatternODESolver): hint = ... has_integral = ... order = ... - class Separable(SinglePatternODESolver): hint = ... has_integral = ... order = ... - class SeparableReduced(Separable): hint = ... has_integral = ... order = ... - class HomogeneousCoeffSubsDepDivIndep(SinglePatternODESolver): hint = ... has_integral = ... order = ... - class HomogeneousCoeffSubsIndepDivDep(SinglePatternODESolver): hint = ... has_integral = ... order = ... - class HomogeneousCoeffBest(HomogeneousCoeffSubsIndepDivDep, HomogeneousCoeffSubsDepDivIndep): hint = ... has_integral = ... order = ... - class LinearCoefficients(HomogeneousCoeffBest): hint = ... has_integral = ... order = ... - class NthOrderReducible(SingleODESolver): hint = ... has_integral = ... - class SecondHypergeometric(SingleODESolver): hint = ... has_integral = ... - class NthLinearConstantCoeffHomogeneous(SingleODESolver): hint = ... has_integral = ... - class NthLinearConstantCoeffVariationOfParameters(SingleODESolver): hint = ... has_integral = ... - class NthLinearConstantCoeffUndeterminedCoefficients(SingleODESolver): hint = ... has_integral = ... - class NthLinearEulerEqHomogeneous(SingleODESolver): hint = ... has_integral = ... - class NthLinearEulerEqNonhomogeneousVariationOfParameters(SingleODESolver): hint = ... has_integral = ... - class NthLinearEulerEqNonhomogeneousUndeterminedCoefficients(SingleODESolver): hint = ... has_integral = ... - class SecondLinearBessel(SingleODESolver): hint = ... has_integral = ... - class SecondLinearAiry(SingleODESolver): hint = ... has_integral = ... - class LieGroup(SingleODESolver): hint = ... has_integral = ... - solver_map = ... diff --git a/stubs/sympy-stubs/solvers/ode/subscheck.pyi b/stubs/sympy-stubs/solvers/ode/subscheck.pyi index 85cff924..1996fbc0 100644 --- a/stubs/sympy-stubs/solvers/ode/subscheck.pyi +++ b/stubs/sympy-stubs/solvers/ode/subscheck.pyi @@ -1,11 +1,5 @@ from typing import Any, Literal -def sub_func_doit(eq, func, new): - ... - -def checkodesol(ode, sol, func=..., order=..., solve_for_func=...): - ... - -def checksysodesol(eqs, sols, func=...) -> tuple[Literal[True], list[Any]] | tuple[Literal[False], list[Any]]: - ... - +def sub_func_doit(eq, func, new): ... +def checkodesol(ode, sol, func=..., order=..., solve_for_func=...): ... +def checksysodesol(eqs, sols, func=...) -> tuple[Literal[True], list[Any]] | tuple[Literal[False], list[Any]]: ... diff --git a/stubs/sympy-stubs/solvers/ode/systems.pyi b/stubs/sympy-stubs/solvers/ode/systems.pyi index 612b06bd..f2d6fd04 100644 --- a/stubs/sympy-stubs/solvers/ode/systems.pyi +++ b/stubs/sympy-stubs/solvers/ode/systems.pyi @@ -4,35 +4,14 @@ from sympy.core.relational import Eq, Ne, Relational from sympy.matrices import Matrix from sympy.solvers.solveset import NonlinearError -class ODEOrderError(ValueError): - ... - - -class ODENonlinearError(NonlinearError): - ... - - -def simpsol(sol, wrt1, wrt2, doit=...) -> list[Eq | Any | Relational | Ne]: - ... - -def linodesolve_type(A, t, b=...) -> dict[Any, Any]: - ... - -def linear_ode_to_matrix(eqs, funcs, t, order) -> tuple[list[Any], Any | Matrix]: - ... - -def matrix_exp(A, t): - ... - -def matrix_exp_jordan_form(A, t) -> tuple[Matrix, Any]: - ... - -def linodesolve(A, t, b=..., B=..., type=..., doit=..., tau=...) -> list[Any]: - ... - -def canonical_odes(eqs, funcs, t) -> list[Any]: - ... - -def dsolve_system(eqs, funcs=..., t=..., ics=..., doit=..., simplify=...) -> list[Any]: - ... - +class ODEOrderError(ValueError): ... +class ODENonlinearError(NonlinearError): ... + +def simpsol(sol, wrt1, wrt2, doit=...) -> list[Eq | Any | Relational | Ne]: ... +def linodesolve_type(A, t, b=...) -> dict[Any, Any]: ... +def linear_ode_to_matrix(eqs, funcs, t, order) -> tuple[list[Any], Any | Matrix]: ... +def matrix_exp(A, t): ... +def matrix_exp_jordan_form(A, t) -> tuple[Matrix, Any]: ... +def linodesolve(A, t, b=..., B=..., type=..., doit=..., tau=...) -> list[Any]: ... +def canonical_odes(eqs, funcs, t) -> list[Any]: ... +def dsolve_system(eqs, funcs=..., t=..., ics=..., doit=..., simplify=...) -> list[Any]: ... diff --git a/stubs/sympy-stubs/solvers/pde.pyi b/stubs/sympy-stubs/solvers/pde.pyi index 15f17029..9eab656c 100644 --- a/stubs/sympy-stubs/solvers/pde.pyi +++ b/stubs/sympy-stubs/solvers/pde.pyi @@ -3,30 +3,13 @@ from typing import Any from sympy.core.relational import Eq, Ne, Relational allhints = ... -def pdsolve(eq, func=..., hint=..., dict=..., solvefun=..., **kwargs) -> dict[Any, Any] | Any: - ... - -def classify_pde(eq, func=..., dict=..., *, prep=..., **kwargs): - ... - -def checkpdesol(pde, sol, func=..., solve_for_func=...) -> Any | tuple[bool, Any]: - ... - -def pde_1st_linear_constant_coeff_homogeneous(eq, func, order, match, solvefun) -> Eq | Relational | Ne: - ... - -def pde_1st_linear_constant_coeff(eq, func, order, match, solvefun) -> Eq | Relational | Ne: - ... - -def pde_1st_linear_variable_coeff(eq, func, order, match, solvefun) -> Eq | Relational | Ne: - ... - -def pde_separate(eq, fun, sep, strategy=...) -> list[Any] | None: - ... - -def pde_separate_add(eq, fun, sep) -> list[Any] | None: - ... - -def pde_separate_mul(eq, fun, sep) -> list[Any] | None: - ... +def pdsolve(eq, func=..., hint=..., dict=..., solvefun=..., **kwargs) -> dict[Any, Any] | Any: ... +def classify_pde(eq, func=..., dict=..., *, prep=..., **kwargs): ... +def checkpdesol(pde, sol, func=..., solve_for_func=...) -> Any | tuple[bool, Any]: ... +def pde_1st_linear_constant_coeff_homogeneous(eq, func, order, match, solvefun) -> Eq | Relational | Ne: ... +def pde_1st_linear_constant_coeff(eq, func, order, match, solvefun) -> Eq | Relational | Ne: ... +def pde_1st_linear_variable_coeff(eq, func, order, match, solvefun) -> Eq | Relational | Ne: ... +def pde_separate(eq, fun, sep, strategy=...) -> list[Any] | None: ... +def pde_separate_add(eq, fun, sep) -> list[Any] | None: ... +def pde_separate_mul(eq, fun, sep) -> list[Any] | None: ... diff --git a/stubs/sympy-stubs/solvers/polysys.pyi b/stubs/sympy-stubs/solvers/polysys.pyi index b0745d43..4a8d5260 100644 --- a/stubs/sympy-stubs/solvers/polysys.pyi +++ b/stubs/sympy-stubs/solvers/polysys.pyi @@ -1,18 +1,8 @@ from typing import Any -class SolveFailed(Exception): - ... - - -def solve_poly_system(seq, *gens, strict=..., **args) -> list[tuple[Any, Any]] | list[tuple[Any]] | None: - ... - -def solve_biquadratic(f, g, opt) -> list[tuple[Any, Any]] | None: - ... - -def solve_generic(polys, opt, strict=...) -> list[tuple[Any]] | None: - ... - -def solve_triangulated(polys, *gens, **args) -> list[Any]: - ... +class SolveFailed(Exception): ... +def solve_poly_system(seq, *gens, strict=..., **args) -> list[tuple[Any, Any]] | list[tuple[Any]] | None: ... +def solve_biquadratic(f, g, opt) -> list[tuple[Any, Any]] | None: ... +def solve_generic(polys, opt, strict=...) -> list[tuple[Any]] | None: ... +def solve_triangulated(polys, *gens, **args) -> list[Any]: ... diff --git a/stubs/sympy-stubs/solvers/recurr.pyi b/stubs/sympy-stubs/solvers/recurr.pyi index 3dc206c8..70b7b655 100644 --- a/stubs/sympy-stubs/solvers/recurr.pyi +++ b/stubs/sympy-stubs/solvers/recurr.pyi @@ -1,14 +1,6 @@ from typing import Any -def rsolve_poly(coeffs, f, n, shift=..., **hints): - ... - -def rsolve_ratio(coeffs, f, n, **hints) -> tuple[Any, Any] | None: - ... - -def rsolve_hyper(coeffs, f, n, **hints): - ... - -def rsolve(f, y, init=...): - ... - +def rsolve_poly(coeffs, f, n, shift=..., **hints): ... +def rsolve_ratio(coeffs, f, n, **hints) -> tuple[Any, Any] | None: ... +def rsolve_hyper(coeffs, f, n, **hints): ... +def rsolve(f, y, init=...): ... diff --git a/stubs/sympy-stubs/solvers/solvers.pyi b/stubs/sympy-stubs/solvers/solvers.pyi index 90a904f3..9e809629 100644 --- a/stubs/sympy-stubs/solvers/solvers.pyi +++ b/stubs/sympy-stubs/solvers/solvers.pyi @@ -4,50 +4,24 @@ from sympy.matrices import Matrix from sympy.series.order import Order from sympy.utilities.decorator import conserve_mpmath_dps -def recast_to_symbols(eqs, symbols) -> tuple[list[Any], list[Any], dict[Any, Any]]: - ... - -def denoms(eq, *symbols) -> set[Any]: - ... - -def checksol(f, symbol, sol=..., **flags): - ... - -def solve(f, *symbols, **flags): - ... - -def solve_linear(lhs, rhs=..., symbols=..., exclude=...) -> tuple[Any, Any]: - ... - -def minsolve_linear_system(system, *symbols, **flags) -> dict[Any, Any] | None: - ... - -def solve_linear_system(system, *symbols, **flags) -> dict[Any, Any] | None: - ... - -def solve_undetermined_coeffs(equ, coeffs, *syms, **flags) -> tuple[list[Any], dict[Any, Any]] | list[Any] | dict[Any, Any] | None: - ... - -def solve_linear_system_LU(matrix, syms) -> dict[Any, Any]: - ... - -def det_perm(M) -> Order: - ... - -def det_minor(M): - ... - -def det_quick(M, method=...) -> Order: - ... - -def inv_quick(M): - ... +def recast_to_symbols(eqs, symbols) -> tuple[list[Any], list[Any], dict[Any, Any]]: ... +def denoms(eq, *symbols) -> set[Any]: ... +def checksol(f, symbol, sol=..., **flags): ... +def solve(f, *symbols, **flags): ... +def solve_linear(lhs, rhs=..., symbols=..., exclude=...) -> tuple[Any, Any]: ... +def minsolve_linear_system(system, *symbols, **flags) -> dict[Any, Any] | None: ... +def solve_linear_system(system, *symbols, **flags) -> dict[Any, Any] | None: ... +def solve_undetermined_coeffs( + equ, coeffs, *syms, **flags +) -> tuple[list[Any], dict[Any, Any]] | list[Any] | dict[Any, Any] | None: ... +def solve_linear_system_LU(matrix, syms) -> dict[Any, Any]: ... +def det_perm(M) -> Order: ... +def det_minor(M): ... +def det_quick(M, method=...) -> Order: ... +def inv_quick(M): ... multi_inverses = ... -@conserve_mpmath_dps -def nsolve(*args, dict=..., **kwargs) -> list[dict[Any, Any]] | Matrix: - ... - -def unrad(eq, *syms, **flags): - ... +@conserve_mpmath_dps +def nsolve(*args, dict=..., **kwargs) -> list[dict[Any, Any]] | Matrix: ... +def unrad(eq, *syms, **flags): ... diff --git a/stubs/sympy-stubs/solvers/solveset.pyi b/stubs/sympy-stubs/solvers/solveset.pyi index 71a9ed44..0cdd77ec 100644 --- a/stubs/sympy-stubs/solvers/solveset.pyi +++ b/stubs/sympy-stubs/solvers/solveset.pyi @@ -5,49 +5,27 @@ from sympy.matrices import Matrix from sympy.sets.conditionset import ConditionSet from sympy.sets.sets import Complement, FiniteSet, Intersection, Set, Union -class NonlinearError(ValueError): - ... - +class NonlinearError(ValueError): ... _rc = ... invert_complex = ... -def invert_real(f_x, y, x) -> tuple[Any, Any | FiniteSet] | tuple[Any, FiniteSet] | tuple[Any, Any | FiniteSet | Intersection | Union | Complement]: - ... - -def domain_check(f, symbol, p) -> bool | None: - ... - -class _SolveTrig1Error(Exception): - ... - - -def solve_decomposition(f, symbol, domain) -> Set | FiniteSet | Intersection | Union | Complement | ConditionSet: - ... - -def solveset(f, symbol=..., domain=...) -> Set: - ... - -def solveset_real(f, symbol) -> Set: - ... - -def solveset_complex(f, symbol) -> Set: - ... - -def solvify(f, symbol, domain) -> list[Basic] | None: - ... - -def linear_coeffs(eq, *syms, dict=...) -> list[Any]: - ... - -def linear_eq_to_matrix(equations, *symbols) -> tuple[Any, Matrix]: - ... - -def linsolve(system, *symbols) -> FiniteSet | Basic: - ... - -def substitution(system, symbols, result=..., known_symbols=..., exclude=..., all_symbols=...) -> Set | FiniteSet | Intersection | Union | Complement | ConditionSet: - ... - -def nonlinsolve(system, *symbols) -> FiniteSet | Set | Intersection | Union | Complement | ConditionSet: - ... +def invert_real( + f_x, y, x +) -> tuple[Any, Any | FiniteSet] | tuple[Any, FiniteSet] | tuple[Any, Any | FiniteSet | Intersection | Union | Complement]: ... +def domain_check(f, symbol, p) -> bool | None: ... + +class _SolveTrig1Error(Exception): ... + +def solve_decomposition(f, symbol, domain) -> Set | FiniteSet | Intersection | Union | Complement | ConditionSet: ... +def solveset(f, symbol=..., domain=...) -> Set: ... +def solveset_real(f, symbol) -> Set: ... +def solveset_complex(f, symbol) -> Set: ... +def solvify(f, symbol, domain) -> list[Basic] | None: ... +def linear_coeffs(eq, *syms, dict=...) -> list[Any]: ... +def linear_eq_to_matrix(equations, *symbols) -> tuple[Any, Matrix]: ... +def linsolve(system, *symbols) -> FiniteSet | Basic: ... +def substitution( + system, symbols, result=..., known_symbols=..., exclude=..., all_symbols=... +) -> Set | FiniteSet | Intersection | Union | Complement | ConditionSet: ... +def nonlinsolve(system, *symbols) -> FiniteSet | Set | Intersection | Union | Complement | ConditionSet: ... diff --git a/stubs/sympy-stubs/stats/__init__.pyi b/stubs/sympy-stubs/stats/__init__.pyi index dadaa703..f1a53dfb 100644 --- a/stubs/sympy-stubs/stats/__init__.pyi +++ b/stubs/sympy-stubs/stats/__init__.pyi @@ -159,4 +159,161 @@ from sympy.stats.stochastic_process_types import ( from sympy.stats.symbolic_multivariate_probability import CrossCovarianceMatrix, ExpectationMatrix, VarianceMatrix from sympy.stats.symbolic_probability import CentralMoment, Covariance, Expectation, Moment, Probability, Variance -__all__ = ['P', 'E', 'H', 'density', 'where', 'given', 'sample', 'cdf', 'median', 'characteristic_function', 'pspace', 'sample_iter', 'variance', 'std', 'skewness', 'kurtosis', 'covariance', 'dependent', 'entropy', 'independent', 'random_symbols', 'correlation', 'factorial_moment', 'moment', 'cmoment', 'sampling_density', 'moment_generating_function', 'smoment', 'quantile', 'coskewness', 'sample_stochastic_process', 'FiniteRV', 'DiscreteUniform', 'Die', 'Bernoulli', 'Coin', 'Binomial', 'BetaBinomial', 'Hypergeometric', 'Rademacher', 'IdealSoliton', 'RobustSoliton', 'FiniteDistributionHandmade', 'ContinuousRV', 'Arcsin', 'Benini', 'Beta', 'BetaNoncentral', 'BetaPrime', 'BoundedPareto', 'Cauchy', 'Chi', 'ChiNoncentral', 'ChiSquared', 'Dagum', 'Erlang', 'ExGaussian', 'Exponential', 'ExponentialPower', 'FDistribution', 'FisherZ', 'Frechet', 'Gamma', 'GammaInverse', 'Gompertz', 'Gumbel', 'Kumaraswamy', 'Laplace', 'Levy', 'Logistic', 'LogCauchy', 'LogLogistic', 'LogitNormal', 'LogNormal', 'Lomax', 'Moyal', 'Maxwell', 'Nakagami', 'Normal', 'GaussianInverse', 'Pareto', 'PowerFunction', 'QuadraticU', 'RaisedCosine', 'Rayleigh', 'Reciprocal', 'StudentT', 'ShiftedGompertz', 'Trapezoidal', 'Triangular', 'Uniform', 'UniformSum', 'VonMises', 'Wald', 'Weibull', 'WignerSemicircle', 'ContinuousDistributionHandmade', 'FlorySchulz', 'Geometric', 'Hermite', 'Logarithmic', 'NegativeBinomial', 'Poisson', 'Skellam', 'YuleSimon', 'Zeta', 'DiscreteRV', 'DiscreteDistributionHandmade', 'JointRV', 'Dirichlet', 'GeneralizedMultivariateLogGamma', 'GeneralizedMultivariateLogGammaOmega', 'Multinomial', 'MultivariateBeta', 'MultivariateEwens', 'MultivariateT', 'NegativeMultinomial', 'NormalGamma', 'MultivariateNormal', 'MultivariateLaplace', 'marginal_distribution', 'StochasticProcess', 'DiscreteTimeStochasticProcess', 'DiscreteMarkovChain', 'TransitionMatrixOf', 'StochasticStateSpaceOf', 'GeneratorMatrixOf', 'ContinuousMarkovChain', 'BernoulliProcess', 'PoissonProcess', 'WienerProcess', 'GammaProcess', 'CircularEnsemble', 'CircularUnitaryEnsemble', 'CircularOrthogonalEnsemble', 'CircularSymplecticEnsemble', 'GaussianEnsemble', 'GaussianUnitaryEnsemble', 'GaussianOrthogonalEnsemble', 'GaussianSymplecticEnsemble', 'joint_eigen_distribution', 'JointEigenDistribution', 'level_spacing_distribution', 'MatrixGamma', 'Wishart', 'MatrixNormal', 'MatrixStudentT', 'Probability', 'Expectation', 'Variance', 'Covariance', 'Moment', 'CentralMoment', 'ExpectationMatrix', 'VarianceMatrix', 'CrossCovarianceMatrix'] +__all__ = [ + "P", + "E", + "H", + "density", + "where", + "given", + "sample", + "cdf", + "median", + "characteristic_function", + "pspace", + "sample_iter", + "variance", + "std", + "skewness", + "kurtosis", + "covariance", + "dependent", + "entropy", + "independent", + "random_symbols", + "correlation", + "factorial_moment", + "moment", + "cmoment", + "sampling_density", + "moment_generating_function", + "smoment", + "quantile", + "coskewness", + "sample_stochastic_process", + "FiniteRV", + "DiscreteUniform", + "Die", + "Bernoulli", + "Coin", + "Binomial", + "BetaBinomial", + "Hypergeometric", + "Rademacher", + "IdealSoliton", + "RobustSoliton", + "FiniteDistributionHandmade", + "ContinuousRV", + "Arcsin", + "Benini", + "Beta", + "BetaNoncentral", + "BetaPrime", + "BoundedPareto", + "Cauchy", + "Chi", + "ChiNoncentral", + "ChiSquared", + "Dagum", + "Erlang", + "ExGaussian", + "Exponential", + "ExponentialPower", + "FDistribution", + "FisherZ", + "Frechet", + "Gamma", + "GammaInverse", + "Gompertz", + "Gumbel", + "Kumaraswamy", + "Laplace", + "Levy", + "Logistic", + "LogCauchy", + "LogLogistic", + "LogitNormal", + "LogNormal", + "Lomax", + "Moyal", + "Maxwell", + "Nakagami", + "Normal", + "GaussianInverse", + "Pareto", + "PowerFunction", + "QuadraticU", + "RaisedCosine", + "Rayleigh", + "Reciprocal", + "StudentT", + "ShiftedGompertz", + "Trapezoidal", + "Triangular", + "Uniform", + "UniformSum", + "VonMises", + "Wald", + "Weibull", + "WignerSemicircle", + "ContinuousDistributionHandmade", + "FlorySchulz", + "Geometric", + "Hermite", + "Logarithmic", + "NegativeBinomial", + "Poisson", + "Skellam", + "YuleSimon", + "Zeta", + "DiscreteRV", + "DiscreteDistributionHandmade", + "JointRV", + "Dirichlet", + "GeneralizedMultivariateLogGamma", + "GeneralizedMultivariateLogGammaOmega", + "Multinomial", + "MultivariateBeta", + "MultivariateEwens", + "MultivariateT", + "NegativeMultinomial", + "NormalGamma", + "MultivariateNormal", + "MultivariateLaplace", + "marginal_distribution", + "StochasticProcess", + "DiscreteTimeStochasticProcess", + "DiscreteMarkovChain", + "TransitionMatrixOf", + "StochasticStateSpaceOf", + "GeneratorMatrixOf", + "ContinuousMarkovChain", + "BernoulliProcess", + "PoissonProcess", + "WienerProcess", + "GammaProcess", + "CircularEnsemble", + "CircularUnitaryEnsemble", + "CircularOrthogonalEnsemble", + "CircularSymplecticEnsemble", + "GaussianEnsemble", + "GaussianUnitaryEnsemble", + "GaussianOrthogonalEnsemble", + "GaussianSymplecticEnsemble", + "joint_eigen_distribution", + "JointEigenDistribution", + "level_spacing_distribution", + "MatrixGamma", + "Wishart", + "MatrixNormal", + "MatrixStudentT", + "Probability", + "Expectation", + "Variance", + "Covariance", + "Moment", + "CentralMoment", + "ExpectationMatrix", + "VarianceMatrix", + "CrossCovarianceMatrix", +] diff --git a/stubs/sympy-stubs/stats/compound_rv.pyi b/stubs/sympy-stubs/stats/compound_rv.pyi index ddf1e924..3f82b2bb 100644 --- a/stubs/sympy-stubs/stats/compound_rv.pyi +++ b/stubs/sympy-stubs/stats/compound_rv.pyi @@ -11,84 +11,43 @@ from sympy.stats.rv import Distribution, NamedArgsMixin, PSpace, RandomSymbol from sympy.stats.symbolic_probability import Probability class CompoundPSpace(PSpace): - def __new__(cls, s, distribution) -> SingleContinuousPSpace | SingleDiscretePSpace | SingleFinitePSpace | Self: - ... - + def __new__(cls, s, distribution) -> SingleContinuousPSpace | SingleDiscretePSpace | SingleFinitePSpace | Self: ... @property - def value(self) -> RandomSymbol: - ... - + def value(self) -> RandomSymbol: ... @property - def symbol(self) -> Basic: - ... - + def symbol(self) -> Basic: ... @property - def is_Continuous(self): - ... - + def is_Continuous(self): ... @property - def is_Finite(self): - ... - + def is_Finite(self): ... @property - def is_Discrete(self): - ... - + def is_Discrete(self): ... @property - def distribution(self) -> Basic: - ... - + def distribution(self) -> Basic: ... @property - def pdf(self): - ... - + def pdf(self): ... @property - def set(self): - ... - + def set(self): ... @property - def domain(self) -> SingleContinuousDomain | SingleDiscreteDomain | SingleFiniteDomain: - ... - - def compute_density(self, expr, *, compound_evaluate=..., **kwargs) -> Basic | Lambda | FiniteDensity: - ... - - def compute_cdf(self, expr, *, compound_evaluate=..., **kwargs) -> Lambda | dict[Any, Any]: - ... - - def compute_expectation(self, expr, rvs=..., evaluate=..., **kwargs) -> tuple[Any, ...] | Sum | Order | Any | Piecewise | Basic | Equality | Relational | Ne | Integral | None: - ... - - def probability(self, condition, *, compound_evaluate=..., **kwargs) -> Probability | Equality | Relational | Ne | int: - ... - - def conditional_space(self, condition, *, compound_evaluate=..., **kwargs) -> ContinuousPSpace | DiscretePSpace | FinitePSpace: - ... - - + def domain(self) -> SingleContinuousDomain | SingleDiscreteDomain | SingleFiniteDomain: ... + def compute_density(self, expr, *, compound_evaluate=..., **kwargs) -> Basic | Lambda | FiniteDensity: ... + def compute_cdf(self, expr, *, compound_evaluate=..., **kwargs) -> Lambda | dict[Any, Any]: ... + def compute_expectation( + self, expr, rvs=..., evaluate=..., **kwargs + ) -> tuple[Any, ...] | Sum | Order | Any | Piecewise | Basic | Equality | Relational | Ne | Integral | None: ... + def probability(self, condition, *, compound_evaluate=..., **kwargs) -> Probability | Equality | Relational | Ne | int: ... + def conditional_space( + self, condition, *, compound_evaluate=..., **kwargs + ) -> ContinuousPSpace | DiscretePSpace | FinitePSpace: ... class CompoundDistribution(Distribution, NamedArgsMixin): - def __new__(cls, dist) -> ContinuousDistribution | SingleFiniteDistribution | DiscreteDistribution | Self: - ... - + def __new__(cls, dist) -> ContinuousDistribution | SingleFiniteDistribution | DiscreteDistribution | Self: ... @property - def set(self): - ... - + def set(self): ... @property - def is_Continuous(self) -> bool: - ... - + def is_Continuous(self) -> bool: ... @property - def is_Finite(self) -> bool: - ... - + def is_Finite(self) -> bool: ... @property - def is_Discrete(self) -> bool: - ... - - def pdf(self, x, evaluate=...) -> Basic: - ... - - - + def is_Discrete(self) -> bool: ... + def pdf(self, x, evaluate=...) -> Basic: ... diff --git a/stubs/sympy-stubs/stats/crv.pyi b/stubs/sympy-stubs/stats/crv.pyi index 0e5b0817..090d548e 100644 --- a/stubs/sympy-stubs/stats/crv.pyi +++ b/stubs/sympy-stubs/stats/crv.pyi @@ -20,162 +20,74 @@ from sympy.stats.rv import ( class ContinuousDomain(RandomDomain): is_Continuous = ... - def as_boolean(self): - ... - - + def as_boolean(self): ... class SingleContinuousDomain(ContinuousDomain, SingleDomain): - def compute_expectation(self, expr, variables=..., **kwargs) -> Equality | Relational | Ne | Integral: - ... - - def as_boolean(self): - ... - - + def compute_expectation(self, expr, variables=..., **kwargs) -> Equality | Relational | Ne | Integral: ... + def as_boolean(self): ... class ProductContinuousDomain(ProductDomain, ContinuousDomain): - def compute_expectation(self, expr, variables=..., **kwargs): - ... - - def as_boolean(self) -> And: - ... - - + def compute_expectation(self, expr, variables=..., **kwargs): ... + def as_boolean(self) -> And: ... class ConditionalContinuousDomain(ContinuousDomain, ConditionalDomain): - def compute_expectation(self, expr, variables=..., **kwargs) -> Equality | Relational | Ne | Integral: - ... - - def as_boolean(self) -> And: - ... - + def compute_expectation(self, expr, variables=..., **kwargs) -> Equality | Relational | Ne | Integral: ... + def as_boolean(self) -> And: ... @property - def set(self): - ... - - + def set(self): ... class ContinuousDistribution(Distribution): - def __call__(self, *args): - ... - - + def __call__(self, *args): ... class SingleContinuousDistribution(ContinuousDistribution, NamedArgsMixin): set = ... - def __new__(cls, *args) -> Self: - ... - + def __new__(cls, *args) -> Self: ... @staticmethod - def check(*args) -> None: - ... - + def check(*args) -> None: ... @cacheit - def compute_cdf(self, **kwargs) -> Lambda: - ... - - def cdf(self, x, **kwargs) -> Basic: - ... - + def compute_cdf(self, **kwargs) -> Lambda: ... + def cdf(self, x, **kwargs) -> Basic: ... @cacheit - def compute_characteristic_function(self, **kwargs) -> Lambda: - ... - - def characteristic_function(self, t, **kwargs) -> Basic: - ... - + def compute_characteristic_function(self, **kwargs) -> Lambda: ... + def characteristic_function(self, t, **kwargs) -> Basic: ... @cacheit - def compute_moment_generating_function(self, **kwargs) -> Lambda: - ... - - def moment_generating_function(self, t, **kwargs) -> Basic: - ... - - def expectation(self, expr, var, evaluate=..., **kwargs) -> Equality | Relational | Ne | Any | Integral | Literal[0]: - ... - + def compute_moment_generating_function(self, **kwargs) -> Lambda: ... + def moment_generating_function(self, t, **kwargs) -> Basic: ... + def expectation(self, expr, var, evaluate=..., **kwargs) -> Equality | Relational | Ne | Any | Integral | Literal[0]: ... @cacheit - def compute_quantile(self, **kwargs) -> Lambda: - ... - - def quantile(self, x, **kwargs) -> Basic: - ... - - + def compute_quantile(self, **kwargs) -> Lambda: ... + def quantile(self, x, **kwargs) -> Basic: ... class ContinuousPSpace(PSpace): is_Continuous = ... is_real = ... @property - def pdf(self): - ... - - def compute_expectation(self, expr, rvs=..., evaluate=..., **kwargs): - ... - - def compute_density(self, expr, **kwargs) -> Lambda: - ... - + def pdf(self): ... + def compute_expectation(self, expr, rvs=..., evaluate=..., **kwargs): ... + def compute_density(self, expr, **kwargs) -> Lambda: ... @cacheit - def compute_cdf(self, expr, **kwargs) -> Lambda: - ... - + def compute_cdf(self, expr, **kwargs) -> Lambda: ... @cacheit - def compute_characteristic_function(self, expr, **kwargs) -> Lambda: - ... - + def compute_characteristic_function(self, expr, **kwargs) -> Lambda: ... @cacheit - def compute_moment_generating_function(self, expr, **kwargs) -> Lambda: - ... - + def compute_moment_generating_function(self, expr, **kwargs) -> Lambda: ... @cacheit - def compute_quantile(self, expr, **kwargs) -> Lambda: - ... - - def probability(self, condition, **kwargs): - ... - - def where(self, condition) -> SingleContinuousDomain: - ... - - def conditional_space(self, condition, normalize=..., **kwargs) -> ContinuousPSpace: - ... - - + def compute_quantile(self, expr, **kwargs) -> Lambda: ... + def probability(self, condition, **kwargs): ... + def where(self, condition) -> SingleContinuousDomain: ... + def conditional_space(self, condition, normalize=..., **kwargs) -> ContinuousPSpace: ... class SingleContinuousPSpace(ContinuousPSpace, SinglePSpace): @property - def set(self): - ... - + def set(self): ... @property - def domain(self) -> SingleContinuousDomain: - ... - - def sample(self, size=..., library=..., seed=...) -> dict[RandomSymbol, Any]: - ... - - def compute_expectation(self, expr, rvs=..., evaluate=..., **kwargs) -> Equality | Relational | Ne | Integral: - ... - - def compute_cdf(self, expr, **kwargs) -> Lambda: - ... - - def compute_characteristic_function(self, expr, **kwargs) -> Lambda: - ... - - def compute_moment_generating_function(self, expr, **kwargs) -> Lambda: - ... - - def compute_density(self, expr, **kwargs) -> Basic | Lambda: - ... - - def compute_quantile(self, expr, **kwargs) -> Lambda: - ... - - - -def reduce_rational_inequalities_wrap(condition, var) -> FiniteSet | Union | None: - ... - + def domain(self) -> SingleContinuousDomain: ... + def sample(self, size=..., library=..., seed=...) -> dict[RandomSymbol, Any]: ... + def compute_expectation(self, expr, rvs=..., evaluate=..., **kwargs) -> Equality | Relational | Ne | Integral: ... + def compute_cdf(self, expr, **kwargs) -> Lambda: ... + def compute_characteristic_function(self, expr, **kwargs) -> Lambda: ... + def compute_moment_generating_function(self, expr, **kwargs) -> Lambda: ... + def compute_density(self, expr, **kwargs) -> Basic | Lambda: ... + def compute_quantile(self, expr, **kwargs) -> Lambda: ... + +def reduce_rational_inequalities_wrap(condition, var) -> FiniteSet | Union | None: ... diff --git a/stubs/sympy-stubs/stats/crv_types.pyi b/stubs/sympy-stubs/stats/crv_types.pyi index 514c7666..ed417a93 100644 --- a/stubs/sympy-stubs/stats/crv_types.pyi +++ b/stubs/sympy-stubs/stats/crv_types.pyi @@ -9,830 +9,542 @@ from sympy.stats.joint_rv import JointRandomSymbol from sympy.stats.rv import RandomSymbol, is_random oo = ... -__all__ = ['ContinuousRV', 'Arcsin', 'Benini', 'Beta', 'BetaNoncentral', 'BetaPrime', 'BoundedPareto', 'Cauchy', 'Chi', 'ChiNoncentral', 'ChiSquared', 'Dagum', 'Erlang', 'ExGaussian', 'Exponential', 'ExponentialPower', 'FDistribution', 'FisherZ', 'Frechet', 'Gamma', 'GammaInverse', 'Gompertz', 'Gumbel', 'Kumaraswamy', 'Laplace', 'Levy', 'LogCauchy', 'Logistic', 'LogLogistic', 'LogitNormal', 'LogNormal', 'Lomax', 'Maxwell', 'Moyal', 'Nakagami', 'Normal', 'GaussianInverse', 'Pareto', 'PowerFunction', 'QuadraticU', 'RaisedCosine', 'Rayleigh', 'Reciprocal', 'StudentT', 'ShiftedGompertz', 'Trapezoidal', 'Triangular', 'Uniform', 'UniformSum', 'VonMises', 'Wald', 'Weibull', 'WignerSemicircle'] -@is_random.register(MatrixBase) -def _(x) -> bool: - ... +__all__ = [ + "ContinuousRV", + "Arcsin", + "Benini", + "Beta", + "BetaNoncentral", + "BetaPrime", + "BoundedPareto", + "Cauchy", + "Chi", + "ChiNoncentral", + "ChiSquared", + "Dagum", + "Erlang", + "ExGaussian", + "Exponential", + "ExponentialPower", + "FDistribution", + "FisherZ", + "Frechet", + "Gamma", + "GammaInverse", + "Gompertz", + "Gumbel", + "Kumaraswamy", + "Laplace", + "Levy", + "LogCauchy", + "Logistic", + "LogLogistic", + "LogitNormal", + "LogNormal", + "Lomax", + "Maxwell", + "Moyal", + "Nakagami", + "Normal", + "GaussianInverse", + "Pareto", + "PowerFunction", + "QuadraticU", + "RaisedCosine", + "Rayleigh", + "Reciprocal", + "StudentT", + "ShiftedGompertz", + "Trapezoidal", + "Triangular", + "Uniform", + "UniformSum", + "VonMises", + "Wald", + "Weibull", + "WignerSemicircle", +] -def rv(symbol, cls, args, **kwargs) -> RandomSymbol: - ... +@is_random.register(MatrixBase) +def _(x) -> bool: ... +def rv(symbol, cls, args, **kwargs) -> RandomSymbol: ... class ContinuousDistributionHandmade(SingleContinuousDistribution): _argnames = ... - def __new__(cls, pdf, set=...) -> Self: - ... - + def __new__(cls, pdf, set=...) -> Self: ... @property - def set(self) -> Basic: - ... - + def set(self) -> Basic: ... @staticmethod - def check(pdf, set) -> None: - ... - + def check(pdf, set) -> None: ... - -def ContinuousRV(symbol, density, set=..., **kwargs) -> RandomSymbol: - ... +def ContinuousRV(symbol, density, set=..., **kwargs) -> RandomSymbol: ... class ArcsinDistribution(SingleContinuousDistribution): _argnames = ... @property - def set(self) -> FiniteSet | Interval: - ... - - def pdf(self, x): - ... - - + def set(self) -> FiniteSet | Interval: ... + def pdf(self, x): ... -def Arcsin(name, a=..., b=...) -> RandomSymbol: - ... +def Arcsin(name, a=..., b=...) -> RandomSymbol: ... class BeniniDistribution(SingleContinuousDistribution): _argnames = ... @staticmethod - def check(alpha, beta, sigma) -> None: - ... - + def check(alpha, beta, sigma) -> None: ... @property - def set(self) -> FiniteSet | Interval: - ... - - def pdf(self, x): - ... - + def set(self) -> FiniteSet | Interval: ... + def pdf(self, x): ... - -def Benini(name, alpha, beta, sigma) -> RandomSymbol: - ... +def Benini(name, alpha, beta, sigma) -> RandomSymbol: ... class BetaDistribution(SingleContinuousDistribution): _argnames = ... set = ... @staticmethod - def check(alpha, beta) -> None: - ... - - def pdf(self, x): - ... - - + def check(alpha, beta) -> None: ... + def pdf(self, x): ... -def Beta(name, alpha, beta) -> RandomSymbol: - ... +def Beta(name, alpha, beta) -> RandomSymbol: ... class BetaNoncentralDistribution(SingleContinuousDistribution): _argnames = ... set = ... @staticmethod - def check(alpha, beta, lamda) -> None: - ... - - def pdf(self, x) -> Equality | Relational | Ne | Sum: - ... - + def check(alpha, beta, lamda) -> None: ... + def pdf(self, x) -> Equality | Relational | Ne | Sum: ... - -def BetaNoncentral(name, alpha, beta, lamda) -> RandomSymbol: - ... +def BetaNoncentral(name, alpha, beta, lamda) -> RandomSymbol: ... class BetaPrimeDistribution(SingleContinuousDistribution): _argnames = ... @staticmethod - def check(alpha, beta) -> None: - ... - - set = ... - def pdf(self, x): - ... - + def check(alpha, beta) -> None: ... + set = ... + def pdf(self, x): ... -def BetaPrime(name, alpha, beta) -> RandomSymbol: - ... +def BetaPrime(name, alpha, beta) -> RandomSymbol: ... class BoundedParetoDistribution(SingleContinuousDistribution): _argnames = ... @property - def set(self) -> FiniteSet | Interval: - ... - + def set(self) -> FiniteSet | Interval: ... @staticmethod - def check(alpha, left, right) -> None: - ... - - def pdf(self, x): - ... - - + def check(alpha, left, right) -> None: ... + def pdf(self, x): ... -def BoundedPareto(name, alpha, left, right) -> RandomSymbol: - ... +def BoundedPareto(name, alpha, left, right) -> RandomSymbol: ... class CauchyDistribution(SingleContinuousDistribution): _argnames = ... @staticmethod - def check(x0, gamma) -> None: - ... - - def pdf(self, x): - ... - + def check(x0, gamma) -> None: ... + def pdf(self, x): ... - -def Cauchy(name, x0, gamma) -> RandomSymbol: - ... +def Cauchy(name, x0, gamma) -> RandomSymbol: ... class ChiDistribution(SingleContinuousDistribution): _argnames = ... @staticmethod - def check(k) -> None: - ... - - set = ... - def pdf(self, x): - ... - + def check(k) -> None: ... + set = ... + def pdf(self, x): ... -def Chi(name, k) -> RandomSymbol: - ... +def Chi(name, k) -> RandomSymbol: ... class ChiNoncentralDistribution(SingleContinuousDistribution): _argnames = ... @staticmethod - def check(k, l) -> None: - ... - - set = ... - def pdf(self, x): - ... - + def check(k, l) -> None: ... + set = ... + def pdf(self, x): ... -def ChiNoncentral(name, k, l) -> RandomSymbol: - ... +def ChiNoncentral(name, k, l) -> RandomSymbol: ... class ChiSquaredDistribution(SingleContinuousDistribution): _argnames = ... @staticmethod - def check(k) -> None: - ... - - set = ... - def pdf(self, x): - ... - + def check(k) -> None: ... + set = ... + def pdf(self, x): ... -def ChiSquared(name, k) -> RandomSymbol: - ... +def ChiSquared(name, k) -> RandomSymbol: ... class DagumDistribution(SingleContinuousDistribution): _argnames = ... set = ... @staticmethod - def check(p, a, b) -> None: - ... - - def pdf(self, x): - ... - - - -def Dagum(name, p, a, b) -> RandomSymbol: - ... + def check(p, a, b) -> None: ... + def pdf(self, x): ... -def Erlang(name, k, l) -> RandomSymbol: - ... +def Dagum(name, p, a, b) -> RandomSymbol: ... +def Erlang(name, k, l) -> RandomSymbol: ... class ExGaussianDistribution(SingleContinuousDistribution): _argnames = ... set = ... @staticmethod - def check(mean, std, rate) -> None: - ... - - def pdf(self, x): - ... - + def check(mean, std, rate) -> None: ... + def pdf(self, x): ... - -def ExGaussian(name, mean, std, rate) -> RandomSymbol: - ... +def ExGaussian(name, mean, std, rate) -> RandomSymbol: ... class ExponentialDistribution(SingleContinuousDistribution): _argnames = ... set = ... @staticmethod - def check(rate) -> None: - ... - - def pdf(self, x): - ... - - + def check(rate) -> None: ... + def pdf(self, x): ... -def Exponential(name, rate) -> RandomSymbol: - ... +def Exponential(name, rate) -> RandomSymbol: ... class ExponentialPowerDistribution(SingleContinuousDistribution): _argnames = ... set = ... @staticmethod - def check(mu, alpha, beta) -> None: - ... - - def pdf(self, x): - ... - + def check(mu, alpha, beta) -> None: ... + def pdf(self, x): ... - -def ExponentialPower(name, mu, alpha, beta) -> RandomSymbol: - ... +def ExponentialPower(name, mu, alpha, beta) -> RandomSymbol: ... class FDistributionDistribution(SingleContinuousDistribution): _argnames = ... set = ... @staticmethod - def check(d1, d2) -> None: - ... - - def pdf(self, x): - ... - - + def check(d1, d2) -> None: ... + def pdf(self, x): ... -def FDistribution(name, d1, d2) -> RandomSymbol: - ... +def FDistribution(name, d1, d2) -> RandomSymbol: ... class FisherZDistribution(SingleContinuousDistribution): _argnames = ... set = ... @staticmethod - def check(d1, d2) -> None: - ... - - def pdf(self, x): - ... - + def check(d1, d2) -> None: ... + def pdf(self, x): ... - -def FisherZ(name, d1, d2) -> RandomSymbol: - ... +def FisherZ(name, d1, d2) -> RandomSymbol: ... class FrechetDistribution(SingleContinuousDistribution): _argnames = ... set = ... @staticmethod - def check(a, s, m) -> None: - ... - - def __new__(cls, a, s=..., m=...) -> Self: - ... - - def pdf(self, x): - ... - - + def check(a, s, m) -> None: ... + def __new__(cls, a, s=..., m=...) -> Self: ... + def pdf(self, x): ... -def Frechet(name, a, s=..., m=...) -> RandomSymbol: - ... +def Frechet(name, a, s=..., m=...) -> RandomSymbol: ... class GammaDistribution(SingleContinuousDistribution): _argnames = ... set = ... @staticmethod - def check(k, theta) -> None: - ... - - def pdf(self, x): - ... - + def check(k, theta) -> None: ... + def pdf(self, x): ... - -def Gamma(name, k, theta) -> RandomSymbol: - ... +def Gamma(name, k, theta) -> RandomSymbol: ... class GammaInverseDistribution(SingleContinuousDistribution): _argnames = ... set = ... @staticmethod - def check(a, b) -> None: - ... - - def pdf(self, x): - ... - - + def check(a, b) -> None: ... + def pdf(self, x): ... -def GammaInverse(name, a, b) -> RandomSymbol: - ... +def GammaInverse(name, a, b) -> RandomSymbol: ... class GumbelDistribution(SingleContinuousDistribution): _argnames = ... set = ... @staticmethod - def check(beta, mu, minimum) -> None: - ... - - def pdf(self, x) -> Piecewise: - ... - + def check(beta, mu, minimum) -> None: ... + def pdf(self, x) -> Piecewise: ... - -def Gumbel(name, beta, mu, minimum=...) -> RandomSymbol: - ... +def Gumbel(name, beta, mu, minimum=...) -> RandomSymbol: ... class GompertzDistribution(SingleContinuousDistribution): _argnames = ... set = ... @staticmethod - def check(b, eta) -> None: - ... - - def pdf(self, x): - ... - - + def check(b, eta) -> None: ... + def pdf(self, x): ... -def Gompertz(name, b, eta) -> RandomSymbol: - ... +def Gompertz(name, b, eta) -> RandomSymbol: ... class KumaraswamyDistribution(SingleContinuousDistribution): _argnames = ... set = ... @staticmethod - def check(a, b) -> None: - ... - - def pdf(self, x): - ... - - + def check(a, b) -> None: ... + def pdf(self, x): ... -def Kumaraswamy(name, a, b) -> RandomSymbol: - ... +def Kumaraswamy(name, a, b) -> RandomSymbol: ... class LaplaceDistribution(SingleContinuousDistribution): _argnames = ... set = ... @staticmethod - def check(mu, b) -> None: - ... - - def pdf(self, x): - ... - + def check(mu, b) -> None: ... + def pdf(self, x): ... - -def Laplace(name, mu, b) -> RandomSymbol | JointRandomSymbol: - ... +def Laplace(name, mu, b) -> RandomSymbol | JointRandomSymbol: ... class LevyDistribution(SingleContinuousDistribution): _argnames = ... @property - def set(self) -> FiniteSet | Interval: - ... - + def set(self) -> FiniteSet | Interval: ... @staticmethod - def check(mu, c) -> None: - ... - - def pdf(self, x): - ... - - + def check(mu, c) -> None: ... + def pdf(self, x): ... -def Levy(name, mu, c) -> RandomSymbol: - ... +def Levy(name, mu, c) -> RandomSymbol: ... class LogCauchyDistribution(SingleContinuousDistribution): _argnames = ... set = ... @staticmethod - def check(mu, sigma) -> None: - ... - - def pdf(self, x): - ... - + def check(mu, sigma) -> None: ... + def pdf(self, x): ... - -def LogCauchy(name, mu, sigma) -> RandomSymbol: - ... +def LogCauchy(name, mu, sigma) -> RandomSymbol: ... class LogisticDistribution(SingleContinuousDistribution): _argnames = ... set = ... @staticmethod - def check(mu, s) -> None: - ... - - def pdf(self, x): - ... - - + def check(mu, s) -> None: ... + def pdf(self, x): ... -def Logistic(name, mu, s) -> RandomSymbol: - ... +def Logistic(name, mu, s) -> RandomSymbol: ... class LogLogisticDistribution(SingleContinuousDistribution): _argnames = ... set = ... @staticmethod - def check(alpha, beta) -> None: - ... - - def pdf(self, x): - ... - - def expectation(self, expr, var, **kwargs) -> Piecewise: - ... - + def check(alpha, beta) -> None: ... + def pdf(self, x): ... + def expectation(self, expr, var, **kwargs) -> Piecewise: ... - -def LogLogistic(name, alpha, beta) -> RandomSymbol: - ... +def LogLogistic(name, alpha, beta) -> RandomSymbol: ... class LogitNormalDistribution(SingleContinuousDistribution): _argnames = ... set = ... @staticmethod - def check(mu, s) -> None: - ... - - def pdf(self, x): - ... - - + def check(mu, s) -> None: ... + def pdf(self, x): ... -def LogitNormal(name, mu, s) -> RandomSymbol: - ... +def LogitNormal(name, mu, s) -> RandomSymbol: ... class LogNormalDistribution(SingleContinuousDistribution): _argnames = ... set = ... @staticmethod - def check(mean, std) -> None: - ... - - def pdf(self, x): - ... - + def check(mean, std) -> None: ... + def pdf(self, x): ... - -def LogNormal(name, mean, std) -> RandomSymbol: - ... +def LogNormal(name, mean, std) -> RandomSymbol: ... class LomaxDistribution(SingleContinuousDistribution): _argnames = ... set = ... @staticmethod - def check(alpha, lamda) -> None: - ... - - def pdf(self, x): - ... - - + def check(alpha, lamda) -> None: ... + def pdf(self, x): ... -def Lomax(name, alpha, lamda) -> RandomSymbol: - ... +def Lomax(name, alpha, lamda) -> RandomSymbol: ... class MaxwellDistribution(SingleContinuousDistribution): _argnames = ... set = ... @staticmethod - def check(a) -> None: - ... - - def pdf(self, x): - ... - + def check(a) -> None: ... + def pdf(self, x): ... - -def Maxwell(name, a) -> RandomSymbol: - ... +def Maxwell(name, a) -> RandomSymbol: ... class MoyalDistribution(SingleContinuousDistribution): _argnames = ... @staticmethod - def check(mu, sigma) -> None: - ... - - def pdf(self, x): - ... - - + def check(mu, sigma) -> None: ... + def pdf(self, x): ... -def Moyal(name, mu, sigma) -> RandomSymbol: - ... +def Moyal(name, mu, sigma) -> RandomSymbol: ... class NakagamiDistribution(SingleContinuousDistribution): _argnames = ... set = ... @staticmethod - def check(mu, omega) -> None: - ... - - def pdf(self, x): - ... - + def check(mu, omega) -> None: ... + def pdf(self, x): ... - -def Nakagami(name, mu, omega) -> RandomSymbol: - ... +def Nakagami(name, mu, omega) -> RandomSymbol: ... class NormalDistribution(SingleContinuousDistribution): _argnames = ... @staticmethod - def check(mean, std) -> None: - ... - - def pdf(self, x): - ... - - + def check(mean, std) -> None: ... + def pdf(self, x): ... -def Normal(name, mean, std) -> RandomSymbol | JointRandomSymbol: - ... +def Normal(name, mean, std) -> RandomSymbol | JointRandomSymbol: ... class GaussianInverseDistribution(SingleContinuousDistribution): _argnames = ... @property - def set(self) -> FiniteSet | Interval: - ... - + def set(self) -> FiniteSet | Interval: ... @staticmethod - def check(mean, shape) -> None: - ... - - def pdf(self, x): - ... - + def check(mean, shape) -> None: ... + def pdf(self, x): ... - -def GaussianInverse(name, mean, shape) -> RandomSymbol: - ... +def GaussianInverse(name, mean, shape) -> RandomSymbol: ... Wald = ... + class ParetoDistribution(SingleContinuousDistribution): _argnames = ... @property - def set(self) -> FiniteSet | Interval: - ... - + def set(self) -> FiniteSet | Interval: ... @staticmethod - def check(xm, alpha) -> None: - ... - - def pdf(self, x): - ... - - + def check(xm, alpha) -> None: ... + def pdf(self, x): ... -def Pareto(name, xm, alpha) -> RandomSymbol: - ... +def Pareto(name, xm, alpha) -> RandomSymbol: ... class PowerFunctionDistribution(SingleContinuousDistribution): _argnames = ... @property - def set(self) -> FiniteSet | Interval: - ... - + def set(self) -> FiniteSet | Interval: ... @staticmethod - def check(alpha, a, b) -> None: - ... - - def pdf(self, x): - ... - + def check(alpha, a, b) -> None: ... + def pdf(self, x): ... - -def PowerFunction(name, alpha, a, b) -> RandomSymbol: - ... +def PowerFunction(name, alpha, a, b) -> RandomSymbol: ... class QuadraticUDistribution(SingleContinuousDistribution): _argnames = ... @property - def set(self) -> FiniteSet | Interval: - ... - + def set(self) -> FiniteSet | Interval: ... @staticmethod - def check(a, b) -> None: - ... - - def pdf(self, x) -> Piecewise: - ... - - + def check(a, b) -> None: ... + def pdf(self, x) -> Piecewise: ... -def QuadraticU(name, a, b) -> RandomSymbol: - ... +def QuadraticU(name, a, b) -> RandomSymbol: ... class RaisedCosineDistribution(SingleContinuousDistribution): _argnames = ... @property - def set(self) -> FiniteSet | Interval: - ... - + def set(self) -> FiniteSet | Interval: ... @staticmethod - def check(mu, s) -> None: - ... - - def pdf(self, x) -> Piecewise: - ... - + def check(mu, s) -> None: ... + def pdf(self, x) -> Piecewise: ... - -def RaisedCosine(name, mu, s) -> RandomSymbol: - ... +def RaisedCosine(name, mu, s) -> RandomSymbol: ... class RayleighDistribution(SingleContinuousDistribution): _argnames = ... set = ... @staticmethod - def check(sigma) -> None: - ... - - def pdf(self, x): - ... - - + def check(sigma) -> None: ... + def pdf(self, x): ... -def Rayleigh(name, sigma) -> RandomSymbol: - ... +def Rayleigh(name, sigma) -> RandomSymbol: ... class ReciprocalDistribution(SingleContinuousDistribution): _argnames = ... @property - def set(self) -> FiniteSet | Interval: - ... - + def set(self) -> FiniteSet | Interval: ... @staticmethod - def check(a, b) -> None: - ... - - def pdf(self, x): - ... - + def check(a, b) -> None: ... + def pdf(self, x): ... - -def Reciprocal(name, a, b) -> RandomSymbol: - ... +def Reciprocal(name, a, b) -> RandomSymbol: ... class ShiftedGompertzDistribution(SingleContinuousDistribution): _argnames = ... set = ... @staticmethod - def check(b, eta) -> None: - ... - - def pdf(self, x): - ... - - + def check(b, eta) -> None: ... + def pdf(self, x): ... -def ShiftedGompertz(name, b, eta) -> RandomSymbol: - ... +def ShiftedGompertz(name, b, eta) -> RandomSymbol: ... class StudentTDistribution(SingleContinuousDistribution): _argnames = ... set = ... @staticmethod - def check(nu) -> None: - ... - - def pdf(self, x): - ... - + def check(nu) -> None: ... + def pdf(self, x): ... - -def StudentT(name, nu) -> RandomSymbol: - ... +def StudentT(name, nu) -> RandomSymbol: ... class TrapezoidalDistribution(SingleContinuousDistribution): _argnames = ... @property - def set(self) -> FiniteSet | Interval: - ... - + def set(self) -> FiniteSet | Interval: ... @staticmethod - def check(a, b, c, d) -> None: - ... - - def pdf(self, x) -> Piecewise: - ... - - + def check(a, b, c, d) -> None: ... + def pdf(self, x) -> Piecewise: ... -def Trapezoidal(name, a, b, c, d) -> RandomSymbol: - ... +def Trapezoidal(name, a, b, c, d) -> RandomSymbol: ... class TriangularDistribution(SingleContinuousDistribution): _argnames = ... @property - def set(self) -> FiniteSet | Interval: - ... - + def set(self) -> FiniteSet | Interval: ... @staticmethod - def check(a, b, c) -> None: - ... - - def pdf(self, x) -> Piecewise: - ... - + def check(a, b, c) -> None: ... + def pdf(self, x) -> Piecewise: ... - -def Triangular(name, a, b, c) -> RandomSymbol: - ... +def Triangular(name, a, b, c) -> RandomSymbol: ... class UniformDistribution(SingleContinuousDistribution): _argnames = ... @property - def set(self) -> FiniteSet | Interval: - ... - + def set(self) -> FiniteSet | Interval: ... @staticmethod - def check(left, right) -> None: - ... - - def pdf(self, x) -> Piecewise: - ... - - def expectation(self, expr, var, **kwargs) -> Equality | Basic | Relational | Ne | Integral | Any: - ... - - + def check(left, right) -> None: ... + def pdf(self, x) -> Piecewise: ... + def expectation(self, expr, var, **kwargs) -> Equality | Basic | Relational | Ne | Integral | Any: ... -def Uniform(name, left, right) -> RandomSymbol: - ... +def Uniform(name, left, right) -> RandomSymbol: ... class UniformSumDistribution(SingleContinuousDistribution): _argnames = ... @property - def set(self) -> FiniteSet | Interval: - ... - + def set(self) -> FiniteSet | Interval: ... @staticmethod - def check(n) -> None: - ... - - def pdf(self, x): - ... - + def check(n) -> None: ... + def pdf(self, x): ... - -def UniformSum(name, n) -> RandomSymbol: - ... +def UniformSum(name, n) -> RandomSymbol: ... class VonMisesDistribution(SingleContinuousDistribution): _argnames = ... set = ... @staticmethod - def check(mu, k) -> None: - ... - - def pdf(self, x): - ... - - + def check(mu, k) -> None: ... + def pdf(self, x): ... -def VonMises(name, mu, k) -> RandomSymbol: - ... +def VonMises(name, mu, k) -> RandomSymbol: ... class WeibullDistribution(SingleContinuousDistribution): _argnames = ... set = ... @staticmethod - def check(alpha, beta) -> None: - ... - - def pdf(self, x): - ... - + def check(alpha, beta) -> None: ... + def pdf(self, x): ... - -def Weibull(name, alpha, beta) -> RandomSymbol: - ... +def Weibull(name, alpha, beta) -> RandomSymbol: ... class WignerSemicircleDistribution(SingleContinuousDistribution): _argnames = ... @property - def set(self) -> FiniteSet | Interval: - ... - + def set(self) -> FiniteSet | Interval: ... @staticmethod - def check(R) -> None: - ... - - def pdf(self, x): - ... - - - -def WignerSemicircle(name, R) -> RandomSymbol: - ... + def check(R) -> None: ... + def pdf(self, x): ... +def WignerSemicircle(name, R) -> RandomSymbol: ... diff --git a/stubs/sympy-stubs/stats/drv.pyi b/stubs/sympy-stubs/stats/drv.pyi index 321134d7..1596330c 100644 --- a/stubs/sympy-stubs/stats/drv.pyi +++ b/stubs/sympy-stubs/stats/drv.pyi @@ -22,130 +22,61 @@ from sympy.stats.rv import ( from sympy.stats.symbolic_probability import Probability class DiscreteDistribution(Distribution): - def __call__(self, *args): - ... - - + def __call__(self, *args): ... class SingleDiscreteDistribution(DiscreteDistribution, NamedArgsMixin): set = ... - def __new__(cls, *args) -> Self: - ... - + def __new__(cls, *args) -> Self: ... @staticmethod - def check(*args) -> None: - ... - + def check(*args) -> None: ... @cacheit - def compute_cdf(self, **kwargs) -> Lambda: - ... - - def cdf(self, x, **kwargs) -> Basic: - ... - + def compute_cdf(self, **kwargs) -> Lambda: ... + def cdf(self, x, **kwargs) -> Basic: ... @cacheit - def compute_characteristic_function(self, **kwargs) -> Lambda: - ... - - def characteristic_function(self, t, **kwargs) -> Basic: - ... - + def compute_characteristic_function(self, **kwargs) -> Lambda: ... + def characteristic_function(self, t, **kwargs) -> Basic: ... @cacheit - def compute_moment_generating_function(self, **kwargs) -> Lambda: - ... - - def moment_generating_function(self, t, **kwargs) -> Basic: - ... - + def compute_moment_generating_function(self, **kwargs) -> Lambda: ... + def moment_generating_function(self, t, **kwargs) -> Basic: ... @cacheit - def compute_quantile(self, **kwargs) -> Lambda: - ... - - def quantile(self, x, **kwargs) -> Basic: - ... - - def expectation(self, expr, var, evaluate=..., **kwargs) -> Any | Equality | Relational | Ne | Sum | Literal[0]: - ... - - def __call__(self, *args): - ... - - + def compute_quantile(self, **kwargs) -> Lambda: ... + def quantile(self, x, **kwargs) -> Basic: ... + def expectation(self, expr, var, evaluate=..., **kwargs) -> Any | Equality | Relational | Ne | Sum | Literal[0]: ... + def __call__(self, *args): ... class DiscreteDomain(RandomDomain): is_Discrete = ... - class SingleDiscreteDomain(DiscreteDomain, SingleDomain): - def as_boolean(self) -> Contains: - ... - - + def as_boolean(self) -> Contains: ... class ConditionalDiscreteDomain(DiscreteDomain, ConditionalDomain): @property - def set(self) -> FiniteSet | Intersection | Union | Complement: - ... - - + def set(self) -> FiniteSet | Intersection | Union | Complement: ... class DiscretePSpace(PSpace): is_real = ... is_Discrete = ... @property - def pdf(self): - ... - - def where(self, condition) -> SingleDiscreteDomain: - ... - - def probability(self, condition) -> Probability | Equality | Relational | Ne | int: - ... - - def eval_prob(self, _domain) -> Equality | Relational | Ne | int | None: - ... - - def conditional_space(self, condition) -> DiscretePSpace: - ... - - + def pdf(self): ... + def where(self, condition) -> SingleDiscreteDomain: ... + def probability(self, condition) -> Probability | Equality | Relational | Ne | int: ... + def eval_prob(self, _domain) -> Equality | Relational | Ne | int | None: ... + def conditional_space(self, condition) -> DiscretePSpace: ... class ProductDiscreteDomain(ProductDomain, DiscreteDomain): - def as_boolean(self) -> And: - ... - - + def as_boolean(self) -> And: ... class SingleDiscretePSpace(DiscretePSpace, SinglePSpace): is_real = ... @property - def set(self): - ... - + def set(self): ... @property - def domain(self) -> SingleDiscreteDomain: - ... - - def sample(self, size=..., library=..., seed=...) -> dict[RandomSymbol, Any]: - ... - - def compute_expectation(self, expr, rvs=..., evaluate=..., **kwargs) -> Equality | Relational | Ne | Sum: - ... - - def compute_cdf(self, expr, **kwargs) -> Lambda: - ... - - def compute_density(self, expr, **kwargs) -> Basic: - ... - - def compute_characteristic_function(self, expr, **kwargs) -> Lambda: - ... - - def compute_moment_generating_function(self, expr, **kwargs) -> Lambda: - ... - - def compute_quantile(self, expr, **kwargs) -> Lambda: - ... - - - + def domain(self) -> SingleDiscreteDomain: ... + def sample(self, size=..., library=..., seed=...) -> dict[RandomSymbol, Any]: ... + def compute_expectation(self, expr, rvs=..., evaluate=..., **kwargs) -> Equality | Relational | Ne | Sum: ... + def compute_cdf(self, expr, **kwargs) -> Lambda: ... + def compute_density(self, expr, **kwargs) -> Basic: ... + def compute_characteristic_function(self, expr, **kwargs) -> Lambda: ... + def compute_moment_generating_function(self, expr, **kwargs) -> Lambda: ... + def compute_quantile(self, expr, **kwargs) -> Lambda: ... diff --git a/stubs/sympy-stubs/stats/drv_types.pyi b/stubs/sympy-stubs/stats/drv_types.pyi index 61c56c19..c2ca0106 100644 --- a/stubs/sympy-stubs/stats/drv_types.pyi +++ b/stubs/sympy-stubs/stats/drv_types.pyi @@ -4,160 +4,97 @@ from sympy import Basic from sympy.stats.drv import SingleDiscreteDistribution from sympy.stats.rv import RandomSymbol -__all__ = ['FlorySchulz', 'Geometric', 'Hermite', 'Logarithmic', 'NegativeBinomial', 'Poisson', 'Skellam', 'YuleSimon', 'Zeta'] -def rv(symbol, cls, *args, **kwargs) -> RandomSymbol: - ... +__all__ = ["FlorySchulz", "Geometric", "Hermite", "Logarithmic", "NegativeBinomial", "Poisson", "Skellam", "YuleSimon", "Zeta"] + +def rv(symbol, cls, *args, **kwargs) -> RandomSymbol: ... class DiscreteDistributionHandmade(SingleDiscreteDistribution): _argnames = ... - def __new__(cls, pdf, set=...) -> Self: - ... - + def __new__(cls, pdf, set=...) -> Self: ... @property - def set(self) -> Basic: - ... - + def set(self) -> Basic: ... @staticmethod - def check(pdf, set) -> None: - ... - - + def check(pdf, set) -> None: ... -def DiscreteRV(symbol, density, set=..., **kwargs) -> RandomSymbol: - ... +def DiscreteRV(symbol, density, set=..., **kwargs) -> RandomSymbol: ... class FlorySchulzDistribution(SingleDiscreteDistribution): _argnames = ... set = ... @staticmethod - def check(a) -> None: - ... - - def pdf(self, k): - ... - - + def check(a) -> None: ... + def pdf(self, k): ... -def FlorySchulz(name, a) -> RandomSymbol: - ... +def FlorySchulz(name, a) -> RandomSymbol: ... class GeometricDistribution(SingleDiscreteDistribution): _argnames = ... set = ... @staticmethod - def check(p) -> None: - ... - - def pdf(self, k): - ... - + def check(p) -> None: ... + def pdf(self, k): ... - -def Geometric(name, p) -> RandomSymbol: - ... +def Geometric(name, p) -> RandomSymbol: ... class HermiteDistribution(SingleDiscreteDistribution): _argnames = ... set = ... @staticmethod - def check(a1, a2) -> None: - ... - - def pdf(self, k): - ... - - + def check(a1, a2) -> None: ... + def pdf(self, k): ... -def Hermite(name, a1, a2) -> RandomSymbol: - ... +def Hermite(name, a1, a2) -> RandomSymbol: ... class LogarithmicDistribution(SingleDiscreteDistribution): _argnames = ... set = ... @staticmethod - def check(p) -> None: - ... - - def pdf(self, k): - ... - - + def check(p) -> None: ... + def pdf(self, k): ... -def Logarithmic(name, p) -> RandomSymbol: - ... +def Logarithmic(name, p) -> RandomSymbol: ... class NegativeBinomialDistribution(SingleDiscreteDistribution): _argnames = ... set = ... @staticmethod - def check(r, p) -> None: - ... - - def pdf(self, k): - ... - + def check(r, p) -> None: ... + def pdf(self, k): ... - -def NegativeBinomial(name, r, p) -> RandomSymbol: - ... +def NegativeBinomial(name, r, p) -> RandomSymbol: ... class PoissonDistribution(SingleDiscreteDistribution): _argnames = ... set = ... @staticmethod - def check(lamda) -> None: - ... - - def pdf(self, k): - ... - - + def check(lamda) -> None: ... + def pdf(self, k): ... -def Poisson(name, lamda) -> RandomSymbol: - ... +def Poisson(name, lamda) -> RandomSymbol: ... class SkellamDistribution(SingleDiscreteDistribution): _argnames = ... set = ... @staticmethod - def check(mu1, mu2) -> None: - ... - - def pdf(self, k): - ... - - + def check(mu1, mu2) -> None: ... + def pdf(self, k): ... -def Skellam(name, mu1, mu2) -> RandomSymbol: - ... +def Skellam(name, mu1, mu2) -> RandomSymbol: ... class YuleSimonDistribution(SingleDiscreteDistribution): _argnames = ... set = ... @staticmethod - def check(rho) -> None: - ... - - def pdf(self, k): - ... - + def check(rho) -> None: ... + def pdf(self, k): ... - -def YuleSimon(name, rho) -> RandomSymbol: - ... +def YuleSimon(name, rho) -> RandomSymbol: ... class ZetaDistribution(SingleDiscreteDistribution): _argnames = ... set = ... @staticmethod - def check(s) -> None: - ... - - def pdf(self, k): - ... - - - -def Zeta(name, s) -> RandomSymbol: - ... + def check(s) -> None: ... + def pdf(self, k): ... +def Zeta(name, s) -> RandomSymbol: ... diff --git a/stubs/sympy-stubs/stats/frv.pyi b/stubs/sympy-stubs/stats/frv.pyi index 90db722c..d96f719c 100644 --- a/stubs/sympy-stubs/stats/frv.pyi +++ b/stubs/sympy-stubs/stats/frv.pyi @@ -21,232 +21,111 @@ from sympy.stats.rv import ( ) class FiniteDensity(dict): - def __call__(self, item) -> Literal[0]: - ... - + def __call__(self, item) -> Literal[0]: ... @property - def dict(self) -> dict[Any, Any]: - ... - - + def dict(self) -> dict[Any, Any]: ... class FiniteDomain(RandomDomain): is_Finite = ... @property - def symbols(self) -> FiniteSet: - ... - - @property - def elements(self) -> Basic: - ... - - @property - def dict(self) -> FiniteSet: - ... - - def __contains__(self, other) -> bool: - ... - - def __iter__(self): - ... - - def as_boolean(self) -> Or: - ... - - + def symbols(self) -> FiniteSet: ... + @property + def elements(self) -> Basic: ... + @property + def dict(self) -> FiniteSet: ... + def __contains__(self, other) -> bool: ... + def __iter__(self): ... + def as_boolean(self) -> Or: ... class SingleFiniteDomain(FiniteDomain): - def __new__(cls, symbol, set) -> Self: - ... - - @property - def symbol(self) -> Basic: - ... - - @property - def symbols(self) -> FiniteSet: - ... - - @property - def set(self) -> Basic: - ... - - @property - def elements(self) -> FiniteSet: - ... - - def __iter__(self) -> Generator[frozenset[tuple[Basic, Any]], None, None]: - ... - - def __contains__(self, other) -> bool: - ... - - + def __new__(cls, symbol, set) -> Self: ... + @property + def symbol(self) -> Basic: ... + @property + def symbols(self) -> FiniteSet: ... + @property + def set(self) -> Basic: ... + @property + def elements(self) -> FiniteSet: ... + def __iter__(self) -> Generator[frozenset[tuple[Basic, Any]], None, None]: ... + def __contains__(self, other) -> bool: ... class ProductFiniteDomain(ProductDomain, FiniteDomain): - def __iter__(self) -> Generator[frozenset[Any], None, None]: - ... - + def __iter__(self) -> Generator[frozenset[Any], None, None]: ... @property - def elements(self) -> FiniteSet: - ... - - + def elements(self) -> FiniteSet: ... class ConditionalFiniteDomain(ConditionalDomain, ProductFiniteDomain): - def __new__(cls, domain, condition) -> Self: - ... - - def __contains__(self, other) -> Basic | Literal[False]: - ... - - def __iter__(self) -> Generator[Any, None, None]: - ... - - @property - def set(self) -> FiniteSet: - ... - - def as_boolean(self) -> Or: - ... - - + def __new__(cls, domain, condition) -> Self: ... + def __contains__(self, other) -> Basic | Literal[False]: ... + def __iter__(self) -> Generator[Any, None, None]: ... + @property + def set(self) -> FiniteSet: ... + def as_boolean(self) -> Or: ... class SingleFiniteDistribution(Distribution, NamedArgsMixin): - def __new__(cls, *args) -> Self: - ... - + def __new__(cls, *args) -> Self: ... @staticmethod - def check(*args) -> None: - ... - + def check(*args) -> None: ... @property @cacheit - def dict(self) -> Density | dict[Any, Any]: - ... - - def pmf(self, *args): - ... - - @property - def set(self): - ... - + def dict(self) -> Density | dict[Any, Any]: ... + def pmf(self, *args): ... + @property + def set(self): ... + values = ... items = ... is_symbolic = ... __iter__ = ... __getitem__ = ... - def __call__(self, *args): - ... - - def __contains__(self, other) -> bool: - ... - - + def __call__(self, *args): ... + def __contains__(self, other) -> bool: ... class FinitePSpace(PSpace): is_Finite = ... - def __new__(cls, domain, density) -> Self: - ... - - def prob_of(self, elem): - ... - - def where(self, condition) -> ConditionalFiniteDomain: - ... - - def compute_density(self, expr) -> FiniteDensity: - ... - + def __new__(cls, domain, density) -> Self: ... + def prob_of(self, elem): ... + def where(self, condition) -> ConditionalFiniteDomain: ... + def compute_density(self, expr) -> FiniteDensity: ... @cacheit - def compute_cdf(self, expr) -> dict[Any, Any]: - ... - + def compute_cdf(self, expr) -> dict[Any, Any]: ... @cacheit - def sorted_cdf(self, expr, python_float=...) -> list[tuple[Any, float]] | list[tuple[Any, Any]]: - ... - + def sorted_cdf(self, expr, python_float=...) -> list[tuple[Any, float]] | list[tuple[Any, Any]]: ... @cacheit - def compute_characteristic_function(self, expr) -> Lambda: - ... - + def compute_characteristic_function(self, expr) -> Lambda: ... @cacheit - def compute_moment_generating_function(self, expr) -> Lambda: - ... - - def compute_expectation(self, expr, rvs=..., **kwargs): - ... - - def compute_quantile(self, expr) -> Lambda: - ... - - def probability(self, condition): - ... - - def conditional_space(self, condition) -> FinitePSpace: - ... - - def sample(self, size=..., library=..., seed=...) -> dict[Any, Any]: - ... - - + def compute_moment_generating_function(self, expr) -> Lambda: ... + def compute_expectation(self, expr, rvs=..., **kwargs): ... + def compute_quantile(self, expr) -> Lambda: ... + def probability(self, condition): ... + def conditional_space(self, condition) -> FinitePSpace: ... + def sample(self, size=..., library=..., seed=...) -> dict[Any, Any]: ... class SingleFinitePSpace(SinglePSpace, FinitePSpace): @property - def domain(self) -> SingleFiniteDomain: - ... - + def domain(self) -> SingleFiniteDomain: ... @property - def distribution(self) -> Basic: - ... - - def pmf(self, expr): - ... - + def distribution(self) -> Basic: ... + def pmf(self, expr): ... @cacheit - def compute_characteristic_function(self, expr) -> Lambda: - ... - + def compute_characteristic_function(self, expr) -> Lambda: ... @cacheit - def compute_moment_generating_function(self, expr) -> Lambda: - ... - - def compute_quantile(self, expr) -> Lambda: - ... - - def compute_density(self, expr) -> Lambda | FiniteDensity: - ... - - def compute_cdf(self, expr) -> Lambda | dict[Any, Any]: - ... - - def compute_expectation(self, expr, rvs=..., **kwargs) -> tuple[Any, ...] | Sum | Order | Any | Piecewise | Basic | Equality | Relational | Ne | None: - ... - - def probability(self, condition): - ... - - def conditional_space(self, condition) -> FinitePSpace: - ... - - + def compute_moment_generating_function(self, expr) -> Lambda: ... + def compute_quantile(self, expr) -> Lambda: ... + def compute_density(self, expr) -> Lambda | FiniteDensity: ... + def compute_cdf(self, expr) -> Lambda | dict[Any, Any]: ... + def compute_expectation( + self, expr, rvs=..., **kwargs + ) -> tuple[Any, ...] | Sum | Order | Any | Piecewise | Basic | Equality | Relational | Ne | None: ... + def probability(self, condition): ... + def conditional_space(self, condition) -> FinitePSpace: ... class ProductFinitePSpace(IndependentProductPSpace, FinitePSpace): @property - def domain(self) -> ProductDiscreteDomain | ProductContinuousDomain | ProductFiniteDomain: - ... - + def domain(self) -> ProductDiscreteDomain | ProductContinuousDomain | ProductFiniteDomain: ... @property @cacheit - def density(self) -> Dict: - ... - - def probability(self, condition): - ... - - def compute_density(self, expr) -> FiniteDensity: - ... - - - + def density(self) -> Dict: ... + def probability(self, condition): ... + def compute_density(self, expr) -> FiniteDensity: ... diff --git a/stubs/sympy-stubs/stats/frv_types.pyi b/stubs/sympy-stubs/stats/frv_types.pyi index 001eba27..938ee01b 100644 --- a/stubs/sympy-stubs/stats/frv_types.pyi +++ b/stubs/sympy-stubs/stats/frv_types.pyi @@ -8,283 +8,166 @@ from sympy.sets.sets import Complement, Union from sympy.stats.frv import SingleFiniteDistribution from sympy.stats.rv import Density, RandomSymbol -__all__ = ['FiniteRV', 'DiscreteUniform', 'Die', 'Bernoulli', 'Coin', 'Binomial', 'BetaBinomial', 'Hypergeometric', 'Rademacher', 'IdealSoliton', 'RobustSoliton'] -def rv(name, cls, *args, **kwargs) -> RandomSymbol: - ... +__all__ = [ + "FiniteRV", + "DiscreteUniform", + "Die", + "Bernoulli", + "Coin", + "Binomial", + "BetaBinomial", + "Hypergeometric", + "Rademacher", + "IdealSoliton", + "RobustSoliton", +] + +def rv(name, cls, *args, **kwargs) -> RandomSymbol: ... class FiniteDistributionHandmade(SingleFiniteDistribution): @property - def dict(self) -> Basic: - ... - - def pmf(self, x) -> Lambda: - ... - + def dict(self) -> Basic: ... + def pmf(self, x) -> Lambda: ... @property - def set(self) -> set[Any]: - ... - + def set(self) -> set[Any]: ... @staticmethod - def check(density) -> None: - ... - + def check(density) -> None: ... - -def FiniteRV(name, density, **kwargs) -> RandomSymbol: - ... +def FiniteRV(name, density, **kwargs) -> RandomSymbol: ... class DiscreteUniformDistribution(SingleFiniteDistribution): @staticmethod - def check(*args) -> None: - ... - + def check(*args) -> None: ... @property - def p(self) -> Rational | Integer: - ... - + def p(self) -> Rational | Integer: ... @property @cacheit - def dict(self) -> dict[Basic, Rational | Any | Integer]: - ... - - @property - def set(self) -> set[Basic]: - ... - - def pmf(self, x) -> Rational | Integer: - ... - - + def dict(self) -> dict[Basic, Rational | Any | Integer]: ... + @property + def set(self) -> set[Basic]: ... + def pmf(self, x) -> Rational | Integer: ... -def DiscreteUniform(name, items) -> RandomSymbol: - ... +def DiscreteUniform(name, items) -> RandomSymbol: ... class DieDistribution(SingleFiniteDistribution): _argnames = ... @staticmethod - def check(sides) -> None: - ... - - @property - def is_symbolic(self) -> bool: - ... - - @property - def high(self): - ... - - @property - def low(self): - ... - - @property - def set(self) -> FiniteSet | Intersection | Union | Complement | set[Any | Integer]: - ... - - def pmf(self, x) -> Piecewise: - ... - - + def check(sides) -> None: ... + @property + def is_symbolic(self) -> bool: ... + @property + def high(self): ... + @property + def low(self): ... + @property + def set(self) -> FiniteSet | Intersection | Union | Complement | set[Any | Integer]: ... + def pmf(self, x) -> Piecewise: ... -def Die(name, sides=...) -> RandomSymbol: - ... +def Die(name, sides=...) -> RandomSymbol: ... class BernoulliDistribution(SingleFiniteDistribution): _argnames = ... @staticmethod - def check(p, succ, fail) -> None: - ... - - @property - def set(self) -> set[Any]: - ... - - def pmf(self, x) -> Piecewise: - ... - - - -def Bernoulli(name, p, succ=..., fail=...) -> RandomSymbol: - ... + def check(p, succ, fail) -> None: ... + @property + def set(self) -> set[Any]: ... + def pmf(self, x) -> Piecewise: ... -def Coin(name, p=...) -> RandomSymbol: - ... +def Bernoulli(name, p, succ=..., fail=...) -> RandomSymbol: ... +def Coin(name, p=...) -> RandomSymbol: ... class BinomialDistribution(SingleFiniteDistribution): _argnames = ... @staticmethod - def check(n, p, succ, fail) -> None: - ... - + def check(n, p, succ, fail) -> None: ... @property - def high(self): - ... - + def high(self): ... @property - def low(self): - ... - + def low(self): ... @property - def is_symbolic(self) -> bool: - ... - + def is_symbolic(self) -> bool: ... @property - def set(self) -> FiniteSet | Intersection | Union | Complement | set[Any]: - ... - - def pmf(self, x) -> Piecewise: - ... - + def set(self) -> FiniteSet | Intersection | Union | Complement | set[Any]: ... + def pmf(self, x) -> Piecewise: ... @property @cacheit - def dict(self) -> Density | dict[Any, Any | Piecewise]: - ... - - + def dict(self) -> Density | dict[Any, Any | Piecewise]: ... -def Binomial(name, n, p, succ=..., fail=...) -> RandomSymbol: - ... +def Binomial(name, n, p, succ=..., fail=...) -> RandomSymbol: ... class BetaBinomialDistribution(SingleFiniteDistribution): _argnames = ... @staticmethod - def check(n, alpha, beta) -> None: - ... - - @property - def high(self): - ... - - @property - def low(self): - ... - - @property - def is_symbolic(self) -> bool: - ... - - @property - def set(self) -> FiniteSet | Intersection | Union | Complement | set[Any | Integer]: - ... - - def pmf(self, k): - ... - - + def check(n, alpha, beta) -> None: ... + @property + def high(self): ... + @property + def low(self): ... + @property + def is_symbolic(self) -> bool: ... + @property + def set(self) -> FiniteSet | Intersection | Union | Complement | set[Any | Integer]: ... + def pmf(self, k): ... -def BetaBinomial(name, n, alpha, beta) -> RandomSymbol: - ... +def BetaBinomial(name, n, alpha, beta) -> RandomSymbol: ... class HypergeometricDistribution(SingleFiniteDistribution): _argnames = ... @staticmethod - def check(n, N, m) -> None: - ... - - @property - def is_symbolic(self) -> bool: - ... - - @property - def high(self) -> Piecewise: - ... - - @property - def low(self) -> Piecewise: - ... - - @property - def set(self) -> FiniteSet | Intersection | Union | Complement | set[int]: - ... - - def pmf(self, k): - ... - - + def check(n, N, m) -> None: ... + @property + def is_symbolic(self) -> bool: ... + @property + def high(self) -> Piecewise: ... + @property + def low(self) -> Piecewise: ... + @property + def set(self) -> FiniteSet | Intersection | Union | Complement | set[int]: ... + def pmf(self, k): ... -def Hypergeometric(name, N, m, n) -> RandomSymbol: - ... +def Hypergeometric(name, N, m, n) -> RandomSymbol: ... class RademacherDistribution(SingleFiniteDistribution): @property - def set(self) -> set[int]: - ... - + def set(self) -> set[int]: ... @property - def pmf(self) -> Lambda: - ... - + def pmf(self) -> Lambda: ... - -def Rademacher(name) -> RandomSymbol: - ... +def Rademacher(name) -> RandomSymbol: ... class IdealSolitonDistribution(SingleFiniteDistribution): _argnames = ... @staticmethod - def check(k) -> None: - ... - + def check(k) -> None: ... @property - def low(self): - ... - + def low(self): ... @property - def high(self): - ... - + def high(self): ... @property - def set(self) -> set[Any | Integer]: - ... - + def set(self) -> set[Any | Integer]: ... @property @cacheit - def dict(self) -> Density | dict[int, Rational | Any | Integer]: - ... - - def pmf(self, x) -> Piecewise: - ... - - + def dict(self) -> Density | dict[int, Rational | Any | Integer]: ... + def pmf(self, x) -> Piecewise: ... -def IdealSoliton(name, k) -> RandomSymbol: - ... +def IdealSoliton(name, k) -> RandomSymbol: ... class RobustSolitonDistribution(SingleFiniteDistribution): _argnames = ... @staticmethod - def check(k, delta, c) -> None: - ... - - @property - def R(self): - ... - - @property - def Z(self): - ... - - @property - def low(self): - ... - - @property - def high(self): - ... - - @property - def set(self) -> set[Any | Integer]: - ... - - @property - def is_symbolic(self) -> bool: - ... - - def pmf(self, x): - ... - - - -def RobustSoliton(name, k, delta, c) -> RandomSymbol: - ... + def check(k, delta, c) -> None: ... + @property + def R(self): ... + @property + def Z(self): ... + @property + def low(self): ... + @property + def high(self): ... + @property + def set(self) -> set[Any | Integer]: ... + @property + def is_symbolic(self) -> bool: ... + def pmf(self, x): ... +def RobustSoliton(name, k, delta, c) -> RandomSymbol: ... diff --git a/stubs/sympy-stubs/stats/joint_rv.pyi b/stubs/sympy-stubs/stats/joint_rv.pyi index 17d3f2d1..27203389 100644 --- a/stubs/sympy-stubs/stats/joint_rv.pyi +++ b/stubs/sympy-stubs/stats/joint_rv.pyi @@ -10,135 +10,62 @@ from sympy.stats.frv import ProductFiniteDomain from sympy.stats.rv import Distribution, NamedArgsMixin, ProductDomain, ProductPSpace, RandomSymbol, SingleDomain class JointPSpace(ProductPSpace): - def __new__(cls, sym, dist) -> SingleContinuousPSpace | SingleDiscretePSpace | Self: - ... - + def __new__(cls, sym, dist) -> SingleContinuousPSpace | SingleDiscretePSpace | Self: ... @property - def set(self) -> Basic | FiniteSet | ProductSet: - ... - + def set(self) -> Basic | FiniteSet | ProductSet: ... @property - def symbol(self) -> Basic: - ... - + def symbol(self) -> Basic: ... @property - def distribution(self) -> Basic: - ... - + def distribution(self) -> Basic: ... @property - def value(self) -> RandomSymbol | JointRandomSymbol: - ... - + def value(self) -> RandomSymbol | JointRandomSymbol: ... @property - def component_count(self) -> Expr: - ... - + def component_count(self) -> Expr: ... @property - def pdf(self): - ... - + def pdf(self): ... @property - def domain(self) -> SingleDomain | ProductDiscreteDomain | ProductContinuousDomain | ProductFiniteDomain | ProductDomain: - ... - - def component_domain(self, index): - ... - - def marginal_distribution(self, *indices) -> Lambda: - ... - - def compute_expectation(self, expr, rvs=..., evaluate=..., **kwargs) -> Equality | Relational | Ne | Integral: - ... - - def where(self, condition): - ... - - def compute_density(self, expr): - ... - - def sample(self, size=..., library=..., seed=...) -> dict[RandomSymbol, Any]: - ... - - def probability(self, condition): - ... - - + def domain(self) -> SingleDomain | ProductDiscreteDomain | ProductContinuousDomain | ProductFiniteDomain | ProductDomain: ... + def component_domain(self, index): ... + def marginal_distribution(self, *indices) -> Lambda: ... + def compute_expectation(self, expr, rvs=..., evaluate=..., **kwargs) -> Equality | Relational | Ne | Integral: ... + def where(self, condition): ... + def compute_density(self, expr): ... + def sample(self, size=..., library=..., seed=...) -> dict[RandomSymbol, Any]: ... + def probability(self, condition): ... class SampleJointScipy: - def __new__(cls, dist, size, seed=...) -> None: - ... - - + def __new__(cls, dist, size, seed=...) -> None: ... class SampleJointNumpy: - def __new__(cls, dist, size, seed=...) -> None: - ... - - + def __new__(cls, dist, size, seed=...) -> None: ... class SampleJointPymc: - def __new__(cls, dist, size, seed=...) -> None: - ... - - + def __new__(cls, dist, size, seed=...) -> None: ... _get_sample_class_jrv = ... + class JointDistribution(Distribution, NamedArgsMixin): _argnames = ... - def __new__(cls, *args) -> Self: - ... - + def __new__(cls, *args) -> Self: ... @property - def domain(self) -> ProductDiscreteDomain | ProductContinuousDomain | ProductFiniteDomain | ProductDomain: - ... - + def domain(self) -> ProductDiscreteDomain | ProductContinuousDomain | ProductFiniteDomain | ProductDomain: ... @property - def pdf(self): - ... - - def cdf(self, other) -> Equality | Relational | Ne | Integral | Sum: - ... - - def sample(self, size=..., library=..., seed=...): - ... - - def __call__(self, *args): - ... - - + def pdf(self): ... + def cdf(self, other) -> Equality | Relational | Ne | Integral | Sum: ... + def sample(self, size=..., library=..., seed=...): ... + def __call__(self, *args): ... class JointRandomSymbol(RandomSymbol): - def __getitem__(self, key) -> Indexed | None: - ... - - + def __getitem__(self, key) -> Indexed | None: ... class MarginalDistribution(Distribution): - def __new__(cls, dist, *rvs) -> Self: - ... - - def check(self) -> None: - ... - + def __new__(cls, dist, *rvs) -> Self: ... + def check(self) -> None: ... @property - def set(self) -> FiniteSet | ProductSet: - ... - + def set(self) -> FiniteSet | ProductSet: ... @property - def symbols(self) -> set[Any]: - ... - - def pdf(self, *x) -> Basic: - ... - - def compute_pdf(self, expr, rvs) -> Equality | Relational | Ne | Integral | Sum: - ... - - def marginalise_out(self, expr, rv) -> Equality | Relational | Ne | Integral | Sum: - ... - - def __call__(self, *args) -> Basic: - ... - - - + def symbols(self) -> set[Any]: ... + def pdf(self, *x) -> Basic: ... + def compute_pdf(self, expr, rvs) -> Equality | Relational | Ne | Integral | Sum: ... + def marginalise_out(self, expr, rv) -> Equality | Relational | Ne | Integral | Sum: ... + def __call__(self, *args) -> Basic: ... diff --git a/stubs/sympy-stubs/stats/joint_rv_types.pyi b/stubs/sympy-stubs/stats/joint_rv_types.pyi index c9993cdc..d71a8bda 100644 --- a/stubs/sympy-stubs/stats/joint_rv_types.pyi +++ b/stubs/sympy-stubs/stats/joint_rv_types.pyi @@ -4,199 +4,132 @@ from sympy.matrices.expressions.matexpr import MatrixElement from sympy.stats.joint_rv import JointDistribution, JointRandomSymbol from sympy.stats.rv import RandomSymbol -__all__ = ['JointRV', 'MultivariateNormal', 'MultivariateLaplace', 'Dirichlet', 'GeneralizedMultivariateLogGamma', 'GeneralizedMultivariateLogGammaOmega', 'Multinomial', 'MultivariateBeta', 'MultivariateEwens', 'MultivariateT', 'NegativeMultinomial', 'NormalGamma'] -def multivariate_rv(cls, sym, *args) -> RandomSymbol | JointRandomSymbol: - ... - -def marginal_distribution(rv, *indices): - ... +__all__ = [ + "JointRV", + "MultivariateNormal", + "MultivariateLaplace", + "Dirichlet", + "GeneralizedMultivariateLogGamma", + "GeneralizedMultivariateLogGammaOmega", + "Multinomial", + "MultivariateBeta", + "MultivariateEwens", + "MultivariateT", + "NegativeMultinomial", + "NormalGamma", +] + +def multivariate_rv(cls, sym, *args) -> RandomSymbol | JointRandomSymbol: ... +def marginal_distribution(rv, *indices): ... class JointDistributionHandmade(JointDistribution): _argnames = ... is_Continuous = ... @property - def set(self) -> Basic: - ... - - + def set(self) -> Basic: ... -def JointRV(symbol, pdf, _set=...) -> RandomSymbol | JointRandomSymbol: - ... +def JointRV(symbol, pdf, _set=...) -> RandomSymbol | JointRandomSymbol: ... class MultivariateNormalDistribution(JointDistribution): _argnames = ... is_Continuous = ... @property - def set(self): - ... - + def set(self): ... @staticmethod - def check(mu, sigma) -> None: - ... - - def pdf(self, *args) -> MatrixElement: - ... - + def check(mu, sigma) -> None: ... + def pdf(self, *args) -> MatrixElement: ... - -def MultivariateNormal(name, mu, sigma) -> RandomSymbol | JointRandomSymbol: - ... +def MultivariateNormal(name, mu, sigma) -> RandomSymbol | JointRandomSymbol: ... class MultivariateLaplaceDistribution(JointDistribution): _argnames = ... is_Continuous = ... @property - def set(self): - ... - + def set(self): ... @staticmethod - def check(mu, sigma) -> None: - ... - - def pdf(self, *args): - ... - - + def check(mu, sigma) -> None: ... + def pdf(self, *args): ... -def MultivariateLaplace(name, mu, sigma) -> RandomSymbol | JointRandomSymbol: - ... +def MultivariateLaplace(name, mu, sigma) -> RandomSymbol | JointRandomSymbol: ... class MultivariateTDistribution(JointDistribution): _argnames = ... is_Continuous = ... @property - def set(self): - ... - + def set(self): ... @staticmethod - def check(mu, sigma, v) -> None: - ... - - def pdf(self, *args): - ... - + def check(mu, sigma, v) -> None: ... + def pdf(self, *args): ... - -def MultivariateT(syms, mu, sigma, v) -> RandomSymbol | JointRandomSymbol: - ... +def MultivariateT(syms, mu, sigma, v) -> RandomSymbol | JointRandomSymbol: ... class NormalGammaDistribution(JointDistribution): _argnames = ... is_Continuous = ... @staticmethod - def check(mu, lamda, alpha, beta) -> None: - ... - + def check(mu, lamda, alpha, beta) -> None: ... @property - def set(self): - ... - - def pdf(self, x, tau): - ... - - + def set(self): ... + def pdf(self, x, tau): ... -def NormalGamma(sym, mu, lamda, alpha, beta) -> RandomSymbol | JointRandomSymbol: - ... +def NormalGamma(sym, mu, lamda, alpha, beta) -> RandomSymbol | JointRandomSymbol: ... class MultivariateBetaDistribution(JointDistribution): _argnames = ... is_Continuous = ... @staticmethod - def check(alpha) -> None: - ... - + def check(alpha) -> None: ... @property - def set(self): - ... - - def pdf(self, *syms): - ... - - + def set(self): ... + def pdf(self, *syms): ... -def MultivariateBeta(syms, *alpha) -> RandomSymbol | JointRandomSymbol: - ... +def MultivariateBeta(syms, *alpha) -> RandomSymbol | JointRandomSymbol: ... Dirichlet = ... + class MultivariateEwensDistribution(JointDistribution): _argnames = ... is_Discrete = ... is_Continuous = ... @staticmethod - def check(n, theta) -> None: - ... - + def check(n, theta) -> None: ... @property - def set(self) -> Equality | Relational | Ne | Product: - ... - - def pdf(self, *syms) -> Piecewise: - ... - - + def set(self) -> Equality | Relational | Ne | Product: ... + def pdf(self, *syms) -> Piecewise: ... -def MultivariateEwens(syms, n, theta) -> RandomSymbol | JointRandomSymbol: - ... +def MultivariateEwens(syms, n, theta) -> RandomSymbol | JointRandomSymbol: ... class GeneralizedMultivariateLogGammaDistribution(JointDistribution): _argnames = ... is_Continuous = ... - def check(self, delta, v, l, mu) -> None: - ... - + def check(self, delta, v, l, mu) -> None: ... @property - def set(self): - ... - - def pdf(self, *y): - ... - - - -def GeneralizedMultivariateLogGamma(syms, delta, v, lamda, mu) -> RandomSymbol | JointRandomSymbol: - ... + def set(self): ... + def pdf(self, *y): ... -def GeneralizedMultivariateLogGammaOmega(syms, omega, v, lamda, mu) -> RandomSymbol | JointRandomSymbol: - ... +def GeneralizedMultivariateLogGamma(syms, delta, v, lamda, mu) -> RandomSymbol | JointRandomSymbol: ... +def GeneralizedMultivariateLogGammaOmega(syms, omega, v, lamda, mu) -> RandomSymbol | JointRandomSymbol: ... class MultinomialDistribution(JointDistribution): _argnames = ... is_Continuous = ... is_Discrete = ... @staticmethod - def check(n, p) -> None: - ... - + def check(n, p) -> None: ... @property - def set(self): - ... - - def pdf(self, *x) -> Piecewise: - ... - + def set(self): ... + def pdf(self, *x) -> Piecewise: ... - -def Multinomial(syms, n, *p) -> RandomSymbol | JointRandomSymbol: - ... +def Multinomial(syms, n, *p) -> RandomSymbol | JointRandomSymbol: ... class NegativeMultinomialDistribution(JointDistribution): _argnames = ... is_Continuous = ... is_Discrete = ... @staticmethod - def check(k0, p) -> None: - ... - + def check(k0, p) -> None: ... @property - def set(self): - ... - - def pdf(self, *k): - ... - - - -def NegativeMultinomial(syms, k0, *p) -> RandomSymbol | JointRandomSymbol: - ... + def set(self): ... + def pdf(self, *k): ... +def NegativeMultinomial(syms, k0, *p) -> RandomSymbol | JointRandomSymbol: ... diff --git a/stubs/sympy-stubs/stats/matrix_distributions.pyi b/stubs/sympy-stubs/stats/matrix_distributions.pyi index 15795e2e..a79006ec 100644 --- a/stubs/sympy-stubs/stats/matrix_distributions.pyi +++ b/stubs/sympy-stubs/stats/matrix_distributions.pyi @@ -4,154 +4,83 @@ from sympy.matrices.expressions.sets import MatrixSet from sympy.stats.rv import Distribution, MatrixDomain, NamedArgsMixin, PSpace, RandomMatrixSymbol class MatrixPSpace(PSpace): - def __new__(cls, sym, distribution, dim_n, dim_m) -> Self: - ... - + def __new__(cls, sym, distribution, dim_n, dim_m) -> Self: ... + distribution = ... symbol = ... @property - def domain(self) -> MatrixDomain: - ... - + def domain(self) -> MatrixDomain: ... @property - def value(self) -> RandomMatrixSymbol: - ... - + def value(self) -> RandomMatrixSymbol: ... @property - def values(self) -> set[RandomMatrixSymbol]: - ... - - def compute_density(self, expr, *args) -> Any: - ... - - def sample(self, size=..., library=..., seed=...) -> dict[RandomMatrixSymbol, Any]: - ... - - + def values(self) -> set[RandomMatrixSymbol]: ... + def compute_density(self, expr, *args) -> Any: ... + def sample(self, size=..., library=..., seed=...) -> dict[RandomMatrixSymbol, Any]: ... -def rv(symbol, cls, args) -> RandomMatrixSymbol: - ... +def rv(symbol, cls, args) -> RandomMatrixSymbol: ... class SampleMatrixScipy: - def __new__(cls, dist, size, seed=...) -> None: - ... - - + def __new__(cls, dist, size, seed=...) -> None: ... class SampleMatrixNumpy: - def __new__(cls, dist, size, seed=...) -> None: - ... - - + def __new__(cls, dist, size, seed=...) -> None: ... class SampleMatrixPymc: - def __new__(cls, dist, size, seed=...) -> None: - ... - - + def __new__(cls, dist, size, seed=...) -> None: ... _get_sample_class_matrixrv = ... + class MatrixDistribution(Distribution, NamedArgsMixin): - def __new__(cls, *args) -> Self: - ... - + def __new__(cls, *args) -> Self: ... @staticmethod - def check(*args) -> None: - ... - - def __call__(self, expr): - ... - - def sample(self, size=..., library=..., seed=...): - ... - - + def check(*args) -> None: ... + def __call__(self, expr): ... + def sample(self, size=..., library=..., seed=...): ... class MatrixGammaDistribution(MatrixDistribution): _argnames = ... @staticmethod - def check(alpha, beta, scale_matrix) -> None: - ... - + def check(alpha, beta, scale_matrix) -> None: ... @property - def set(self) -> MatrixSet: - ... - + def set(self) -> MatrixSet: ... @property - def dimension(self): - ... - - def pdf(self, x): - ... - - + def dimension(self): ... + def pdf(self, x): ... -def MatrixGamma(symbol, alpha, beta, scale_matrix) -> RandomMatrixSymbol: - ... +def MatrixGamma(symbol, alpha, beta, scale_matrix) -> RandomMatrixSymbol: ... class WishartDistribution(MatrixDistribution): _argnames = ... @staticmethod - def check(n, scale_matrix) -> None: - ... - + def check(n, scale_matrix) -> None: ... @property - def set(self) -> MatrixSet: - ... - + def set(self) -> MatrixSet: ... @property - def dimension(self): - ... - - def pdf(self, x): - ... - - + def dimension(self): ... + def pdf(self, x): ... -def Wishart(symbol, n, scale_matrix) -> RandomMatrixSymbol: - ... +def Wishart(symbol, n, scale_matrix) -> RandomMatrixSymbol: ... class MatrixNormalDistribution(MatrixDistribution): _argnames = ... @staticmethod - def check(location_matrix, scale_matrix_1, scale_matrix_2) -> None: - ... - + def check(location_matrix, scale_matrix_1, scale_matrix_2) -> None: ... @property - def set(self) -> MatrixSet: - ... - + def set(self) -> MatrixSet: ... @property - def dimension(self): - ... - - def pdf(self, x): - ... - + def dimension(self): ... + def pdf(self, x): ... - -def MatrixNormal(symbol, location_matrix, scale_matrix_1, scale_matrix_2) -> RandomMatrixSymbol: - ... +def MatrixNormal(symbol, location_matrix, scale_matrix_1, scale_matrix_2) -> RandomMatrixSymbol: ... class MatrixStudentTDistribution(MatrixDistribution): _argnames = ... @staticmethod - def check(nu, location_matrix, scale_matrix_1, scale_matrix_2) -> None: - ... - + def check(nu, location_matrix, scale_matrix_1, scale_matrix_2) -> None: ... @property - def set(self) -> MatrixSet: - ... - + def set(self) -> MatrixSet: ... @property - def dimension(self): - ... - - def pdf(self, x): - ... - - - -def MatrixStudentT(symbol, nu, location_matrix, scale_matrix_1, scale_matrix_2) -> RandomMatrixSymbol: - ... + def dimension(self): ... + def pdf(self, x): ... +def MatrixStudentT(symbol, nu, location_matrix, scale_matrix_1, scale_matrix_2) -> RandomMatrixSymbol: ... diff --git a/stubs/sympy-stubs/stats/random_matrix.pyi b/stubs/sympy-stubs/stats/random_matrix.pyi index 5302f896..3843105a 100644 --- a/stubs/sympy-stubs/stats/random_matrix.pyi +++ b/stubs/sympy-stubs/stats/random_matrix.pyi @@ -4,15 +4,7 @@ from sympy import Basic from sympy.stats.rv import PSpace class RandomMatrixPSpace(PSpace): - def __new__(cls, sym, model=...) -> Self: - ... - + def __new__(cls, sym, model=...) -> Self: ... @property - def model(self) -> Basic | None: - ... - - def compute_density(self, expr, *args): - ... - - - + def model(self) -> Basic | None: ... + def compute_density(self, expr, *args): ... diff --git a/stubs/sympy-stubs/stats/random_matrix_models.pyi b/stubs/sympy-stubs/stats/random_matrix_models.pyi index 2b03d71d..7965fd1e 100644 --- a/stubs/sympy-stubs/stats/random_matrix_models.pyi +++ b/stubs/sympy-stubs/stats/random_matrix_models.pyi @@ -7,131 +7,75 @@ from sympy.core.relational import Relational from sympy.stats.joint_rv_types import JointDistributionHandmade from sympy.stats.rv import Density, RandomMatrixSymbol, is_random -__all__ = ['CircularEnsemble', 'CircularUnitaryEnsemble', 'CircularOrthogonalEnsemble', 'CircularSymplecticEnsemble', 'GaussianEnsemble', 'GaussianUnitaryEnsemble', 'GaussianOrthogonalEnsemble', 'GaussianSymplecticEnsemble', 'joint_eigen_distribution', 'JointEigenDistribution', 'level_spacing_distribution'] +__all__ = [ + "CircularEnsemble", + "CircularUnitaryEnsemble", + "CircularOrthogonalEnsemble", + "CircularSymplecticEnsemble", + "GaussianEnsemble", + "GaussianUnitaryEnsemble", + "GaussianOrthogonalEnsemble", + "GaussianSymplecticEnsemble", + "joint_eigen_distribution", + "JointEigenDistribution", + "level_spacing_distribution", +] + @is_random.register(RandomMatrixSymbol) -def _(x) -> Literal[True]: - ... +def _(x) -> Literal[True]: ... class RandomMatrixEnsembleModel(Basic): - def __new__(cls, sym, dim=...) -> Self: - ... - + def __new__(cls, sym, dim=...) -> Self: ... + symbol = ... dimension = ... - def density(self, expr) -> Density: - ... - - def __call__(self, expr) -> Density: - ... - - - -class GaussianEnsembleModel(RandomMatrixEnsembleModel): - ... + def density(self, expr) -> Density: ... + def __call__(self, expr) -> Density: ... +class GaussianEnsembleModel(RandomMatrixEnsembleModel): ... class GaussianUnitaryEnsembleModel(GaussianEnsembleModel): @property - def normalization_constant(self): - ... - - def density(self, expr) -> Basic: - ... - - def joint_eigen_distribution(self) -> Lambda: - ... - - def level_spacing_distribution(self) -> Lambda: - ... - - + def normalization_constant(self): ... + def density(self, expr) -> Basic: ... + def joint_eigen_distribution(self) -> Lambda: ... + def level_spacing_distribution(self) -> Lambda: ... class GaussianOrthogonalEnsembleModel(GaussianEnsembleModel): @property - def normalization_constant(self) -> Equality | Relational | Ne | Integral: - ... - - def density(self, expr) -> Basic: - ... - - def joint_eigen_distribution(self) -> Lambda: - ... - - def level_spacing_distribution(self) -> Lambda: - ... - - + def normalization_constant(self) -> Equality | Relational | Ne | Integral: ... + def density(self, expr) -> Basic: ... + def joint_eigen_distribution(self) -> Lambda: ... + def level_spacing_distribution(self) -> Lambda: ... class GaussianSymplecticEnsembleModel(GaussianEnsembleModel): @property - def normalization_constant(self) -> Equality | Relational | Ne | Integral: - ... - - def density(self, expr) -> Basic: - ... - - def joint_eigen_distribution(self) -> Lambda: - ... - - def level_spacing_distribution(self) -> Lambda: - ... - + def normalization_constant(self) -> Equality | Relational | Ne | Integral: ... + def density(self, expr) -> Basic: ... + def joint_eigen_distribution(self) -> Lambda: ... + def level_spacing_distribution(self) -> Lambda: ... - -def GaussianEnsemble(sym, dim) -> RandomMatrixSymbol: - ... - -def GaussianUnitaryEnsemble(sym, dim) -> RandomMatrixSymbol: - ... - -def GaussianOrthogonalEnsemble(sym, dim) -> RandomMatrixSymbol: - ... - -def GaussianSymplecticEnsemble(sym, dim) -> RandomMatrixSymbol: - ... +def GaussianEnsemble(sym, dim) -> RandomMatrixSymbol: ... +def GaussianUnitaryEnsemble(sym, dim) -> RandomMatrixSymbol: ... +def GaussianOrthogonalEnsemble(sym, dim) -> RandomMatrixSymbol: ... +def GaussianSymplecticEnsemble(sym, dim) -> RandomMatrixSymbol: ... class CircularEnsembleModel(RandomMatrixEnsembleModel): - def density(self, expr): - ... - - + def density(self, expr): ... class CircularUnitaryEnsembleModel(CircularEnsembleModel): - def joint_eigen_distribution(self) -> Lambda: - ... - - + def joint_eigen_distribution(self) -> Lambda: ... class CircularOrthogonalEnsembleModel(CircularEnsembleModel): - def joint_eigen_distribution(self) -> Lambda: - ... - - + def joint_eigen_distribution(self) -> Lambda: ... class CircularSymplecticEnsembleModel(CircularEnsembleModel): - def joint_eigen_distribution(self) -> Lambda: - ... - - - -def CircularEnsemble(sym, dim) -> RandomMatrixSymbol: - ... - -def CircularUnitaryEnsemble(sym, dim) -> RandomMatrixSymbol: - ... - -def CircularOrthogonalEnsemble(sym, dim) -> RandomMatrixSymbol: - ... - -def CircularSymplecticEnsemble(sym, dim) -> RandomMatrixSymbol: - ... - -def joint_eigen_distribution(mat) -> Any: - ... - -def JointEigenDistribution(mat) -> JointDistributionHandmade: - ... - -def level_spacing_distribution(mat): - ... - + def joint_eigen_distribution(self) -> Lambda: ... + +def CircularEnsemble(sym, dim) -> RandomMatrixSymbol: ... +def CircularUnitaryEnsemble(sym, dim) -> RandomMatrixSymbol: ... +def CircularOrthogonalEnsemble(sym, dim) -> RandomMatrixSymbol: ... +def CircularSymplecticEnsemble(sym, dim) -> RandomMatrixSymbol: ... +def joint_eigen_distribution(mat) -> Any: ... +def JointEigenDistribution(mat) -> JointDistributionHandmade: ... +def level_spacing_distribution(mat): ... diff --git a/stubs/sympy-stubs/stats/rv.pyi b/stubs/sympy-stubs/stats/rv.pyi index ba9467d2..8a8be9d4 100644 --- a/stubs/sympy-stubs/stats/rv.pyi +++ b/stubs/sympy-stubs/stats/rv.pyi @@ -21,93 +21,51 @@ from sympy.stats.symbolic_probability import Expectation, Probability from sympy.utilities.decorator import doctest_depends_on x = ... -@singledispatch -def is_random(x) -> bool: - ... +@singledispatch +def is_random(x) -> bool: ... @is_random.register(Basic) -def _(x) -> bool: - ... +def _(x) -> bool: ... class RandomDomain(Basic): is_ProductDomain = ... is_Finite = ... is_Continuous = ... is_Discrete = ... - def __new__(cls, symbols, *args) -> Self: - ... - - @property - def symbols(self) -> Basic: - ... - - @property - def set(self) -> Basic: - ... - - def __contains__(self, other): - ... - - def compute_expectation(self, expr): - ... - - + def __new__(cls, symbols, *args) -> Self: ... + @property + def symbols(self) -> Basic: ... + @property + def set(self) -> Basic: ... + def __contains__(self, other): ... + def compute_expectation(self, expr): ... class SingleDomain(RandomDomain): - def __new__(cls, symbol, set) -> Self: - ... - - @property - def symbol(self) -> Basic: - ... - - @property - def symbols(self) -> FiniteSet: - ... - - def __contains__(self, other) -> bool: - ... - - + def __new__(cls, symbol, set) -> Self: ... + @property + def symbol(self) -> Basic: ... + @property + def symbols(self) -> FiniteSet: ... + def __contains__(self, other) -> bool: ... class MatrixDomain(RandomDomain): - def __new__(cls, symbol, set) -> Self: - ... - + def __new__(cls, symbol, set) -> Self: ... @property - def symbol(self) -> Basic: - ... - + def symbol(self) -> Basic: ... @property - def symbols(self) -> FiniteSet: - ... - - + def symbols(self) -> FiniteSet: ... class ConditionalDomain(RandomDomain): - def __new__(cls, fulldomain, condition) -> Self: - ... - - @property - def symbols(self): - ... - - @property - def fulldomain(self) -> Basic: - ... - - @property - def condition(self) -> Basic: - ... - - @property - def set(self): - ... - - def as_boolean(self) -> And: - ... - - + def __new__(cls, fulldomain, condition) -> Self: ... + @property + def symbols(self): ... + @property + def fulldomain(self) -> Basic: ... + @property + def condition(self) -> Basic: ... + @property + def set(self): ... + def as_boolean(self) -> And: ... class PSpace(Basic): is_Finite: bool = ... @@ -115,64 +73,33 @@ class PSpace(Basic): is_Discrete: bool = ... is_real: bool = ... @property - def domain(self) -> Basic: - ... - - @property - def density(self) -> Basic: - ... - - @property - def values(self) -> frozenset[RandomSymbol]: - ... - - @property - def symbols(self): - ... - - def where(self, condition): - ... - - def compute_density(self, expr): - ... - - def sample(self, size=..., library=..., seed=...): - ... - - def probability(self, condition): - ... - - def compute_expectation(self, expr): - ... - - + def domain(self) -> Basic: ... + @property + def density(self) -> Basic: ... + @property + def values(self) -> frozenset[RandomSymbol]: ... + @property + def symbols(self): ... + def where(self, condition): ... + def compute_density(self, expr): ... + def sample(self, size=..., library=..., seed=...): ... + def probability(self, condition): ... + def compute_expectation(self, expr): ... class SinglePSpace(PSpace): - def __new__(cls, s, distribution) -> Self: - ... - + def __new__(cls, s, distribution) -> Self: ... @property - def value(self) -> RandomSymbol: - ... - + def value(self) -> RandomSymbol: ... @property - def symbol(self) -> Basic: - ... - + def symbol(self) -> Basic: ... @property - def distribution(self) -> Basic: - ... - + def distribution(self) -> Basic: ... @property - def pdf(self): - ... - - + def pdf(self): ... class RandomSymbol(Expr): - def __new__(cls, symbol, pspace=...) -> RandomSymbol | Self: - ... - + def __new__(cls, symbol, pspace=...) -> RandomSymbol | Self: ... + is_finite = ... is_symbol = ... is_Atom = ... @@ -181,228 +108,134 @@ class RandomSymbol(Expr): symbol = ... name = ... @property - def is_commutative(self) -> Any: - ... - + def is_commutative(self) -> Any: ... @property - def free_symbols(self) -> set[Self]: - ... - - + def free_symbols(self) -> set[Self]: ... class RandomIndexedSymbol(RandomSymbol): - def __new__(cls, idx_obj, pspace=...) -> Self: - ... - + def __new__(cls, idx_obj, pspace=...) -> Self: ... + symbol = ... name = ... @property - def key(self) -> Basic | None: - ... - + def key(self) -> Basic | None: ... @property - def free_symbols(self) -> set[Basic] | set[Self]: - ... - + def free_symbols(self) -> set[Basic] | set[Self]: ... @property - def pspace(self) -> Basic: - ... - - + def pspace(self) -> Basic: ... class RandomMatrixSymbol(RandomSymbol, MatrixSymbol): - def __new__(cls, symbol, n, m, pspace=...) -> Self: - ... - + def __new__(cls, symbol, n, m, pspace=...) -> Self: ... + symbol = ... pspace = ... - -class ProductPSpace(PSpace): - ... - +class ProductPSpace(PSpace): ... class IndependentProductPSpace(ProductPSpace): - def __new__(cls, *spaces) -> ProductFinitePSpace | Self: - ... - - @property - def pdf(self) -> Order | Basic: - ... - - @property - def rs_space_dict(self) -> dict[Any, Any]: - ... - - @property - def symbols(self) -> FiniteSet: - ... - - @property - def spaces(self) -> FiniteSet: - ... - - @property - def values(self) -> frozenset[Any]: - ... - - def compute_expectation(self, expr, rvs=..., evaluate=..., **kwargs): - ... - - @property - def domain(self) -> ProductDiscreteDomain | ProductContinuousDomain | ProductFiniteDomain | ProductDomain: - ... - - @property - def density(self): - ... - - def sample(self, size=..., library=..., seed=...) -> dict[Any, Any]: - ... - - def probability(self, condition, **kwargs) -> Order | Lambda | Probability | Equality | Relational | Ne | int: - ... - - def compute_density(self, expr, **kwargs) -> Lambda: - ... - - def compute_cdf(self, expr, **kwargs): - ... - - def conditional_space(self, condition, normalize=..., **kwargs) -> FinitePSpace | ContinuousPSpace | DiscretePSpace: - ... - - + def __new__(cls, *spaces) -> ProductFinitePSpace | Self: ... + @property + def pdf(self) -> Order | Basic: ... + @property + def rs_space_dict(self) -> dict[Any, Any]: ... + @property + def symbols(self) -> FiniteSet: ... + @property + def spaces(self) -> FiniteSet: ... + @property + def values(self) -> frozenset[Any]: ... + def compute_expectation(self, expr, rvs=..., evaluate=..., **kwargs): ... + @property + def domain(self) -> ProductDiscreteDomain | ProductContinuousDomain | ProductFiniteDomain | ProductDomain: ... + @property + def density(self): ... + def sample(self, size=..., library=..., seed=...) -> dict[Any, Any]: ... + def probability(self, condition, **kwargs) -> Order | Lambda | Probability | Equality | Relational | Ne | int: ... + def compute_density(self, expr, **kwargs) -> Lambda: ... + def compute_cdf(self, expr, **kwargs): ... + def conditional_space(self, condition, normalize=..., **kwargs) -> FinitePSpace | ContinuousPSpace | DiscretePSpace: ... class ProductDomain(RandomDomain): is_ProductDomain = ... - def __new__(cls, *domains) -> ProductDiscreteDomain | ProductContinuousDomain | ProductFiniteDomain | Self: - ... - - @property - def sym_domain_dict(self) -> dict[Any, Basic]: - ... - - @property - def symbols(self) -> FiniteSet: - ... - - @property - def domains(self) -> tuple[Basic, ...]: - ... - - @property - def set(self) -> FiniteSet | ProductSet: - ... - - def __contains__(self, other) -> bool: - ... - - def as_boolean(self) -> And: - ... - - - -def random_symbols(expr) -> list[Any]: - ... - -def pspace(expr) -> Any | CompoundPSpace | StochasticPSpace | ProductFinitePSpace | IndependentProductPSpace: - ... - -def sumsets(sets) -> frozenset[Any]: - ... - -def rs_swap(a, b) -> dict[Any, Any]: - ... - -def given(expr, condition=..., **kwargs) -> Relational | Basic | bool: - ... - -def expectation(expr, condition=..., numsamples=..., evaluate=..., **kwargs) -> Basic | Expectation | tuple[Any, ...] | Sum | Order | Any | Piecewise | Equality | Relational | Ne | Integral | ExpectationMatrix | None: - ... - -def probability(condition, given_condition=..., numsamples=..., evaluate=..., **kwargs) -> Any | BernoulliDistribution | Probability | Equality | Lambda | Order | Relational | Ne | int: - ... + def __new__(cls, *domains) -> ProductDiscreteDomain | ProductContinuousDomain | ProductFiniteDomain | Self: ... + @property + def sym_domain_dict(self) -> dict[Any, Basic]: ... + @property + def symbols(self) -> FiniteSet: ... + @property + def domains(self) -> tuple[Basic, ...]: ... + @property + def set(self) -> FiniteSet | ProductSet: ... + def __contains__(self, other) -> bool: ... + def as_boolean(self) -> And: ... + +def random_symbols(expr) -> list[Any]: ... +def pspace(expr) -> Any | CompoundPSpace | StochasticPSpace | ProductFinitePSpace | IndependentProductPSpace: ... +def sumsets(sets) -> frozenset[Any]: ... +def rs_swap(a, b) -> dict[Any, Any]: ... +def given(expr, condition=..., **kwargs) -> Relational | Basic | bool: ... +def expectation( + expr, condition=..., numsamples=..., evaluate=..., **kwargs +) -> ( + Basic + | Expectation + | tuple[Any, ...] + | Sum + | Order + | Any + | Piecewise + | Equality + | Relational + | Ne + | Integral + | ExpectationMatrix + | None +): ... +def probability( + condition, given_condition=..., numsamples=..., evaluate=..., **kwargs +) -> Any | BernoulliDistribution | Probability | Equality | Lambda | Order | Relational | Ne | int: ... class Density(Basic): expr = ... - def __new__(cls, expr, condition=...) -> Self: - ... - - @property - def condition(self) -> Basic | None: - ... - - def doit(self, evaluate=..., **kwargs) -> Density | dict[Any, Any] | Lambda | Basic | Any | FiniteDensity | None: - ... - - - -def density(expr, condition=..., evaluate=..., numsamples=..., **kwargs) -> dict[Any, Any] | Density | Lambda | Basic | Any | FiniteDensity | None: - ... - -def cdf(expr, condition=..., evaluate=..., **kwargs) -> Lambda | Any | dict[Any, Any]: - ... - -def characteristic_function(expr, condition=..., evaluate=..., **kwargs) -> Lambda | Any: - ... - -def moment_generating_function(expr, condition=..., evaluate=..., **kwargs) -> Lambda | Any: - ... - -def where(condition, given_condition=..., **kwargs) -> ConditionalFiniteDomain | Any: - ... - -@doctest_depends_on(modules=('scipy', )) -def sample(expr, condition=..., size=..., library=..., numsamples=..., seed=..., **kwargs) -> list[Any | JointRandomSymbol | Basic] | JointRandomSymbol | Basic: - ... - -def quantile(expr, evaluate=..., **kwargs) -> Lambda | Any: - ... - -def sample_iter(expr, condition=..., size=..., library=..., numsamples=..., seed=..., **kwargs) -> Generator[Any, Any, None] | Generator[Any | JointRandomSymbol | Basic, Any, None]: - ... - -def sample_iter_lambdify(expr, condition=..., size=..., numsamples=..., seed=..., **kwargs) -> Generator[Any, Any, None] | Generator[Any | JointRandomSymbol | Basic, Any, None]: - ... - -def sample_iter_subs(expr, condition=..., size=..., numsamples=..., seed=..., **kwargs) -> Generator[Any, Any, None] | Generator[Any | JointRandomSymbol | Basic, Any, None]: - ... - -def sampling_P(condition, given_condition=..., library=..., numsamples=..., evalf=..., seed=..., **kwargs): - ... - -def sampling_E(expr, given_condition=..., library=..., numsamples=..., evalf=..., seed=..., **kwargs): - ... - -def sampling_density(expr, given_condition=..., library=..., numsamples=..., seed=..., **kwargs) -> dict[Any, Any]: - ... - -def dependent(a, b) -> Any | bool: - ... - -def independent(a, b) -> bool: - ... - -def pspace_independent(a, b) -> bool | None: - ... - -def rv_subs(expr, symbols=...): - ... + def __new__(cls, expr, condition=...) -> Self: ... + @property + def condition(self) -> Basic | None: ... + def doit(self, evaluate=..., **kwargs) -> Density | dict[Any, Any] | Lambda | Basic | Any | FiniteDensity | None: ... + +def density( + expr, condition=..., evaluate=..., numsamples=..., **kwargs +) -> dict[Any, Any] | Density | Lambda | Basic | Any | FiniteDensity | None: ... +def cdf(expr, condition=..., evaluate=..., **kwargs) -> Lambda | Any | dict[Any, Any]: ... +def characteristic_function(expr, condition=..., evaluate=..., **kwargs) -> Lambda | Any: ... +def moment_generating_function(expr, condition=..., evaluate=..., **kwargs) -> Lambda | Any: ... +def where(condition, given_condition=..., **kwargs) -> ConditionalFiniteDomain | Any: ... +@doctest_depends_on(modules=("scipy",)) +def sample( + expr, condition=..., size=..., library=..., numsamples=..., seed=..., **kwargs +) -> list[Any | JointRandomSymbol | Basic] | JointRandomSymbol | Basic: ... +def quantile(expr, evaluate=..., **kwargs) -> Lambda | Any: ... +def sample_iter( + expr, condition=..., size=..., library=..., numsamples=..., seed=..., **kwargs +) -> Generator[Any, Any, None] | Generator[Any | JointRandomSymbol | Basic, Any, None]: ... +def sample_iter_lambdify( + expr, condition=..., size=..., numsamples=..., seed=..., **kwargs +) -> Generator[Any, Any, None] | Generator[Any | JointRandomSymbol | Basic, Any, None]: ... +def sample_iter_subs( + expr, condition=..., size=..., numsamples=..., seed=..., **kwargs +) -> Generator[Any, Any, None] | Generator[Any | JointRandomSymbol | Basic, Any, None]: ... +def sampling_P(condition, given_condition=..., library=..., numsamples=..., evalf=..., seed=..., **kwargs): ... +def sampling_E(expr, given_condition=..., library=..., numsamples=..., evalf=..., seed=..., **kwargs): ... +def sampling_density(expr, given_condition=..., library=..., numsamples=..., seed=..., **kwargs) -> dict[Any, Any]: ... +def dependent(a, b) -> Any | bool: ... +def independent(a, b) -> bool: ... +def pspace_independent(a, b) -> bool | None: ... +def rv_subs(expr, symbols=...): ... class NamedArgsMixin: _argnames: tuple[str, ...] = ... - def __getattr__(self, attr): - ... - - + def __getattr__(self, attr): ... class Distribution(Basic): - def sample(self, size=..., library=..., seed=...): - ... - - - -def sample_stochastic_process(process): - ... + def sample(self, size=..., library=..., seed=...): ... +def sample_stochastic_process(process): ... diff --git a/stubs/sympy-stubs/stats/rv_interface.pyi b/stubs/sympy-stubs/stats/rv_interface.pyi index cf89e3a5..eb3862fa 100644 --- a/stubs/sympy-stubs/stats/rv_interface.pyi +++ b/stubs/sympy-stubs/stats/rv_interface.pyi @@ -34,46 +34,108 @@ from .rv import ( where, ) -__all__ = ['P', 'E', 'H', 'density', 'where', 'given', 'sample', 'cdf', 'characteristic_function', 'pspace', 'sample_iter', 'variance', 'std', 'skewness', 'kurtosis', 'covariance', 'dependent', 'entropy', 'median', 'independent', 'random_symbols', 'correlation', 'factorial_moment', 'moment', 'cmoment', 'sampling_density', 'moment_generating_function', 'smoment', 'quantile', 'sample_stochastic_process'] -def moment(X, n, c=..., condition=..., *, evaluate=..., **kwargs) -> Any | Moment: - ... - -def variance(X, condition=..., **kwargs) -> VarianceMatrix | Variance | Any | CentralMoment: - ... - -def standard_deviation(X, condition=..., **kwargs) -> Pow: - ... +__all__ = [ + "P", + "E", + "H", + "density", + "where", + "given", + "sample", + "cdf", + "characteristic_function", + "pspace", + "sample_iter", + "variance", + "std", + "skewness", + "kurtosis", + "covariance", + "dependent", + "entropy", + "median", + "independent", + "random_symbols", + "correlation", + "factorial_moment", + "moment", + "cmoment", + "sampling_density", + "moment_generating_function", + "smoment", + "quantile", + "sample_stochastic_process", +] + +def moment(X, n, c=..., condition=..., *, evaluate=..., **kwargs) -> Any | Moment: ... +def variance(X, condition=..., **kwargs) -> VarianceMatrix | Variance | Any | CentralMoment: ... +def standard_deviation(X, condition=..., **kwargs) -> Pow: ... std = ... -def entropy(expr, condition=..., **kwargs) -> int | Mul | Basic | Expectation | tuple[Any, ...] | Sum | Order | Any | Piecewise | Equality | Relational | Ne | Integral | ExpectationMatrix | None: - ... - -def covariance(X, Y, condition=..., **kwargs) -> CrossCovarianceMatrix | Covariance | Basic | Expectation | tuple[Any, ...] | Sum | Order | Any | Piecewise | Equality | Relational | Ne | Integral | ExpectationMatrix | None: - ... - -def correlation(X, Y, condition=..., **kwargs): - ... - -def cmoment(X, n, condition=..., *, evaluate=..., **kwargs) -> Any | CentralMoment: - ... - -def smoment(X, n, condition=..., **kwargs): - ... - -def skewness(X, condition=..., **kwargs): - ... - -def kurtosis(X, condition=..., **kwargs): - ... - -def factorial_moment(X, n, condition=..., **kwargs) -> type[UndefinedFunction] | Basic | Expectation | tuple[Any, ...] | Sum | Order | Any | Piecewise | Equality | Relational | Ne | Integral | ExpectationMatrix | None: - ... - -def median(X, evaluate=..., **kwargs) -> FiniteSet | Set: - ... -def coskewness(X, Y, Z, condition=..., **kwargs): - ... +def entropy( + expr, condition=..., **kwargs +) -> ( + int + | Mul + | Basic + | Expectation + | tuple[Any, ...] + | Sum + | Order + | Any + | Piecewise + | Equality + | Relational + | Ne + | Integral + | ExpectationMatrix + | None +): ... +def covariance( + X, Y, condition=..., **kwargs +) -> ( + CrossCovarianceMatrix + | Covariance + | Basic + | Expectation + | tuple[Any, ...] + | Sum + | Order + | Any + | Piecewise + | Equality + | Relational + | Ne + | Integral + | ExpectationMatrix + | None +): ... +def correlation(X, Y, condition=..., **kwargs): ... +def cmoment(X, n, condition=..., *, evaluate=..., **kwargs) -> Any | CentralMoment: ... +def smoment(X, n, condition=..., **kwargs): ... +def skewness(X, condition=..., **kwargs): ... +def kurtosis(X, condition=..., **kwargs): ... +def factorial_moment( + X, n, condition=..., **kwargs +) -> ( + type[UndefinedFunction] + | Basic + | Expectation + | tuple[Any, ...] + | Sum + | Order + | Any + | Piecewise + | Equality + | Relational + | Ne + | Integral + | ExpectationMatrix + | None +): ... +def median(X, evaluate=..., **kwargs) -> FiniteSet | Set: ... +def coskewness(X, Y, Z, condition=..., **kwargs): ... P = ... E = ... diff --git a/stubs/sympy-stubs/stats/sampling/sample_numpy.pyi b/stubs/sympy-stubs/stats/sampling/sample_numpy.pyi index c743b9d7..fa31ff15 100644 --- a/stubs/sympy-stubs/stats/sampling/sample_numpy.pyi +++ b/stubs/sympy-stubs/stats/sampling/sample_numpy.pyi @@ -20,83 +20,44 @@ from sympy.stats.drv_types import GeometricDistribution, PoissonDistribution, Ze from sympy.stats.frv_types import BinomialDistribution, HypergeometricDistribution numpy = ... -@singledispatch -def do_sample_numpy(dist, size, rand_state) -> None: - ... +@singledispatch +def do_sample_numpy(dist, size, rand_state) -> None: ... @do_sample_numpy.register(BetaDistribution) -def _(dist: BetaDistribution, size, rand_state): - ... - +def _(dist: BetaDistribution, size, rand_state): ... @do_sample_numpy.register(ChiSquaredDistribution) -def _(dist: ChiSquaredDistribution, size, rand_state): - ... - +def _(dist: ChiSquaredDistribution, size, rand_state): ... @do_sample_numpy.register(ExponentialDistribution) -def _(dist: ExponentialDistribution, size, rand_state): - ... - +def _(dist: ExponentialDistribution, size, rand_state): ... @do_sample_numpy.register(FDistributionDistribution) -def _(dist: FDistributionDistribution, size, rand_state): - ... - +def _(dist: FDistributionDistribution, size, rand_state): ... @do_sample_numpy.register(GammaDistribution) -def _(dist: GammaDistribution, size, rand_state): - ... - +def _(dist: GammaDistribution, size, rand_state): ... @do_sample_numpy.register(GumbelDistribution) -def _(dist: GumbelDistribution, size, rand_state): - ... - +def _(dist: GumbelDistribution, size, rand_state): ... @do_sample_numpy.register(LaplaceDistribution) -def _(dist: LaplaceDistribution, size, rand_state): - ... - +def _(dist: LaplaceDistribution, size, rand_state): ... @do_sample_numpy.register(LogisticDistribution) -def _(dist: LogisticDistribution, size, rand_state): - ... - +def _(dist: LogisticDistribution, size, rand_state): ... @do_sample_numpy.register(LogNormalDistribution) -def _(dist: LogNormalDistribution, size, rand_state): - ... - +def _(dist: LogNormalDistribution, size, rand_state): ... @do_sample_numpy.register(NormalDistribution) -def _(dist: NormalDistribution, size, rand_state): - ... - +def _(dist: NormalDistribution, size, rand_state): ... @do_sample_numpy.register(RayleighDistribution) -def _(dist: RayleighDistribution, size, rand_state): - ... - +def _(dist: RayleighDistribution, size, rand_state): ... @do_sample_numpy.register(ParetoDistribution) -def _(dist: ParetoDistribution, size, rand_state): - ... - +def _(dist: ParetoDistribution, size, rand_state): ... @do_sample_numpy.register(TriangularDistribution) -def _(dist: TriangularDistribution, size, rand_state): - ... - +def _(dist: TriangularDistribution, size, rand_state): ... @do_sample_numpy.register(UniformDistribution) -def _(dist: UniformDistribution, size, rand_state): - ... - +def _(dist: UniformDistribution, size, rand_state): ... @do_sample_numpy.register(GeometricDistribution) -def _(dist: GeometricDistribution, size, rand_state): - ... - +def _(dist: GeometricDistribution, size, rand_state): ... @do_sample_numpy.register(PoissonDistribution) -def _(dist: PoissonDistribution, size, rand_state): - ... - +def _(dist: PoissonDistribution, size, rand_state): ... @do_sample_numpy.register(ZetaDistribution) -def _(dist: ZetaDistribution, size, rand_state): - ... - +def _(dist: ZetaDistribution, size, rand_state): ... @do_sample_numpy.register(BinomialDistribution) -def _(dist: BinomialDistribution, size, rand_state): - ... - +def _(dist: BinomialDistribution, size, rand_state): ... @do_sample_numpy.register(HypergeometricDistribution) -def _(dist: HypergeometricDistribution, size, rand_state): - ... - +def _(dist: HypergeometricDistribution, size, rand_state): ... diff --git a/stubs/sympy-stubs/stats/sampling/sample_pymc.pyi b/stubs/sympy-stubs/stats/sampling/sample_pymc.pyi index fb05e624..451d2d6e 100644 --- a/stubs/sympy-stubs/stats/sampling/sample_pymc.pyi +++ b/stubs/sympy-stubs/stats/sampling/sample_pymc.pyi @@ -16,66 +16,34 @@ from sympy.stats.drv_types import GeometricDistribution, NegativeBinomialDistrib from sympy.stats.frv_types import BernoulliDistribution, BinomialDistribution @singledispatch -def do_sample_pymc(dist) -> None: - ... - +def do_sample_pymc(dist) -> None: ... @do_sample_pymc.register(BetaDistribution) -def _(dist: BetaDistribution): - ... - +def _(dist: BetaDistribution): ... @do_sample_pymc.register(CauchyDistribution) -def _(dist: CauchyDistribution): - ... - +def _(dist: CauchyDistribution): ... @do_sample_pymc.register(ChiSquaredDistribution) -def _(dist: ChiSquaredDistribution): - ... - +def _(dist: ChiSquaredDistribution): ... @do_sample_pymc.register(ExponentialDistribution) -def _(dist: ExponentialDistribution): - ... - +def _(dist: ExponentialDistribution): ... @do_sample_pymc.register(GammaDistribution) -def _(dist: GammaDistribution): - ... - +def _(dist: GammaDistribution): ... @do_sample_pymc.register(LogNormalDistribution) -def _(dist: LogNormalDistribution): - ... - +def _(dist: LogNormalDistribution): ... @do_sample_pymc.register(NormalDistribution) -def _(dist: NormalDistribution): - ... - +def _(dist: NormalDistribution): ... @do_sample_pymc.register(GaussianInverseDistribution) -def _(dist: GaussianInverseDistribution): - ... - +def _(dist: GaussianInverseDistribution): ... @do_sample_pymc.register(ParetoDistribution) -def _(dist: ParetoDistribution): - ... - +def _(dist: ParetoDistribution): ... @do_sample_pymc.register(UniformDistribution) -def _(dist: UniformDistribution): - ... - +def _(dist: UniformDistribution): ... @do_sample_pymc.register(GeometricDistribution) -def _(dist: GeometricDistribution): - ... - +def _(dist: GeometricDistribution): ... @do_sample_pymc.register(NegativeBinomialDistribution) -def _(dist: NegativeBinomialDistribution): - ... - +def _(dist: NegativeBinomialDistribution): ... @do_sample_pymc.register(PoissonDistribution) -def _(dist: PoissonDistribution): - ... - +def _(dist: PoissonDistribution): ... @do_sample_pymc.register(BernoulliDistribution) -def _(dist: BernoulliDistribution): - ... - +def _(dist: BernoulliDistribution): ... @do_sample_pymc.register(BinomialDistribution) -def _(dist: BinomialDistribution): - ... - +def _(dist: BinomialDistribution): ... diff --git a/stubs/sympy-stubs/stats/sampling/sample_scipy.pyi b/stubs/sympy-stubs/stats/sampling/sample_scipy.pyi index c40989fa..4a30f77d 100644 --- a/stubs/sympy-stubs/stats/sampling/sample_scipy.pyi +++ b/stubs/sympy-stubs/stats/sampling/sample_scipy.pyi @@ -26,93 +26,50 @@ from sympy.stats.drv_types import ( from sympy.stats.frv import SingleFiniteDistribution scipy = ... -@singledispatch -def do_sample_scipy(dist, size, seed) -> None | int: - ... +@singledispatch +def do_sample_scipy(dist, size, seed) -> None | int: ... @do_sample_scipy.register(SingleContinuousDistribution) def _(dist: SingleContinuousDistribution, size, seed) -> int: - class scipy_pdf(scipy.stats.rv_continuous): - ... - - + class scipy_pdf(scipy.stats.rv_continuous): ... @do_sample_scipy.register(ChiSquaredDistribution) -def _(dist: ChiSquaredDistribution, size, seed): - ... - +def _(dist: ChiSquaredDistribution, size, seed): ... @do_sample_scipy.register(ExponentialDistribution) -def _(dist: ExponentialDistribution, size, seed): - ... - +def _(dist: ExponentialDistribution, size, seed): ... @do_sample_scipy.register(GammaDistribution) -def _(dist: GammaDistribution, size, seed): - ... - +def _(dist: GammaDistribution, size, seed): ... @do_sample_scipy.register(LogNormalDistribution) -def _(dist: LogNormalDistribution, size, seed): - ... - +def _(dist: LogNormalDistribution, size, seed): ... @do_sample_scipy.register(NormalDistribution) -def _(dist: NormalDistribution, size, seed): - ... - +def _(dist: NormalDistribution, size, seed): ... @do_sample_scipy.register(ParetoDistribution) -def _(dist: ParetoDistribution, size, seed): - ... - +def _(dist: ParetoDistribution, size, seed): ... @do_sample_scipy.register(StudentTDistribution) -def _(dist: StudentTDistribution, size, seed): - ... - +def _(dist: StudentTDistribution, size, seed): ... @do_sample_scipy.register(UniformDistribution) -def _(dist: UniformDistribution, size, seed): - ... - +def _(dist: UniformDistribution, size, seed): ... @do_sample_scipy.register(BetaDistribution) -def _(dist: BetaDistribution, size, seed): - ... - +def _(dist: BetaDistribution, size, seed): ... @do_sample_scipy.register(CauchyDistribution) -def _(dist: CauchyDistribution, size, seed): - ... - +def _(dist: CauchyDistribution, size, seed): ... @do_sample_scipy.register(DiscreteDistributionHandmade) def _(dist: DiscreteDistributionHandmade, size, seed) -> int: - class scipy_pmf(): - ... - - + class scipy_pmf: ... @do_sample_scipy.register(GeometricDistribution) -def _(dist: GeometricDistribution, size, seed): - ... - +def _(dist: GeometricDistribution, size, seed): ... @do_sample_scipy.register(LogarithmicDistribution) -def _(dist: LogarithmicDistribution, size, seed): - ... - +def _(dist: LogarithmicDistribution, size, seed): ... @do_sample_scipy.register(NegativeBinomialDistribution) -def _(dist: NegativeBinomialDistribution, size, seed): - ... - +def _(dist: NegativeBinomialDistribution, size, seed): ... @do_sample_scipy.register(PoissonDistribution) -def _(dist: PoissonDistribution, size, seed): - ... - +def _(dist: PoissonDistribution, size, seed): ... @do_sample_scipy.register(SkellamDistribution) -def _(dist: SkellamDistribution, size, seed): - ... - +def _(dist: SkellamDistribution, size, seed): ... @do_sample_scipy.register(YuleSimonDistribution) -def _(dist: YuleSimonDistribution, size, seed): - ... - +def _(dist: YuleSimonDistribution, size, seed): ... @do_sample_scipy.register(ZetaDistribution) -def _(dist: ZetaDistribution, size, seed): - ... - +def _(dist: ZetaDistribution, size, seed): ... @do_sample_scipy.register(SingleFiniteDistribution) -def _(dist: SingleFiniteDistribution, size, seed) -> int: - ... - +def _(dist: SingleFiniteDistribution, size, seed) -> int: ... diff --git a/stubs/sympy-stubs/stats/stochastic_process.pyi b/stubs/sympy-stubs/stats/stochastic_process.pyi index ad8b947e..0410c637 100644 --- a/stubs/sympy-stubs/stats/stochastic_process.pyi +++ b/stubs/sympy-stubs/stats/stochastic_process.pyi @@ -8,30 +8,14 @@ from sympy.stats.joint_rv import ProductPSpace from sympy.stats.rv import ProductDomain class StochasticPSpace(ProductPSpace): - def __new__(cls, sym, process, distribution=...) -> Self: - ... - + def __new__(cls, sym, process, distribution=...) -> Self: ... @property - def process(self) -> Basic: - ... - + def process(self) -> Basic: ... @property - def domain(self) -> ProductDiscreteDomain | ProductContinuousDomain | ProductFiniteDomain | ProductDomain: - ... - + def domain(self) -> ProductDiscreteDomain | ProductContinuousDomain | ProductFiniteDomain | ProductDomain: ... @property - def symbol(self) -> Basic: - ... - + def symbol(self) -> Basic: ... @property - def distribution(self) -> Basic: - ... - - def probability(self, condition, given_condition=..., evaluate=..., **kwargs): - ... - - def compute_expectation(self, expr, condition=..., evaluate=..., **kwargs): - ... - - - + def distribution(self) -> Basic: ... + def probability(self, condition, given_condition=..., evaluate=..., **kwargs): ... + def compute_expectation(self, expr, condition=..., evaluate=..., **kwargs): ... diff --git a/stubs/sympy-stubs/stats/stochastic_process_types.pyi b/stubs/sympy-stubs/stats/stochastic_process_types.pyi index d6f43670..11a96d1a 100644 --- a/stubs/sympy-stubs/stats/stochastic_process_types.pyi +++ b/stubs/sympy-stubs/stats/stochastic_process_types.pyi @@ -27,311 +27,181 @@ from sympy.stats.symbolic_probability import Expectation, Probability from sympy.tensor.indexed import Indexed EmptySet = ... -__all__ = ['StochasticProcess', 'DiscreteTimeStochasticProcess', 'DiscreteMarkovChain', 'TransitionMatrixOf', 'StochasticStateSpaceOf', 'GeneratorMatrixOf', 'ContinuousMarkovChain', 'BernoulliProcess', 'PoissonProcess', 'WienerProcess', 'GammaProcess'] -@is_random.register(Indexed) -def _(x) -> bool: - ... +__all__ = [ + "StochasticProcess", + "DiscreteTimeStochasticProcess", + "DiscreteMarkovChain", + "TransitionMatrixOf", + "StochasticStateSpaceOf", + "GeneratorMatrixOf", + "ContinuousMarkovChain", + "BernoulliProcess", + "PoissonProcess", + "WienerProcess", + "GammaProcess", +] +@is_random.register(Indexed) +def _(x) -> bool: ... @is_random.register(RandomIndexedSymbol) -def _(x) -> Literal[True]: - ... +def _(x) -> Literal[True]: ... class StochasticProcess(Basic): index_set = ... - def __new__(cls, sym, state_space=..., **kwargs) -> Self: - ... - + def __new__(cls, sym, state_space=..., **kwargs) -> Self: ... @property - def symbol(self) -> Basic: - ... - + def symbol(self) -> Basic: ... @property - def state_space(self) -> tUnion[FiniteSet, Range]: - ... - - def distribution(self, key=...) -> Distribution: - ... - - def density(self, x) -> Density: - ... - - def __call__(self, time): - ... - - def __getitem__(self, time): - ... - - def probability(self, condition): - ... - - def joint_distribution(self, *args) -> JointDistribution | JointDistributionHandmade: - ... - - def expectation(self, condition, given_condition): - ... - - def sample(self): - ... - - + def state_space(self) -> tUnion[FiniteSet, Range]: ... + def distribution(self, key=...) -> Distribution: ... + def density(self, x) -> Density: ... + def __call__(self, time): ... + def __getitem__(self, time): ... + def probability(self, condition): ... + def joint_distribution(self, *args) -> JointDistribution | JointDistributionHandmade: ... + def expectation(self, condition, given_condition): ... + def sample(self): ... class DiscreteTimeStochasticProcess(StochasticProcess): - def __getitem__(self, time) -> RandomIndexedSymbol: - ... - - + def __getitem__(self, time) -> RandomIndexedSymbol: ... class ContinuousTimeStochasticProcess(StochasticProcess): - def __call__(self, time) -> RandomIndexedSymbol: - ... - - + def __call__(self, time) -> RandomIndexedSymbol: ... class TransitionMatrixOf(Boolean): - def __new__(cls, process, matrix) -> Self: - ... - + def __new__(cls, process, matrix) -> Self: ... + process = ... matrix = ... - class GeneratorMatrixOf(TransitionMatrixOf): - def __new__(cls, process, matrix) -> Self: - ... - - + def __new__(cls, process, matrix) -> Self: ... class StochasticStateSpaceOf(Boolean): - def __new__(cls, process, state_space) -> Self: - ... - + def __new__(cls, process, state_space) -> Self: ... + process = ... state_index = ... - class MarkovProcess(StochasticProcess): @property - def number_of_states(self) -> tUnion[Integer, Symbol]: - ... - - def replace_with_index(self, condition) -> Relational | Eq | Ne: - ... - - def probability(self, condition, given_condition=..., evaluate=..., **kwargs): - ... - - def expectation(self, expr, condition=..., evaluate=..., **kwargs) -> ExpectationMatrix | Expectation | int: - ... - - + def number_of_states(self) -> tUnion[Integer, Symbol]: ... + def replace_with_index(self, condition) -> Relational | Eq | Ne: ... + def probability(self, condition, given_condition=..., evaluate=..., **kwargs): ... + def expectation(self, expr, condition=..., evaluate=..., **kwargs) -> ExpectationMatrix | Expectation | int: ... class DiscreteMarkovChain(DiscreteTimeStochasticProcess, MarkovProcess): index_set = ... - def __new__(cls, sym, state_space=..., trans_probs=...) -> Self: - ... - - @property - def transition_probabilities(self) -> Basic: - ... - - def communication_classes(self) -> tList[tTuple[tList[Basic], Boolean, Integer]]: - ... - - def fundamental_matrix(self): - ... - - def absorbing_probabilities(self) -> None: - ... - - def absorbing_probabilites(self) -> None: - ... - - def is_regular(self) -> And: - ... - - def is_ergodic(self): - ... - - def is_absorbing_state(self, state) -> bool | None: - ... - - def is_absorbing_chain(self) -> And: - ... - - def stationary_distribution(self, condition_set=...) -> tUnion[ImmutableMatrix, ConditionSet, Lambda]: - ... - - def fixed_row_vector(self) -> ImmutableMatrix | ConditionSet | Lambda: - ... - - @property - def limiting_distribution(self) -> ImmutableMatrix | ConditionSet | Lambda: - ... - - def decompose(self) -> tTuple[tList[Basic], ImmutableMatrix, ImmutableMatrix, ImmutableMatrix]: - ... - - def canonical_form(self) -> tTuple[tList[Basic], ImmutableMatrix]: - ... - - def sample(self) -> Generator[Basic, Any, None]: - ... - - + def __new__(cls, sym, state_space=..., trans_probs=...) -> Self: ... + @property + def transition_probabilities(self) -> Basic: ... + def communication_classes(self) -> tList[tTuple[tList[Basic], Boolean, Integer]]: ... + def fundamental_matrix(self): ... + def absorbing_probabilities(self) -> None: ... + def absorbing_probabilites(self) -> None: ... + def is_regular(self) -> And: ... + def is_ergodic(self): ... + def is_absorbing_state(self, state) -> bool | None: ... + def is_absorbing_chain(self) -> And: ... + def stationary_distribution(self, condition_set=...) -> tUnion[ImmutableMatrix, ConditionSet, Lambda]: ... + def fixed_row_vector(self) -> ImmutableMatrix | ConditionSet | Lambda: ... + @property + def limiting_distribution(self) -> ImmutableMatrix | ConditionSet | Lambda: ... + def decompose(self) -> tTuple[tList[Basic], ImmutableMatrix, ImmutableMatrix, ImmutableMatrix]: ... + def canonical_form(self) -> tTuple[tList[Basic], ImmutableMatrix]: ... + def sample(self) -> Generator[Basic, Any, None]: ... class ContinuousMarkovChain(ContinuousTimeStochasticProcess, MarkovProcess): index_set = ... - def __new__(cls, sym, state_space=..., gen_mat=...) -> Self: - ... - + def __new__(cls, sym, state_space=..., gen_mat=...) -> Self: ... @property - def generator_matrix(self) -> Basic: - ... - + def generator_matrix(self) -> Basic: ... @cacheit - def transition_probabilities(self, gen_mat=...) -> Lambda | None: - ... - - def limiting_distribution(self) -> Lambda | ImmutableMatrix | None: - ... - - + def transition_probabilities(self, gen_mat=...) -> Lambda | None: ... + def limiting_distribution(self) -> Lambda | ImmutableMatrix | None: ... class BernoulliProcess(DiscreteTimeStochasticProcess): index_set = ... - def __new__(cls, sym, p, success=..., failure=...) -> Self: - ... - + def __new__(cls, sym, p, success=..., failure=...) -> Self: ... @property - def symbol(self) -> Basic: - ... - + def symbol(self) -> Basic: ... @property - def p(self) -> Basic: - ... - + def p(self) -> Basic: ... @property - def success(self) -> Basic: - ... - + def success(self) -> Basic: ... @property - def failure(self) -> Basic: - ... - + def failure(self) -> Basic: ... @property - def state_space(self) -> FiniteSet: - ... - - def distribution(self, key=...) -> BernoulliDistribution: - ... - - def simple_rv(self, rv) -> RandomSymbol: - ... - - def expectation(self, expr, condition=..., evaluate=..., **kwargs) -> Order | tuple[Any, ...] | Sum | Any | Piecewise | Basic | Equality | Relational | Ne | Integral | bool | None: - ... - - def probability(self, condition, given_condition=..., evaluate=..., **kwargs) -> BernoulliDistribution | Probability | Any | Equality | Lambda | Order | Relational | Ne | int: - ... - - def density(self, x) -> Piecewise: - ... - - - -class _SubstituteRV: - ... + def state_space(self) -> FiniteSet: ... + def distribution(self, key=...) -> BernoulliDistribution: ... + def simple_rv(self, rv) -> RandomSymbol: ... + def expectation( + self, expr, condition=..., evaluate=..., **kwargs + ) -> Order | tuple[Any, ...] | Sum | Any | Piecewise | Basic | Equality | Relational | Ne | Integral | bool | None: ... + def probability( + self, condition, given_condition=..., evaluate=..., **kwargs + ) -> BernoulliDistribution | Probability | Any | Equality | Lambda | Order | Relational | Ne | int: ... + def density(self, x) -> Piecewise: ... +class _SubstituteRV: ... -def get_timerv_swaps(expr, condition) -> tuple[list[Any], dict[Any, Any]]: - ... +def get_timerv_swaps(expr, condition) -> tuple[list[Any], dict[Any, Any]]: ... class CountingProcess(ContinuousTimeStochasticProcess): index_set = ... @property - def symbol(self) -> Basic: - ... - - def expectation(self, expr, condition=..., evaluate=..., **kwargs) -> Add | ExpectationMatrix | Expectation | Order | tuple[Any, ...] | Sum | Any | Piecewise | Basic | Equality | Relational | Ne | Integral | bool | None: - ... - - def probability(self, condition, given_condition=..., evaluate=..., **kwargs) -> Add | Mul | Probability | BernoulliDistribution | Any | Equality | Lambda | Order | Relational | Ne | int: - ... - - + def symbol(self) -> Basic: ... + def expectation( + self, expr, condition=..., evaluate=..., **kwargs + ) -> ( + Add + | ExpectationMatrix + | Expectation + | Order + | tuple[Any, ...] + | Sum + | Any + | Piecewise + | Basic + | Equality + | Relational + | Ne + | Integral + | bool + | None + ): ... + def probability( + self, condition, given_condition=..., evaluate=..., **kwargs + ) -> Add | Mul | Probability | BernoulliDistribution | Any | Equality | Lambda | Order | Relational | Ne | int: ... class PoissonProcess(CountingProcess): - def __new__(cls, sym, lamda) -> Self: - ... - + def __new__(cls, sym, lamda) -> Self: ... @property - def lamda(self) -> Basic: - ... - + def lamda(self) -> Basic: ... @property - def state_space(self): - ... - - def distribution(self, key) -> PoissonDistribution: - ... - - def density(self, x): - ... - - def simple_rv(self, rv) -> RandomSymbol: - ... - - def __add__(self, other) -> PoissonProcess: - ... - - def split(self, l1, l2) -> tuple[PoissonProcess, PoissonProcess]: - ... - - + def state_space(self): ... + def distribution(self, key) -> PoissonDistribution: ... + def density(self, x): ... + def simple_rv(self, rv) -> RandomSymbol: ... + def __add__(self, other) -> PoissonProcess: ... + def split(self, l1, l2) -> tuple[PoissonProcess, PoissonProcess]: ... class WienerProcess(CountingProcess): - def __new__(cls, sym) -> Self: - ... - + def __new__(cls, sym) -> Self: ... @property - def state_space(self): - ... - - def distribution(self, key) -> NormalDistribution: - ... - - def density(self, x): - ... - - def simple_rv(self, rv) -> RandomSymbol | JointRandomSymbol: - ... - - + def state_space(self): ... + def distribution(self, key) -> NormalDistribution: ... + def density(self, x): ... + def simple_rv(self, rv) -> RandomSymbol | JointRandomSymbol: ... class GammaProcess(CountingProcess): - def __new__(cls, sym, lamda, gamma) -> Self: - ... - + def __new__(cls, sym, lamda, gamma) -> Self: ... @property - def lamda(self) -> Basic: - ... - + def lamda(self) -> Basic: ... @property - def gamma(self) -> Basic: - ... - + def gamma(self) -> Basic: ... @property - def state_space(self) -> FiniteSet: - ... - - def distribution(self, key) -> GammaDistribution: - ... - - def density(self, x): - ... - - def simple_rv(self, rv) -> RandomSymbol: - ... - - - + def state_space(self) -> FiniteSet: ... + def distribution(self, key) -> GammaDistribution: ... + def density(self, x): ... + def simple_rv(self, rv) -> RandomSymbol: ... diff --git a/stubs/sympy-stubs/stats/symbolic_multivariate_probability.pyi b/stubs/sympy-stubs/stats/symbolic_multivariate_probability.pyi index 72794829..dcc3557c 100644 --- a/stubs/sympy-stubs/stats/symbolic_multivariate_probability.pyi +++ b/stubs/sympy-stubs/stats/symbolic_multivariate_probability.pyi @@ -7,41 +7,19 @@ from sympy.matrices.expressions.special import ZeroMatrix from sympy.stats.symbolic_probability import Covariance, Expectation, Variance class ExpectationMatrix(Expectation, MatrixExpr): - def __new__(cls, expr, condition=...) -> Self: - ... - + def __new__(cls, expr, condition=...) -> Self: ... @property - def shape(self): - ... - - def expand(self, **hints) -> Basic | Add | Self: - ... - - + def shape(self): ... + def expand(self, **hints) -> Basic | Add | Self: ... class VarianceMatrix(Variance, MatrixExpr): - def __new__(cls, arg, condition=...) -> Self: - ... - + def __new__(cls, arg, condition=...) -> Self: ... @property - def shape(self): - ... - - def expand(self, **hints) -> ZeroMatrix | Self: - ... - - + def shape(self): ... + def expand(self, **hints) -> ZeroMatrix | Self: ... class CrossCovarianceMatrix(Covariance, MatrixExpr): - def __new__(cls, arg1, arg2, condition=...) -> Self: - ... - + def __new__(cls, arg1, arg2, condition=...) -> Self: ... @property - def shape(self): - ... - - def expand(self, **hints) -> ZeroMatrix | CrossCovarianceMatrix | Add: - ... - - - + def shape(self): ... + def expand(self, **hints) -> ZeroMatrix | CrossCovarianceMatrix | Add: ... diff --git a/stubs/sympy-stubs/stats/symbolic_probability.pyi b/stubs/sympy-stubs/stats/symbolic_probability.pyi index 976b4175..9cdd41ac 100644 --- a/stubs/sympy-stubs/stats/symbolic_probability.pyi +++ b/stubs/sympy-stubs/stats/symbolic_probability.pyi @@ -10,86 +10,82 @@ from sympy.stats.frv_types import BernoulliDistribution from sympy.stats.rv import RandomSymbol, is_random from sympy.stats.symbolic_multivariate_probability import CrossCovarianceMatrix, ExpectationMatrix, VarianceMatrix -__all__ = ['Probability', 'Expectation', 'Variance', 'Covariance'] -@is_random.register(Expr) -def _(x) -> bool: - ... +__all__ = ["Probability", "Expectation", "Variance", "Covariance"] +@is_random.register(Expr) +def _(x) -> bool: ... @is_random.register(RandomSymbol) -def _(x) -> Literal[True]: - ... +def _(x) -> Literal[True]: ... class Probability(Expr): - def __new__(cls, prob, condition=..., **kwargs) -> Self: - ... - - def doit(self, **hints) -> Any | BernoulliDistribution | Probability | Equality | Lambda | Order | Relational | Ne | int: - ... - - _eval_rewrite_as_Sum = ... - def evaluate_integral(self) -> Any | BernoulliDistribution | Probability | Equality | Lambda | Order | Relational | Ne | int: - ... - + def __new__(cls, prob, condition=..., **kwargs) -> Self: ... + def doit(self, **hints) -> Any | BernoulliDistribution | Probability | Equality | Lambda | Order | Relational | Ne | int: ... + _eval_rewrite_as_Sum = ... + def evaluate_integral( + self, + ) -> Any | BernoulliDistribution | Probability | Equality | Lambda | Order | Relational | Ne | int: ... class Expectation(Expr): - def __new__(cls, expr, condition=..., **kwargs) -> ExpectationMatrix | Self: - ... - - def expand(self, **hints) -> Basic | Add | Self: - ... - - def doit(self, **hints) -> Basic | Expectation | tuple[Any, ...] | Sum | Order | Any | Piecewise | Equality | Relational | Ne | Integral | Self | None: - ... - + def __new__(cls, expr, condition=..., **kwargs) -> ExpectationMatrix | Self: ... + def expand(self, **hints) -> Basic | Add | Self: ... + def doit( + self, **hints + ) -> ( + Basic + | Expectation + | tuple[Any, ...] + | Sum + | Order + | Any + | Piecewise + | Equality + | Relational + | Ne + | Integral + | Self + | None + ): ... + _eval_rewrite_as_Sum = ... - def evaluate_integral(self) -> Basic | Expectation | tuple[Any, ...] | Sum | Order | Any | Piecewise | Equality | Relational | Ne | Integral | Self | None: - ... - - evaluate_sum = ... + def evaluate_integral( + self, + ) -> ( + Basic + | Expectation + | tuple[Any, ...] + | Sum + | Order + | Any + | Piecewise + | Equality + | Relational + | Ne + | Integral + | Self + | None + ): ... + evaluate_sum = ... class Variance(Expr): - def __new__(cls, arg, condition=..., **kwargs) -> VarianceMatrix | Self: - ... - - def expand(self, **hints) -> Self: - ... - - _eval_rewrite_as_Sum = ... - def evaluate_integral(self) -> Self | Any: - ... - + def __new__(cls, arg, condition=..., **kwargs) -> VarianceMatrix | Self: ... + def expand(self, **hints) -> Self: ... + _eval_rewrite_as_Sum = ... + def evaluate_integral(self) -> Self | Any: ... class Covariance(Expr): - def __new__(cls, arg1, arg2, condition=..., **kwargs) -> CrossCovarianceMatrix | Self: - ... - - def expand(self, **hints) -> CrossCovarianceMatrix | Covariance | Add: - ... - - _eval_rewrite_as_Sum = ... - def evaluate_integral(self) -> Self | Any: - ... - + def __new__(cls, arg1, arg2, condition=..., **kwargs) -> CrossCovarianceMatrix | Self: ... + def expand(self, **hints) -> CrossCovarianceMatrix | Covariance | Add: ... + _eval_rewrite_as_Sum = ... + def evaluate_integral(self) -> Self | Any: ... class Moment(Expr): - def __new__(cls, X, n, c=..., condition=..., **kwargs) -> Self: - ... - - def doit(self, **hints) -> Any: - ... - - + def __new__(cls, X, n, c=..., condition=..., **kwargs) -> Self: ... + def doit(self, **hints) -> Any: ... class CentralMoment(Expr): - def __new__(cls, X, n, condition=..., **kwargs) -> Self: - ... - - def doit(self, **hints) -> Any: - ... - - - + def __new__(cls, X, n, condition=..., **kwargs) -> Self: ... + def doit(self, **hints) -> Any: ... diff --git a/stubs/sympy-stubs/strategies/__init__.pyi b/stubs/sympy-stubs/strategies/__init__.pyi index 592475e1..63c6a390 100644 --- a/stubs/sympy-stubs/strategies/__init__.pyi +++ b/stubs/sympy-stubs/strategies/__init__.pyi @@ -4,4 +4,26 @@ from sympy.strategies.rl import distribute, flatten, glom, rebuild, rm_id, sort, from sympy.strategies.tools import canon, typed from sympy.strategies.util import new -__all__ = ['rl', 'traverse', 'rm_id', 'unpack', 'flatten', 'sort', 'glom', 'distribute', 'rebuild', 'new', 'condition', 'debug', 'chain', 'null_safe', 'do_one', 'exhaust', 'minimize', 'tryit', 'canon', 'typed', 'branch'] +__all__ = [ + "rl", + "traverse", + "rm_id", + "unpack", + "flatten", + "sort", + "glom", + "distribute", + "rebuild", + "new", + "condition", + "debug", + "chain", + "null_safe", + "do_one", + "exhaust", + "minimize", + "tryit", + "canon", + "typed", + "branch", +] diff --git a/stubs/sympy-stubs/strategies/branch/__init__.pyi b/stubs/sympy-stubs/strategies/branch/__init__.pyi index 777f4979..5750ba9b 100644 --- a/stubs/sympy-stubs/strategies/branch/__init__.pyi +++ b/stubs/sympy-stubs/strategies/branch/__init__.pyi @@ -14,4 +14,18 @@ from sympy.strategies.branch.core import ( ) from sympy.strategies.branch.tools import canon -__all__ = ['traverse', 'condition', 'debug', 'multiplex', 'exhaust', 'notempty', 'chain', 'onaction', 'sfilter', 'yieldify', 'do_one', 'identity', 'canon'] +__all__ = [ + "traverse", + "condition", + "debug", + "multiplex", + "exhaust", + "notempty", + "chain", + "onaction", + "sfilter", + "yieldify", + "do_one", + "identity", + "canon", +] diff --git a/stubs/sympy-stubs/strategies/branch/core.pyi b/stubs/sympy-stubs/strategies/branch/core.pyi index ecc0e727..b1c1fba6 100644 --- a/stubs/sympy-stubs/strategies/branch/core.pyi +++ b/stubs/sympy-stubs/strategies/branch/core.pyi @@ -1,35 +1,13 @@ from typing import Any, Callable, Generator -def identity(x) -> Generator[Any, Any, None]: - ... - -def exhaust(brule) -> Callable[..., Generator[Any, Any, None]]: - ... - -def onaction(brule, fn) -> Callable[..., Generator[Any, Any, None]]: - ... - -def debug(brule, file=...) -> Callable[..., Generator[Any, Any, None]]: - ... - -def multiplex(*brules) -> Callable[..., Generator[Any, Any, None]]: - ... - -def condition(cond, brule) -> Callable[..., Generator[Any, Any, None]]: - ... - -def sfilter(pred, brule) -> Callable[..., Generator[Any, Any, None]]: - ... - -def notempty(brule) -> Callable[..., Generator[Any, Any, None]]: - ... - -def do_one(*brules) -> Callable[..., Generator[Any, Any, None]]: - ... - -def chain(*brules) -> Callable[..., Generator[Any, Any, None]]: - ... - -def yieldify(rl) -> Callable[..., Generator[Any, Any, None]]: - ... - +def identity(x) -> Generator[Any, Any, None]: ... +def exhaust(brule) -> Callable[..., Generator[Any, Any, None]]: ... +def onaction(brule, fn) -> Callable[..., Generator[Any, Any, None]]: ... +def debug(brule, file=...) -> Callable[..., Generator[Any, Any, None]]: ... +def multiplex(*brules) -> Callable[..., Generator[Any, Any, None]]: ... +def condition(cond, brule) -> Callable[..., Generator[Any, Any, None]]: ... +def sfilter(pred, brule) -> Callable[..., Generator[Any, Any, None]]: ... +def notempty(brule) -> Callable[..., Generator[Any, Any, None]]: ... +def do_one(*brules) -> Callable[..., Generator[Any, Any, None]]: ... +def chain(*brules) -> Callable[..., Generator[Any, Any, None]]: ... +def yieldify(rl) -> Callable[..., Generator[Any, Any, None]]: ... diff --git a/stubs/sympy-stubs/strategies/branch/tools.pyi b/stubs/sympy-stubs/strategies/branch/tools.pyi index dd0d525d..60ab6f8d 100644 --- a/stubs/sympy-stubs/strategies/branch/tools.pyi +++ b/stubs/sympy-stubs/strategies/branch/tools.pyi @@ -1,5 +1,3 @@ from typing import Any, Callable, Generator -def canon(*rules) -> Callable[..., Generator[Any, Any, None]]: - ... - +def canon(*rules) -> Callable[..., Generator[Any, Any, None]]: ... diff --git a/stubs/sympy-stubs/strategies/branch/traverse.pyi b/stubs/sympy-stubs/strategies/branch/traverse.pyi index c2117607..a8d9249d 100644 --- a/stubs/sympy-stubs/strategies/branch/traverse.pyi +++ b/stubs/sympy-stubs/strategies/branch/traverse.pyi @@ -1,8 +1,4 @@ from typing import Any, Callable, Generator -def top_down(brule, fns=...) -> Callable[..., Generator[Any, Any, None]]: - ... - -def sall(brule, fns=...) -> Callable[..., Generator[Any, Any, None]]: - ... - +def top_down(brule, fns=...) -> Callable[..., Generator[Any, Any, None]]: ... +def sall(brule, fns=...) -> Callable[..., Generator[Any, Any, None]]: ... diff --git a/stubs/sympy-stubs/strategies/core.pyi b/stubs/sympy-stubs/strategies/core.pyi index c39b710f..246dbb13 100644 --- a/stubs/sympy-stubs/strategies/core.pyi +++ b/stubs/sympy-stubs/strategies/core.pyi @@ -1,38 +1,17 @@ from collections.abc import Callable, Mapping from typing import Any, TypeVar -_S = TypeVar('_S') -_T = TypeVar('_T') -def identity(x: _T) -> _T: - ... - -def exhaust(rule: Callable[[_T], _T]) -> Callable[[_T], _T]: - ... - -def memoize(rule: Callable[[_S], _T]) -> Callable[[_S], _T]: - ... - -def condition(cond: Callable[[_T], bool], rule: Callable[[_T], _T]) -> Callable[[_T], _T]: - ... - -def chain(*rules: Callable[[_T], _T]) -> Callable[[_T], _T]: - ... - -def debug(rule, file=...) -> Callable[..., Any]: - ... - -def null_safe(rule: Callable[[_T], _T | None]) -> Callable[[_T], _T]: - ... - -def tryit(rule: Callable[[_T], _T], exception) -> Callable[[_T], _T]: - ... - -def do_one(*rules: Callable[[_T], _T]) -> Callable[[_T], _T]: - ... - -def switch(key: Callable[[_S], _T], ruledict: Mapping[_T, Callable[[_S], _S]]) -> Callable[[_S], _S]: - ... - -def minimize(*rules: Callable[[_S], _T], objective=...) -> Callable[[_S], _T]: - ... - +_S = TypeVar("_S") +_T = TypeVar("_T") + +def identity(x: _T) -> _T: ... +def exhaust(rule: Callable[[_T], _T]) -> Callable[[_T], _T]: ... +def memoize(rule: Callable[[_S], _T]) -> Callable[[_S], _T]: ... +def condition(cond: Callable[[_T], bool], rule: Callable[[_T], _T]) -> Callable[[_T], _T]: ... +def chain(*rules: Callable[[_T], _T]) -> Callable[[_T], _T]: ... +def debug(rule, file=...) -> Callable[..., Any]: ... +def null_safe(rule: Callable[[_T], _T | None]) -> Callable[[_T], _T]: ... +def tryit(rule: Callable[[_T], _T], exception) -> Callable[[_T], _T]: ... +def do_one(*rules: Callable[[_T], _T]) -> Callable[[_T], _T]: ... +def switch(key: Callable[[_S], _T], ruledict: Mapping[_T, Callable[[_S], _S]]) -> Callable[[_S], _S]: ... +def minimize(*rules: Callable[[_S], _T], objective=...) -> Callable[[_S], _T]: ... diff --git a/stubs/sympy-stubs/strategies/rl.pyi b/stubs/sympy-stubs/strategies/rl.pyi index 24ada2a5..c9f996e0 100644 --- a/stubs/sympy-stubs/strategies/rl.pyi +++ b/stubs/sympy-stubs/strategies/rl.pyi @@ -1,26 +1,10 @@ from typing import Any, Callable -def rm_id(isid, new=...) -> Callable[..., Any]: - ... - -def glom(key, count, combine) -> Callable[..., Any]: - ... - -def sort(key, new=...) -> Callable[..., Any]: - ... - -def distribute(A, B) -> Callable[..., Any]: - ... - -def subs(a, b) -> Callable[..., Any]: - ... - -def unpack(expr): - ... - -def flatten(expr, new=...): - ... - -def rebuild(expr): - ... - +def rm_id(isid, new=...) -> Callable[..., Any]: ... +def glom(key, count, combine) -> Callable[..., Any]: ... +def sort(key, new=...) -> Callable[..., Any]: ... +def distribute(A, B) -> Callable[..., Any]: ... +def subs(a, b) -> Callable[..., Any]: ... +def unpack(expr): ... +def flatten(expr, new=...): ... +def rebuild(expr): ... diff --git a/stubs/sympy-stubs/strategies/tools.pyi b/stubs/sympy-stubs/strategies/tools.pyi index 68e73028..21f0ddb8 100644 --- a/stubs/sympy-stubs/strategies/tools.pyi +++ b/stubs/sympy-stubs/strategies/tools.pyi @@ -1,11 +1,5 @@ from typing import Any, Callable -def subs(d, **kwargs) -> Callable[[Any], Any] | Callable[..., Any]: - ... - -def canon(*rules, **kwargs) -> Callable[[Any], Any]: - ... - -def typed(ruletypes) -> Callable[[object], object]: - ... - +def subs(d, **kwargs) -> Callable[[Any], Any] | Callable[..., Any]: ... +def canon(*rules, **kwargs) -> Callable[[Any], Any]: ... +def typed(ruletypes) -> Callable[[object], object]: ... diff --git a/stubs/sympy-stubs/strategies/traverse.pyi b/stubs/sympy-stubs/strategies/traverse.pyi index 1eff7215..8f4d30dd 100644 --- a/stubs/sympy-stubs/strategies/traverse.pyi +++ b/stubs/sympy-stubs/strategies/traverse.pyi @@ -1,17 +1,7 @@ from typing import Any, Callable -def top_down(rule, fns=...) -> Callable[[Any], Any]: - ... - -def bottom_up(rule, fns=...) -> Callable[[Any], Any]: - ... - -def top_down_once(rule, fns=...) -> Callable[[Any], Any]: - ... - -def bottom_up_once(rule, fns=...) -> Callable[[Any], Any]: - ... - -def sall(rule, fns=...) -> Callable[..., Any]: - ... - +def top_down(rule, fns=...) -> Callable[[Any], Any]: ... +def bottom_up(rule, fns=...) -> Callable[[Any], Any]: ... +def top_down_once(rule, fns=...) -> Callable[[Any], Any]: ... +def bottom_up_once(rule, fns=...) -> Callable[[Any], Any]: ... +def sall(rule, fns=...) -> Callable[..., Any]: ... diff --git a/stubs/sympy-stubs/strategies/tree.pyi b/stubs/sympy-stubs/strategies/tree.pyi index 329976a1..bfcd1c8f 100644 --- a/stubs/sympy-stubs/strategies/tree.pyi +++ b/stubs/sympy-stubs/strategies/tree.pyi @@ -1,14 +1,6 @@ from typing import Any, Callable, Generator -def treeapply(tree, join, leaf=...): - ... - -def greedy(tree, objective=..., **kwargs): - ... - -def allresults(tree, leaf=...): - ... - -def brute(tree, objective=..., **kwargs) -> Callable[..., Any]: - ... - +def treeapply(tree, join, leaf=...): ... +def greedy(tree, objective=..., **kwargs): ... +def allresults(tree, leaf=...): ... +def brute(tree, objective=..., **kwargs) -> Callable[..., Any]: ... diff --git a/stubs/sympy-stubs/tensor/__init__.pyi b/stubs/sympy-stubs/tensor/__init__.pyi index f6d7dd3d..288f08a5 100644 --- a/stubs/sympy-stubs/tensor/__init__.pyi +++ b/stubs/sympy-stubs/tensor/__init__.pyi @@ -17,4 +17,24 @@ from sympy.tensor.functions import shape from sympy.tensor.index_methods import get_contraction_structure, get_indices from sympy.tensor.indexed import Idx, Indexed, IndexedBase -__all__ = ['IndexedBase', 'Idx', 'Indexed', 'get_contraction_structure', 'get_indices', 'shape', 'MutableDenseNDimArray', 'ImmutableDenseNDimArray', 'MutableSparseNDimArray', 'ImmutableSparseNDimArray', 'NDimArray', 'tensorproduct', 'tensorcontraction', 'tensordiagonal', 'derive_by_array', 'permutedims', 'Array', 'DenseNDimArray', 'SparseNDimArray'] +__all__ = [ + "IndexedBase", + "Idx", + "Indexed", + "get_contraction_structure", + "get_indices", + "shape", + "MutableDenseNDimArray", + "ImmutableDenseNDimArray", + "MutableSparseNDimArray", + "ImmutableSparseNDimArray", + "NDimArray", + "tensorproduct", + "tensorcontraction", + "tensordiagonal", + "derive_by_array", + "permutedims", + "Array", + "DenseNDimArray", + "SparseNDimArray", +] diff --git a/stubs/sympy-stubs/tensor/array/__init__.pyi b/stubs/sympy-stubs/tensor/array/__init__.pyi index 2d113a25..cc70adad 100644 --- a/stubs/sympy-stubs/tensor/array/__init__.pyi +++ b/stubs/sympy-stubs/tensor/array/__init__.pyi @@ -5,4 +5,21 @@ from sympy.tensor.array.ndim_array import ArrayKind, NDimArray from sympy.tensor.array.sparse_ndim_array import ImmutableSparseNDimArray, MutableSparseNDimArray, SparseNDimArray Array = ImmutableDenseNDimArray -__all__ = ['MutableDenseNDimArray', 'ImmutableDenseNDimArray', 'DenseNDimArray', 'MutableSparseNDimArray', 'ImmutableSparseNDimArray', 'SparseNDimArray', 'NDimArray', 'ArrayKind', 'tensorproduct', 'tensorcontraction', 'tensordiagonal', 'derive_by_array', 'permutedims', 'ArrayComprehension', 'ArrayComprehensionMap', 'Array'] +__all__ = [ + "MutableDenseNDimArray", + "ImmutableDenseNDimArray", + "DenseNDimArray", + "MutableSparseNDimArray", + "ImmutableSparseNDimArray", + "SparseNDimArray", + "NDimArray", + "ArrayKind", + "tensorproduct", + "tensorcontraction", + "tensordiagonal", + "derive_by_array", + "permutedims", + "ArrayComprehension", + "ArrayComprehensionMap", + "Array", +] diff --git a/stubs/sympy-stubs/tensor/array/array_comprehension.pyi b/stubs/sympy-stubs/tensor/array/array_comprehension.pyi index 9890d4ae..6015bd14 100644 --- a/stubs/sympy-stubs/tensor/array/array_comprehension.pyi +++ b/stubs/sympy-stubs/tensor/array/array_comprehension.pyi @@ -5,67 +5,31 @@ from sympy.core import Basic from sympy.matrices import Matrix class ArrayComprehension(Basic): - def __new__(cls, function, *symbols, **assumptions) -> Self: - ... - + def __new__(cls, function, *symbols, **assumptions) -> Self: ... @property - def function(self) -> Basic: - ... - + def function(self) -> Basic: ... @property - def limits(self): - ... - + def limits(self): ... @property - def free_symbols(self) -> set[Basic] | set[Basic | Any]: - ... - + def free_symbols(self) -> set[Basic] | set[Basic | Any]: ... @property - def variables(self) -> list[Any]: - ... - + def variables(self) -> list[Any]: ... @property - def bound_symbols(self) -> list[Any]: - ... - + def bound_symbols(self) -> list[Any]: ... @property - def shape(self): - ... - + def shape(self): ... @property - def is_shape_numeric(self) -> bool: - ... - - def rank(self): - ... - - def __len__(self): - ... - - def doit(self, **hints) -> Self | ImmutableDenseNDimArray: - ... - - def tolist(self) -> list[Any]: - ... - - def tomatrix(self) -> Matrix: - ... - + def is_shape_numeric(self) -> bool: ... + def rank(self): ... + def __len__(self): ... + def doit(self, **hints) -> Self | ImmutableDenseNDimArray: ... + def tolist(self) -> list[Any]: ... + def tomatrix(self) -> Matrix: ... - -def isLambda(v) -> Literal[False]: - ... +def isLambda(v) -> Literal[False]: ... class ArrayComprehensionMap(ArrayComprehension): - def __new__(cls, function, *symbols, **assumptions) -> Self: - ... - + def __new__(cls, function, *symbols, **assumptions) -> Self: ... @property def func(self) -> type[Any]: - class _(ArrayComprehensionMap): - ... - - - - - + class _(ArrayComprehensionMap): ... diff --git a/stubs/sympy-stubs/tensor/array/array_derivatives.pyi b/stubs/sympy-stubs/tensor/array/array_derivatives.pyi index d50dee0e..68b6c94c 100644 --- a/stubs/sympy-stubs/tensor/array/array_derivatives.pyi +++ b/stubs/sympy-stubs/tensor/array/array_derivatives.pyi @@ -2,12 +2,6 @@ from sympy.core.function import Derivative class ArrayDerivative(Derivative): is_scalar = ... - def __new__(cls, expr, *variables, **kwargs) -> ArrayDerivative: - ... - + def __new__(cls, expr, *variables, **kwargs) -> ArrayDerivative: ... @property - def shape(self): - ... - - - + def shape(self): ... diff --git a/stubs/sympy-stubs/tensor/array/arrayop.pyi b/stubs/sympy-stubs/tensor/array/arrayop.pyi index bd4ace9a..2600c588 100644 --- a/stubs/sympy-stubs/tensor/array/arrayop.pyi +++ b/stubs/sympy-stubs/tensor/array/arrayop.pyi @@ -11,33 +11,33 @@ from sympy.tensor.array.expressions.array_expressions import ( ZeroArray, ) -def tensorproduct(*args) -> NDimArray | ImmutableDenseNDimArray | ZeroArray | ArrayTensorProduct | ArrayContraction | Basic | PermuteDims | ImmutableSparseNDimArray: - ... - -def tensorcontraction(array, *contraction_axes) -> Basic | ZeroArray | ArrayTensorProduct | ArrayContraction | PermuteDims | ImmutableDenseNDimArray | Any: - ... - -def tensordiagonal(array, *diagonal_axes) -> ZeroArray | ArrayTensorProduct | ArrayContraction | Basic | PermuteDims | ArrayDiagonal | ImmutableDenseNDimArray | Any: - ... - -def derive_by_array(expr, dx) -> ImmutableDenseNDimArray | ImmutableSparseNDimArray | Any | ArrayDerivative | Derivative: - ... - -def permutedims(expr, perm=..., index_order_old=..., index_order_new=...) -> ZeroArray | ArrayTensorProduct | ArrayContraction | Basic | PermuteDims | ImmutableSparseNDimArray | ImmutableDenseNDimArray: - ... +def tensorproduct( + *args, +) -> ( + NDimArray + | ImmutableDenseNDimArray + | ZeroArray + | ArrayTensorProduct + | ArrayContraction + | Basic + | PermuteDims + | ImmutableSparseNDimArray +): ... +def tensorcontraction( + array, *contraction_axes +) -> Basic | ZeroArray | ArrayTensorProduct | ArrayContraction | PermuteDims | ImmutableDenseNDimArray | Any: ... +def tensordiagonal( + array, *diagonal_axes +) -> ZeroArray | ArrayTensorProduct | ArrayContraction | Basic | PermuteDims | ArrayDiagonal | ImmutableDenseNDimArray | Any: ... +def derive_by_array(expr, dx) -> ImmutableDenseNDimArray | ImmutableSparseNDimArray | Any | ArrayDerivative | Derivative: ... +def permutedims( + expr, perm=..., index_order_old=..., index_order_new=... +) -> ( + ZeroArray | ArrayTensorProduct | ArrayContraction | Basic | PermuteDims | ImmutableSparseNDimArray | ImmutableDenseNDimArray +): ... class Flatten(Printable): - def __init__(self, iterable) -> None: - ... - - def __iter__(self) -> Self: - ... - - def __next__(self) -> Basic | Literal[0]: - ... - - def next(self) -> Basic | Literal[0]: - ... - - - + def __init__(self, iterable) -> None: ... + def __iter__(self) -> Self: ... + def __next__(self) -> Basic | Literal[0]: ... + def next(self) -> Basic | Literal[0]: ... diff --git a/stubs/sympy-stubs/tensor/array/dense_ndim_array.pyi b/stubs/sympy-stubs/tensor/array/dense_ndim_array.pyi index 0a2dbba3..26cdba8a 100644 --- a/stubs/sympy-stubs/tensor/array/dense_ndim_array.pyi +++ b/stubs/sympy-stubs/tensor/array/dense_ndim_array.pyi @@ -8,53 +8,23 @@ from sympy.tensor.array.ndim_array import ArrayKind, ImmutableNDimArray, NDimArr class DenseNDimArray(NDimArray): _array: List[Basic] - def __new__(self, *args, **kwargs) -> ImmutableDenseNDimArray: - ... - + def __new__(self, *args, **kwargs) -> ImmutableDenseNDimArray: ... @property - def kind(self) -> ArrayKind: - ... - - def __getitem__(self, index) -> Indexed | Self | Basic: - ... - + def kind(self) -> ArrayKind: ... + def __getitem__(self, index) -> Indexed | Self | Basic: ... @classmethod - def zeros(cls, *shape): - ... - - def tomatrix(self) -> Matrix: - ... - - def reshape(self, *newshape) -> Self: - ... - - + def zeros(cls, *shape): ... + def tomatrix(self) -> Matrix: ... + def reshape(self, *newshape) -> Self: ... class ImmutableDenseNDimArray(DenseNDimArray, ImmutableNDimArray): - def __new__(cls, iterable, shape=..., **kwargs) -> Self: - ... - - def __setitem__(self, index, value): - ... - - def as_mutable(self) -> MutableDenseNDimArray: - ... - - + def __new__(cls, iterable, shape=..., **kwargs) -> Self: ... + def __setitem__(self, index, value): ... + def as_mutable(self) -> MutableDenseNDimArray: ... class MutableDenseNDimArray(DenseNDimArray, MutableNDimArray): - def __new__(cls, iterable=..., shape=..., **kwargs) -> Self: - ... - - def __setitem__(self, index, value) -> None: - ... - - def as_immutable(self) -> ImmutableDenseNDimArray: - ... - + def __new__(cls, iterable=..., shape=..., **kwargs) -> Self: ... + def __setitem__(self, index, value) -> None: ... + def as_immutable(self) -> ImmutableDenseNDimArray: ... @property - def free_symbols(self) -> set[Basic]: - ... - - - + def free_symbols(self) -> set[Basic]: ... diff --git a/stubs/sympy-stubs/tensor/array/expressions/array_expressions.pyi b/stubs/sympy-stubs/tensor/array/expressions/array_expressions.pyi index 531adf85..5f7ea7db 100644 --- a/stubs/sympy-stubs/tensor/array/expressions/array_expressions.pyi +++ b/stubs/sympy-stubs/tensor/array/expressions/array_expressions.pyi @@ -10,306 +10,175 @@ from sympy.tensor.array.dense_ndim_array import ImmutableDenseNDimArray class _ArrayExpr(Expr): shape: tTuple[Expr, ...] - def __getitem__(self, item) -> ArrayElement: - ... - - + def __getitem__(self, item) -> ArrayElement: ... class ArraySymbol(_ArrayExpr): - def __new__(cls, symbol, shape: typing.Iterable) -> ArraySymbol: - ... - + def __new__(cls, symbol, shape: typing.Iterable) -> ArraySymbol: ... @property - def name(self) -> Basic: - ... - + def name(self) -> Basic: ... @property - def shape(self) -> Basic: - ... - - def as_explicit(self) -> ImmutableDenseNDimArray: - ... - - + def shape(self) -> Basic: ... + def as_explicit(self) -> ImmutableDenseNDimArray: ... class ArrayElement(Expr): _diff_wrt = ... is_symbol = ... is_commutative = ... - def __new__(cls, name, indices) -> Self: - ... - + def __new__(cls, name, indices) -> Self: ... @property - def name(self) -> Basic: - ... - + def name(self) -> Basic: ... @property - def indices(self) -> Basic: - ... - - + def indices(self) -> Basic: ... class ZeroArray(_ArrayExpr): - def __new__(cls, *shape) -> Self: - ... - + def __new__(cls, *shape) -> Self: ... @property - def shape(self) -> tuple[Basic, ...]: - ... - - def as_explicit(self): - ... - - + def shape(self) -> tuple[Basic, ...]: ... + def as_explicit(self): ... class OneArray(_ArrayExpr): - def __new__(cls, *shape) -> Self: - ... - + def __new__(cls, *shape) -> Self: ... @property - def shape(self) -> tuple[Basic, ...]: - ... - - def as_explicit(self) -> ImmutableDenseNDimArray: - ... - - + def shape(self) -> tuple[Basic, ...]: ... + def as_explicit(self) -> ImmutableDenseNDimArray: ... class _CodegenArrayAbstract(Basic): @property - def subranks(self): - ... - - def subrank(self) -> int: - ... - + def subranks(self): ... + def subrank(self) -> int: ... @property - def shape(self): - ... - - def doit(self, **hints): - ... - - + def shape(self): ... + def doit(self, **hints): ... class ArrayTensorProduct(_CodegenArrayAbstract): - def __new__(cls, *args, **kwargs) -> ZeroArray | ArrayTensorProduct | ArrayContraction | Basic | PermuteDims | Self: - ... - - def as_explicit(self) -> NDimArray | ImmutableDenseNDimArray | ZeroArray | ArrayTensorProduct | ArrayContraction | Basic | PermuteDims | ImmutableSparseNDimArray: - ... - - + def __new__(cls, *args, **kwargs) -> ZeroArray | ArrayTensorProduct | ArrayContraction | Basic | PermuteDims | Self: ... + def as_explicit( + self, + ) -> ( + NDimArray + | ImmutableDenseNDimArray + | ZeroArray + | ArrayTensorProduct + | ArrayContraction + | Basic + | PermuteDims + | ImmutableSparseNDimArray + ): ... class ArrayAdd(_CodegenArrayAbstract): - def __new__(cls, *args, **kwargs) -> ZeroArray | Self: - ... - - def as_explicit(self) -> Any: - ... - - + def __new__(cls, *args, **kwargs) -> ZeroArray | Self: ... + def as_explicit(self) -> Any: ... class PermuteDims(_CodegenArrayAbstract): - def __new__(cls, expr, permutation=..., index_order_old=..., index_order_new=..., **kwargs) -> ZeroArray | ArrayTensorProduct | ArrayContraction | Basic | Self: - ... - - @property - def expr(self) -> Basic: - ... - - @property - def permutation(self) -> Basic: - ... - - def nest_permutation(self) -> Self | ZeroArray | ArrayTensorProduct | ArrayContraction | Basic | PermuteDims | ArrayAdd: - ... - - def as_explicit(self) -> ZeroArray | ArrayTensorProduct | ArrayContraction | Basic | PermuteDims | ImmutableSparseNDimArray | ImmutableDenseNDimArray: - ... - - + def __new__( + cls, expr, permutation=..., index_order_old=..., index_order_new=..., **kwargs + ) -> ZeroArray | ArrayTensorProduct | ArrayContraction | Basic | Self: ... + @property + def expr(self) -> Basic: ... + @property + def permutation(self) -> Basic: ... + def nest_permutation(self) -> Self | ZeroArray | ArrayTensorProduct | ArrayContraction | Basic | PermuteDims | ArrayAdd: ... + def as_explicit( + self, + ) -> ( + ZeroArray + | ArrayTensorProduct + | ArrayContraction + | Basic + | PermuteDims + | ImmutableSparseNDimArray + | ImmutableDenseNDimArray + ): ... class ArrayDiagonal(_CodegenArrayAbstract): - def __new__(cls, expr, *diagonal_indices, **kwargs) -> ZeroArray | ArrayTensorProduct | ArrayContraction | Basic | PermuteDims | Self: - ... - + def __new__( + cls, expr, *diagonal_indices, **kwargs + ) -> ZeroArray | ArrayTensorProduct | ArrayContraction | Basic | PermuteDims | Self: ... @property - def expr(self) -> Basic: - ... - + def expr(self) -> Basic: ... @property - def diagonal_indices(self) -> tuple[Basic, ...]: - ... - - def as_explicit(self) -> ZeroArray | ArrayTensorProduct | ArrayContraction | Basic | PermuteDims | ArrayDiagonal | ImmutableDenseNDimArray | Any: - ... - - + def diagonal_indices(self) -> tuple[Basic, ...]: ... + def as_explicit( + self, + ) -> ( + ZeroArray | ArrayTensorProduct | ArrayContraction | Basic | PermuteDims | ArrayDiagonal | ImmutableDenseNDimArray | Any + ): ... class ArrayElementwiseApplyFunc(_CodegenArrayAbstract): - def __new__(cls, function, element) -> Self: - ... - + def __new__(cls, function, element) -> Self: ... @property - def function(self) -> Basic: - ... - + def function(self) -> Basic: ... @property - def expr(self) -> Basic: - ... - + def expr(self) -> Basic: ... @property - def shape(self): - ... - - def as_explicit(self): - ... - - + def shape(self): ... + def as_explicit(self): ... class ArrayContraction(_CodegenArrayAbstract): - def __new__(cls, expr, *contraction_indices, **kwargs) -> Basic | ZeroArray | ArrayTensorProduct | ArrayContraction | PermuteDims | Self: - ... - - def __mul__(self, other) -> Self: - ... - - def __rmul__(self, other) -> Self: - ... - - def split_multiple_contractions(self) -> ZeroArray | ArrayTensorProduct | ArrayContraction | Basic | PermuteDims: - ... - - def flatten_contraction_of_diagonal(self) -> Self | Basic | ZeroArray | ArrayTensorProduct | ArrayContraction | PermuteDims: - ... - + def __new__( + cls, expr, *contraction_indices, **kwargs + ) -> Basic | ZeroArray | ArrayTensorProduct | ArrayContraction | PermuteDims | Self: ... + def __mul__(self, other) -> Self: ... + def __rmul__(self, other) -> Self: ... + def split_multiple_contractions(self) -> ZeroArray | ArrayTensorProduct | ArrayContraction | Basic | PermuteDims: ... + def flatten_contraction_of_diagonal( + self, + ) -> Self | Basic | ZeroArray | ArrayTensorProduct | ArrayContraction | PermuteDims: ... @property - def free_indices(self): - ... - + def free_indices(self): ... @property - def free_indices_to_position(self) -> dict[Any, Any]: - ... - + def free_indices_to_position(self) -> dict[Any, Any]: ... @property - def expr(self) -> Basic: - ... - + def expr(self) -> Basic: ... @property - def contraction_indices(self) -> tuple[Basic, ...]: - ... - - def sort_args_by_name(self) -> Self | Basic | ZeroArray | ArrayTensorProduct | ArrayContraction | PermuteDims: - ... - - def as_explicit(self) -> Basic | ZeroArray | ArrayTensorProduct | ArrayContraction | PermuteDims | ImmutableDenseNDimArray | Any: - ... - - + def contraction_indices(self) -> tuple[Basic, ...]: ... + def sort_args_by_name(self) -> Self | Basic | ZeroArray | ArrayTensorProduct | ArrayContraction | PermuteDims: ... + def as_explicit( + self, + ) -> Basic | ZeroArray | ArrayTensorProduct | ArrayContraction | PermuteDims | ImmutableDenseNDimArray | Any: ... class Reshape(_CodegenArrayAbstract): - def __new__(cls, expr, shape) -> Self: - ... - + def __new__(cls, expr, shape) -> Self: ... @property - def shape(self): - ... - + def shape(self): ... @property - def expr(self): - ... - - def doit(self, *args, **kwargs) -> Reshape: - ... - - def as_explicit(self) -> Self | Array: - ... - - + def expr(self): ... + def doit(self, *args, **kwargs) -> Reshape: ... + def as_explicit(self) -> Self | Array: ... class _ArgE: indices: List[Optional[int]] - def __init__(self, element, indices: Optional[List[Optional[int]]] = ...) -> None: - ... - - def __str__(self) -> str: - ... - - __repr__ = ... + def __init__(self, element, indices: Optional[List[Optional[int]]] = ...) -> None: ... + def __str__(self) -> str: ... + __repr__ = ... class _IndPos: - def __init__(self, arg: int, rel: int) -> None: - ... - - def __str__(self) -> str: - ... - - __repr__ = ... - def __iter__(self) -> Generator[int, Any, None]: - ... - + def __init__(self, arg: int, rel: int) -> None: ... + def __str__(self) -> str: ... + __repr__ = ... + def __iter__(self) -> Generator[int, Any, None]: ... class _EditArrayContraction: - def __init__(self, base_array: typing.Union[ArrayContraction, ArrayDiagonal, ArrayTensorProduct]) -> None: - ... - - def insert_after(self, arg: _ArgE, new_arg: _ArgE) -> None: - ... - - def get_new_contraction_index(self) -> int: - ... - - def refresh_indices(self) -> None: - ... - - def merge_scalars(self) -> None: - ... - - def to_array_contraction(self) -> ZeroArray | ArrayTensorProduct | ArrayContraction | Basic | PermuteDims: - ... - - def get_contraction_indices(self) -> List[List[int]]: - ... - - def get_mapping_for_index(self, ind) -> List[_IndPos]: - ... - - def get_contraction_indices_to_ind_rel_pos(self) -> List[List[_IndPos]]: - ... - - def count_args_with_index(self, index: int) -> int: - ... - - def get_args_with_index(self, index: int) -> List[_ArgE]: - ... - - @property - def number_of_diagonal_indices(self) -> int: - ... - - def track_permutation_start(self) -> None: - ... - - def track_permutation_merge(self, destination: _ArgE, from_element: _ArgE) -> None: - ... - - def get_absolute_free_range(self, arg: _ArgE) -> typing.Tuple[int, int]: - ... - - def get_absolute_range(self, arg: _ArgE) -> typing.Tuple[int, int]: - ... - - - -def get_rank(expr) -> int: - ... - -def get_shape(expr) -> tuple[()]: - ... - -def nest_permutation(expr) -> PermuteDims | ZeroArray | ArrayTensorProduct | ArrayContraction | Basic | ArrayAdd: - ... - + def __init__(self, base_array: typing.Union[ArrayContraction, ArrayDiagonal, ArrayTensorProduct]) -> None: ... + def insert_after(self, arg: _ArgE, new_arg: _ArgE) -> None: ... + def get_new_contraction_index(self) -> int: ... + def refresh_indices(self) -> None: ... + def merge_scalars(self) -> None: ... + def to_array_contraction(self) -> ZeroArray | ArrayTensorProduct | ArrayContraction | Basic | PermuteDims: ... + def get_contraction_indices(self) -> List[List[int]]: ... + def get_mapping_for_index(self, ind) -> List[_IndPos]: ... + def get_contraction_indices_to_ind_rel_pos(self) -> List[List[_IndPos]]: ... + def count_args_with_index(self, index: int) -> int: ... + def get_args_with_index(self, index: int) -> List[_ArgE]: ... + @property + def number_of_diagonal_indices(self) -> int: ... + def track_permutation_start(self) -> None: ... + def track_permutation_merge(self, destination: _ArgE, from_element: _ArgE) -> None: ... + def get_absolute_free_range(self, arg: _ArgE) -> typing.Tuple[int, int]: ... + def get_absolute_range(self, arg: _ArgE) -> typing.Tuple[int, int]: ... + +def get_rank(expr) -> int: ... +def get_shape(expr) -> tuple[()]: ... +def nest_permutation(expr) -> PermuteDims | ZeroArray | ArrayTensorProduct | ArrayContraction | Basic | ArrayAdd: ... diff --git a/stubs/sympy-stubs/tensor/array/expressions/arrayexpr_derivatives.pyi b/stubs/sympy-stubs/tensor/array/expressions/arrayexpr_derivatives.pyi index 58a4c187..112975f6 100644 --- a/stubs/sympy-stubs/tensor/array/expressions/arrayexpr_derivatives.pyi +++ b/stubs/sympy-stubs/tensor/array/expressions/arrayexpr_derivatives.pyi @@ -22,77 +22,45 @@ from sympy.tensor.array.expressions.array_expressions import ( ) @singledispatch -def array_derive(expr, x): - ... - +def array_derive(expr, x): ... @array_derive.register(Expr) -def _(expr: Expr, x: _ArrayExpr) -> ZeroArray: - ... - +def _(expr: Expr, x: _ArrayExpr) -> ZeroArray: ... @array_derive.register(ArrayTensorProduct) -def _(expr: ArrayTensorProduct, x: Expr) -> ZeroArray | ArrayAdd: - ... - +def _(expr: ArrayTensorProduct, x: Expr) -> ZeroArray | ArrayAdd: ... @array_derive.register(ArraySymbol) -def _(expr: ArraySymbol, x: _ArrayExpr) -> ZeroArray | ArrayTensorProduct | ArrayContraction | Basic | PermuteDims: - ... - +def _(expr: ArraySymbol, x: _ArrayExpr) -> ZeroArray | ArrayTensorProduct | ArrayContraction | Basic | PermuteDims: ... @array_derive.register(MatrixSymbol) -def _(expr: MatrixSymbol, x: _ArrayExpr) -> ZeroArray | ArrayTensorProduct | ArrayContraction | Basic | PermuteDims: - ... - +def _(expr: MatrixSymbol, x: _ArrayExpr) -> ZeroArray | ArrayTensorProduct | ArrayContraction | Basic | PermuteDims: ... @array_derive.register(Identity) -def _(expr: Identity, x: _ArrayExpr) -> ZeroArray: - ... - +def _(expr: Identity, x: _ArrayExpr) -> ZeroArray: ... @array_derive.register(OneMatrix) -def _(expr: OneMatrix, x: _ArrayExpr) -> ZeroArray: - ... - +def _(expr: OneMatrix, x: _ArrayExpr) -> ZeroArray: ... @array_derive.register(Transpose) -def _(expr: Transpose, x: Expr) -> ZeroArray | ArrayTensorProduct | ArrayContraction | Basic | PermuteDims: - ... - +def _(expr: Transpose, x: Expr) -> ZeroArray | ArrayTensorProduct | ArrayContraction | Basic | PermuteDims: ... @array_derive.register(Inverse) -def _(expr: Inverse, x: Expr) -> ZeroArray | ArrayTensorProduct | ArrayContraction | Basic | PermuteDims: - ... - +def _(expr: Inverse, x: Expr) -> ZeroArray | ArrayTensorProduct | ArrayContraction | Basic | PermuteDims: ... @array_derive.register(ElementwiseApplyFunction) -def _(expr: ElementwiseApplyFunction, x: Expr) -> ZeroArray | ArrayTensorProduct | ArrayContraction | Basic | PermuteDims | ArrayDiagonal: - ... - +def _( + expr: ElementwiseApplyFunction, x: Expr +) -> ZeroArray | ArrayTensorProduct | ArrayContraction | Basic | PermuteDims | ArrayDiagonal: ... @array_derive.register(ArrayElementwiseApplyFunc) -def _(expr: ArrayElementwiseApplyFunc, x: Expr) -> ZeroArray | ArrayTensorProduct | ArrayContraction | Basic | PermuteDims | ArrayDiagonal: - ... - +def _( + expr: ArrayElementwiseApplyFunc, x: Expr +) -> ZeroArray | ArrayTensorProduct | ArrayContraction | Basic | PermuteDims | ArrayDiagonal: ... @array_derive.register(MatrixExpr) -def _(expr: MatrixExpr, x: Expr): - ... - +def _(expr: MatrixExpr, x: Expr): ... @array_derive.register(HadamardProduct) -def _(expr: HadamardProduct, x: Expr): - ... - +def _(expr: HadamardProduct, x: Expr): ... @array_derive.register(ArrayContraction) -def _(expr: ArrayContraction, x: Expr) -> Basic | ZeroArray | ArrayTensorProduct | ArrayContraction | PermuteDims: - ... - +def _(expr: ArrayContraction, x: Expr) -> Basic | ZeroArray | ArrayTensorProduct | ArrayContraction | PermuteDims: ... @array_derive.register(ArrayDiagonal) -def _(expr: ArrayDiagonal, x: Expr) -> ZeroArray | ArrayTensorProduct | ArrayContraction | Basic | PermuteDims | ArrayDiagonal: - ... - +def _( + expr: ArrayDiagonal, x: Expr +) -> ZeroArray | ArrayTensorProduct | ArrayContraction | Basic | PermuteDims | ArrayDiagonal: ... @array_derive.register(ArrayAdd) -def _(expr: ArrayAdd, x: Expr) -> ZeroArray | ArrayAdd: - ... - +def _(expr: ArrayAdd, x: Expr) -> ZeroArray | ArrayAdd: ... @array_derive.register(PermuteDims) -def _(expr: PermuteDims, x: Expr) -> ZeroArray | ArrayTensorProduct | ArrayContraction | Basic | PermuteDims: - ... - +def _(expr: PermuteDims, x: Expr) -> ZeroArray | ArrayTensorProduct | ArrayContraction | Basic | PermuteDims: ... @array_derive.register(Reshape) -def _(expr: Reshape, x: Expr) -> Reshape: - ... - -def matrix_derive(expr, x): - ... - +def _(expr: Reshape, x: Expr) -> Reshape: ... +def matrix_derive(expr, x): ... diff --git a/stubs/sympy-stubs/tensor/array/expressions/from_array_to_indexed.pyi b/stubs/sympy-stubs/tensor/array/expressions/from_array_to_indexed.pyi index af50a90e..502689a2 100644 --- a/stubs/sympy-stubs/tensor/array/expressions/from_array_to_indexed.pyi +++ b/stubs/sympy-stubs/tensor/array/expressions/from_array_to_indexed.pyi @@ -3,15 +3,8 @@ from sympy.core.add import Add from sympy.core.relational import Relational from sympy.tensor.array.expressions.array_expressions import ArrayElement -def convert_array_to_indexed(expr, indices) -> Mul | Equality | Relational | Ne | Sum | Add | ArrayElement: - ... +def convert_array_to_indexed(expr, indices) -> Mul | Equality | Relational | Ne | Sum | Add | ArrayElement: ... class _ConvertArrayToIndexed: - def __init__(self) -> None: - ... - - def do_convert(self, expr, indices) -> Mul | Equality | Relational | Ne | Sum | Add | ArrayElement: - ... - - - + def __init__(self) -> None: ... + def do_convert(self, expr, indices) -> Mul | Equality | Relational | Ne | Sum | Add | ArrayElement: ... diff --git a/stubs/sympy-stubs/tensor/array/expressions/from_array_to_matrix.pyi b/stubs/sympy-stubs/tensor/array/expressions/from_array_to_matrix.pyi index 4e1f6956..e6b79809 100644 --- a/stubs/sympy-stubs/tensor/array/expressions/from_array_to_matrix.pyi +++ b/stubs/sympy-stubs/tensor/array/expressions/from_array_to_matrix.pyi @@ -19,82 +19,69 @@ from sympy.tensor.array.expressions.array_expressions import ( ) @singledispatch -def _array2matrix(expr) -> Any: - ... - +def _array2matrix(expr) -> Any: ... @_array2matrix.register(ZeroArray) -def _(expr: ZeroArray) -> ZeroMatrix | ZeroArray: - ... - +def _(expr: ZeroArray) -> ZeroMatrix | ZeroArray: ... @_array2matrix.register(ArrayTensorProduct) -def _(expr: ArrayTensorProduct) -> Mul | ArrayTensorProduct: - ... - +def _(expr: ArrayTensorProduct) -> Mul | ArrayTensorProduct: ... @_array2matrix.register(ArrayContraction) -def _(expr: ArrayContraction) -> GenericIdentity | Order | object | Mul | ArrayTensorProduct | ZeroArray | ArrayContraction | Basic | PermuteDims | Trace | None: - ... - +def _( + expr: ArrayContraction, +) -> ( + GenericIdentity + | Order + | object + | Mul + | ArrayTensorProduct + | ZeroArray + | ArrayContraction + | Basic + | PermuteDims + | Trace + | None +): ... @_array2matrix.register(ArrayDiagonal) -def _(expr: ArrayDiagonal) -> ArrayDiagonal: - ... - +def _(expr: ArrayDiagonal) -> ArrayDiagonal: ... @_array2matrix.register(PermuteDims) -def _(expr: PermuteDims) -> ZeroArray | ArrayTensorProduct | ArrayContraction | Basic | PermuteDims | Any | Transpose | Mul: - ... - +def _(expr: PermuteDims) -> ZeroArray | ArrayTensorProduct | ArrayContraction | Basic | PermuteDims | Any | Transpose | Mul: ... @_array2matrix.register(ArrayAdd) -def _(expr: ArrayAdd) -> MatAdd | GenericZeroMatrix | ZeroArray | ArrayAdd: - ... - +def _(expr: ArrayAdd) -> MatAdd | GenericZeroMatrix | ZeroArray | ArrayAdd: ... @_array2matrix.register(ArrayElementwiseApplyFunc) -def _(expr: ArrayElementwiseApplyFunc) -> MatrixExpr | ElementwiseApplyFunction | ArrayElementwiseApplyFunc: - ... - +def _(expr: ArrayElementwiseApplyFunc) -> MatrixExpr | ElementwiseApplyFunction | ArrayElementwiseApplyFunc: ... @_array2matrix.register(ArrayElement) -def _(expr: ArrayElement) -> MatrixElement | ArrayElement: - ... - +def _(expr: ArrayElement) -> MatrixElement | ArrayElement: ... @singledispatch -def _remove_trivial_dims(expr) -> Any: - ... - +def _remove_trivial_dims(expr) -> Any: ... @_remove_trivial_dims.register(ArrayTensorProduct) -def _(expr: ArrayTensorProduct) -> tuple[ArrayTensorProduct | Mul, List[int] | list[Any]]: - ... - +def _(expr: ArrayTensorProduct) -> tuple[ArrayTensorProduct | Mul, List[int] | list[Any]]: ... @_remove_trivial_dims.register(ArrayAdd) -def _(expr: ArrayAdd) -> tuple[ArrayAdd, list[Any]] | tuple[ArrayAdd, Any] | tuple[MatAdd | Any | GenericZeroMatrix | ZeroArray | ArrayAdd, Any]: - ... - +def _( + expr: ArrayAdd, +) -> tuple[ArrayAdd, list[Any]] | tuple[ArrayAdd, Any] | tuple[MatAdd | Any | GenericZeroMatrix | ZeroArray | ArrayAdd, Any]: ... @_remove_trivial_dims.register(PermuteDims) -def _(expr: PermuteDims) -> tuple[Any | ZeroArray | ArrayTensorProduct | ArrayContraction | Basic | PermuteDims, List[int] | list[Any]]: - ... - +def _( + expr: PermuteDims, +) -> tuple[Any | ZeroArray | ArrayTensorProduct | ArrayContraction | Basic | PermuteDims, List[int] | list[Any]]: ... @_remove_trivial_dims.register(ArrayContraction) -def _(expr: ArrayContraction) -> tuple[Any, List[int]] | tuple[Basic | Any | ZeroArray | ArrayTensorProduct | ArrayContraction | PermuteDims, list[int]]: - ... - +def _( + expr: ArrayContraction, +) -> tuple[Any, List[int]] | tuple[Basic | Any | ZeroArray | ArrayTensorProduct | ArrayContraction | PermuteDims, list[int]]: ... @_remove_trivial_dims.register(ArrayDiagonal) -def _(expr: ArrayDiagonal) -> tuple[Any | ZeroArray | ArrayTensorProduct | ArrayContraction | Basic | PermuteDims, List[int]] | tuple[Any | ZeroArray | ArrayTensorProduct | ArrayContraction | Basic | PermuteDims, list[Any]]: - ... - +def _( + expr: ArrayDiagonal, +) -> ( + tuple[Any | ZeroArray | ArrayTensorProduct | ArrayContraction | Basic | PermuteDims, List[int]] + | tuple[Any | ZeroArray | ArrayTensorProduct | ArrayContraction | Basic | PermuteDims, list[Any]] +): ... @_remove_trivial_dims.register(ElementwiseApplyFunction) -def _(expr: ElementwiseApplyFunction) -> tuple[Any, list[Any]] | tuple[MatrixExpr | ElementwiseApplyFunction, list[Any]]: - ... - +def _(expr: ElementwiseApplyFunction) -> tuple[Any, list[Any]] | tuple[MatrixExpr | ElementwiseApplyFunction, list[Any]]: ... @_remove_trivial_dims.register(ArrayElementwiseApplyFunc) -def _(expr: ArrayElementwiseApplyFunc) -> tuple[ArrayElementwiseApplyFunc, list[Any]]: - ... - -def convert_array_to_matrix(expr): - ... - -def identify_hadamard_products(expr: tUnion[ArrayContraction, ArrayDiagonal]) -> ZeroArray | ArrayTensorProduct | ArrayContraction | Basic | PermuteDims: - ... - -def identify_removable_identity_matrices(expr) -> ZeroArray | ArrayTensorProduct | ArrayContraction | Basic | PermuteDims: - ... - -def remove_identity_matrices(expr: ArrayContraction) -> tuple[Any | ZeroArray | ArrayTensorProduct | ArrayContraction | Basic | PermuteDims, list[int]]: - ... - +def _(expr: ArrayElementwiseApplyFunc) -> tuple[ArrayElementwiseApplyFunc, list[Any]]: ... +def convert_array_to_matrix(expr): ... +def identify_hadamard_products( + expr: tUnion[ArrayContraction, ArrayDiagonal] +) -> ZeroArray | ArrayTensorProduct | ArrayContraction | Basic | PermuteDims: ... +def identify_removable_identity_matrices(expr) -> ZeroArray | ArrayTensorProduct | ArrayContraction | Basic | PermuteDims: ... +def remove_identity_matrices( + expr: ArrayContraction, +) -> tuple[Any | ZeroArray | ArrayTensorProduct | ArrayContraction | Basic | PermuteDims, list[int]]: ... diff --git a/stubs/sympy-stubs/tensor/array/expressions/from_indexed_to_array.pyi b/stubs/sympy-stubs/tensor/array/expressions/from_indexed_to_array.pyi index 9a457e06..9f8e56af 100644 --- a/stubs/sympy-stubs/tensor/array/expressions/from_indexed_to_array.pyi +++ b/stubs/sympy-stubs/tensor/array/expressions/from_indexed_to_array.pyi @@ -11,6 +11,18 @@ from sympy.tensor.array.expressions.array_expressions import ( ZeroArray, ) -def convert_indexed_to_array(expr, first_indices=...) -> ArrayElement | Basic | ZeroArray | ArrayTensorProduct | ArrayContraction | PermuteDims | ArrayDiagonal | KroneckerDelta | ArrayAdd | ArrayElementwiseApplyFunc | Pow: - ... - +def convert_indexed_to_array( + expr, first_indices=... +) -> ( + ArrayElement + | Basic + | ZeroArray + | ArrayTensorProduct + | ArrayContraction + | PermuteDims + | ArrayDiagonal + | KroneckerDelta + | ArrayAdd + | ArrayElementwiseApplyFunc + | Pow +): ... diff --git a/stubs/sympy-stubs/tensor/array/mutable_ndim_array.pyi b/stubs/sympy-stubs/tensor/array/mutable_ndim_array.pyi index 1c5c888d..8f731fcd 100644 --- a/stubs/sympy-stubs/tensor/array/mutable_ndim_array.pyi +++ b/stubs/sympy-stubs/tensor/array/mutable_ndim_array.pyi @@ -3,11 +3,5 @@ from typing import Self from sympy.tensor.array.ndim_array import NDimArray class MutableNDimArray(NDimArray): - def as_immutable(self): - ... - - def as_mutable(self) -> Self: - ... - - - + def as_immutable(self): ... + def as_mutable(self) -> Self: ... diff --git a/stubs/sympy-stubs/tensor/array/ndim_array.pyi b/stubs/sympy-stubs/tensor/array/ndim_array.pyi index 75d39d30..2b89561e 100644 --- a/stubs/sympy-stubs/tensor/array/ndim_array.pyi +++ b/stubs/sympy-stubs/tensor/array/ndim_array.pyi @@ -10,93 +10,47 @@ from sympy.tensor.array.array_derivatives import ArrayDerivative from sympy.tensor.array.expressions.array_expressions import ArrayContraction, ArrayTensorProduct, PermuteDims, ZeroArray class ArrayKind(Kind): - def __new__(cls, element_kind=...) -> Self: - ... - - def __repr__(self): - ... - - + def __new__(cls, element_kind=...) -> Self: ... + def __repr__(self): ... class NDimArray(Printable): _diff_wrt = ... is_scalar = ... - def __new__(cls, iterable, shape=..., **kwargs) -> ImmutableDenseNDimArray: - ... - - def __getitem__(self, index): - ... - - def __len__(self): - ... - + def __new__(cls, iterable, shape=..., **kwargs) -> ImmutableDenseNDimArray: ... + def __getitem__(self, index): ... + def __len__(self): ... @property - def shape(self): - ... - - def rank(self): - ... - - def diff(self, *args, **kwargs) -> ArrayDerivative: - ... - - def applyfunc(self, f) -> ImmutableSparseNDimArray | ImmutableDenseNDimArray: - ... - - def tolist(self) -> list[Any]: - ... - - def __add__(self, other) -> NotImplementedType | Self: - ... - - def __sub__(self, other) -> NotImplementedType | Self: - ... - - def __mul__(self, other) -> ImmutableSparseNDimArray | ImmutableDenseNDimArray: - ... - - def __rmul__(self, other) -> ImmutableSparseNDimArray | ImmutableDenseNDimArray: - ... - - def __truediv__(self, other) -> ImmutableSparseNDimArray | ImmutableDenseNDimArray: - ... - - def __rtruediv__(self, other): - ... - - def __neg__(self) -> ImmutableSparseNDimArray | ImmutableDenseNDimArray: - ... - - def __iter__(self) -> Generator[Any, Any, None]: - ... - - def __eq__(self, other) -> bool: - ... - - def __ne__(self, other) -> bool: - ... - - def transpose(self) -> ZeroArray | ArrayTensorProduct | ArrayContraction | Basic | PermuteDims | ImmutableSparseNDimArray | ImmutableDenseNDimArray: - ... - - def conjugate(self): - ... - - def adjoint(self) -> type[UndefinedFunction]: - ... - - + def shape(self): ... + def rank(self): ... + def diff(self, *args, **kwargs) -> ArrayDerivative: ... + def applyfunc(self, f) -> ImmutableSparseNDimArray | ImmutableDenseNDimArray: ... + def tolist(self) -> list[Any]: ... + def __add__(self, other) -> NotImplementedType | Self: ... + def __sub__(self, other) -> NotImplementedType | Self: ... + def __mul__(self, other) -> ImmutableSparseNDimArray | ImmutableDenseNDimArray: ... + def __rmul__(self, other) -> ImmutableSparseNDimArray | ImmutableDenseNDimArray: ... + def __truediv__(self, other) -> ImmutableSparseNDimArray | ImmutableDenseNDimArray: ... + def __rtruediv__(self, other): ... + def __neg__(self) -> ImmutableSparseNDimArray | ImmutableDenseNDimArray: ... + def __iter__(self) -> Generator[Any, Any, None]: ... + def __eq__(self, other) -> bool: ... + def __ne__(self, other) -> bool: ... + def transpose( + self, + ) -> ( + ZeroArray + | ArrayTensorProduct + | ArrayContraction + | Basic + | PermuteDims + | ImmutableSparseNDimArray + | ImmutableDenseNDimArray + ): ... + def conjugate(self): ... + def adjoint(self) -> type[UndefinedFunction]: ... class ImmutableNDimArray(NDimArray, Basic): _op_priority = ... - def __hash__(self) -> int: - ... - - def as_immutable(self) -> Self: - ... - - def as_mutable(self): - ... - - - + def __hash__(self) -> int: ... + def as_immutable(self) -> Self: ... + def as_mutable(self): ... diff --git a/stubs/sympy-stubs/tensor/array/sparse_ndim_array.pyi b/stubs/sympy-stubs/tensor/array/sparse_ndim_array.pyi index 4bb3852f..a7b158b1 100644 --- a/stubs/sympy-stubs/tensor/array/sparse_ndim_array.pyi +++ b/stubs/sympy-stubs/tensor/array/sparse_ndim_array.pyi @@ -6,49 +6,21 @@ from sympy.tensor.array.mutable_ndim_array import MutableNDimArray from sympy.tensor.array.ndim_array import ImmutableNDimArray, NDimArray class SparseNDimArray(NDimArray): - def __new__(self, *args, **kwargs) -> ImmutableSparseNDimArray: - ... - - def __getitem__(self, index) -> Indexed | Self: - ... - + def __new__(self, *args, **kwargs) -> ImmutableSparseNDimArray: ... + def __getitem__(self, index) -> Indexed | Self: ... @classmethod - def zeros(cls, *shape) -> Self: - ... - - def tomatrix(self) -> SparseMatrix: - ... - - def reshape(self, *newshape) -> Self: - ... - - + def zeros(cls, *shape) -> Self: ... + def tomatrix(self) -> SparseMatrix: ... + def reshape(self, *newshape) -> Self: ... class ImmutableSparseNDimArray(SparseNDimArray, ImmutableNDimArray): - def __new__(cls, iterable=..., shape=..., **kwargs) -> Self: - ... - - def __setitem__(self, index, value): - ... - - def as_mutable(self) -> MutableSparseNDimArray: - ... - - + def __new__(cls, iterable=..., shape=..., **kwargs) -> Self: ... + def __setitem__(self, index, value): ... + def as_mutable(self) -> MutableSparseNDimArray: ... class MutableSparseNDimArray(MutableNDimArray, SparseNDimArray): - def __new__(cls, iterable=..., shape=..., **kwargs) -> Self: - ... - - def __setitem__(self, index, value) -> None: - ... - - def as_immutable(self) -> ImmutableSparseNDimArray: - ... - + def __new__(cls, iterable=..., shape=..., **kwargs) -> Self: ... + def __setitem__(self, index, value) -> None: ... + def as_immutable(self) -> ImmutableSparseNDimArray: ... @property - def free_symbols(self) -> set[Any]: - ... - - - + def free_symbols(self) -> set[Any]: ... diff --git a/stubs/sympy-stubs/tensor/functions.pyi b/stubs/sympy-stubs/tensor/functions.pyi index 03336fc0..d9f7e2df 100644 --- a/stubs/sympy-stubs/tensor/functions.pyi +++ b/stubs/sympy-stubs/tensor/functions.pyi @@ -6,26 +6,13 @@ from sympy.core.expr import Expr class TensorProduct(Expr): is_number = ... - def __new__(cls, *args, **kwargs) -> Self: - ... - - def rank(self) -> int: - ... - + def __new__(cls, *args, **kwargs) -> Self: ... + def rank(self) -> int: ... @property - def shape(self) -> tuple[()]: - ... - - def __getitem__(self, index) -> Mul: - ... - - + def shape(self) -> tuple[()]: ... + def __getitem__(self, index) -> Mul: ... @singledispatch -def shape(expr): - ... - -class NoShapeError(Exception): - ... - +def shape(expr): ... +class NoShapeError(Exception): ... diff --git a/stubs/sympy-stubs/tensor/index_methods.pyi b/stubs/sympy-stubs/tensor/index_methods.pyi index a7a161e9..57aebf91 100644 --- a/stubs/sympy-stubs/tensor/index_methods.pyi +++ b/stubs/sympy-stubs/tensor/index_methods.pyi @@ -4,13 +4,26 @@ from sympy import Idx, Indexed, Piecewise from sympy.core.function import Function from sympy.functions.elementary.exponential import exp -class IndexConformanceException(Exception): - ... - - -def get_indices(expr) -> tuple[set[Any], dict[Any, Any]] | tuple[set[Idx], dict[Any, Any]] | tuple[set[Any], dict[Any, Any], tuple[Any, ...]] | tuple[Any, Any | dict[Any, Any]] | tuple[Any, dict[Any, Any]] | tuple[set[Any] | Any, Any]: - ... - -def get_contraction_structure(expr) -> dict[tuple[Any, ...] | None, set[Indexed]] | dict[None, set[Any]] | dict[tuple[Any, ...] | None, set[Any]] | dict[None, set[Any | exp]] | dict[Any, Any] | dict[None, Piecewise] | dict[None, set[Function]]: - ... +class IndexConformanceException(Exception): ... +def get_indices( + expr, +) -> ( + tuple[set[Any], dict[Any, Any]] + | tuple[set[Idx], dict[Any, Any]] + | tuple[set[Any], dict[Any, Any], tuple[Any, ...]] + | tuple[Any, Any | dict[Any, Any]] + | tuple[Any, dict[Any, Any]] + | tuple[set[Any] | Any, Any] +): ... +def get_contraction_structure( + expr, +) -> ( + dict[tuple[Any, ...] | None, set[Indexed]] + | dict[None, set[Any]] + | dict[tuple[Any, ...] | None, set[Any]] + | dict[None, set[Any | exp]] + | dict[Any, Any] + | dict[None, Piecewise] + | dict[None, set[Function]] +): ... diff --git a/stubs/sympy-stubs/tensor/indexed.pyi b/stubs/sympy-stubs/tensor/indexed.pyi index 84c02e49..4228b471 100644 --- a/stubs/sympy-stubs/tensor/indexed.pyi +++ b/stubs/sympy-stubs/tensor/indexed.pyi @@ -4,91 +4,51 @@ from sympy import Basic, MatrixBase, NDimArray from sympy.core import Expr from sympy.utilities.iterables import NotIterable -class IndexException(Exception): - ... - +class IndexException(Exception): ... class Indexed(Expr): is_commutative = ... is_Indexed = ... is_symbol = ... is_Atom = ... - def __new__(cls, base, *args, **kw_args) -> Self: - ... - + def __new__(cls, base, *args, **kw_args) -> Self: ... @property - def name(self) -> str: - ... - + def name(self) -> str: ... @property - def assumptions0(self) -> dict[Any, Any]: - ... - + def assumptions0(self) -> dict[Any, Any]: ... @property - def base(self) -> Basic: - ... - + def base(self) -> Basic: ... @property - def indices(self) -> tuple[Basic, ...]: - ... - + def indices(self) -> tuple[Basic, ...]: ... @property - def rank(self) -> int: - ... - + def rank(self) -> int: ... @property - def shape(self) -> Tuple: - ... - + def shape(self) -> Tuple: ... @property - def ranges(self) -> list[Any]: - ... - + def ranges(self) -> list[Any]: ... @property - def free_symbols(self) -> set[Self | Basic] | set[Basic]: - ... - + def free_symbols(self) -> set[Self | Basic] | set[Basic]: ... @property - def expr_free_symbols(self) -> set[Self]: - ... - - + def expr_free_symbols(self) -> set[Self]: ... class IndexedBase(Expr, NotIterable): is_commutative = ... is_symbol = ... is_Atom = ... - def __new__(cls, label, shape=..., *, offset=..., strides=..., **kw_args) -> MatrixBase | NDimArray | Self: - ... - - @property - def name(self): - ... - - @property - def assumptions0(self) -> dict[Any, Any]: - ... - - def __getitem__(self, indices, **kw_args) -> Indexed: - ... - - @property - def shape(self): - ... - - @property - def strides(self): - ... - - @property - def offset(self): - ... - - @property - def label(self) -> Basic: - ... - - + def __new__(cls, label, shape=..., *, offset=..., strides=..., **kw_args) -> MatrixBase | NDimArray | Self: ... + @property + def name(self): ... + @property + def assumptions0(self) -> dict[Any, Any]: ... + def __getitem__(self, indices, **kw_args) -> Indexed: ... + @property + def shape(self): ... + @property + def strides(self): ... + @property + def offset(self): ... + @property + def label(self) -> Basic: ... class Idx(Expr): is_integer = ... @@ -97,28 +57,14 @@ class Idx(Expr): is_symbol = ... is_Atom = ... _diff_wrt = ... - def __new__(cls, label, range=..., **kw_args) -> Self: - ... - + def __new__(cls, label, range=..., **kw_args) -> Self: ... @property - def label(self) -> Basic: - ... - + def label(self) -> Basic: ... @property - def lower(self) -> None: - ... - + def lower(self) -> None: ... @property - def upper(self) -> None: - ... - + def upper(self) -> None: ... @property - def name(self) -> str: - ... - + def name(self) -> str: ... @property - def free_symbols(self) -> set[Self]: - ... - - - + def free_symbols(self) -> set[Self]: ... diff --git a/stubs/sympy-stubs/tensor/tensor.pyi b/stubs/sympy-stubs/tensor/tensor.pyi index f1ce4c53..5e35a72d 100644 --- a/stubs/sympy-stubs/tensor/tensor.pyi +++ b/stubs/sympy-stubs/tensor/tensor.pyi @@ -18,859 +18,433 @@ from sympy.tensor.array.expressions.array_expressions import ( ) from sympy.utilities.decorator import deprecated, memoize_property -def deprecate_data() -> None: - ... - -def deprecate_fun_eval() -> None: - ... - -def deprecate_call() -> None: - ... +def deprecate_data() -> None: ... +def deprecate_fun_eval() -> None: ... +def deprecate_call() -> None: ... class _IndexStructure(CantSympify): - def __init__(self, free, dum, index_types, indices, canon_bp=...) -> None: - ... - + def __init__(self, free, dum, index_types, indices, canon_bp=...) -> None: ... @staticmethod - def from_indices(*indices) -> _IndexStructure: - ... - + def from_indices(*indices) -> _IndexStructure: ... @staticmethod - def from_components_free_dum(components, free, dum) -> _IndexStructure: - ... - - def get_indices(self): - ... - + def from_components_free_dum(components, free, dum) -> _IndexStructure: ... + def get_indices(self): ... @staticmethod - def generate_indices_from_free_dum_index_types(free, dum, index_types) -> list[Any]: - ... - - def get_free_indices(self) -> list[TensorIndex]: - ... - - def __str__(self) -> str: - ... - - def __repr__(self) -> LiteralString: - ... - - def perm2tensor(self, g, is_canon_bp=...) -> _IndexStructure: - ... - - def indices_canon_args(self) -> tuple[Perm, list[Any], list[Any]]: - ... - - + def generate_indices_from_free_dum_index_types(free, dum, index_types) -> list[Any]: ... + def get_free_indices(self) -> list[TensorIndex]: ... + def __str__(self) -> str: ... + def __repr__(self) -> LiteralString: ... + def perm2tensor(self, g, is_canon_bp=...) -> _IndexStructure: ... + def indices_canon_args(self) -> tuple[Perm, list[Any], list[Any]]: ... -def components_canon_args(components) -> list[Any]: - ... +def components_canon_args(components) -> list[Any]: ... class _TensorDataLazyEvaluator(CantSympify): _substitutions_dict: dict[Any, Any] = ... _substitutions_dict_tensmul: dict[Any, Any] = ... - def __getitem__(self, key) -> Any | Basic | ZeroArray | ArrayTensorProduct | ArrayContraction | PermuteDims | Indexed | ImmutableDenseNDimArray | None: - ... - + def __getitem__( + self, key + ) -> ( + Any | Basic | ZeroArray | ArrayTensorProduct | ArrayContraction | PermuteDims | Indexed | ImmutableDenseNDimArray | None + ): ... @staticmethod - def data_contract_dum(ndarray_list, dum, ext_rank) -> Basic | ZeroArray | ArrayTensorProduct | ArrayContraction | PermuteDims | ImmutableDenseNDimArray | Any: - ... - - def data_tensorhead_from_tensmul(self, data, tensmul, tensorhead) -> Basic | ZeroArray | ArrayTensorProduct | ArrayContraction | PermuteDims | ImmutableDenseNDimArray | Any | None: - ... - - def data_from_tensor(self, tensor) -> Basic | ZeroArray | ArrayTensorProduct | ArrayContraction | PermuteDims | ImmutableDenseNDimArray | Any | None: - ... - - def __setitem__(self, key, value) -> None: - ... - - def __delitem__(self, key) -> None: - ... - - def __contains__(self, key) -> bool: - ... - - def add_metric_data(self, metric, data) -> None: - ... - + def data_contract_dum( + ndarray_list, dum, ext_rank + ) -> Basic | ZeroArray | ArrayTensorProduct | ArrayContraction | PermuteDims | ImmutableDenseNDimArray | Any: ... + def data_tensorhead_from_tensmul( + self, data, tensmul, tensorhead + ) -> Basic | ZeroArray | ArrayTensorProduct | ArrayContraction | PermuteDims | ImmutableDenseNDimArray | Any | None: ... + def data_from_tensor( + self, tensor + ) -> Basic | ZeroArray | ArrayTensorProduct | ArrayContraction | PermuteDims | ImmutableDenseNDimArray | Any | None: ... + def __setitem__(self, key, value) -> None: ... + def __delitem__(self, key) -> None: ... + def __contains__(self, key) -> bool: ... + def add_metric_data(self, metric, data) -> None: ... @staticmethod - def inverse_matrix(ndarray) -> MutableDenseNDimArray: - ... - + def inverse_matrix(ndarray) -> MutableDenseNDimArray: ... @staticmethod - def inverse_transpose_matrix(ndarray) -> MutableDenseNDimArray: - ... - + def inverse_transpose_matrix(ndarray) -> MutableDenseNDimArray: ... @staticmethod - def add_rearrange_tensmul_parts(new_tensmul, old_tensmul) -> None: - ... - + def add_rearrange_tensmul_parts(new_tensmul, old_tensmul) -> None: ... @staticmethod - def parse_data(data) -> MutableDenseNDimArray: - ... - - + def parse_data(data) -> MutableDenseNDimArray: ... _tensor_data_substitution_dict = ... -class _TensorManager: - def __init__(self) -> None: - ... - - @property - def comm(self) -> list[dict[Any, Any]]: - ... - - def comm_symbols2i(self, i) -> int: - ... - - def comm_i2symbol(self, i) -> int: - ... - - def set_comm(self, i, j, c) -> None: - ... - - def set_comms(self, *args) -> None: - ... - - def get_comm(self, i, j): - ... - - def clear(self) -> None: - ... - +class _TensorManager: + def __init__(self) -> None: ... + @property + def comm(self) -> list[dict[Any, Any]]: ... + def comm_symbols2i(self, i) -> int: ... + def comm_i2symbol(self, i) -> int: ... + def set_comm(self, i, j, c) -> None: ... + def set_comms(self, *args) -> None: ... + def get_comm(self, i, j): ... + def clear(self) -> None: ... TensorManager = ... + class TensorIndexType(Basic): - def __new__(cls, name, dummy_name=..., dim=..., eps_dim=..., metric_symmetry=..., metric_name=..., **kwargs) -> Self: - ... - + def __new__(cls, name, dummy_name=..., dim=..., eps_dim=..., metric_symmetry=..., metric_name=..., **kwargs) -> Self: ... @property - def name(self): - ... - + def name(self): ... @property - def dummy_name(self): - ... - + def dummy_name(self): ... @property - def dim(self) -> Basic: - ... - + def dim(self) -> Basic: ... @property - def eps_dim(self) -> Basic: - ... - + def eps_dim(self) -> Basic: ... @memoize_property - def metric(self) -> TensorHead | None: - ... - + def metric(self) -> TensorHead | None: ... @memoize_property - def delta(self) -> TensorHead: - ... - + def delta(self) -> TensorHead: ... @memoize_property - def epsilon(self) -> TensorHead | None: - ... - - def set_metric(self, tensor) -> None: - ... - - def __lt__(self, other) -> bool: - ... - - def __str__(self) -> str: - ... - + def epsilon(self) -> TensorHead | None: ... + def set_metric(self, tensor) -> None: ... + def __lt__(self, other) -> bool: ... + def __str__(self) -> str: ... + __repr__ = ... @property - def data(self) -> Any | Basic | ZeroArray | ArrayTensorProduct | ArrayContraction | PermuteDims | Indexed | ImmutableDenseNDimArray | None: - ... - + def data( + self, + ) -> ( + Any | Basic | ZeroArray | ArrayTensorProduct | ArrayContraction | PermuteDims | Indexed | ImmutableDenseNDimArray | None + ): ... @data.setter - def data(self, data) -> None: - ... - + def data(self, data) -> None: ... @data.deleter - def data(self) -> None: - ... - - def get_kronecker_delta(self) -> TensorHead: - ... - - def get_epsilon(self) -> TensorHead | None: - ... - - + def data(self) -> None: ... + def get_kronecker_delta(self) -> TensorHead: ... + def get_epsilon(self) -> TensorHead | None: ... class TensorIndex(Basic): - def __new__(cls, name, tensor_index_type, is_up=...) -> Self: - ... - - @property - def name(self): - ... - - @property - def tensor_index_type(self) -> Basic: - ... - - @property - def is_up(self) -> Basic: - ... - - def __lt__(self, other) -> bool: - ... - - def __neg__(self) -> TensorIndex: - ... - - + def __new__(cls, name, tensor_index_type, is_up=...) -> Self: ... + @property + def name(self): ... + @property + def tensor_index_type(self) -> Basic: ... + @property + def is_up(self) -> Basic: ... + def __lt__(self, other) -> bool: ... + def __neg__(self) -> TensorIndex: ... -def tensor_indices(s, typ) -> TensorIndex | list[TensorIndex]: - ... +def tensor_indices(s, typ) -> TensorIndex | list[TensorIndex]: ... class TensorSymmetry(Basic): - def __new__(cls, *args, **kw_args) -> Self: - ... - + def __new__(cls, *args, **kw_args) -> Self: ... @property - def base(self) -> Basic: - ... - + def base(self) -> Basic: ... @property - def generators(self) -> Basic: - ... - + def generators(self) -> Basic: ... @property - def rank(self): - ... - + def rank(self): ... @classmethod - def fully_symmetric(cls, rank) -> TensorSymmetry: - ... - + def fully_symmetric(cls, rank) -> TensorSymmetry: ... @classmethod - def direct_product(cls, *args) -> TensorSymmetry: - ... - + def direct_product(cls, *args) -> TensorSymmetry: ... @classmethod - def riemann(cls) -> TensorSymmetry: - ... - + def riemann(cls) -> TensorSymmetry: ... @classmethod - def no_symmetry(cls, rank) -> TensorSymmetry: - ... - - + def no_symmetry(cls, rank) -> TensorSymmetry: ... -def tensorsymmetry(*args) -> TensorSymmetry: - ... - -@deprecated("TensorType is deprecated. Use tensor_heads() instead.", deprecated_since_version="1.5", active_deprecations_target="deprecated-tensortype") +def tensorsymmetry(*args) -> TensorSymmetry: ... +@deprecated( + "TensorType is deprecated. Use tensor_heads() instead.", + deprecated_since_version="1.5", + active_deprecations_target="deprecated-tensortype", +) class TensorType(Basic): is_commutative = ... - def __new__(cls, index_types, symmetry, **kw_args) -> Self: - ... - - @property - def index_types(self) -> Basic: - ... - - @property - def symmetry(self) -> Basic: - ... - - @property - def types(self): - ... - - def __str__(self) -> str: - ... - - def __call__(self, s, comm=...) -> TensorHead | list[TensorHead]: - ... - - + def __new__(cls, index_types, symmetry, **kw_args) -> Self: ... + @property + def index_types(self) -> Basic: ... + @property + def symmetry(self) -> Basic: ... + @property + def types(self): ... + def __str__(self) -> str: ... + def __call__(self, s, comm=...) -> TensorHead | list[TensorHead]: ... -def tensorhead(name, typ, sym=..., comm=...) -> TensorHead: - ... +def tensorhead(name, typ, sym=..., comm=...) -> TensorHead: ... class TensorHead(Basic): is_commutative = ... - def __new__(cls, name, index_types, symmetry=..., comm=...) -> Self: - ... - - @property - def name(self): - ... - - @property - def index_types(self) -> list[Any]: - ... - - @property - def symmetry(self) -> Basic: - ... - - @property - def rank(self) -> int: - ... - - def __lt__(self, other) -> bool: - ... - - def commutes_with(self, other): - ... - - def __call__(self, *indices, **kw_args) -> TensExpr: - ... - - def __pow__(self, other): - ... - - @property - def data(self) -> Any | Basic | ZeroArray | ArrayTensorProduct | ArrayContraction | PermuteDims | Indexed | ImmutableDenseNDimArray | None: - ... - + def __new__(cls, name, index_types, symmetry=..., comm=...) -> Self: ... + @property + def name(self): ... + @property + def index_types(self) -> list[Any]: ... + @property + def symmetry(self) -> Basic: ... + @property + def rank(self) -> int: ... + def __lt__(self, other) -> bool: ... + def commutes_with(self, other): ... + def __call__(self, *indices, **kw_args) -> TensExpr: ... + def __pow__(self, other): ... + @property + def data( + self, + ) -> ( + Any | Basic | ZeroArray | ArrayTensorProduct | ArrayContraction | PermuteDims | Indexed | ImmutableDenseNDimArray | None + ): ... @data.setter - def data(self, data) -> None: - ... - + def data(self, data) -> None: ... @data.deleter - def data(self) -> None: - ... - - def __iter__(self) -> Generator[Any, Any, None] | Any: - ... - - + def data(self) -> None: ... + def __iter__(self) -> Generator[Any, Any, None] | Any: ... -def tensor_heads(s, index_types, symmetry=..., comm=...) -> TensorHead | list[TensorHead]: - ... +def tensor_heads(s, index_types, symmetry=..., comm=...) -> TensorHead | list[TensorHead]: ... class TensExpr(Expr, ABC): _op_priority = ... is_commutative = ... - def __neg__(self): - ... - - def __abs__(self): - ... - - def __add__(self, other) -> Basic | TensExpr | TensMul | Expr | TensAdd: - ... - - def __radd__(self, other) -> Basic | TensExpr | TensMul | Expr | TensAdd: - ... - - def __sub__(self, other) -> Basic | TensExpr | TensMul | Expr | TensAdd: - ... - - def __rsub__(self, other) -> Basic | TensExpr | TensMul | Expr | TensAdd: - ... - - def __mul__(self, other) -> TensExpr | TensMul: - ... - - def __rmul__(self, other) -> TensExpr | TensMul: - ... - - def __truediv__(self, other) -> TensExpr | TensMul: - ... - - def __rtruediv__(self, other): - ... - - def __pow__(self, other): - ... - - def __rpow__(self, other): - ... - + def __neg__(self): ... + def __abs__(self): ... + def __add__(self, other) -> Basic | TensExpr | TensMul | Expr | TensAdd: ... + def __radd__(self, other) -> Basic | TensExpr | TensMul | Expr | TensAdd: ... + def __sub__(self, other) -> Basic | TensExpr | TensMul | Expr | TensAdd: ... + def __rsub__(self, other) -> Basic | TensExpr | TensMul | Expr | TensAdd: ... + def __mul__(self, other) -> TensExpr | TensMul: ... + def __rmul__(self, other) -> TensExpr | TensMul: ... + def __truediv__(self, other) -> TensExpr | TensMul: ... + def __rtruediv__(self, other): ... + def __pow__(self, other): ... + def __rpow__(self, other): ... @property @abstractmethod - def nocoeff(self): - ... - + def nocoeff(self): ... @property @abstractmethod - def coeff(self): - ... - + def coeff(self): ... @abstractmethod - def get_indices(self): - ... - + def get_indices(self): ... @abstractmethod - def get_free_indices(self) -> list[TensorIndex]: - ... - - def fun_eval(self, *index_tuples): - ... - - def get_matrix(self) -> Matrix: - ... - - def expand(self, **hints) -> Self: - ... - - def replace_with_arrays(self, replacement_dict, indices=...) -> ArrayElement | Indexed | ImmutableSparseNDimArray | ImmutableDenseNDimArray | Basic | ZeroArray | ArrayTensorProduct | ArrayContraction | PermuteDims: - ... - - + def get_free_indices(self) -> list[TensorIndex]: ... + def fun_eval(self, *index_tuples): ... + def get_matrix(self) -> Matrix: ... + def expand(self, **hints) -> Self: ... + def replace_with_arrays( + self, replacement_dict, indices=... + ) -> ( + ArrayElement + | Indexed + | ImmutableSparseNDimArray + | ImmutableDenseNDimArray + | Basic + | ZeroArray + | ArrayTensorProduct + | ArrayContraction + | PermuteDims + ): ... class TensAdd(TensExpr, AssocOp): - def __new__(cls, *args, **kw_args) -> Self: - ... - - @property - def coeff(self): - ... - - @property - def nocoeff(self) -> Self: - ... - - def get_free_indices(self) -> list[TensorIndex]: - ... - + def __new__(cls, *args, **kw_args) -> Self: ... + @property + def coeff(self): ... + @property + def nocoeff(self) -> Self: ... + def get_free_indices(self) -> list[TensorIndex]: ... @memoize_property - def rank(self) -> Literal[0]: - ... - + def rank(self) -> Literal[0]: ... @memoize_property - def free_args(self) -> list[Any]: - ... - + def free_args(self) -> list[Any]: ... @memoize_property - def free_indices(self) -> list[TensorIndex] | set[Any]: - ... - - def doit(self, **hints) -> Basic | TensExpr | TensMul | Expr | Self: - ... - - def get_indices(self) -> list[Any]: - ... - - def __call__(self, *indices) -> Self | Basic | TensExpr | TensMul | Expr | TensAdd: - ... - - def canon_bp(self) -> Basic | TensExpr | TensMul | Expr | TensAdd: - ... - - def equals(self, other) -> bool | NotImplementedType: - ... - - def __getitem__(self, item) -> Any | ArrayElement | Indexed | ImmutableDenseNDimArray | Basic: - ... - - def contract_delta(self, delta) -> TensMul | TensExpr | Basic | Expr | TensAdd: - ... - - def contract_metric(self, g) -> TensMul | TensExpr | Basic | Expr | TensAdd: - ... - - def substitute_indices(self, *index_tuples) -> Basic | TensExpr | TensMul | Expr | TensAdd: - ... - - @property - def data(self) -> Any | Basic | ZeroArray | ArrayTensorProduct | ArrayContraction | PermuteDims | Indexed | ImmutableDenseNDimArray | None: - ... - + def free_indices(self) -> list[TensorIndex] | set[Any]: ... + def doit(self, **hints) -> Basic | TensExpr | TensMul | Expr | Self: ... + def get_indices(self) -> list[Any]: ... + def __call__(self, *indices) -> Self | Basic | TensExpr | TensMul | Expr | TensAdd: ... + def canon_bp(self) -> Basic | TensExpr | TensMul | Expr | TensAdd: ... + def equals(self, other) -> bool | NotImplementedType: ... + def __getitem__(self, item) -> Any | ArrayElement | Indexed | ImmutableDenseNDimArray | Basic: ... + def contract_delta(self, delta) -> TensMul | TensExpr | Basic | Expr | TensAdd: ... + def contract_metric(self, g) -> TensMul | TensExpr | Basic | Expr | TensAdd: ... + def substitute_indices(self, *index_tuples) -> Basic | TensExpr | TensMul | Expr | TensAdd: ... + @property + def data( + self, + ) -> ( + Any | Basic | ZeroArray | ArrayTensorProduct | ArrayContraction | PermuteDims | Indexed | ImmutableDenseNDimArray | None + ): ... @data.setter - def data(self, data) -> None: - ... - + def data(self, data) -> None: ... @data.deleter - def data(self) -> None: - ... - - def __iter__(self) -> Any: - ... - - + def data(self) -> None: ... + def __iter__(self) -> Any: ... class Tensor(TensExpr): is_commutative = ... _index_structure: _IndexStructure = ... args: tuple[TensorHead, Tuple] - def __new__(cls, tensor_head, indices, *, is_canon_bp=..., **kw_args) -> Self: - ... - - @property - def free(self): - ... - - @property - def dum(self): - ... - - @property - def ext_rank(self): - ... - - @property - def coeff(self): - ... - - @property - def nocoeff(self): - ... - - @property - def component(self): - ... - - @property - def components(self): - ... - - @property - def head(self) -> TensorHead: - ... - - @property - def indices(self) -> Tuple: - ... - - @property - def free_indices(self) -> set[TensorIndex]: - ... - - @property - def index_types(self) -> list[Any]: - ... - - @property - def rank(self) -> int: - ... - - def doit(self, **hints) -> TensExpr: - ... - - @property - def free_in_args(self) -> list[tuple[Any, Any, Literal[0]]]: - ... - - @property - def dum_in_args(self) -> list[tuple[Any, Any, Literal[0], Literal[0]]]: - ... - - @property - def free_args(self) -> list[Any]: - ... - - def commutes_with(self, other) -> type[NotImplementedError] | Literal[0]: - ... - - def perm2tensor(self, g, is_canon_bp=...) -> TensExpr: - ... - - def canon_bp(self) -> Self | TensExpr: - ... - - def split(self) -> list[Self]: - ... - - def sorted_components(self) -> Self: - ... - - def get_indices(self) -> list[TensorIndex]: - ... - - def get_free_indices(self) -> list[TensorIndex]: - ... - - def as_base_exp(self) -> tuple[Self, Any]: - ... - - def substitute_indices(self, *index_tuples) -> TensExpr: - ... - - def __call__(self, *indices) -> Self | TensExpr: - ... - - def __iter__(self) -> Generator[Any, Any, None] | Any: - ... - - def __getitem__(self, item) -> Any | ArrayElement | Indexed | ImmutableDenseNDimArray | Basic: - ... - - @property - def data(self) -> Any | Basic | ZeroArray | ArrayTensorProduct | ArrayContraction | PermuteDims | Indexed | ImmutableDenseNDimArray | None: - ... - + def __new__(cls, tensor_head, indices, *, is_canon_bp=..., **kw_args) -> Self: ... + @property + def free(self): ... + @property + def dum(self): ... + @property + def ext_rank(self): ... + @property + def coeff(self): ... + @property + def nocoeff(self): ... + @property + def component(self): ... + @property + def components(self): ... + @property + def head(self) -> TensorHead: ... + @property + def indices(self) -> Tuple: ... + @property + def free_indices(self) -> set[TensorIndex]: ... + @property + def index_types(self) -> list[Any]: ... + @property + def rank(self) -> int: ... + def doit(self, **hints) -> TensExpr: ... + @property + def free_in_args(self) -> list[tuple[Any, Any, Literal[0]]]: ... + @property + def dum_in_args(self) -> list[tuple[Any, Any, Literal[0], Literal[0]]]: ... + @property + def free_args(self) -> list[Any]: ... + def commutes_with(self, other) -> type[NotImplementedError] | Literal[0]: ... + def perm2tensor(self, g, is_canon_bp=...) -> TensExpr: ... + def canon_bp(self) -> Self | TensExpr: ... + def split(self) -> list[Self]: ... + def sorted_components(self) -> Self: ... + def get_indices(self) -> list[TensorIndex]: ... + def get_free_indices(self) -> list[TensorIndex]: ... + def as_base_exp(self) -> tuple[Self, Any]: ... + def substitute_indices(self, *index_tuples) -> TensExpr: ... + def __call__(self, *indices) -> Self | TensExpr: ... + def __iter__(self) -> Generator[Any, Any, None] | Any: ... + def __getitem__(self, item) -> Any | ArrayElement | Indexed | ImmutableDenseNDimArray | Basic: ... + @property + def data( + self, + ) -> ( + Any | Basic | ZeroArray | ArrayTensorProduct | ArrayContraction | PermuteDims | Indexed | ImmutableDenseNDimArray | None + ): ... @data.setter - def data(self, data) -> None: - ... - + def data(self, data) -> None: ... @data.deleter - def data(self) -> None: - ... - - def equals(self, other) -> bool: - ... - - def contract_metric(self, g) -> Self: - ... - - def contract_delta(self, metric) -> Self: - ... - - + def data(self) -> None: ... + def equals(self, other) -> bool: ... + def contract_metric(self, g) -> Self: ... + def contract_delta(self, metric) -> Self: ... class TensMul(TensExpr, AssocOp): identity = ... _index_structure: _IndexStructure = ... - def __new__(cls, *args, **kw_args) -> Self: - ... - + def __new__(cls, *args, **kw_args) -> Self: ... + index_types = ... free = ... dum = ... free_indices = ... rank = ... ext_rank = ... - def doit(self, **hints) -> TensExpr | Self: - ... - + def doit(self, **hints) -> TensExpr | Self: ... @staticmethod - def from_data(coeff, components, free, dum, **kw_args) -> TensExpr | TensMul: - ... - - @property - def free_args(self) -> list[Any]: - ... - - @property - def components(self) -> list[Any]: - ... - - @property - def free_in_args(self) -> list[tuple[Any, Any, Any]]: - ... - - @property - def coeff(self): - ... - - @property - def nocoeff(self) -> TensExpr | Self: - ... - - @property - def dum_in_args(self) -> list[tuple[Any, Any, Any, Any]]: - ... - - def equals(self, other): - ... - - def get_indices(self): - ... - - def get_free_indices(self) -> list[TensorIndex]: - ... - - def split(self) -> list[Self] | list[Any]: - ... - - def __neg__(self) -> TensExpr | TensMul: - ... - - def __getitem__(self, item) -> Any | ArrayElement | Indexed | ImmutableDenseNDimArray | Basic: - ... - - def sorted_components(self) -> TensExpr | TensMul: - ... - - def perm2tensor(self, g, is_canon_bp=...) -> TensExpr | TensMul: - ... - - def canon_bp(self) -> Self | TensMul | TensExpr: - ... - - def contract_delta(self, delta): - ... - - def contract_metric(self, g): - ... - - def substitute_indices(self, *index_tuples) -> TensExpr | TensMul: - ... - - def __call__(self, *indices) -> Self | TensExpr | TensMul: - ... - - @property - def data(self) -> Any | Basic | ZeroArray | ArrayTensorProduct | ArrayContraction | PermuteDims | Indexed | ImmutableDenseNDimArray | None: - ... - + def from_data(coeff, components, free, dum, **kw_args) -> TensExpr | TensMul: ... + @property + def free_args(self) -> list[Any]: ... + @property + def components(self) -> list[Any]: ... + @property + def free_in_args(self) -> list[tuple[Any, Any, Any]]: ... + @property + def coeff(self): ... + @property + def nocoeff(self) -> TensExpr | Self: ... + @property + def dum_in_args(self) -> list[tuple[Any, Any, Any, Any]]: ... + def equals(self, other): ... + def get_indices(self): ... + def get_free_indices(self) -> list[TensorIndex]: ... + def split(self) -> list[Self] | list[Any]: ... + def __neg__(self) -> TensExpr | TensMul: ... + def __getitem__(self, item) -> Any | ArrayElement | Indexed | ImmutableDenseNDimArray | Basic: ... + def sorted_components(self) -> TensExpr | TensMul: ... + def perm2tensor(self, g, is_canon_bp=...) -> TensExpr | TensMul: ... + def canon_bp(self) -> Self | TensMul | TensExpr: ... + def contract_delta(self, delta): ... + def contract_metric(self, g): ... + def substitute_indices(self, *index_tuples) -> TensExpr | TensMul: ... + def __call__(self, *indices) -> Self | TensExpr | TensMul: ... + @property + def data( + self, + ) -> ( + Any | Basic | ZeroArray | ArrayTensorProduct | ArrayContraction | PermuteDims | Indexed | ImmutableDenseNDimArray | None + ): ... @data.setter - def data(self, data): - ... - + def data(self, data): ... @data.deleter - def data(self): - ... - - def __iter__(self) -> Generator[Any, Any, None] | Any: - ... - - + def data(self): ... + def __iter__(self) -> Generator[Any, Any, None] | Any: ... class TensorElement(TensExpr): - def __new__(cls, expr, index_map) -> TensExpr | Tensor | Self: - ... - - @property - def free(self) -> list[tuple[Any, int]]: - ... - - @property - def dum(self) -> list[Any]: - ... - - @property - def expr(self) -> Basic: - ... - - @property - def index_map(self) -> Basic: - ... - - @property - def coeff(self): - ... - - @property - def nocoeff(self) -> Self: - ... - - def get_free_indices(self): - ... - - def get_indices(self): - ... - - + def __new__(cls, expr, index_map) -> TensExpr | Tensor | Self: ... + @property + def free(self) -> list[tuple[Any, int]]: ... + @property + def dum(self) -> list[Any]: ... + @property + def expr(self) -> Basic: ... + @property + def index_map(self) -> Basic: ... + @property + def coeff(self): ... + @property + def nocoeff(self) -> Self: ... + def get_free_indices(self): ... + def get_indices(self): ... class WildTensorHead(TensorHead): - def __new__(cls, name, index_types=..., symmetry=..., comm=..., unordered_indices=...) -> Self: - ... - - def __call__(self, *indices, **kwargs) -> TensExpr: - ... - - + def __new__(cls, name, index_types=..., symmetry=..., comm=..., unordered_indices=...) -> Self: ... + def __call__(self, *indices, **kwargs) -> TensExpr: ... class WildTensor(Tensor): - def __new__(cls, tensor_head, indices, **kw_args) -> Tensor | Self: - ... - - def matches(self, expr, repl_dict=..., old=...) -> dict[Any, Any] | None: - ... - - + def __new__(cls, tensor_head, indices, **kw_args) -> Tensor | Self: ... + def matches(self, expr, repl_dict=..., old=...) -> dict[Any, Any] | None: ... class WildTensorIndex(TensorIndex): - def __new__(cls, name, tensor_index_type, is_up=..., ignore_updown=...) -> Self: - ... - - @property - def ignore_updown(self) -> Basic: - ... - - def __neg__(self) -> WildTensorIndex: - ... - - def matches(self, expr, repl_dict=..., old=...) -> dict[Any, Any] | None: - ... - - + def __new__(cls, name, tensor_index_type, is_up=..., ignore_updown=...) -> Self: ... + @property + def ignore_updown(self) -> Basic: ... + def __neg__(self) -> WildTensorIndex: ... + def matches(self, expr, repl_dict=..., old=...) -> dict[Any, Any] | None: ... class _WildTensExpr(Basic): - def __init__(self, expr) -> None: - ... - - def __call__(self, *indices) -> TensExpr: - ... - - def __neg__(self) -> Self: - ... - - def __abs__(self): - ... - - def __add__(self, other) -> Self: - ... - - def __radd__(self, other) -> Self: - ... - - def __sub__(self, other): - ... - - def __rsub__(self, other): - ... - - def __mul__(self, other): - ... - - def __rmul__(self, other): - ... - - def __truediv__(self, other): - ... - - def __rtruediv__(self, other): - ... - - def __pow__(self, other): - ... - - def __rpow__(self, other): - ... - - - -def canon_bp(p): - ... - -def tensor_mul(*a) -> TensExpr | TensMul: - ... - -def riemann_cyclic_replace(t_r): - ... - -def riemann_cyclic(t2) -> TensMul | TensExpr | Basic | Expr | TensAdd: - ... - -def get_lines(ex, index_type) -> tuple[list[Any], list[Any], list[int]]: - ... - -def get_free_indices(t) -> tuple[()] | list[TensorIndex]: - ... - -def get_indices(t) -> tuple[()]: - ... - -def get_dummy_indices(t) -> tuple[()] | list[Any]: - ... - -def get_index_structure(t) -> _IndexStructure: - ... - -def get_coeff(t): - ... - -def contract_metric(t, g): - ... - -def perm2tensor(t, g, is_canon_bp=...) -> TensExpr | TensMul: - ... - -def substitute_indices(t, *index_tuples): - ... - + def __init__(self, expr) -> None: ... + def __call__(self, *indices) -> TensExpr: ... + def __neg__(self) -> Self: ... + def __abs__(self): ... + def __add__(self, other) -> Self: ... + def __radd__(self, other) -> Self: ... + def __sub__(self, other): ... + def __rsub__(self, other): ... + def __mul__(self, other): ... + def __rmul__(self, other): ... + def __truediv__(self, other): ... + def __rtruediv__(self, other): ... + def __pow__(self, other): ... + def __rpow__(self, other): ... + +def canon_bp(p): ... +def tensor_mul(*a) -> TensExpr | TensMul: ... +def riemann_cyclic_replace(t_r): ... +def riemann_cyclic(t2) -> TensMul | TensExpr | Basic | Expr | TensAdd: ... +def get_lines(ex, index_type) -> tuple[list[Any], list[Any], list[int]]: ... +def get_free_indices(t) -> tuple[()] | list[TensorIndex]: ... +def get_indices(t) -> tuple[()]: ... +def get_dummy_indices(t) -> tuple[()] | list[Any]: ... +def get_index_structure(t) -> _IndexStructure: ... +def get_coeff(t): ... +def contract_metric(t, g): ... +def perm2tensor(t, g, is_canon_bp=...) -> TensExpr | TensMul: ... +def substitute_indices(t, *index_tuples): ... diff --git a/stubs/sympy-stubs/testing/__init__.pyi b/stubs/sympy-stubs/testing/__init__.pyi index 0c77e3e5..1b129aab 100644 --- a/stubs/sympy-stubs/testing/__init__.pyi +++ b/stubs/sympy-stubs/testing/__init__.pyi @@ -1,3 +1,3 @@ from sympy.testing.runtests import doctest -__all__ = ['doctest'] +__all__ = ["doctest"] diff --git a/stubs/sympy-stubs/testing/runtests.pyi b/stubs/sympy-stubs/testing/runtests.pyi index d77b14dd..8935ca7d 100644 --- a/stubs/sympy-stubs/testing/runtests.pyi +++ b/stubs/sympy-stubs/testing/runtests.pyi @@ -7,168 +7,93 @@ IS_WINDOWS = ... ON_CI = ... SPLIT_DENSITY = ... SPLIT_DENSITY_SLOW = ... -class Skipped(Exception): - ... - - -class TimeOutError(Exception): - ... - - -class DependencyError(Exception): - ... +class Skipped(Exception): ... +class TimeOutError(Exception): ... +class DependencyError(Exception): ... if IS_WINDOWS: ... -def convert_to_native_paths(lst) -> list[Any]: - ... - -def get_sympy_dir() -> str: - ... - -def setup_pprint() -> bool: - ... +def convert_to_native_paths(lst) -> list[Any]: ... +def get_sympy_dir() -> str: ... +def setup_pprint() -> bool: ... @contextmanager -def raise_on_deprecated() -> Generator[None, Any, None]: - ... - -def run_in_subprocess_with_hash_randomization(function, function_args=..., function_kwargs=..., command=..., module=..., force=...) -> int | Any | Literal[False]: - ... - -def run_all_tests(test_args=..., test_kwargs=..., doctest_args=..., doctest_kwargs=..., examples_args=..., examples_kwargs=...) -> None: - ... - -def test(*paths, subprocess=..., rerun=..., **kwargs) -> bool | None: - ... - -def doctest(*paths, subprocess=..., rerun=..., **kwargs) -> bool | None: - ... +def raise_on_deprecated() -> Generator[None, Any, None]: ... +def run_in_subprocess_with_hash_randomization( + function, function_args=..., function_kwargs=..., command=..., module=..., force=... +) -> int | Any | Literal[False]: ... +def run_all_tests( + test_args=..., test_kwargs=..., doctest_args=..., doctest_kwargs=..., examples_args=..., examples_kwargs=... +) -> None: ... +def test(*paths, subprocess=..., rerun=..., **kwargs) -> bool | None: ... +def doctest(*paths, subprocess=..., rerun=..., **kwargs) -> bool | None: ... sp = ... -def split_list(l, split, density=...): - ... + +def split_list(l, split, density=...): ... SymPyTestResults = ... -def sympytestfile(filename, module_relative=..., name=..., package=..., globs=..., verbose=..., report=..., optionflags=..., extraglobs=..., raise_on_error=..., parser=..., encoding=...) -> SymPyTestResults: - ... -class SymPyTests: - def __init__(self, reporter, kw=..., post_mortem=..., seed=..., fast_threshold=..., slow_threshold=...) -> None: - ... - - def test(self, sort=..., timeout=..., slow=..., enhance_asserts=..., fail_on_timeout=...): - ... - - def test_file(self, filename, sort=..., timeout=..., slow=..., enhance_asserts=..., fail_on_timeout=...): - ... - - def matches(self, x) -> bool: - ... - - def get_test_files(self, dir, pat=...) -> list[Any]: - ... - +def sympytestfile( + filename, + module_relative=..., + name=..., + package=..., + globs=..., + verbose=..., + report=..., + optionflags=..., + extraglobs=..., + raise_on_error=..., + parser=..., + encoding=..., +) -> SymPyTestResults: ... +class SymPyTests: + def __init__(self, reporter, kw=..., post_mortem=..., seed=..., fast_threshold=..., slow_threshold=...) -> None: ... + def test(self, sort=..., timeout=..., slow=..., enhance_asserts=..., fail_on_timeout=...): ... + def test_file(self, filename, sort=..., timeout=..., slow=..., enhance_asserts=..., fail_on_timeout=...): ... + def matches(self, x) -> bool: ... + def get_test_files(self, dir, pat=...) -> list[Any]: ... class SymPyDocTests: - def __init__(self, reporter, normal) -> None: - ... - - def test(self): - ... - - def test_file(self, filename) -> None: - ... - - def get_test_files(self, dir, pat=..., init_only=...) -> list[Any]: - ... - - - -class SymPyDocTestFinder(DocTestFinder): - ... + def __init__(self, reporter, normal) -> None: ... + def test(self): ... + def test_file(self, filename) -> None: ... + def get_test_files(self, dir, pat=..., init_only=...) -> list[Any]: ... +class SymPyDocTestFinder(DocTestFinder): ... class SymPyDocTestRunner(DocTestRunner): - def run(self, test, compileflags=..., out=..., clear_globs=...): - ... - - + def run(self, test, compileflags=..., out=..., clear_globs=...): ... monkeypatched_methods = ... -class SymPyOutputChecker(pdoctest.OutputChecker): - def __init__(self) -> None: - ... - - def check_output(self, want, got, optionflags) -> bool: - ... - - -class Reporter: - ... +class SymPyOutputChecker(pdoctest.OutputChecker): + def __init__(self) -> None: ... + def check_output(self, want, got, optionflags) -> bool: ... +class Reporter: ... class PyTestReporter(Reporter): - def __init__(self, verbose=..., tb=..., colors=..., force_colors=..., split=...) -> None: - ... - - def root_dir(self, dir) -> None: - ... - + def __init__(self, verbose=..., tb=..., colors=..., force_colors=..., split=...) -> None: ... + def root_dir(self, dir) -> None: ... @property - def terminal_width(self) -> Any | int: - ... - - def write(self, text, color=..., align=..., width=..., force_colors=...) -> None: - ... - - def write_center(self, text, delim=...) -> None: - ... - - def write_exception(self, e, val, tb) -> None: - ... - - def start(self, seed=..., msg=...) -> None: - ... - - def finish(self) -> bool: - ... - - def entering_filename(self, filename, n) -> None: - ... - - def leaving_filename(self) -> None: - ... - - def entering_test(self, f) -> None: - ... - - def test_xfail(self) -> None: - ... - - def test_xpass(self, v) -> None: - ... - - def test_fail(self, exc_info) -> None: - ... - - def doctest_fail(self, name, error_msg) -> None: - ... - - def test_pass(self, char=...) -> None: - ... - - def test_skip(self, v=...) -> None: - ... - - def test_exception(self, exc_info) -> None: - ... - - def import_error(self, filename, exc_info) -> None: - ... - - - + def terminal_width(self) -> Any | int: ... + def write(self, text, color=..., align=..., width=..., force_colors=...) -> None: ... + def write_center(self, text, delim=...) -> None: ... + def write_exception(self, e, val, tb) -> None: ... + def start(self, seed=..., msg=...) -> None: ... + def finish(self) -> bool: ... + def entering_filename(self, filename, n) -> None: ... + def leaving_filename(self) -> None: ... + def entering_test(self, f) -> None: ... + def test_xfail(self) -> None: ... + def test_xpass(self, v) -> None: ... + def test_fail(self, exc_info) -> None: ... + def doctest_fail(self, name, error_msg) -> None: ... + def test_pass(self, char=...) -> None: ... + def test_skip(self, v=...) -> None: ... + def test_exception(self, exc_info) -> None: ... + def import_error(self, filename, exc_info) -> None: ... diff --git a/stubs/sympy-stubs/unify/__init__.pyi b/stubs/sympy-stubs/unify/__init__.pyi index 557ca5b1..388ab1a9 100644 --- a/stubs/sympy-stubs/unify/__init__.pyi +++ b/stubs/sympy-stubs/unify/__init__.pyi @@ -1,4 +1,4 @@ from sympy.unify.rewrite import rewriterule from sympy.unify.usympy import rebuild, unify -__all__ = ['unify', 'rebuild', 'rewriterule'] +__all__ = ["unify", "rebuild", "rewriterule"] diff --git a/stubs/sympy-stubs/unify/core.pyi b/stubs/sympy-stubs/unify/core.pyi index a5eeea6b..5cea44a7 100644 --- a/stubs/sympy-stubs/unify/core.pyi +++ b/stubs/sympy-stubs/unify/core.pyi @@ -1,74 +1,31 @@ from typing import Any, Generator class Compound: - def __init__(self, op, args) -> None: - ... - - def __eq__(self, other) -> bool: - ... - - def __hash__(self) -> int: - ... - - def __str__(self) -> str: - ... - - + def __init__(self, op, args) -> None: ... + def __eq__(self, other) -> bool: ... + def __hash__(self) -> int: ... + def __str__(self) -> str: ... class Variable: - def __init__(self, arg) -> None: - ... - - def __eq__(self, other) -> bool: - ... - - def __hash__(self) -> int: - ... - - def __str__(self) -> str: - ... - - + def __init__(self, arg) -> None: ... + def __eq__(self, other) -> bool: ... + def __hash__(self) -> int: ... + def __str__(self) -> str: ... class CondVariable: - def __init__(self, arg, valid) -> None: - ... - - def __eq__(self, other) -> bool: - ... - - def __hash__(self) -> int: - ... - - def __str__(self) -> str: - ... - - - -def unify(x, y, s=..., **fns) -> Generator[Any | dict[Any, Any], Any, None]: - ... - -def unify_var(var, x, s, **fns) -> Generator[Any, Any, None]: - ... - -def occur_check(var, x) -> bool: - ... - -def assoc(d, key, val): - ... - -def is_args(x) -> bool: - ... - -def unpack(x) -> Compound: - ... - -def allcombinations(A, B, ordered) -> Generator[tuple[tuple[tuple[Any], ...], Any] | tuple[Any, tuple[tuple[Any], ...]], Any, None]: - ... - -def partition(it, part) -> Any: - ... - -def index(it, ind) -> Any: - ... - + def __init__(self, arg, valid) -> None: ... + def __eq__(self, other) -> bool: ... + def __hash__(self) -> int: ... + def __str__(self) -> str: ... + +def unify(x, y, s=..., **fns) -> Generator[Any | dict[Any, Any], Any, None]: ... +def unify_var(var, x, s, **fns) -> Generator[Any, Any, None]: ... +def occur_check(var, x) -> bool: ... +def assoc(d, key, val): ... +def is_args(x) -> bool: ... +def unpack(x) -> Compound: ... +def allcombinations( + A, B, ordered +) -> Generator[tuple[tuple[tuple[Any], ...], Any] | tuple[Any, tuple[tuple[Any], ...]], Any, None]: ... +def partition(it, part) -> Any: ... +def index(it, ind) -> Any: ... diff --git a/stubs/sympy-stubs/unify/rewrite.pyi b/stubs/sympy-stubs/unify/rewrite.pyi index f2c82084..51787fa5 100644 --- a/stubs/sympy-stubs/unify/rewrite.pyi +++ b/stubs/sympy-stubs/unify/rewrite.pyi @@ -2,6 +2,4 @@ from typing import Any, Callable, Generator from sympy import Basic -def rewriterule(source, target, variables=..., condition=..., assume=...) -> Callable[..., Generator[Any | Basic, Any, None]]: - ... - +def rewriterule(source, target, variables=..., condition=..., assume=...) -> Callable[..., Generator[Any | Basic, Any, None]]: ... diff --git a/stubs/sympy-stubs/unify/usympy.pyi b/stubs/sympy-stubs/unify/usympy.pyi index 2a346c47..7f483e15 100644 --- a/stubs/sympy-stubs/unify/usympy.pyi +++ b/stubs/sympy-stubs/unify/usympy.pyi @@ -6,30 +6,13 @@ from sympy.unify.core import Compound, CondVariable, Variable basic_new_legal = ... eval_false_legal = ... illegal = ... -def sympy_associative(op) -> bool: - ... - -def sympy_commutative(op) -> bool: - ... - -def is_associative(x) -> bool: - ... - -def is_commutative(x) -> bool | None: - ... - -def mk_matchtype(typ) -> Callable[..., bool]: - ... - -def deconstruct(s, variables=...) -> Variable | CondVariable | Basic | Compound: - ... - -def construct(t) -> Any: - ... - -def rebuild(s) -> Any | Basic: - ... - -def unify(x, y, s=..., variables=..., **kwargs) -> Generator[dict[Any, Any], Any, None]: - ... +def sympy_associative(op) -> bool: ... +def sympy_commutative(op) -> bool: ... +def is_associative(x) -> bool: ... +def is_commutative(x) -> bool | None: ... +def mk_matchtype(typ) -> Callable[..., bool]: ... +def deconstruct(s, variables=...) -> Variable | CondVariable | Basic | Compound: ... +def construct(t) -> Any: ... +def rebuild(s) -> Any | Basic: ... +def unify(x, y, s=..., variables=..., **kwargs) -> Generator[dict[Any, Any], Any, None]: ... diff --git a/stubs/sympy-stubs/utilities/__init__.pyi b/stubs/sympy-stubs/utilities/__init__.pyi index da097786..c0b7a7a3 100644 --- a/stubs/sympy-stubs/utilities/__init__.pyi +++ b/stubs/sympy-stubs/utilities/__init__.pyi @@ -23,4 +23,30 @@ from sympy.utilities.lambdify import lambdify from sympy.utilities.misc import filldedent from sympy.utilities.timeutils import timed -__all__ = ['flatten', 'group', 'take', 'subsets', 'variations', 'numbered_symbols', 'cartes', 'capture', 'dict_merge', 'prefixes', 'postfixes', 'sift', 'topological_sort', 'unflatten', 'has_dups', 'has_variety', 'reshape', 'rotations', 'filldedent', 'lambdify', 'threaded', 'xthreaded', 'public', 'memoize_property', 'timed'] +__all__ = [ + "flatten", + "group", + "take", + "subsets", + "variations", + "numbered_symbols", + "cartes", + "capture", + "dict_merge", + "prefixes", + "postfixes", + "sift", + "topological_sort", + "unflatten", + "has_dups", + "has_variety", + "reshape", + "rotations", + "filldedent", + "lambdify", + "threaded", + "xthreaded", + "public", + "memoize_property", + "timed", +] diff --git a/stubs/sympy-stubs/utilities/decorator.pyi b/stubs/sympy-stubs/utilities/decorator.pyi index d0b0c4b8..403f4ffd 100644 --- a/stubs/sympy-stubs/utilities/decorator.pyi +++ b/stubs/sympy-stubs/utilities/decorator.pyi @@ -2,36 +2,18 @@ from functools import _Wrapped from types import FunctionType from typing import Any, Callable -def threaded_factory(func, use_add) -> _Wrapped[..., Any, ..., Any]: - ... - -def threaded(func) -> _Wrapped[..., Any, ..., Any]: - ... - -def xthreaded(func) -> _Wrapped[..., Any, ..., Any]: - ... - -def conserve_mpmath_dps(func) -> Callable[..., Any]: - ... +def threaded_factory(func, use_add) -> _Wrapped[..., Any, ..., Any]: ... +def threaded(func) -> _Wrapped[..., Any, ..., Any]: ... +def xthreaded(func) -> _Wrapped[..., Any, ..., Any]: ... +def conserve_mpmath_dps(func) -> Callable[..., Any]: ... class no_attrs_in_subclass: - def __init__(self, cls, f) -> None: - ... - - def __get__(self, instance, owner=...) -> Any: - ... - - - -def doctest_depends_on(exe=..., modules=..., disable_viewers=..., python_version=...) -> Callable[..., type[Any] | Any]: - ... - -def public(obj) -> type: - ... - -def memoize_property(propfunc) -> property: - ... - -def deprecated(message, *, deprecated_since_version, active_deprecations_target, stacklevel=...) -> Callable[..., Any | _Wrapped[..., Any, ..., Any]]: - ... - + def __init__(self, cls, f) -> None: ... + def __get__(self, instance, owner=...) -> Any: ... + +def doctest_depends_on(exe=..., modules=..., disable_viewers=..., python_version=...) -> Callable[..., type[Any] | Any]: ... +def public(obj) -> type: ... +def memoize_property(propfunc) -> property: ... +def deprecated( + message, *, deprecated_since_version, active_deprecations_target, stacklevel=... +) -> Callable[..., Any | _Wrapped[..., Any, ..., Any]]: ... diff --git a/stubs/sympy-stubs/utilities/enumerative.pyi b/stubs/sympy-stubs/utilities/enumerative.pyi index ca32a565..a07005e5 100644 --- a/stubs/sympy-stubs/utilities/enumerative.pyi +++ b/stubs/sympy-stubs/utilities/enumerative.pyi @@ -2,75 +2,32 @@ from typing import Any, Generator class PartComponent: __slots__ = ... - def __init__(self) -> None: - ... - + def __init__(self) -> None: ... def __repr__(self) -> str: "for debug/algorithm animation purposes" ... - - def __eq__(self, other) -> bool: - ... - - def __ne__(self, other) -> bool: - ... - + def __eq__(self, other) -> bool: ... + def __ne__(self, other) -> bool: ... -def multiset_partitions_taocp(multiplicities) -> Generator[list[Any], Any, None]: - ... - -def factoring_visitor(state, primes) -> list[Any]: - ... - -def list_visitor(state, components) -> list[Any]: - ... +def multiset_partitions_taocp(multiplicities) -> Generator[list[Any], Any, None]: ... +def factoring_visitor(state, primes) -> list[Any]: ... +def list_visitor(state, components) -> list[Any]: ... class MultisetPartitionTraverser: - def __init__(self) -> None: - ... - - def db_trace(self, msg) -> None: - ... - - def decrement_part(self, part) -> bool: - ... - - def decrement_part_small(self, part, ub) -> bool: - ... - - def decrement_part_large(self, part, amt, lb) -> bool | None: - ... - - def decrement_part_range(self, part, lb, ub) -> bool | None: - ... - - def spread_part_multiplicity(self) -> bool: - ... - - def top_part(self) -> list[PartComponent]: - ... - - def enum_all(self, multiplicities) -> Generator[list[Any], Any, None]: - ... - - def enum_small(self, multiplicities, ub) -> Generator[list[Any], Any, None]: - ... - - def enum_large(self, multiplicities, lb) -> Generator[list[Any], Any, None]: - ... - - def enum_range(self, multiplicities, lb, ub) -> Generator[list[Any], Any, None]: - ... - - def count_partitions_slow(self, multiplicities) -> int: - ... - - def count_partitions(self, multiplicities) -> int: - ... - - - -def part_key(part) -> tuple[Any, ...]: - ... - + def __init__(self) -> None: ... + def db_trace(self, msg) -> None: ... + def decrement_part(self, part) -> bool: ... + def decrement_part_small(self, part, ub) -> bool: ... + def decrement_part_large(self, part, amt, lb) -> bool | None: ... + def decrement_part_range(self, part, lb, ub) -> bool | None: ... + def spread_part_multiplicity(self) -> bool: ... + def top_part(self) -> list[PartComponent]: ... + def enum_all(self, multiplicities) -> Generator[list[Any], Any, None]: ... + def enum_small(self, multiplicities, ub) -> Generator[list[Any], Any, None]: ... + def enum_large(self, multiplicities, lb) -> Generator[list[Any], Any, None]: ... + def enum_range(self, multiplicities, lb, ub) -> Generator[list[Any], Any, None]: ... + def count_partitions_slow(self, multiplicities) -> int: ... + def count_partitions(self, multiplicities) -> int: ... + +def part_key(part) -> tuple[Any, ...]: ... diff --git a/stubs/sympy-stubs/utilities/exceptions.pyi b/stubs/sympy-stubs/utilities/exceptions.pyi index 6a2343b0..787f7ba1 100644 --- a/stubs/sympy-stubs/utilities/exceptions.pyi +++ b/stubs/sympy-stubs/utilities/exceptions.pyi @@ -2,27 +2,12 @@ import contextlib from typing import Any, Callable, Generator, Self class SymPyDeprecationWarning(DeprecationWarning): - def __init__(self, message, *, deprecated_since_version, active_deprecations_target) -> None: - ... - - def __str__(self) -> str: - ... - - def __repr__(self) -> str: - ... - - def __eq__(self, other) -> bool: - ... - - def __reduce__(self) -> tuple[Callable[..., Self], tuple[Any, str, Any]]: - ... - - - -def sympy_deprecation_warning(message, *, deprecated_since_version, active_deprecations_target, stacklevel=...) -> None: - ... + def __init__(self, message, *, deprecated_since_version, active_deprecations_target) -> None: ... + def __str__(self) -> str: ... + def __repr__(self) -> str: ... + def __eq__(self, other) -> bool: ... + def __reduce__(self) -> tuple[Callable[..., Self], tuple[Any, str, Any]]: ... +def sympy_deprecation_warning(message, *, deprecated_since_version, active_deprecations_target, stacklevel=...) -> None: ... @contextlib.contextmanager -def ignore_warnings(warningcls) -> Generator[None, Any, None]: - ... - +def ignore_warnings(warningcls) -> Generator[None, Any, None]: ... diff --git a/stubs/sympy-stubs/utilities/iterables.pyi b/stubs/sympy-stubs/utilities/iterables.pyi index 96a718e9..81b2c994 100644 --- a/stubs/sympy-stubs/utilities/iterables.pyi +++ b/stubs/sympy-stubs/utilities/iterables.pyi @@ -5,181 +5,93 @@ from typing import Any, Generator, Iterator, Literal, Never, NoReturn from sympy import Basic, Symbol from sympy.utilities.decorator import deprecated -def is_palindromic(s, i=..., j=...) -> bool: - ... - -def flatten(iterable, levels=..., cls=...) -> list[Any]: - ... - -def unflatten(iter, n=...) -> list[Any]: - ... - -def reshape(seq, how) -> Any: - ... - -def group(seq, multiple=...) -> list[list[Any]] | list[tuple[Any, int]]: - ... - -def iproduct(*iterables) -> Generator[tuple[()] | tuple[Any] | tuple[Any, Any] | Any, Any, None]: - ... - -def multiset(seq) -> dict[Any, int]: - ... - -def ibin(n, bits=..., str=...) -> list[int] | Iterator[Never] | permutations[Any] | Iterator[tuple[()]] | product[tuple[Any, ...]] | str | Generator[str, None, None]: - ... - -def variations(seq, n, repetition=...) -> Iterator[Never] | permutations[Any] | Iterator[tuple[()]] | product[tuple[Any, ...]]: - ... - -def subsets(seq, k=..., repetition=...) -> chain[tuple[Any, ...]] | combinations[Any] | combinations_with_replacement[Any]: - ... - -def filter_symbols(iterator, exclude) -> Generator[Any, Any, None]: - ... - -def numbered_symbols(prefix=..., cls=..., start=..., exclude=..., *args, **assumptions) -> Generator[Symbol | Any, Any, NoReturn]: - ... - -def capture(func) -> str: - ... - -def sift(seq, keyfunc, binary=...) -> defaultdict[Any, list[Any]] | tuple[list[Any], list[Any]]: - ... - -def take(iter, n) -> list[Any]: - ... - -def dict_merge(*dicts) -> dict[Any, Any]: - ... - -def common_prefix(*seqs) -> list[Any]: - ... - -def common_suffix(*seqs) -> list[Any]: - ... - -def prefixes(seq) -> Generator[Any, Any, None]: - ... - -def postfixes(seq) -> Generator[Any, Any, None]: - ... - -def topological_sort(graph, key=...) -> list[Any]: - ... - -def strongly_connected_components(G) -> list[Any]: - ... - -def connected_components(G) -> list[Any]: - ... - -def rotate_left(x, y) -> list[Any]: - ... - -def rotate_right(x, y) -> list[Any]: - ... - -def least_rotation(x, key=...) -> int: - ... - -def multiset_combinations(m, n, g=...) -> Generator[Any | list[Any], Any, None]: - ... - -def multiset_permutations(m, size=..., g=...) -> Generator[list[Any | int] | Any, Any, None]: - ... - -def multiset_partitions(multiset, m=...) -> Generator[list[list[int]] | list[list[Any]] | list[list[str] | Any] | list[Any], Any, None]: - ... - -def partitions(n, m=..., k=..., size=...) -> Generator[tuple[Literal[0], dict[Any, Any]] | tuple[int, dict[int, int]] | dict[int, int], Any, None]: - ... - -def ordered_partitions(n, m=..., sort=...) -> Generator[Any | list[Any], Any, None]: - ... - -def binary_partitions(n) -> Generator[Any | list[Any], Any, None]: - ... - -def has_dups(seq) -> bool: - ... - -def has_variety(seq) -> bool: - ... - -def uniq(seq, result=...) -> Generator[Any, Any, None]: - ... - -def generate_bell(n) -> Generator[tuple[Literal[0]] | tuple[Literal[0], Literal[1]] | tuple[Literal[1], Literal[0]] | Any | tuple[int, ...], Any, None]: - ... - -def generate_involutions(n) -> Generator[tuple[int, ...], Any, None]: - ... - -def multiset_derangements(s) -> Generator[list[Any] | list[None] | Any, Any, None]: - ... - -def random_derangement(t, choice=..., strict=...) -> str | list[None] | list[Any]: - ... - -def generate_derangements(s) -> Generator[list[Any] | list[None], Any, None]: - ... - -def necklaces(n, k, free=...) -> Generator[tuple[Any, ...], Any, None]: - ... - -def bracelets(n, k) -> Generator[tuple[Any, ...], Any, None]: - ... - -def generate_oriented_forest(n) -> Generator[list[int], Any, None]: - ... - -def minlex(seq, directed=..., key=...) -> tuple[Any, ...] | list[Any]: - ... - -def runs(seq, op=...) -> list[Any]: - ... - -def sequence_partitions(l, n, /) -> Generator[list[Any] | Any, Any, None]: - ... - -def sequence_partitions_empty(l, n, /) -> Generator[list[Any] | Any, Any, None]: - ... - -def kbins(l, k, ordered=...) -> Generator[list[Any] | Any | list[list[int]] | list[list[Any]] | list[list[str] | Any], Any, None]: - ... - -def permute_signs(t) -> Generator[Any, Any, None]: - ... - -def signed_permutations(t) -> Generator[Any, None, None]: - ... - -def rotations(s, dir=...) -> Generator[list[Any] | Any, Any, None]: - ... - -def roundrobin(*iterables) -> Generator[Any, Any, None]: - ... - -class NotIterable: - ... - - -def iterable(i, exclude=...) -> bool: - ... - -def is_sequence(i, include=...) -> bool: - ... - -def postorder_traversal(node, keys=...) -> Generator[Any | Basic, Any, None]: - ... - -def interactive_traversal(expr) -> Basic: - ... - -def default_sort_key(*args, **kwargs) -> tuple[tuple[Literal[5], Literal[0], str], tuple[int, tuple[Any, ...]], Any, Any] | tuple[tuple[Literal[10, 0], Literal[0], str | Any], tuple[int, tuple[Any, ...]] | tuple[Literal[1], tuple[str]], Any, Any]: - ... - -def ordered(*args, **kwargs) -> Generator[Any, Any, None]: - ... - +def is_palindromic(s, i=..., j=...) -> bool: ... +def flatten(iterable, levels=..., cls=...) -> list[Any]: ... +def unflatten(iter, n=...) -> list[Any]: ... +def reshape(seq, how) -> Any: ... +def group(seq, multiple=...) -> list[list[Any]] | list[tuple[Any, int]]: ... +def iproduct(*iterables) -> Generator[tuple[()] | tuple[Any] | tuple[Any, Any] | Any, Any, None]: ... +def multiset(seq) -> dict[Any, int]: ... +def ibin( + n, bits=..., str=... +) -> ( + list[int] + | Iterator[Never] + | permutations[Any] + | Iterator[tuple[()]] + | product[tuple[Any, ...]] + | str + | Generator[str, None, None] +): ... +def variations( + seq, n, repetition=... +) -> Iterator[Never] | permutations[Any] | Iterator[tuple[()]] | product[tuple[Any, ...]]: ... +def subsets(seq, k=..., repetition=...) -> chain[tuple[Any, ...]] | combinations[Any] | combinations_with_replacement[Any]: ... +def filter_symbols(iterator, exclude) -> Generator[Any, Any, None]: ... +def numbered_symbols( + prefix=..., cls=..., start=..., exclude=..., *args, **assumptions +) -> Generator[Symbol | Any, Any, NoReturn]: ... +def capture(func) -> str: ... +def sift(seq, keyfunc, binary=...) -> defaultdict[Any, list[Any]] | tuple[list[Any], list[Any]]: ... +def take(iter, n) -> list[Any]: ... +def dict_merge(*dicts) -> dict[Any, Any]: ... +def common_prefix(*seqs) -> list[Any]: ... +def common_suffix(*seqs) -> list[Any]: ... +def prefixes(seq) -> Generator[Any, Any, None]: ... +def postfixes(seq) -> Generator[Any, Any, None]: ... +def topological_sort(graph, key=...) -> list[Any]: ... +def strongly_connected_components(G) -> list[Any]: ... +def connected_components(G) -> list[Any]: ... +def rotate_left(x, y) -> list[Any]: ... +def rotate_right(x, y) -> list[Any]: ... +def least_rotation(x, key=...) -> int: ... +def multiset_combinations(m, n, g=...) -> Generator[Any | list[Any], Any, None]: ... +def multiset_permutations(m, size=..., g=...) -> Generator[list[Any | int] | Any, Any, None]: ... +def multiset_partitions( + multiset, m=... +) -> Generator[list[list[int]] | list[list[Any]] | list[list[str] | Any] | list[Any], Any, None]: ... +def partitions( + n, m=..., k=..., size=... +) -> Generator[tuple[Literal[0], dict[Any, Any]] | tuple[int, dict[int, int]] | dict[int, int], Any, None]: ... +def ordered_partitions(n, m=..., sort=...) -> Generator[Any | list[Any], Any, None]: ... +def binary_partitions(n) -> Generator[Any | list[Any], Any, None]: ... +def has_dups(seq) -> bool: ... +def has_variety(seq) -> bool: ... +def uniq(seq, result=...) -> Generator[Any, Any, None]: ... +def generate_bell( + n, +) -> Generator[ + tuple[Literal[0]] | tuple[Literal[0], Literal[1]] | tuple[Literal[1], Literal[0]] | Any | tuple[int, ...], Any, None +]: ... +def generate_involutions(n) -> Generator[tuple[int, ...], Any, None]: ... +def multiset_derangements(s) -> Generator[list[Any] | list[None] | Any, Any, None]: ... +def random_derangement(t, choice=..., strict=...) -> str | list[None] | list[Any]: ... +def generate_derangements(s) -> Generator[list[Any] | list[None], Any, None]: ... +def necklaces(n, k, free=...) -> Generator[tuple[Any, ...], Any, None]: ... +def bracelets(n, k) -> Generator[tuple[Any, ...], Any, None]: ... +def generate_oriented_forest(n) -> Generator[list[int], Any, None]: ... +def minlex(seq, directed=..., key=...) -> tuple[Any, ...] | list[Any]: ... +def runs(seq, op=...) -> list[Any]: ... +def sequence_partitions(l, n, /) -> Generator[list[Any] | Any, Any, None]: ... +def sequence_partitions_empty(l, n, /) -> Generator[list[Any] | Any, Any, None]: ... +def kbins( + l, k, ordered=... +) -> Generator[list[Any] | Any | list[list[int]] | list[list[Any]] | list[list[str] | Any], Any, None]: ... +def permute_signs(t) -> Generator[Any, Any, None]: ... +def signed_permutations(t) -> Generator[Any, None, None]: ... +def rotations(s, dir=...) -> Generator[list[Any] | Any, Any, None]: ... +def roundrobin(*iterables) -> Generator[Any, Any, None]: ... + +class NotIterable: ... + +def iterable(i, exclude=...) -> bool: ... +def is_sequence(i, include=...) -> bool: ... +def postorder_traversal(node, keys=...) -> Generator[Any | Basic, Any, None]: ... +def interactive_traversal(expr) -> Basic: ... +def default_sort_key( + *args, **kwargs +) -> ( + tuple[tuple[Literal[5], Literal[0], str], tuple[int, tuple[Any, ...]], Any, Any] + | tuple[tuple[Literal[10, 0], Literal[0], str | Any], tuple[int, tuple[Any, ...]] | tuple[Literal[1], tuple[str]], Any, Any] +): ... +def ordered(*args, **kwargs) -> Generator[Any, Any, None]: ... diff --git a/stubs/sympy-stubs/utilities/lambdify.pyi b/stubs/sympy-stubs/utilities/lambdify.pyi index ba9a92a2..14323ff9 100644 --- a/stubs/sympy-stubs/utilities/lambdify.pyi +++ b/stubs/sympy-stubs/utilities/lambdify.pyi @@ -32,26 +32,15 @@ TENSORFLOW_TRANSLATIONS: dict[str, str] = ... NUMEXPR_TRANSLATIONS: dict[str, str] = ... MODULES = ... _lambdify_generated_counter = ... -@doctest_depends_on(modules=('numpy', 'scipy', 'tensorflow'), python_version=(3, )) -def lambdify(args, expr, modules=..., printer=..., use_imps=..., dummify=..., cse=..., docstring_limit=...): - ... -def lambdastr(args, expr, printer=..., dummify=...) -> str: - ... +@doctest_depends_on(modules=("numpy", "scipy", "tensorflow"), python_version=(3,)) +def lambdify(args, expr, modules=..., printer=..., use_imps=..., dummify=..., cse=..., docstring_limit=...): ... +def lambdastr(args, expr, printer=..., dummify=...) -> str: ... class _EvaluatorPrinter: - def __init__(self, printer=..., dummify=...) -> None: - ... - - def doprint(self, funcname, args, expr, *, cses=...) -> str: - ... - + def __init__(self, printer=..., dummify=...) -> None: ... + def doprint(self, funcname, args, expr, *, cses=...) -> str: ... +class _TensorflowEvaluatorPrinter(_EvaluatorPrinter): ... -class _TensorflowEvaluatorPrinter(_EvaluatorPrinter): - ... - - -def implemented_function(symfunc, implementation) -> type[UndefinedFunction] | UndefinedFunction: - ... - +def implemented_function(symfunc, implementation) -> type[UndefinedFunction] | UndefinedFunction: ... diff --git a/stubs/sympy-stubs/utilities/magic.pyi b/stubs/sympy-stubs/utilities/magic.pyi index f9ee237d..3d80ac97 100644 --- a/stubs/sympy-stubs/utilities/magic.pyi +++ b/stubs/sympy-stubs/utilities/magic.pyi @@ -1,4 +1 @@ - -def pollute(names, objects) -> None: - ... - +def pollute(names, objects) -> None: ... diff --git a/stubs/sympy-stubs/utilities/mathml/__init__.pyi b/stubs/sympy-stubs/utilities/mathml/__init__.pyi index 7a03aa50..030f5bc2 100644 --- a/stubs/sympy-stubs/utilities/mathml/__init__.pyi +++ b/stubs/sympy-stubs/utilities/mathml/__init__.pyi @@ -3,14 +3,9 @@ from pathlib import Path from sympy.utilities.decorator import doctest_depends_on __doctest_requires__ = ... -def add_mathml_headers(s): - ... - -@doctest_depends_on(modules=('lxml', )) -def apply_xsl(mml, xsl) -> str: - ... - -@doctest_depends_on(modules=('lxml', )) -def c2p(mml, simple=...) -> str: - ... +def add_mathml_headers(s): ... +@doctest_depends_on(modules=("lxml",)) +def apply_xsl(mml, xsl) -> str: ... +@doctest_depends_on(modules=("lxml",)) +def c2p(mml, simple=...) -> str: ... diff --git a/stubs/sympy-stubs/utilities/memoization.pyi b/stubs/sympy-stubs/utilities/memoization.pyi index e1a1837a..f2cda6c6 100644 --- a/stubs/sympy-stubs/utilities/memoization.pyi +++ b/stubs/sympy-stubs/utilities/memoization.pyi @@ -1,9 +1,5 @@ from functools import _Wrapped from typing import Any, Callable -def recurrence_memo(initial) -> Callable[..., _Wrapped[..., Any, ..., Any]]: - ... - -def assoc_recurrence_memo(base_seq) -> Callable[..., _Wrapped[..., Any, ..., Any]]: - ... - +def recurrence_memo(initial) -> Callable[..., _Wrapped[..., Any, ..., Any]]: ... +def assoc_recurrence_memo(base_seq) -> Callable[..., _Wrapped[..., Any, ..., Any]]: ... diff --git a/stubs/sympy-stubs/utilities/misc.pyi b/stubs/sympy-stubs/utilities/misc.pyi index 7736a397..24ce606d 100644 --- a/stubs/sympy-stubs/utilities/misc.pyi +++ b/stubs/sympy-stubs/utilities/misc.pyi @@ -1,46 +1,22 @@ from typing import Any, Callable, LiteralString -class Undecidable(ValueError): - ... +class Undecidable(ValueError): ... - -def filldedent(s, w=..., **kwargs) -> str: - ... - -def strlines(s, c=..., short=...) -> str | LiteralString: - ... - -def rawlines(s) -> str | LiteralString: - ... +def filldedent(s, w=..., **kwargs) -> str: ... +def strlines(s, c=..., short=...) -> str | LiteralString: ... +def rawlines(s) -> str | LiteralString: ... ARCH = ... HASH_RANDOMIZATION = ... _debug_tmp: list[str] = ... _debug_iter = ... -def debug_decorator(func) -> Callable[..., Any]: - ... - -def debug(*args) -> None: - ... - -def debugf(string, args) -> None: - ... - -def find_executable(executable, path=...) -> str | None: - ... - -def func_name(x, short=...) -> str | Any: - ... - -def replace(string, *reps) -> str: - ... - -def translate(s, a, b=..., c=...) -> str: - ... - -def ordinal(num) -> str: - ... - -def as_int(n, strict=...) -> int: - ... +def debug_decorator(func) -> Callable[..., Any]: ... +def debug(*args) -> None: ... +def debugf(string, args) -> None: ... +def find_executable(executable, path=...) -> str | None: ... +def func_name(x, short=...) -> str | Any: ... +def replace(string, *reps) -> str: ... +def translate(s, a, b=..., c=...) -> str: ... +def ordinal(num) -> str: ... +def as_int(n, strict=...) -> int: ... diff --git a/stubs/sympy-stubs/utilities/source.pyi b/stubs/sympy-stubs/utilities/source.pyi index 1241b47a..9d463d28 100644 --- a/stubs/sympy-stubs/utilities/source.pyi +++ b/stubs/sympy-stubs/utilities/source.pyi @@ -1,8 +1,4 @@ from typing import Any, Literal -def get_class(lookup_view) -> Any | str: - ... - -def get_mod_func(callback) -> tuple[Any, Literal['']] | tuple[Any, Any]: - ... - +def get_class(lookup_view) -> Any | str: ... +def get_mod_func(callback) -> tuple[Any, Literal[""]] | tuple[Any, Any]: ... diff --git a/stubs/sympy-stubs/utilities/timeutils.pyi b/stubs/sympy-stubs/utilities/timeutils.pyi index 40fe85e2..c22ab0a7 100644 --- a/stubs/sympy-stubs/utilities/timeutils.pyi +++ b/stubs/sympy-stubs/utilities/timeutils.pyi @@ -2,11 +2,10 @@ from typing import Any, Callable _scales = ... _units = ... -def timed(func, setup=..., limit=...) -> tuple[int, float, float, str]: - ... + +def timed(func, setup=..., limit=...) -> tuple[int, float, float, str]: ... _do_timings = ... _timestack = ... -def timethis(name) -> Callable[..., Any | Callable[..., Any]]: - ... +def timethis(name) -> Callable[..., Any | Callable[..., Any]]: ... diff --git a/stubs/sympy-stubs/vector/basisdependent.pyi b/stubs/sympy-stubs/vector/basisdependent.pyi index 14cab724..ad0c4603 100644 --- a/stubs/sympy-stubs/vector/basisdependent.pyi +++ b/stubs/sympy-stubs/vector/basisdependent.pyi @@ -8,123 +8,63 @@ from sympy.vector.vector import BaseVector if TYPE_CHECKING: ... + class BasisDependent(Expr): zero: BasisDependentZero - @call_highest_priority('__radd__') - def __add__(self, other): - ... - - @call_highest_priority('__add__') - def __radd__(self, other): - ... - - @call_highest_priority('__rsub__') - def __sub__(self, other): - ... - - @call_highest_priority('__sub__') - def __rsub__(self, other): - ... - - @_sympifyit('other', NotImplemented) - @call_highest_priority('__rmul__') - def __mul__(self, other): - ... - - @_sympifyit('other', NotImplemented) - @call_highest_priority('__mul__') - def __rmul__(self, other): - ... - - def __neg__(self): - ... - - @_sympifyit('other', NotImplemented) - @call_highest_priority('__rtruediv__') - def __truediv__(self, other): - ... - - @call_highest_priority('__truediv__') - def __rtruediv__(self, other) -> TypeError: - ... - - def evalf(self, n=..., subs=..., maxn=..., chop=..., strict=..., quad=..., verbose=...) -> BasisDependentZero: - ... - - n = ... - def simplify(self, **kwargs): - ... - - def trigsimp(self, **opts): - ... - - def as_numer_denom(self) -> tuple[Self, Any]: - ... - - def factor(self, *args, **kwargs): - ... - - def as_coeff_Mul(self, rational=...) -> tuple[Any, Self]: - ... - - def as_coeff_add(self, *deps) -> tuple[Literal[0], tuple[Any, ...]]: - ... - - def diff(self, *args, **kwargs): - ... - - def doit(self, **hints): - ... - + @call_highest_priority("__radd__") + def __add__(self, other): ... + @call_highest_priority("__add__") + def __radd__(self, other): ... + @call_highest_priority("__rsub__") + def __sub__(self, other): ... + @call_highest_priority("__sub__") + def __rsub__(self, other): ... + @_sympifyit("other", NotImplemented) + @call_highest_priority("__rmul__") + def __mul__(self, other): ... + @_sympifyit("other", NotImplemented) + @call_highest_priority("__mul__") + def __rmul__(self, other): ... + def __neg__(self): ... + @_sympifyit("other", NotImplemented) + @call_highest_priority("__rtruediv__") + def __truediv__(self, other): ... + @call_highest_priority("__truediv__") + def __rtruediv__(self, other) -> TypeError: ... + def evalf(self, n=..., subs=..., maxn=..., chop=..., strict=..., quad=..., verbose=...) -> BasisDependentZero: ... + n = ... + def simplify(self, **kwargs): ... + def trigsimp(self, **opts): ... + def as_numer_denom(self) -> tuple[Self, Any]: ... + def factor(self, *args, **kwargs): ... + def as_coeff_Mul(self, rational=...) -> tuple[Any, Self]: ... + def as_coeff_add(self, *deps) -> tuple[Literal[0], tuple[Any, ...]]: ... + def diff(self, *args, **kwargs): ... + def doit(self, **hints): ... class BasisDependentAdd(BasisDependent, Add): - def __new__(cls, *args, **options) -> BasisDependentZero | Order: - ... - - + def __new__(cls, *args, **options) -> BasisDependentZero | Order: ... class BasisDependentMul(BasisDependent, Mul): - def __new__(cls, *args, **options) -> Order | BasisDependentZero: - ... - - + def __new__(cls, *args, **options) -> Order | BasisDependentZero: ... class BasisDependentZero(BasisDependent): components: dict[BaseVector, Expr] = ... _latex_form: str - def __new__(cls) -> Self: - ... - - def __hash__(self) -> int: - ... - - @call_highest_priority('__req__') - def __eq__(self, other) -> bool: - ... - - __req__ = ... - @call_highest_priority('__radd__') - def __add__(self, other): - ... - - @call_highest_priority('__add__') - def __radd__(self, other): - ... - - @call_highest_priority('__rsub__') - def __sub__(self, other): - ... - - @call_highest_priority('__sub__') - def __rsub__(self, other): - ... - - def __neg__(self) -> Self: - ... - - def normalize(self) -> Self: - ... - - + def __new__(cls) -> Self: ... + def __hash__(self) -> int: ... + @call_highest_priority("__req__") + def __eq__(self, other) -> bool: ... + __req__ = ... + @call_highest_priority("__radd__") + def __add__(self, other): ... + @call_highest_priority("__add__") + def __radd__(self, other): ... + @call_highest_priority("__rsub__") + def __sub__(self, other): ... + @call_highest_priority("__sub__") + def __rsub__(self, other): ... + def __neg__(self) -> Self: ... + def normalize(self) -> Self: ... diff --git a/stubs/sympy-stubs/vector/coordsysrect.pyi b/stubs/sympy-stubs/vector/coordsysrect.pyi index 0ad5773a..5333f943 100644 --- a/stubs/sympy-stubs/vector/coordsysrect.pyi +++ b/stubs/sympy-stubs/vector/coordsysrect.pyi @@ -4,67 +4,44 @@ from sympy.core.basic import Basic from sympy.core.cache import cacheit class CoordSys3D(Basic): - def __new__(cls, name, transformation=..., parent=..., location=..., rotation_matrix=..., vector_names=..., variable_names=...): - ... - - def __iter__(self): - ... - + def __new__( + cls, name, transformation=..., parent=..., location=..., rotation_matrix=..., vector_names=..., variable_names=... + ): ... + def __iter__(self): ... @property - def origin(self): - ... - - def base_vectors(self): - ... - - def base_scalars(self): - ... - - def lame_coefficients(self): - ... - - def transformation_to_parent(self): - ... - - def transformation_from_parent(self) -> tuple[Any, ...]: - ... - - def transformation_from_parent_function(self) -> Callable[..., tuple[Any, ...]]: - ... - - def rotation_matrix(self, other): - ... - + def origin(self): ... + def base_vectors(self): ... + def base_scalars(self): ... + def lame_coefficients(self): ... + def transformation_to_parent(self): ... + def transformation_from_parent(self) -> tuple[Any, ...]: ... + def transformation_from_parent_function(self) -> Callable[..., tuple[Any, ...]]: ... + def rotation_matrix(self, other): ... @cacheit - def position_wrt(self, other): - ... - - def scalar_map(self, other) -> dict[Any, Any]: - ... - - def locate_new(self, name, position, vector_names=..., variable_names=...) -> CoordSys3D: - ... - - def orient_new(self, name, orienters, location=..., vector_names=..., variable_names=...) -> CoordSys3D: - ... - - def orient_new_axis(self, name, angle, axis, location=..., vector_names=..., variable_names=...) -> CoordSys3D: - ... - - def orient_new_body(self, name, angle1, angle2, angle3, rotation_order, location=..., vector_names=..., variable_names=...) -> CoordSys3D: - ... - - def orient_new_space(self, name, angle1, angle2, angle3, rotation_order, location=..., vector_names=..., variable_names=...) -> CoordSys3D: - ... - - def orient_new_quaternion(self, name, q0, q1, q2, q3, location=..., vector_names=..., variable_names=...) -> CoordSys3D: - ... - - def create_new(self, name, transformation, variable_names=..., vector_names=...) -> CoordSys3D: - ... - - def __init__(self, name, location=..., rotation_matrix=..., parent=..., vector_names=..., variable_names=..., latex_vects=..., pretty_vects=..., latex_scalars=..., pretty_scalars=..., transformation=...) -> None: - ... - - - + def position_wrt(self, other): ... + def scalar_map(self, other) -> dict[Any, Any]: ... + def locate_new(self, name, position, vector_names=..., variable_names=...) -> CoordSys3D: ... + def orient_new(self, name, orienters, location=..., vector_names=..., variable_names=...) -> CoordSys3D: ... + def orient_new_axis(self, name, angle, axis, location=..., vector_names=..., variable_names=...) -> CoordSys3D: ... + def orient_new_body( + self, name, angle1, angle2, angle3, rotation_order, location=..., vector_names=..., variable_names=... + ) -> CoordSys3D: ... + def orient_new_space( + self, name, angle1, angle2, angle3, rotation_order, location=..., vector_names=..., variable_names=... + ) -> CoordSys3D: ... + def orient_new_quaternion(self, name, q0, q1, q2, q3, location=..., vector_names=..., variable_names=...) -> CoordSys3D: ... + def create_new(self, name, transformation, variable_names=..., vector_names=...) -> CoordSys3D: ... + def __init__( + self, + name, + location=..., + rotation_matrix=..., + parent=..., + vector_names=..., + variable_names=..., + latex_vects=..., + pretty_vects=..., + latex_scalars=..., + pretty_scalars=..., + transformation=..., + ) -> None: ... diff --git a/stubs/sympy-stubs/vector/deloperator.pyi b/stubs/sympy-stubs/vector/deloperator.pyi index 16503ec5..e0c2a9e6 100644 --- a/stubs/sympy-stubs/vector/deloperator.pyi +++ b/stubs/sympy-stubs/vector/deloperator.pyi @@ -6,20 +6,13 @@ from sympy.vector.operators import Curl, Divergence, Gradient from sympy.vector.vector import VectorAdd, VectorZero class Del(Basic): - def __new__(cls) -> Self: - ... - - def gradient(self, scalar_field, doit=...) -> VectorZero | VectorAdd | Gradient: - ... - + def __new__(cls) -> Self: ... + def gradient(self, scalar_field, doit=...) -> VectorZero | VectorAdd | Gradient: ... + __call__ = ... - def dot(self, vect, doit=...) -> Divergence | Add: - ... - - __and__ = ... - def cross(self, vect, doit=...) -> VectorZero | VectorAdd | Curl: - ... - - __xor__ = ... + def dot(self, vect, doit=...) -> Divergence | Add: ... + __and__ = ... + def cross(self, vect, doit=...) -> VectorZero | VectorAdd | Curl: ... + __xor__ = ... diff --git a/stubs/sympy-stubs/vector/dyadic.pyi b/stubs/sympy-stubs/vector/dyadic.pyi index df449a99..f7c04444 100644 --- a/stubs/sympy-stubs/vector/dyadic.pyi +++ b/stubs/sympy-stubs/vector/dyadic.pyi @@ -14,58 +14,28 @@ class Dyadic(BasisDependent): _base_func: type[Dyadic] zero: DyadicZero @property - def components(self): - ... - - def dot(self, other) -> VectorZero | DyadicZero: - ... - - def __and__(self, other) -> VectorZero | DyadicZero: - ... - - def cross(self, other) -> DyadicZero: - ... - - def __xor__(self, other) -> DyadicZero: - ... - - def to_matrix(self, system, second_system=...): - ... - - + def components(self): ... + def dot(self, other) -> VectorZero | DyadicZero: ... + def __and__(self, other) -> VectorZero | DyadicZero: ... + def cross(self, other) -> DyadicZero: ... + def __xor__(self, other) -> DyadicZero: ... + def to_matrix(self, system, second_system=...): ... class BaseDyadic(Dyadic, AtomicExpr): - def __new__(cls, vector1, vector2) -> DyadicZero | Self: - ... - - + def __new__(cls, vector1, vector2) -> DyadicZero | Self: ... class DyadicMul(BasisDependentMul, Dyadic): - def __new__(cls, *args, **options) -> Order | BasisDependentZero: - ... - + def __new__(cls, *args, **options) -> Order | BasisDependentZero: ... @property - def base_dyadic(self): - ... - + def base_dyadic(self): ... @property - def measure_number(self): - ... - - + def measure_number(self): ... class DyadicAdd(BasisDependentAdd, Dyadic): - def __new__(cls, *args, **options) -> BasisDependentZero | Order: - ... - - + def __new__(cls, *args, **options) -> BasisDependentZero | Order: ... class DyadicZero(BasisDependentZero, Dyadic): _op_priority = ... _pretty_form = ... _latex_form = ... - def __new__(cls) -> Self: - ... - - - + def __new__(cls) -> Self: ... diff --git a/stubs/sympy-stubs/vector/functions.pyi b/stubs/sympy-stubs/vector/functions.pyi index 821ab4bb..38b4e8ee 100644 --- a/stubs/sympy-stubs/vector/functions.pyi +++ b/stubs/sympy-stubs/vector/functions.pyi @@ -7,30 +7,12 @@ from sympy.vector.dyadic import DyadicZero from sympy.vector.operators import Divergence from sympy.vector.vector import VectorZero -def express(expr, system, system2=..., variables=...) -> VectorZero | DyadicZero: - ... - -def directional_derivative(field, direction_vector) -> VectorZero | Literal[0]: - ... - -def laplacian(expr) -> Divergence | Add: - ... - -def is_conservative(field) -> Literal[True]: - ... - -def is_solenoidal(field) -> bool: - ... - -def scalar_potential(field, coord_sys) -> Equality | Relational | Ne: - ... - -def scalar_potential_difference(field, coord_sys, point1, point2): - ... - -def matrix_to_vector(matrix, system) -> VectorZero: - ... - -def orthogonalize(*vlist, orthonormal=...) -> list[Any]: - ... - +def express(expr, system, system2=..., variables=...) -> VectorZero | DyadicZero: ... +def directional_derivative(field, direction_vector) -> VectorZero | Literal[0]: ... +def laplacian(expr) -> Divergence | Add: ... +def is_conservative(field) -> Literal[True]: ... +def is_solenoidal(field) -> bool: ... +def scalar_potential(field, coord_sys) -> Equality | Relational | Ne: ... +def scalar_potential_difference(field, coord_sys, point1, point2): ... +def matrix_to_vector(matrix, system) -> VectorZero: ... +def orthogonalize(*vlist, orthonormal=...) -> list[Any]: ... diff --git a/stubs/sympy-stubs/vector/implicitregion.pyi b/stubs/sympy-stubs/vector/implicitregion.pyi index c09d724e..5457c81a 100644 --- a/stubs/sympy-stubs/vector/implicitregion.pyi +++ b/stubs/sympy-stubs/vector/implicitregion.pyi @@ -5,35 +5,18 @@ from sympy.core import Basic from sympy.sets.sets import Set, Union class ImplicitRegion(Basic): - def __new__(cls, variables, equation) -> Self: - ... - + def __new__(cls, variables, equation) -> Self: ... @property - def variables(self) -> Basic: - ... - + def variables(self) -> Basic: ... @property - def equation(self) -> Basic: - ... - + def equation(self) -> Basic: ... @property - def degree(self) -> Any: - ... - - def regular_point(self) -> tuple[Any] | tuple[Any, Any] | tuple[int, int, Any] | type[list[Any]]: - ... - - def singular_points(self) -> FiniteSet | Set | Intersection | Union | Complement | ConditionSet: - ... - - def multiplicity(self, point) -> Any: - ... - - def rational_parametrization(self, parameters=..., reg_point=...) -> tuple[Basic] | tuple[Any, Any] | tuple[Any, Any, Any]: - ... - - - -def conic_coeff(variables, equation) -> tuple[Any, Any, Any, Any, Any, Any]: - ... + def degree(self) -> Any: ... + def regular_point(self) -> tuple[Any] | tuple[Any, Any] | tuple[int, int, Any] | type[list[Any]]: ... + def singular_points(self) -> FiniteSet | Set | Intersection | Union | Complement | ConditionSet: ... + def multiplicity(self, point) -> Any: ... + def rational_parametrization( + self, parameters=..., reg_point=... + ) -> tuple[Basic] | tuple[Any, Any] | tuple[Any, Any, Any]: ... +def conic_coeff(variables, equation) -> tuple[Any, Any, Any, Any, Any, Any]: ... diff --git a/stubs/sympy-stubs/vector/integrals.pyi b/stubs/sympy-stubs/vector/integrals.pyi index ef65a11a..e27b6d11 100644 --- a/stubs/sympy-stubs/vector/integrals.pyi +++ b/stubs/sympy-stubs/vector/integrals.pyi @@ -5,19 +5,10 @@ from sympy.core import Basic from sympy.core.relational import Relational class ParametricIntegral(Basic): - def __new__(cls, field, parametricregion) -> Equality | Relational | Ne | Self: - ... - + def __new__(cls, field, parametricregion) -> Equality | Relational | Ne | Self: ... @property - def field(self) -> Basic: - ... - + def field(self) -> Basic: ... @property - def parametricregion(self) -> Basic: - ... - - - -def vector_integrate(field, *region) -> Equality | Relational | Ne | ParametricIntegral | Literal[0]: - ... + def parametricregion(self) -> Basic: ... +def vector_integrate(field, *region) -> Equality | Relational | Ne | ParametricIntegral | Literal[0]: ... diff --git a/stubs/sympy-stubs/vector/operators.pyi b/stubs/sympy-stubs/vector/operators.pyi index 2f78e0a2..4a3db03a 100644 --- a/stubs/sympy-stubs/vector/operators.pyi +++ b/stubs/sympy-stubs/vector/operators.pyi @@ -5,47 +5,21 @@ from sympy.core.expr import Expr from sympy.vector.vector import VectorAdd, VectorZero class Gradient(Expr): - def __new__(cls, expr) -> Self: - ... - - def doit(self, **hints) -> VectorZero | VectorAdd | Gradient: - ... - - + def __new__(cls, expr) -> Self: ... + def doit(self, **hints) -> VectorZero | VectorAdd | Gradient: ... class Divergence(Expr): - def __new__(cls, expr) -> Self: - ... - - def doit(self, **hints) -> Divergence | Add: - ... - - + def __new__(cls, expr) -> Self: ... + def doit(self, **hints) -> Divergence | Add: ... class Curl(Expr): - def __new__(cls, expr) -> Self: - ... - - def doit(self, **hints) -> VectorZero | VectorAdd | Curl: - ... - - - -def curl(vect, doit=...) -> VectorZero | VectorAdd | Curl: - ... + def __new__(cls, expr) -> Self: ... + def doit(self, **hints) -> VectorZero | VectorAdd | Curl: ... -def divergence(vect, doit=...) -> Divergence | Add: - ... - -def gradient(scalar_field, doit=...) -> VectorZero | VectorAdd | Gradient: - ... +def curl(vect, doit=...) -> VectorZero | VectorAdd | Curl: ... +def divergence(vect, doit=...) -> Divergence | Add: ... +def gradient(scalar_field, doit=...) -> VectorZero | VectorAdd | Gradient: ... class Laplacian(Expr): - def __new__(cls, expr) -> Self: - ... - - def doit(self, **hints) -> Divergence | Add: - ... - - - + def __new__(cls, expr) -> Self: ... + def doit(self, **hints) -> Divergence | Add: ... diff --git a/stubs/sympy-stubs/vector/orienters.pyi b/stubs/sympy-stubs/vector/orienters.pyi index d3efdeb1..893d8085 100644 --- a/stubs/sympy-stubs/vector/orienters.pyi +++ b/stubs/sympy-stubs/vector/orienters.pyi @@ -4,96 +4,47 @@ from sympy.core.basic import Basic from sympy.core.cache import cacheit class Orienter(Basic): - def rotation_matrix(self): - ... - - + def rotation_matrix(self): ... class AxisOrienter(Orienter): - def __new__(cls, angle, axis) -> Self: - ... - - def __init__(self, angle, axis) -> None: - ... - + def __new__(cls, angle, axis) -> Self: ... + def __init__(self, angle, axis) -> None: ... @cacheit - def rotation_matrix(self, system): - ... - + def rotation_matrix(self, system): ... @property - def angle(self): - ... - + def angle(self): ... @property - def axis(self): - ... - - + def axis(self): ... class ThreeAngleOrienter(Orienter): - def __new__(cls, angle1, angle2, angle3, rot_order) -> Self: - ... - + def __new__(cls, angle1, angle2, angle3, rot_order) -> Self: ... @property - def angle1(self): - ... - + def angle1(self): ... @property - def angle2(self): - ... - + def angle2(self): ... @property - def angle3(self): - ... - + def angle3(self): ... @property - def rot_order(self): - ... - - + def rot_order(self): ... class BodyOrienter(ThreeAngleOrienter): _in_order = ... - def __new__(cls, angle1, angle2, angle3, rot_order) -> Self: - ... - - def __init__(self, angle1, angle2, angle3, rot_order) -> None: - ... - - + def __new__(cls, angle1, angle2, angle3, rot_order) -> Self: ... + def __init__(self, angle1, angle2, angle3, rot_order) -> None: ... class SpaceOrienter(ThreeAngleOrienter): _in_order = ... - def __new__(cls, angle1, angle2, angle3, rot_order) -> Self: - ... - - def __init__(self, angle1, angle2, angle3, rot_order) -> None: - ... - - + def __new__(cls, angle1, angle2, angle3, rot_order) -> Self: ... + def __init__(self, angle1, angle2, angle3, rot_order) -> None: ... class QuaternionOrienter(Orienter): - def __new__(cls, q0, q1, q2, q3) -> Self: - ... - - def __init__(self, angle1, angle2, angle3, rot_order) -> None: - ... - + def __new__(cls, q0, q1, q2, q3) -> Self: ... + def __init__(self, angle1, angle2, angle3, rot_order) -> None: ... @property - def q0(self): - ... - + def q0(self): ... @property - def q1(self): - ... - + def q1(self): ... @property - def q2(self): - ... - + def q2(self): ... @property - def q3(self): - ... - - - + def q3(self): ... diff --git a/stubs/sympy-stubs/vector/parametricregion.pyi b/stubs/sympy-stubs/vector/parametricregion.pyi index 9076164e..d7b6c144 100644 --- a/stubs/sympy-stubs/vector/parametricregion.pyi +++ b/stubs/sympy-stubs/vector/parametricregion.pyi @@ -6,52 +6,27 @@ from sympy.geometry import Curve, Ellipse, Point, Polygon, Segment from sympy.vector import ImplicitRegion class ParametricRegion(Basic): - def __new__(cls, definition, *bounds) -> Self: - ... - + def __new__(cls, definition, *bounds) -> Self: ... @property - def definition(self) -> Basic: - ... - + def definition(self) -> Basic: ... @property - def limits(self): - ... - + def limits(self): ... @property - def parameters(self): - ... - + def parameters(self): ... @property - def dimensions(self) -> int: - ... - - + def dimensions(self) -> int: ... @singledispatch -def parametric_region_list(reg): - ... - +def parametric_region_list(reg): ... @parametric_region_list.register(Point) -def _(obj) -> list[ParametricRegion]: - ... - +def _(obj) -> list[ParametricRegion]: ... @parametric_region_list.register(Curve) -def _(obj) -> list[ParametricRegion]: - ... - +def _(obj) -> list[ParametricRegion]: ... @parametric_region_list.register(Ellipse) -def _(obj, parameter=...) -> list[ParametricRegion]: - ... - +def _(obj, parameter=...) -> list[ParametricRegion]: ... @parametric_region_list.register(Segment) -def _(obj, parameter=...) -> list[ParametricRegion]: - ... - +def _(obj, parameter=...) -> list[ParametricRegion]: ... @parametric_region_list.register(Polygon) -def _(obj, parameter=...) -> list[Any]: - ... - +def _(obj, parameter=...) -> list[Any]: ... @parametric_region_list.register(ImplicitRegion) -def _(obj, parameters=...) -> list[ParametricRegion]: - ... - +def _(obj, parameters=...) -> list[ParametricRegion]: ... diff --git a/stubs/sympy-stubs/vector/point.pyi b/stubs/sympy-stubs/vector/point.pyi index 0d78f5d4..6e18e886 100644 --- a/stubs/sympy-stubs/vector/point.pyi +++ b/stubs/sympy-stubs/vector/point.pyi @@ -5,18 +5,8 @@ from sympy.core.cache import cacheit from sympy.vector.vector import VectorZero class Point(Basic): - def __new__(cls, name, position=..., parent_point=...) -> Self: - ... - + def __new__(cls, name, position=..., parent_point=...) -> Self: ... @cacheit - def position_wrt(self, other) -> VectorZero: - ... - - def locate_new(self, name, position) -> Point: - ... - - def express_coordinates(self, coordinate_system) -> tuple[Any, ...]: - ... - - - + def position_wrt(self, other) -> VectorZero: ... + def locate_new(self, name, position) -> Point: ... + def express_coordinates(self, coordinate_system) -> tuple[Any, ...]: ... diff --git a/stubs/sympy-stubs/vector/scalar.pyi b/stubs/sympy-stubs/vector/scalar.pyi index e526de49..21a96c82 100644 --- a/stubs/sympy-stubs/vector/scalar.pyi +++ b/stubs/sympy-stubs/vector/scalar.pyi @@ -3,20 +3,14 @@ from typing import Self from sympy.core import AtomicExpr class BaseScalar(AtomicExpr): - def __new__(cls, index, system, pretty_str=..., latex_str=...) -> Self: - ... - + def __new__(cls, index, system, pretty_str=..., latex_str=...) -> Self: ... + is_commutative = ... is_symbol = ... @property - def free_symbols(self) -> set[Self]: - ... - + def free_symbols(self) -> set[Self]: ... + _diff_wrt = ... precedence = ... @property - def system(self): - ... - - - + def system(self): ... diff --git a/stubs/sympy-stubs/vector/vector.pyi b/stubs/sympy-stubs/vector/vector.pyi index a425ae94..b6c665e7 100644 --- a/stubs/sympy-stubs/vector/vector.pyi +++ b/stubs/sympy-stubs/vector/vector.pyi @@ -18,108 +18,49 @@ class Vector(BasisDependent): _base_func: type[Vector] zero: VectorZero @property - def components(self): - ... - - def magnitude(self) -> Pow: - ... - - def normalize(self): - ... - - def dot(self, other) -> VectorZero | Callable[..., VectorZero | Any | Literal[0]] | Add | Dot: - ... - - def __and__(self, other) -> VectorZero | Callable[..., VectorZero | Any | Literal[0]] | Add | Dot: - ... - - def cross(self, other) -> DyadicZero | VectorAdd | VectorZero | Cross: - ... - - def __xor__(self, other) -> DyadicZero | VectorAdd | VectorZero | Cross: - ... - - def outer(self, other) -> DyadicZero | BasisDependentZero | Order: - ... - - def projection(self, other, scalar=...) -> VectorZero: - ... - - def __or__(self, other) -> DyadicZero | BasisDependentZero | Order: - ... - - def to_matrix(self, system) -> ImmutableDenseMatrix: - ... - - def separate(self) -> dict[Any, Any]: - ... - - + def components(self): ... + def magnitude(self) -> Pow: ... + def normalize(self): ... + def dot(self, other) -> VectorZero | Callable[..., VectorZero | Any | Literal[0]] | Add | Dot: ... + def __and__(self, other) -> VectorZero | Callable[..., VectorZero | Any | Literal[0]] | Add | Dot: ... + def cross(self, other) -> DyadicZero | VectorAdd | VectorZero | Cross: ... + def __xor__(self, other) -> DyadicZero | VectorAdd | VectorZero | Cross: ... + def outer(self, other) -> DyadicZero | BasisDependentZero | Order: ... + def projection(self, other, scalar=...) -> VectorZero: ... + def __or__(self, other) -> DyadicZero | BasisDependentZero | Order: ... + def to_matrix(self, system) -> ImmutableDenseMatrix: ... + def separate(self) -> dict[Any, Any]: ... class BaseVector(Vector, AtomicExpr): - def __new__(cls, index, system, pretty_str=..., latex_str=...) -> Self: - ... - + def __new__(cls, index, system, pretty_str=..., latex_str=...) -> Self: ... @property - def system(self): - ... - + def system(self): ... @property - def free_symbols(self) -> set[Self]: - ... - - + def free_symbols(self) -> set[Self]: ... class VectorAdd(BasisDependentAdd, Vector): - def __new__(cls, *args, **options) -> BasisDependentZero | Order: - ... - - + def __new__(cls, *args, **options) -> BasisDependentZero | Order: ... class VectorMul(BasisDependentMul, Vector): - def __new__(cls, *args, **options) -> Order | BasisDependentZero: - ... - + def __new__(cls, *args, **options) -> Order | BasisDependentZero: ... @property - def base_vector(self): - ... - + def base_vector(self): ... @property - def measure_number(self): - ... - - + def measure_number(self): ... class VectorZero(BasisDependentZero, Vector): _op_priority = ... _pretty_form = ... _latex_form = ... - def __new__(cls) -> Self: - ... - - + def __new__(cls) -> Self: ... class Cross(Vector): - def __new__(cls, expr1, expr2) -> Self: - ... - - def doit(self, **hints) -> VectorAdd | VectorZero | Cross: - ... - - + def __new__(cls, expr1, expr2) -> Self: ... + def doit(self, **hints) -> VectorAdd | VectorZero | Cross: ... class Dot(Expr): - def __new__(cls, expr1, expr2) -> Self: - ... - - def doit(self, **hints) -> Add | Dot: - ... - - - -def cross(vect1, vect2) -> VectorAdd | VectorZero | Cross: - ... - -def dot(vect1, vect2) -> Add | Dot: - ... + def __new__(cls, expr1, expr2) -> Self: ... + def doit(self, **hints) -> Add | Dot: ... +def cross(vect1, vect2) -> VectorAdd | VectorZero | Cross: ... +def dot(vect1, vect2) -> Add | Dot: ...