multiple-integrate 2.2.0__tar.gz → 2.3.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- multiple_integrate-2.3.0/MANIFEST.in +18 -0
- multiple_integrate-2.3.0/PKG-INFO +348 -0
- multiple_integrate-2.3.0/README.md +265 -0
- multiple_integrate-2.3.0/benchmarks/common_integral_methods.py +62 -0
- multiple_integrate-2.3.0/benchmarks/common_region_integrals.py +85 -0
- multiple_integrate-2.3.0/benchmarks/gaussian_certificate_reuse.py +77 -0
- multiple_integrate-2.3.0/benchmarks/polygon_disk_screened_methods.py +42 -0
- multiple_integrate-2.3.0/benchmarks/results/common-region-integrals.json +44 -0
- multiple_integrate-2.3.0/benchmarks/results/common-region-methods.json +44 -0
- multiple_integrate-2.3.0/benchmarks/results/composable-integrals.json +90 -0
- multiple_integrate-2.3.0/benchmarks/results/extended-common-integrals.json +71 -0
- multiple_integrate-2.3.0/benchmarks/results/gaussian-certificate-reuse.json +23 -0
- multiple_integrate-2.3.0/benchmarks/results/gaussian-relative-periodized.json +125 -0
- multiple_integrate-2.3.0/benchmarks/results/numerical-backend-methods.json +135 -0
- multiple_integrate-2.3.0/benchmarks/results/numerical-regions.json +101 -0
- multiple_integrate-2.3.0/benchmarks/results/positive-quartic-comparison.json +14 -0
- multiple_integrate-2.3.0/benchmarks/results/singular-curved-qmc.json +101 -0
- multiple_integrate-2.3.0/docs/adaptive-numerical-dispatch.md +103 -0
- multiple_integrate-2.3.0/docs/api/expert-namespaces.rst +52 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/docs/api/index.rst +1 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/docs/api/regions.rst +2 -2
- multiple_integrate-2.3.0/docs/api.md +150 -0
- multiple_integrate-2.3.0/docs/architecture/semialg-integration.md +22 -0
- multiple_integrate-2.3.0/docs/asymmetric-principal-values.md +36 -0
- multiple_integrate-2.3.0/docs/boundary-reduction.md +61 -0
- multiple_integrate-2.3.0/docs/branch-safe-box-integrals.md +72 -0
- multiple_integrate-2.3.0/docs/capabilities.md +77 -0
- multiple_integrate-2.3.0/docs/capability-matrix.json +380 -0
- multiple_integrate-2.3.0/docs/certificate-soundness.md +44 -0
- multiple_integrate-2.3.0/docs/certification.md +75 -0
- multiple_integrate-2.3.0/docs/changelog.md +5 -0
- multiple_integrate-2.3.0/docs/coarea.md +105 -0
- multiple_integrate-2.3.0/docs/common-region-integrals.md +63 -0
- multiple_integrate-2.3.0/docs/composable-integral-methods.md +107 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/docs/concepts/ranges-and-regions.rst +1 -1
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/docs/contributing.md +3 -8
- multiple_integrate-2.3.0/docs/curved-partitions-and-multidimensional-phases.md +83 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/docs/decomposition.md +5 -2
- multiple_integrate-2.3.0/docs/design-and-performance.md +61 -0
- multiple_integrate-2.3.0/docs/disk-exponentials-gaussian-rectangles-box-potentials.md +125 -0
- multiple_integrate-2.3.0/docs/domain-requirements.md +177 -0
- multiple_integrate-2.3.0/docs/examples/extended_integrals.py +40 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/docs/examples/regions.rst +1 -1
- multiple_integrate-2.3.0/docs/examples/semialgebraic_certificates.py +42 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/docs/examples.md +2 -4
- multiple_integrate-2.3.0/docs/flux-atlases-and-affine-gaussians.md +60 -0
- multiple_integrate-2.3.0/docs/flux-gaussian-and-fourier-integrals.md +74 -0
- multiple_integrate-2.3.0/docs/fold-products-and-simplex-enclosures.md +69 -0
- multiple_integrate-2.3.0/docs/gaussian-ellipse-and-weighted-surface-integrals.md +133 -0
- multiple_integrate-2.3.0/docs/gaussian-polygons-disk-identities-screened-potentials.md +111 -0
- multiple_integrate-2.3.0/docs/gaussian-polynomial-fourier.md +57 -0
- multiple_integrate-2.3.0/docs/gaussian-potentials-and-curved-regions.md +89 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/docs/geometry/clipped-cutoffs.md +1 -2
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/docs/geometry/cusp-proofs.md +2 -3
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/docs/geometry/parameter-geometry.md +2 -3
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/docs/geometry/radial-series.md +2 -3
- multiple_integrate-2.2.0/docs/geometry-extensions.md → multiple_integrate-2.3.0/docs/geometry-and-parameter-requirements.md +2 -3
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/docs/geometry-casebook.md +6 -7
- multiple_integrate-2.3.0/docs/implemented-capabilities.md +36 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/docs/index.rst +38 -2
- multiple_integrate-2.3.0/docs/installation.rst +75 -0
- multiple_integrate-2.3.0/docs/integration-performance.md +101 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/docs/laurent-clips-and-tangencies.md +5 -6
- multiple_integrate-2.3.0/docs/limitations.md +84 -0
- multiple_integrate-2.3.0/docs/logarithmic-parameter-cases.md +22 -0
- multiple_integrate-2.3.0/docs/method-example-coverage.json +88 -0
- multiple_integrate-2.3.0/docs/method-examples.md +99 -0
- multiple_integrate-2.3.0/docs/method-reference-coverage.json +755 -0
- multiple_integrate-2.3.0/docs/method-references.md +255 -0
- multiple_integrate-2.3.0/docs/nonlinear-changevar.md +80 -0
- multiple_integrate-2.3.0/docs/nonlinear-moments-and-singularities.md +68 -0
- multiple_integrate-2.3.0/docs/nonseparable-improper.md +34 -0
- multiple_integrate-2.3.0/docs/numerical-backends.md +62 -0
- multiple_integrate-2.3.0/docs/numerical-coarea.md +77 -0
- multiple_integrate-2.3.0/docs/numerical-integration.md +155 -0
- multiple_integrate-2.3.0/docs/numerical-method-controls.md +100 -0
- multiple_integrate-2.3.0/docs/numerical-method-selection.md +24 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/docs/parameterized-integration.md +17 -65
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/docs/performance-methods.md +21 -15
- multiple_integrate-2.3.0/docs/polynomial-folds-and-certified-moments.md +110 -0
- multiple_integrate-2.3.0/docs/polynomial-polytopes.md +185 -0
- multiple_integrate-2.3.0/docs/prepared-kernel-performance.md +31 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/docs/proved-families.md +2 -3
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/docs/quickstart.rst +46 -1
- multiple_integrate-2.3.0/docs/reference-verification.json +195 -0
- multiple_integrate-2.3.0/docs/regularization.md +155 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/docs/scoped-convergence.md +17 -54
- multiple_integrate-2.3.0/docs/sectors-and-contact-charts.md +51 -0
- multiple_integrate-2.3.0/docs/selected-symbolic-families.md +91 -0
- multiple_integrate-2.3.0/docs/semialgebraic-atlases-and-provenance.md +173 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/docs/series-evaluation.md +1 -2
- multiple_integrate-2.3.0/docs/sheared-folds-and-boundary-formulas.md +33 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/docs/strategies.md +4 -10
- multiple_integrate-2.3.0/docs/strategy-reference-map.json +1082 -0
- multiple_integrate-2.3.0/docs/stratified-maps-and-truncated-gaussians.md +81 -0
- multiple_integrate-2.3.0/docs/structured-results.md +78 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/docs/supported-regions.md +7 -19
- multiple_integrate-2.3.0/docs/symbolic-and-numerical-preparation.md +72 -0
- multiple_integrate-2.3.0/docs/testing.md +187 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/docs/theory.md +15 -36
- multiple_integrate-2.3.0/docs/weighted-radial-and-quadratic-integrals.md +26 -0
- multiple_integrate-2.3.0/docs/why-multipleintegrate.md +260 -0
- multiple_integrate-2.3.0/docs/worked-failures.md +56 -0
- multiple_integrate-2.3.0/docs/worked-integral-identities.md +154 -0
- multiple_integrate-2.3.0/examples/benchmark_chart_batches.py +130 -0
- multiple_integrate-2.3.0/examples/benchmark_higher_polytopes.py +110 -0
- multiple_integrate-2.3.0/examples/benchmark_polytopes.py +199 -0
- multiple_integrate-2.3.0/examples/compare_sympy.py +238 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/examples/geometry_casebook.py +4 -10
- multiple_integrate-2.3.0/examples/layer_cake.py +13 -0
- multiple_integrate-2.3.0/examples/method_catalogue.py +1043 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/examples/performance_methods.py +2 -1
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/examples/proof_portfolio.py +4 -2
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/notebooks/multiple_integration.ipynb +208 -215
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/pyproject.toml +14 -10
- multiple_integrate-2.3.0/src/multiple_integrate/__init__.py +28 -0
- multiple_integrate-2.3.0/src/multiple_integrate/_compiled_polynomials.py +225 -0
- multiple_integrate-2.3.0/src/multiple_integrate/_expression_features.py +72 -0
- multiple_integrate-2.3.0/src/multiple_integrate/_numeric_accuracy.py +33 -0
- multiple_integrate-2.3.0/src/multiple_integrate/_numeric_adaptive.py +30 -0
- multiple_integrate-2.3.0/src/multiple_integrate/_numeric_batch.py +65 -0
- multiple_integrate-2.3.0/src/multiple_integrate/_numeric_coarea.py +448 -0
- multiple_integrate-2.3.0/src/multiple_integrate/_numeric_cuba.py +367 -0
- multiple_integrate-2.3.0/src/multiple_integrate/_numeric_curved.py +221 -0
- multiple_integrate-2.3.0/src/multiple_integrate/_numeric_curved_partition.py +495 -0
- multiple_integrate-2.3.0/src/multiple_integrate/_numeric_dispatch.py +273 -0
- multiple_integrate-2.3.0/src/multiple_integrate/_numeric_engines.py +471 -0
- multiple_integrate-2.3.0/src/multiple_integrate/_numeric_execution.py +489 -0
- multiple_integrate-2.3.0/src/multiple_integrate/_numeric_fused.py +375 -0
- multiple_integrate-2.3.0/src/multiple_integrate/_numeric_geometry.py +539 -0
- multiple_integrate-2.3.0/src/multiple_integrate/_numeric_intervals.py +630 -0
- multiple_integrate-2.3.0/src/multiple_integrate/_numeric_levin_linear.py +320 -0
- multiple_integrate-2.3.0/src/multiple_integrate/_numeric_methods.py +72 -0
- multiple_integrate-2.3.0/src/multiple_integrate/_numeric_mp_cubature.py +127 -0
- multiple_integrate-2.3.0/src/multiple_integrate/_numeric_multidimensional_oscillatory.py +549 -0
- multiple_integrate-2.3.0/src/multiple_integrate/_numeric_nested.py +183 -0
- multiple_integrate-2.3.0/src/multiple_integrate/_numeric_options.py +211 -0
- multiple_integrate-2.3.0/src/multiple_integrate/_numeric_oscillatory.py +369 -0
- multiple_integrate-2.3.0/src/multiple_integrate/_numeric_partition.py +259 -0
- multiple_integrate-2.3.0/src/multiple_integrate/_numeric_periodic.py +299 -0
- multiple_integrate-2.3.0/src/multiple_integrate/_numeric_plans.py +119 -0
- multiple_integrate-2.3.0/src/multiple_integrate/_numeric_preparation.py +155 -0
- multiple_integrate-2.3.0/src/multiple_integrate/_numeric_problem.py +71 -0
- multiple_integrate-2.3.0/src/multiple_integrate/_numeric_reduction.py +114 -0
- multiple_integrate-2.3.0/src/multiple_integrate/_numeric_results.py +121 -0
- multiple_integrate-2.3.0/src/multiple_integrate/_numeric_sampling.py +98 -0
- multiple_integrate-2.3.0/src/multiple_integrate/_numeric_session.py +271 -0
- multiple_integrate-2.3.0/src/multiple_integrate/_numeric_singularities.py +252 -0
- multiple_integrate-2.3.0/src/multiple_integrate/_numeric_smoothing.py +50 -0
- multiple_integrate-2.3.0/src/multiple_integrate/_numeric_sparse.py +364 -0
- multiple_integrate-2.3.0/src/multiple_integrate/_numeric_stochastic.py +209 -0
- multiple_integrate-2.3.0/src/multiple_integrate/_numeric_worker.py +98 -0
- multiple_integrate-2.3.0/src/multiple_integrate/_polytope_charts.py +164 -0
- multiple_integrate-2.3.0/src/multiple_integrate/_polytope_geometry.py +789 -0
- multiple_integrate-2.3.0/src/multiple_integrate/_polytope_moments.py +351 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/src/multiple_integrate/adapters/asymptotic.py +37 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/src/multiple_integrate/adapters/funcprops.py +44 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/src/multiple_integrate/adapters/semialg.py +307 -3
- multiple_integrate-2.3.0/src/multiple_integrate/affine_delta.py +110 -0
- multiple_integrate-2.3.0/src/multiple_integrate/affine_rational_surface.py +108 -0
- multiple_integrate-2.3.0/src/multiple_integrate/analytic_region_formulas.py +385 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/src/multiple_integrate/analytic_strategies.py +1 -0
- multiple_integrate-2.3.0/src/multiple_integrate/api/__init__.py +22 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/src/multiple_integrate/api/integration.py +235 -38
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/src/multiple_integrate/assumptions.py +25 -4
- multiple_integrate-2.3.0/src/multiple_integrate/bivariate_polynomial_change.py +160 -0
- multiple_integrate-2.3.0/src/multiple_integrate/box_potentials.py +351 -0
- multiple_integrate-2.3.0/src/multiple_integrate/branch_safe.py +418 -0
- multiple_integrate-2.3.0/src/multiple_integrate/cauchy_principal_value.py +300 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/src/multiple_integrate/cell_proofs.py +285 -1
- multiple_integrate-2.3.0/src/multiple_integrate/central_quadratic_wedge.py +162 -0
- multiple_integrate-2.3.0/src/multiple_integrate/certificates.py +22 -0
- multiple_integrate-2.3.0/src/multiple_integrate/certified_operations.py +523 -0
- multiple_integrate-2.3.0/src/multiple_integrate/change_certificates.py +305 -0
- multiple_integrate-2.3.0/src/multiple_integrate/changevar.py +160 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/src/multiple_integrate/coarea.py +113 -31
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/src/multiple_integrate/convergence.py +5 -1
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/src/multiple_integrate/convergence_evidence.py +101 -19
- multiple_integrate-2.3.0/src/multiple_integrate/convex_polygon_certification.py +153 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/src/multiple_integrate/core.py +731 -31
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/src/multiple_integrate/cusp_horns.py +53 -0
- multiple_integrate-2.3.0/src/multiple_integrate/degenerate_fresnel.py +100 -0
- multiple_integrate-2.3.0/src/multiple_integrate/ellipsoid_flux.py +149 -0
- multiple_integrate-2.3.0/src/multiple_integrate/ellipsoid_slab_moments.py +130 -0
- multiple_integrate-2.3.0/src/multiple_integrate/ellipsoid_surface.py +164 -0
- multiple_integrate-2.3.0/src/multiple_integrate/entire_box_series.py +255 -0
- multiple_integrate-2.3.0/src/multiple_integrate/extended_integrals.py +565 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/src/multiple_integrate/fast_rules.py +35 -1
- multiple_integrate-2.3.0/src/multiple_integrate/fourier.py +24 -0
- multiple_integrate-2.3.0/src/multiple_integrate/gaussian.py +57 -0
- multiple_integrate-2.3.0/src/multiple_integrate/gaussian_ellipses.py +332 -0
- multiple_integrate-2.3.0/src/multiple_integrate/gaussian_higher_moments.py +265 -0
- multiple_integrate-2.3.0/src/multiple_integrate/gaussian_moments.py +112 -0
- multiple_integrate-2.3.0/src/multiple_integrate/gaussian_multivariate.py +532 -0
- multiple_integrate-2.3.0/src/multiple_integrate/gaussian_numeric.py +116 -0
- multiple_integrate-2.3.0/src/multiple_integrate/gaussian_verified_numeric.py +291 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/src/multiple_integrate/geometric_principal_value.py +99 -4
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/src/multiple_integrate/hadamard.py +2 -0
- multiple_integrate-2.3.0/src/multiple_integrate/heat_potentials.py +689 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/src/multiple_integrate/hypersurface_atlas.py +7 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/src/multiple_integrate/hypersurface_principal_value.py +214 -44
- multiple_integrate-2.3.0/src/multiple_integrate/nonlinear_change.py +359 -0
- multiple_integrate-2.3.0/src/multiple_integrate/numeric.py +912 -0
- multiple_integrate-2.3.0/src/multiple_integrate/numeric_backends.py +126 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/src/multiple_integrate/numerical_verification.py +45 -0
- multiple_integrate-2.3.0/src/multiple_integrate/orthogonal_degenerate_fresnel.py +99 -0
- multiple_integrate-2.3.0/src/multiple_integrate/orthogonal_quadratic_clips.py +183 -0
- multiple_integrate-2.3.0/src/multiple_integrate/oscillatory.py +151 -0
- multiple_integrate-2.3.0/src/multiple_integrate/ownership.py +176 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/src/multiple_integrate/parameter_cells.py +86 -9
- multiple_integrate-2.3.0/src/multiple_integrate/performance.py +87 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/src/multiple_integrate/planner.py +78 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/src/multiple_integrate/policy.py +42 -4
- multiple_integrate-2.3.0/src/multiple_integrate/polyhedral_surface_flux.py +129 -0
- multiple_integrate-2.3.0/src/multiple_integrate/polynomial_multiplicity.py +330 -0
- multiple_integrate-2.3.0/src/multiple_integrate/polytopes.py +479 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/src/multiple_integrate/principal_value_prescriptions.py +10 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/src/multiple_integrate/pushforward_strategies.py +3 -1
- multiple_integrate-2.3.0/src/multiple_integrate/quadratic_gaussian.py +440 -0
- multiple_integrate-2.3.0/src/multiple_integrate/quadratic_intersections.py +430 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/src/multiple_integrate/quadratic_radial.py +4 -1
- multiple_integrate-2.3.0/src/multiple_integrate/rational_graph_flux.py +135 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/src/multiple_integrate/recognition.py +64 -11
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/src/multiple_integrate/region_formulas.py +65 -7
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/src/multiple_integrate/region_recognition.py +15 -7
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/src/multiple_integrate/region_types.py +181 -24
- multiple_integrate-2.3.0/src/multiple_integrate/regions.py +110 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/src/multiple_integrate/regular_density.py +2 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/src/multiple_integrate/regularization.py +10 -2
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/src/multiple_integrate/results.py +107 -10
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/src/multiple_integrate/selected_families.py +102 -1
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/src/multiple_integrate/semialg_geometry.py +17 -1
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/src/multiple_integrate/separable_strategies.py +26 -5
- multiple_integrate-2.3.0/src/multiple_integrate/sheared_polynomial_coarea.py +194 -0
- multiple_integrate-2.3.0/src/multiple_integrate/simple_polygons.py +363 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/src/multiple_integrate/singular_geometry.py +10 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/src/multiple_integrate/singularities.py +265 -24
- multiple_integrate-2.3.0/src/multiple_integrate/spatial_quadratic_wedge.py +99 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/src/multiple_integrate/sphere_integrals.py +15 -2
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/src/multiple_integrate/strategy_common.py +85 -15
- multiple_integrate-2.3.0/src/multiple_integrate/stratified_change.py +303 -0
- multiple_integrate-2.3.0/src/multiple_integrate/structured_provenance.py +473 -0
- multiple_integrate-2.3.0/src/multiple_integrate/surface_certification.py +713 -0
- multiple_integrate-2.3.0/src/multiple_integrate/surfaces.py +104 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/src/multiple_integrate/symbolic_geometry.py +47 -10
- multiple_integrate-2.3.0/src/multiple_integrate/tetrahedral_flux.py +103 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/src/multiple_integrate/transition_cells.py +7 -0
- multiple_integrate-2.3.0/src/multiple_integrate/translated_oblique_quadratic.py +240 -0
- multiple_integrate-2.3.0/src/multiple_integrate/triangular_intersections.py +452 -0
- multiple_integrate-2.3.0/src/multiple_integrate/verified_quadrature.py +265 -0
- multiple_integrate-2.3.0/src/multiple_integrate/verified_simplex.py +163 -0
- multiple_integrate-2.3.0/src/multiple_integrate.egg-info/PKG-INFO +348 -0
- multiple_integrate-2.3.0/src/multiple_integrate.egg-info/SOURCES.txt +502 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/src/multiple_integrate.egg-info/requires.txt +20 -6
- multiple_integrate-2.3.0/tests/test_adaptive_numerical_controls.py +324 -0
- multiple_integrate-2.3.0/tests/test_adaptive_partitioned_oscillatory_integration.py +361 -0
- multiple_integrate-2.3.0/tests/test_affine_chart_reuse.py +71 -0
- multiple_integrate-2.3.0/tests/test_affine_clipped_gaussian_ellipses.py +94 -0
- multiple_integrate-2.3.0/tests/test_affine_dirac_integrals.py +91 -0
- multiple_integrate-2.3.0/tests/test_affine_parameter_feasibility.py +43 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_algebraic_pv_and_singular_geometry.py +5 -4
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_architecture_contract.py +19 -11
- multiple_integrate-2.3.0/tests/test_assumption_cache.py +76 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_asymmetric_affine_cutoffs.py +2 -3
- multiple_integrate-2.3.0/tests/test_asymmetric_pv_and_partition_cache.py +140 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_asymptotic_log_radical_cutoff.py +3 -3
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_asymptotic_order_adapter.py +4 -3
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_backend_delegation.py +40 -2
- multiple_integrate-2.2.0/tests/test_geometry_extensions.py → multiple_integrate-2.3.0/tests/test_bernstein_contact_geometry.py +11 -11
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_boole_piecewise.py +2 -1
- multiple_integrate-2.2.0/tests/test_serious_boundary_regressions.py → multiple_integrate-2.3.0/tests/test_boundary_conditions.py +10 -9
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_boundary_reduction.py +1 -1
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_bounded_dispatch_contracts.py +18 -4
- multiple_integrate-2.3.0/tests/test_branch_safe_box_rules.py +205 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_casebook_and_docs.py +46 -1
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_certificate_replay_and_singular_order.py +10 -10
- multiple_integrate-2.3.0/tests/test_chart_domains_and_compiled.py +251 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_coarea.py +2 -3
- multiple_integrate-2.3.0/tests/test_coarea_sign_evidence.py +53 -0
- multiple_integrate-2.3.0/tests/test_cold_region_dispatch.py +28 -0
- multiple_integrate-2.3.0/tests/test_combined_heat_potentials.py +171 -0
- multiple_integrate-2.3.0/tests/test_compact_support_and_graph_measure.py +63 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_constant_orientation.py +6 -1
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_convergence_documentation.py +1 -1
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_convergence_summaries.py +3 -7
- multiple_integrate-2.3.0/tests/test_coordinate_binding_and_geometry.py +176 -0
- multiple_integrate-2.3.0/tests/test_coupled_piecewise_fallback.py +55 -0
- multiple_integrate-2.3.0/tests/test_cross_namespace_certificate_soundness_properties.py +365 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_cross_strategy_oracles.py +3 -2
- multiple_integrate-2.3.0/tests/test_curved_partitions_and_multidimensional_phases.py +388 -0
- multiple_integrate-2.3.0/tests/test_density_and_kernel_domains.py +73 -0
- multiple_integrate-2.3.0/tests/test_dependency_real_contract.py +48 -0
- multiple_integrate-2.3.0/tests/test_disk_exponentials_and_box_potentials.py +124 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_disk_radial_classification.py +1 -1
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_dispatch_safety.py +2 -6
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_documentation_examples.py +2 -1
- multiple_integrate-2.2.0/tests/test_moment_extensions.py → multiple_integrate-2.3.0/tests/test_endpoint_and_laplace_moments.py +4 -9
- multiple_integrate-2.2.0/tests/test_serious_shortcut_regressions.py → multiple_integrate-2.3.0/tests/test_exact_shortcut_conditions.py +11 -1
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_exceptional_fiber_matrix.py +2 -7
- multiple_integrate-2.3.0/tests/test_extended_documentation.py +60 -0
- multiple_integrate-2.3.0/tests/test_extended_integrals.py +161 -0
- multiple_integrate-2.3.0/tests/test_fast_gaussian_dispatch.py +28 -0
- multiple_integrate-2.3.0/tests/test_fold_products_and_simplex_enclosures.py +180 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_gap_improvements.py +8 -11
- multiple_integrate-2.3.0/tests/test_gaussian_attraction_and_softening.py +182 -0
- multiple_integrate-2.3.0/tests/test_gaussian_binding_and_certificates.py +108 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_gaussian_branches_and_parameter_domains.py +70 -4
- multiple_integrate-2.3.0/tests/test_gaussian_coulomb_and_curved_regions.py +254 -0
- multiple_integrate-2.3.0/tests/test_gaussian_ellipse_probabilities.py +142 -0
- multiple_integrate-2.3.0/tests/test_gaussian_polygons.py +71 -0
- multiple_integrate-2.3.0/tests/test_gaussian_polynomial_fourier.py +137 -0
- multiple_integrate-2.3.0/tests/test_gaussian_rectangle_evaluation.py +97 -0
- multiple_integrate-2.3.0/tests/test_gaussian_relative_periodized_integration.py +334 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_generated_mathematical_families.py +3 -9
- multiple_integrate-2.3.0/tests/test_geometry_and_parameter_domains.py +263 -0
- multiple_integrate-2.3.0/tests/test_geometry_branch_conditions.py +109 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_geometry_casebook_properties.py +1 -1
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_heuristic_alarm_ownership.py +8 -14
- multiple_integrate-2.3.0/tests/test_higher_polytopes_and_capture.py +272 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_independent_improper_oracles.py +2 -6
- multiple_integrate-2.3.0/tests/test_indicator_quadratic_geometry.py +115 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_integrate.py +1 -3
- multiple_integrate-2.3.0/tests/test_integration_performance_contracts.py +436 -0
- multiple_integrate-2.3.0/tests/test_intrinsic_chart_bound_dependencies.py +65 -0
- multiple_integrate-2.3.0/tests/test_iterated_symmetry_and_radial_orientation.py +129 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_laurent_clips_and_tangencies.py +3 -5
- multiple_integrate-2.3.0/tests/test_linked_transformation_provenance.py +209 -0
- multiple_integrate-2.3.0/tests/test_log_polynomial_parameter_cases.py +119 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_measure_and_parameter_proof_scope.py +2 -1
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_metamorphic_regularization.py +3 -6
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_method_catalogue.py +5 -4
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_method_references.py +22 -0
- multiple_integrate-2.3.0/tests/test_nonlinear_coordinate_maps.py +221 -0
- multiple_integrate-2.3.0/tests/test_numerical_backend_methods.py +203 -0
- multiple_integrate-2.3.0/tests/test_numerical_coarea.py +323 -0
- multiple_integrate-2.3.0/tests/test_numerical_integration.py +240 -0
- multiple_integrate-2.3.0/tests/test_numerical_method_controls.py +492 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_parameter_cells.py +2 -3
- multiple_integrate-2.2.0/tests/test_parameter_geometry_extensions.py → multiple_integrate-2.3.0/tests/test_parameter_geometry_transitions.py +1 -2
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_parameter_specialization_safety.py +2 -1
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_performance_methods.py +2 -3
- multiple_integrate-2.2.0/tests/test_boundary_extensions.py → multiple_integrate-2.3.0/tests/test_polygon_boundary_moments.py +1 -2
- multiple_integrate-2.3.0/tests/test_polygon_certificate_conditions.py +157 -0
- multiple_integrate-2.3.0/tests/test_polygon_holes_and_multiple_ellipses.py +102 -0
- multiple_integrate-2.3.0/tests/test_polynomial_ellipsoid_surfaces.py +104 -0
- multiple_integrate-2.3.0/tests/test_polynomial_folds_and_certified_moments.py +302 -0
- multiple_integrate-2.3.0/tests/test_polytope_product_and_nonfinite.py +239 -0
- multiple_integrate-2.3.0/tests/test_positive_quartic_exponential.py +58 -0
- multiple_integrate-2.3.0/tests/test_prepared_kernel_performance.py +271 -0
- multiple_integrate-2.3.0/tests/test_prepared_polytopes.py +329 -0
- multiple_integrate-2.3.0/tests/test_principal_value_kernel_conditions.py +38 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_principal_value_multiple.py +2 -3
- multiple_integrate-2.3.0/tests/test_principal_value_partition_conditions.py +41 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_public_contracts.py +11 -26
- multiple_integrate-2.3.0/tests/test_public_namespaces.py +226 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_rational_infinity_finite_parts.py +3 -5
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_region_classification_boundaries.py +1 -3
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_region_contracts.py +2 -1
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_region_invariants_and_matrix.py +1 -3
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_region_order_sympy_convention.py +1 -3
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_regions_advanced_shapes.py +2 -1
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_regions_boxes_and_simplex.py +1 -1
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_regions_classification_priority.py +1 -1
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_regions_disk_and_ball.py +2 -1
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_regions_graph_and_simplex.py +2 -1
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_regions_graph_reversal.py +2 -1
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_regions_moments_box_simplex.py +2 -1
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_regions_moments_disk_ball.py +2 -1
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_regions_parse.py +1 -3
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_regions_symmetry.py +2 -4
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_regular_density_cutoff.py +3 -6
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_regularization.py +3 -4
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_requested_bounds.py +7 -7
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_result_and_geometry_domains.py +2 -2
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_robustness_evidence.py +2 -3
- multiple_integrate-2.3.0/tests/test_scalar_singularities_and_parameter_cases.py +100 -0
- multiple_integrate-2.2.0/tests/test_api_audit_fixes.py → multiple_integrate-2.3.0/tests/test_scoped_api_conditions.py +12 -5
- multiple_integrate-2.3.0/tests/test_screened_box_potentials.py +78 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_sectors_and_contact_charts.py +3 -8
- multiple_integrate-2.3.0/tests/test_semialgebraic_atlas_and_provenance.py +274 -0
- multiple_integrate-2.3.0/tests/test_semialgebraic_documentation.py +29 -0
- multiple_integrate-2.3.0/tests/test_semialgebraic_fast_proofs.py +96 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_series_evaluation.py +1 -0
- multiple_integrate-2.3.0/tests/test_shared_radial_cell_preparation.py +92 -0
- multiple_integrate-2.3.0/tests/test_sheared_folds_and_boundary_formulas.py +228 -0
- multiple_integrate-2.3.0/tests/test_simple_polygon_integration.py +72 -0
- multiple_integrate-2.3.0/tests/test_singular_curved_qmc_integration.py +281 -0
- multiple_integrate-2.3.0/tests/test_singularities_and_kernel_conditions.py +306 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_strategy_budget_boundaries.py +1 -1
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_strategy_safety.py +8 -2
- multiple_integrate-2.3.0/tests/test_stratified_maps_and_truncated_gaussians.py +328 -0
- multiple_integrate-2.3.0/tests/test_surface_atlases_and_gaussian_images.py +237 -0
- multiple_integrate-2.3.0/tests/test_surface_dispatch_and_parameters.py +116 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_symbolic_cell_geometry.py +1 -2
- multiple_integrate-2.3.0/tests/test_symbolic_numeric_preparation.py +311 -0
- multiple_integrate-2.3.0/tests/test_sympy_comparison_guide.py +59 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_tangency_finite_part_dispatch.py +6 -2
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_transformed_evidence_contracts.py +3 -9
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_translated_regions.py +2 -4
- multiple_integrate-2.3.0/tests/test_trigonometric_and_rational_disks.py +100 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_truncated_nonlinear_horns.py +1 -1
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_uniform_protocol.py +5 -5
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_validation_and_timeouts.py +2 -6
- multiple_integrate-2.3.0/tests/test_value_domain_and_replay_conditions.py +259 -0
- multiple_integrate-2.3.0/tests/test_verified_preparation_and_levin_reuse.py +194 -0
- multiple_integrate-2.3.0/tests/test_weighted_compact_fourier.py +43 -0
- multiple_integrate-2.3.0/tools/benchmark_dispatch.py +114 -0
- multiple_integrate-2.3.0/tools/benchmark_gaussian_evaluation.py +78 -0
- multiple_integrate-2.3.0/tools/benchmark_geometry_reuse.py +88 -0
- multiple_integrate-2.3.0/tools/benchmark_integration_performance.py +144 -0
- multiple_integrate-2.3.0/tools/benchmark_numerical_coarea.py +82 -0
- multiple_integrate-2.3.0/tools/benchmark_numerical_methods.py +115 -0
- multiple_integrate-2.3.0/tools/benchmark_prepared_kernels.py +242 -0
- multiple_integrate-2.3.0/tools/benchmark_semialg_proofs.py +83 -0
- multiple_integrate-2.3.0/tools/benchmark_shared_numerical_work.py +133 -0
- multiple_integrate-2.3.0/tools/benchmark_verified_preparation_and_levin.py +110 -0
- multiple_integrate-2.3.0/tools/check_compatibility.py +204 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tools/check_release.py +16 -9
- multiple_integrate-2.3.0/tools/generate_capability_reference.py +74 -0
- multiple_integrate-2.3.0/tools/generate_strategy_reference_map.py +84 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tools/installed_wheel_contract.py +29 -9
- multiple_integrate-2.3.0/tools/profile_intrinsic_queries.py +74 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tools/sync_geometry_examples.py +21 -10
- multiple_integrate-2.2.0/CHANGELOG.md +0 -126
- multiple_integrate-2.2.0/MANIFEST.in +0 -9
- multiple_integrate-2.2.0/PKG-INFO +0 -283
- multiple_integrate-2.2.0/README.md +0 -211
- multiple_integrate-2.2.0/docs/api.md +0 -81
- multiple_integrate-2.2.0/docs/architecture/semialg-integration.md +0 -65
- multiple_integrate-2.2.0/docs/boundary-reduction.md +0 -111
- multiple_integrate-2.2.0/docs/capabilities.md +0 -49
- multiple_integrate-2.2.0/docs/certification.md +0 -151
- multiple_integrate-2.2.0/docs/coarea.md +0 -198
- multiple_integrate-2.2.0/docs/installation.rst +0 -43
- multiple_integrate-2.2.0/docs/integration-extensions.md +0 -51
- multiple_integrate-2.2.0/docs/limitations.md +0 -49
- multiple_integrate-2.2.0/docs/method-example-coverage.json +0 -36
- multiple_integrate-2.2.0/docs/method-examples.md +0 -46
- multiple_integrate-2.2.0/docs/method-reference-coverage.json +0 -344
- multiple_integrate-2.2.0/docs/method-references.md +0 -102
- multiple_integrate-2.2.0/docs/nonlinear-moments-and-singularities.md +0 -113
- multiple_integrate-2.2.0/docs/nonseparable-improper.md +0 -57
- multiple_integrate-2.2.0/docs/regularization.md +0 -225
- multiple_integrate-2.2.0/docs/sectors-and-contact-charts.md +0 -81
- multiple_integrate-2.2.0/docs/selected-symbolic-families.md +0 -156
- multiple_integrate-2.2.0/docs/structured-results.md +0 -63
- multiple_integrate-2.2.0/docs/testing.md +0 -209
- multiple_integrate-2.2.0/docs/worked-failures.md +0 -114
- multiple_integrate-2.2.0/examples/method_catalogue.py +0 -356
- multiple_integrate-2.2.0/src/multiple_integrate/__init__.py +0 -70
- multiple_integrate-2.2.0/src/multiple_integrate/analytic_region_formulas.py +0 -127
- multiple_integrate-2.2.0/src/multiple_integrate/api/__init__.py +0 -22
- multiple_integrate-2.2.0/src/multiple_integrate/cauchy_principal_value.py +0 -121
- multiple_integrate-2.2.0/src/multiple_integrate/entire_box_series.py +0 -107
- multiple_integrate-2.2.0/src/multiple_integrate/ownership.py +0 -89
- multiple_integrate-2.2.0/src/multiple_integrate/quadratic_gaussian.py +0 -169
- multiple_integrate-2.2.0/src/multiple_integrate/regions.py +0 -25
- multiple_integrate-2.2.0/src/multiple_integrate/triangular_intersections.py +0 -138
- multiple_integrate-2.2.0/src/multiple_integrate.egg-info/PKG-INFO +0 -283
- multiple_integrate-2.2.0/src/multiple_integrate.egg-info/SOURCES.txt +0 -264
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/LICENSE +0 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/docs/Makefile +0 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/docs/_static/cusp-contact.svg +0 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/docs/_static/graph-contact.svg +0 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/docs/_static/polygon-cutoff.svg +0 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/docs/api/core.rst +0 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/docs/api/public.rst +0 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/docs/api/selected.rst +0 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/docs/api/series.rst +0 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/docs/concepts/measure-and-dimension.rst +0 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/docs/concepts/sampling.rst +0 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/docs/conf.py +0 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/setup.cfg +0 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/src/multiple_integrate/adapters/__init__.py +0 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/src/multiple_integrate/affine_cell_geometry.py +0 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/src/multiple_integrate/anisotropic.py +0 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/src/multiple_integrate/boundary_reduction.py +0 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/src/multiple_integrate/cell_graphs.py +0 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/src/multiple_integrate/clipped_quadratic.py +0 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/src/multiple_integrate/conditional.py +0 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/src/multiple_integrate/contact_charts.py +0 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/src/multiple_integrate/convergence_comparison.py +0 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/src/multiple_integrate/isolated_queries.py +0 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/src/multiple_integrate/layer_cake_strategies.py +0 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/src/multiple_integrate/nonseparable_improper.py +0 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/src/multiple_integrate/polygon_moments.py +0 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/src/multiple_integrate/principal_value.py +0 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/src/multiple_integrate/quadratic_cell_geometry.py +0 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/src/multiple_integrate/quadratic_sectors.py +0 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/src/multiple_integrate/radial_parametrization.py +0 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/src/multiple_integrate/rational_cutoff.py +0 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/src/multiple_integrate/region_strategies.py +0 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/src/multiple_integrate/series_evaluation.py +0 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/src/multiple_integrate/singular_maps.py +0 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/src/multiple_integrate/tangent_cutoff.py +0 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/src/multiple_integrate/transforms.py +0 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/src/multiple_integrate.egg-info/dependency_links.txt +0 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/src/multiple_integrate.egg-info/top_level.txt +0 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/__init__.py +0 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/helpers.py +0 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_assumption_pairs.py +0 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_assumptions_api.py +0 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_coarea_portfolio.py +0 -0
- /multiple_integrate-2.2.0/tests/test_coarea_extensions.py → /multiple_integrate-2.3.0/tests/test_coarea_rank_and_angular_moments.py +0 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_constants_and_caching.py +0 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_convergence_registry.py +0 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_convergence_semantic_corpus.py +0 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_coordinate_changes.py +0 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_coordinate_hygiene.py +0 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_divergence_parameter_domains.py +0 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_exact_graph_reversal.py +0 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_extended_convergence.py +0 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_geometry_properties.py +0 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_geometry_reference_corpus.py +0 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_installed_contract_source.py +0 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_intrinsic_semialgebraic.py +0 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_lower_dimensional_contracts.py +0 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_mathematical_oracles.py +0 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_nonseparable_improper.py +0 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_performance_guards.py +0 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_quadratic_real_geometry.py +0 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_quartic_moments.py +0 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_radial_parametrization.py +0 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_reference_examples.py +0 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_reference_examples_notebook.py +0 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_regions_interactions.py +0 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_regions_radial.py +0 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_scoped_convergence.py +0 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_selected_families.py +0 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_semialg_documentation_traceability.py +0 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_semialgebraic_domains.py +0 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_simplex_dirichlet_engine.py +0 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_singular_and_divergent_cases.py +0 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_singularity_splitting.py +0 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_structured_results.py +0 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_supported_families.py +0 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_symbolic_conditional_convergence.py +0 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_symmetry_and_inner_integrals.py +0 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tests/test_weighted_quadratic_radial.py +0 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tools/benchmark_coarea_certificates.py +0 -0
- {multiple_integrate-2.2.0 → multiple_integrate-2.3.0}/tools/run_notebook.py +0 -0
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
include README.md docs/capabilities.md LICENSE pyproject.toml
|
|
2
|
+
recursive-include src/multiple_integrate *.py
|
|
3
|
+
recursive-include tests *.py
|
|
4
|
+
recursive-include docs *
|
|
5
|
+
recursive-include notebooks *.ipynb
|
|
6
|
+
|
|
7
|
+
recursive-include tools *.py
|
|
8
|
+
|
|
9
|
+
recursive-include examples *.py
|
|
10
|
+
|
|
11
|
+
include benchmarks/common_integral_methods.py
|
|
12
|
+
|
|
13
|
+
include benchmarks/polygon_disk_screened_methods.py
|
|
14
|
+
|
|
15
|
+
include benchmarks/gaussian_certificate_reuse.py
|
|
16
|
+
include benchmarks/common_region_integrals.py
|
|
17
|
+
|
|
18
|
+
recursive-include benchmarks/results *.json
|
|
@@ -0,0 +1,348 @@
|
|
|
1
|
+
Metadata-Version: 2.4
|
|
2
|
+
Name: multiple-integrate
|
|
3
|
+
Version: 2.3.0
|
|
4
|
+
Summary: Symbolic and numerical definite integration with geometric reductions, coordinate transformations, and convergence analysis.
|
|
5
|
+
Author-email: Bhuvanesh Bhatt <bhuvaneshbhatt@gmail.com>
|
|
6
|
+
License-Expression: GPL-3.0-only
|
|
7
|
+
Project-URL: Homepage, https://github.com/BhuvaneshBhatt/multiple_integrate
|
|
8
|
+
Project-URL: Documentation, https://multiple-integrate.readthedocs.io/
|
|
9
|
+
Project-URL: Source, https://github.com/BhuvaneshBhatt/multiple_integrate
|
|
10
|
+
Project-URL: Issue Tracker, https://github.com/BhuvaneshBhatt/multiple_integrate/issues
|
|
11
|
+
Project-URL: Changelog, https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/CHANGELOG.md
|
|
12
|
+
Keywords: symbolic mathematics,symbolic computation,integration,definite integration,multiple integrals,multivariate integrals,calculus,sympy,computer algebra,layer-cake formula,co-area formula,numerical integration,quadrature
|
|
13
|
+
Classifier: Development Status :: 4 - Beta
|
|
14
|
+
Classifier: Intended Audience :: Science/Research
|
|
15
|
+
Classifier: Intended Audience :: Education
|
|
16
|
+
Classifier: Operating System :: OS Independent
|
|
17
|
+
Classifier: Programming Language :: Python :: 3
|
|
18
|
+
Classifier: Programming Language :: Python :: 3.11
|
|
19
|
+
Classifier: Programming Language :: Python :: 3.12
|
|
20
|
+
Classifier: Programming Language :: Python :: 3.13
|
|
21
|
+
Classifier: Programming Language :: Python :: 3.14
|
|
22
|
+
Classifier: Topic :: Scientific/Engineering :: Mathematics
|
|
23
|
+
Requires-Python: >=3.11
|
|
24
|
+
Description-Content-Type: text/markdown
|
|
25
|
+
License-File: LICENSE
|
|
26
|
+
Requires-Dist: sympy<2,>=1.14
|
|
27
|
+
Requires-Dist: mpmath<2,>=1.3
|
|
28
|
+
Requires-Dist: semialg>=1.5.1
|
|
29
|
+
Requires-Dist: funcprops>=0.5.0
|
|
30
|
+
Provides-Extra: numeric
|
|
31
|
+
Requires-Dist: numpy>=2.0; extra == "numeric"
|
|
32
|
+
Requires-Dist: scipy>=1.15; extra == "numeric"
|
|
33
|
+
Provides-Extra: numeric-all
|
|
34
|
+
Requires-Dist: numpy>=2.0; extra == "numeric-all"
|
|
35
|
+
Requires-Dist: scipy>=1.15; extra == "numeric-all"
|
|
36
|
+
Requires-Dist: vegas<7,>=6.2; extra == "numeric-all"
|
|
37
|
+
Requires-Dist: qmcpy<3,>=2.4; extra == "numeric-all"
|
|
38
|
+
Provides-Extra: gaussian-numeric
|
|
39
|
+
Requires-Dist: numpy>=2.0; extra == "gaussian-numeric"
|
|
40
|
+
Requires-Dist: scipy>=1.15; extra == "gaussian-numeric"
|
|
41
|
+
Provides-Extra: asymptotic
|
|
42
|
+
Requires-Dist: asymptotic>=0.2.1; extra == "asymptotic"
|
|
43
|
+
Provides-Extra: test
|
|
44
|
+
Requires-Dist: pytest>=8; extra == "test"
|
|
45
|
+
Requires-Dist: hypothesis>=6; extra == "test"
|
|
46
|
+
Provides-Extra: dev
|
|
47
|
+
Requires-Dist: pytest>=8; extra == "dev"
|
|
48
|
+
Requires-Dist: hypothesis>=6; extra == "dev"
|
|
49
|
+
Requires-Dist: ruff>=0.4; extra == "dev"
|
|
50
|
+
Requires-Dist: mypy>=1.10; extra == "dev"
|
|
51
|
+
Provides-Extra: release
|
|
52
|
+
Requires-Dist: build>=1.2; extra == "release"
|
|
53
|
+
Requires-Dist: twine>=6; extra == "release"
|
|
54
|
+
Provides-Extra: notebook-test
|
|
55
|
+
Requires-Dist: nbclient>=0.10; extra == "notebook-test"
|
|
56
|
+
Requires-Dist: nbformat>=5.10; extra == "notebook-test"
|
|
57
|
+
Requires-Dist: ipykernel>=6; extra == "notebook-test"
|
|
58
|
+
Provides-Extra: notebook
|
|
59
|
+
Requires-Dist: jupyter>=1.0; extra == "notebook"
|
|
60
|
+
Requires-Dist: notebook>=7.0; extra == "notebook"
|
|
61
|
+
Requires-Dist: ipykernel>=6.0; extra == "notebook"
|
|
62
|
+
Requires-Dist: matplotlib>=3.7; extra == "notebook"
|
|
63
|
+
Provides-Extra: docs
|
|
64
|
+
Requires-Dist: sphinx<9,>=8; extra == "docs"
|
|
65
|
+
Requires-Dist: sphinx-rtd-theme<4,>=3; extra == "docs"
|
|
66
|
+
Requires-Dist: myst-parser<5,>=4; extra == "docs"
|
|
67
|
+
Provides-Extra: all
|
|
68
|
+
Requires-Dist: asymptotic>=0.2.1; extra == "all"
|
|
69
|
+
Requires-Dist: funcprops>=0.5.0; extra == "all"
|
|
70
|
+
Requires-Dist: semialg>=1.5.1; extra == "all"
|
|
71
|
+
Requires-Dist: pytest>=8; extra == "all"
|
|
72
|
+
Requires-Dist: hypothesis>=6; extra == "all"
|
|
73
|
+
Requires-Dist: ruff>=0.4; extra == "all"
|
|
74
|
+
Requires-Dist: mypy>=1.10; extra == "all"
|
|
75
|
+
Requires-Dist: jupyter>=1.0; extra == "all"
|
|
76
|
+
Requires-Dist: notebook>=7.0; extra == "all"
|
|
77
|
+
Requires-Dist: ipykernel>=6.0; extra == "all"
|
|
78
|
+
Requires-Dist: matplotlib>=3.7; extra == "all"
|
|
79
|
+
Requires-Dist: sphinx<9,>=8; extra == "all"
|
|
80
|
+
Requires-Dist: sphinx-rtd-theme<4,>=3; extra == "all"
|
|
81
|
+
Requires-Dist: myst-parser<5,>=4; extra == "all"
|
|
82
|
+
Dynamic: license-file
|
|
83
|
+
|
|
84
|
+
# MultipleIntegrate
|
|
85
|
+
|
|
86
|
+
MultipleIntegrate evaluates definite multiple/multivariate integrals by combining SymPy-based evaluation with geometric reductions, moment rules, coordinate changes and some selected regularization prescriptions. It is useful when the structure of a density or domain supplies more information than a generic antiderivative search. The package supports both symbolic and numerical results.
|
|
87
|
+
|
|
88
|
+
## Why use it?
|
|
89
|
+
|
|
90
|
+
A multiple integral is often easier after recognizing a region, separating a radial coordinate, integrating polynomial coordinates exactly or reducing a Gaussian potential to one dimension. MultipleIntegrate performs these reductions before falling back to general integration. Prepared regions and numerical plans reuse validated geometry and compilation across related requests.
|
|
91
|
+
|
|
92
|
+
The [comparison with SymPy](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/why-multipleintegrate.md) gives independently checked examples of branch cuts, singularities and coupled domains. It distinguishes wrong answers, unevaluated calls, convergent series and time limits, and includes a comparison with SymPy's `polytope_integrate`.
|
|
93
|
+
|
|
94
|
+
## Installation
|
|
95
|
+
|
|
96
|
+
```sh
|
|
97
|
+
pip install multiple-integrate
|
|
98
|
+
pip install 'multiple-integrate[numeric]'
|
|
99
|
+
```
|
|
100
|
+
|
|
101
|
+
Python 3.11 or newer is required. SymPy supplies expressions and fallback integration; `semialg` supplies region geometry and decomposition; `funcprops` supplies function properties; mpmath supplies arbitrary-precision evaluation. The `numeric` extra installs NumPy and SciPy. The `numeric-all` extra also installs VEGAS+ and randomised lattice support. Native Cuba methods require a separately installed Cuba library. See [installation](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/installation.rst) and [numerical backends](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/numerical-backends.md).
|
|
102
|
+
|
|
103
|
+
## Symbolic integration
|
|
104
|
+
|
|
105
|
+
```python
|
|
106
|
+
import sympy as sp
|
|
107
|
+
from multiple_integrate import integrate, integrate_result
|
|
108
|
+
|
|
109
|
+
x, y = sp.symbols("x y", real=True)
|
|
110
|
+
assert integrate(x**2 * y, (x, 0, 1), (y, 0, 2)) == sp.Rational(2, 3)
|
|
111
|
+
|
|
112
|
+
triangle = sp.And(x >= 0, y >= 0, x + y <= 1)
|
|
113
|
+
assert integrate(sp.exp(x + y), region=triangle, variables=(x, y)) == 1
|
|
114
|
+
|
|
115
|
+
result = integrate_result(sp.sin(1/x)/x, (x, 0, 1))
|
|
116
|
+
assert result.value == sp.pi/2 - sp.Si(1)
|
|
117
|
+
assert result.ordinary_convergent is True
|
|
118
|
+
assert result.absolute_convergent is False
|
|
119
|
+
```
|
|
120
|
+
|
|
121
|
+
Integration bounds follow SymPy's innermost-to-outermost order, not the outer-to-inner ordering used, for example, by Mathematica. Reversing explicit bounds changes orientation. A `region=` describes a geometric set with unsigned measure, so an empty fiber contributes zero. Use explicit `variables=` with region objects, and use `measure_dimension` to distinguish ambient volume from curve or surface measure. [Ranges and regions](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/concepts/ranges-and-regions.rst) explains these conventions.
|
|
122
|
+
|
|
123
|
+
Canonical region objects and parameter families use the same coordinate conventions:
|
|
124
|
+
|
|
125
|
+
```python
|
|
126
|
+
import semialg
|
|
127
|
+
from multiple_integrate.parameter_cells import integrate_cells
|
|
128
|
+
|
|
129
|
+
a = sp.Symbol("a", real=True)
|
|
130
|
+
assert integrate(1, region=semialg.Box(((0, 1), (0, 2))), variables=(x, y)) == 2
|
|
131
|
+
family = integrate_cells(
|
|
132
|
+
1, region=x**2 <= a, variables=(x,), bounds={x: (-1, 1)}, parameters=(a,),
|
|
133
|
+
)
|
|
134
|
+
assert family.complete and family.value.subs(a, sp.Rational(1, 4)) == 1
|
|
135
|
+
```
|
|
136
|
+
|
|
137
|
+
`integrate` returns the mathematical value. `integrate_result` adds status, parameter cases, convergence evidence, transformations and unresolved obligations. Conditional results can contain SymPy `Piecewise` expressions; [structured results](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/structured-results.md) explains their coverage and meaning.
|
|
138
|
+
|
|
139
|
+
## Numerical integration
|
|
140
|
+
|
|
141
|
+
```python
|
|
142
|
+
from multiple_integrate import nintegrate, nintegrate_result
|
|
143
|
+
|
|
144
|
+
value = nintegrate(sp.exp(x*y), (x, 0, 1), (y, 0, 1))
|
|
145
|
+
result = nintegrate_result(
|
|
146
|
+
sp.exp(x*y), (x, 0, 1), (y, 0, 1),
|
|
147
|
+
absolute_tolerance=1e-9, relative_tolerance=1e-9,
|
|
148
|
+
)
|
|
149
|
+
assert result.success
|
|
150
|
+
assert abs(float(result.value) - 1.3179021514544039) < 1e-9
|
|
151
|
+
```
|
|
152
|
+
|
|
153
|
+
Automatic dispatch uses expression features, dimension, region charts, requested precision and singularities. [Certified coarea preprocessing](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/numerical-coarea.md) can eliminate radial or affine-profile fiber coordinates before quadrature. It first considers exact formulas or lower-dimensional reductions, then chooses a numerical engine with bounded fallback. Explicit method selection and counted pilot selection are available. [Numerical integration](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/numerical-integration.md) describes controls, reusable plans and batches.
|
|
154
|
+
|
|
155
|
+
`nintegrate` returns a numerical value and raises when the request cannot meet its contract. `nintegrate_result` reports the value, estimated error, error kind, tolerance status, evaluation count, precision, method and stopping reason. Domain and integrability evidence are separate from numerical uncertainty. A small estimated error does not prove convergence or provide a rigorous enclosure.
|
|
156
|
+
|
|
157
|
+
## Capabilities and requirements
|
|
158
|
+
|
|
159
|
+
| Integral or region | Support | Main requirements and limits |
|
|
160
|
+
|---|---|---|
|
|
161
|
+
| Boxes and nested bounds | Symbolic reductions and numerical quadrature | Bound order, orientation and singularities must be resolved. |
|
|
162
|
+
| Polynomial polygons and polytopes | Exact moments, prepared geometry and batches, including higher dimensions | Supported convex rational geometry; complexity grows with dimension and degree. |
|
|
163
|
+
| Balls, disks and ellipsoids | Polynomial moments, radial reductions, selected exponential and trig kernels | Each formula checks its shape, parameter and convergence hypotheses. |
|
|
164
|
+
| Gaussian densities and potentials | Rectangle probabilities, polygon and ellipse reductions, screened and softened attraction kernels | Selected covariance, clipping and kernel families; some answers use named probability functions or one-dimensional integrals. |
|
|
165
|
+
| Piecewise densities and Boolean regions | First-match branches, supported disjoint partitions and parameter cases | Incomplete partitions and unproved branch domains retain unresolved results. |
|
|
166
|
+
| Curves, surfaces and flux | Certified charts, graph surfaces, selected implicit surfaces and ellipsoid densities | Regularity, coverage, Jacobians and orientation require evidence. |
|
|
167
|
+
| Singular and improper integrals | Supported endpoint transformations, tails and geometric reductions | Arbitrary intersecting singular sets are not generally resolved. |
|
|
168
|
+
| Principal values, finite parts and distributions | Explicit prescriptions and selected exact reductions | Prescriptions have distinct semantics, ordinary quadrature cannot supply them implicitly. |
|
|
169
|
+
| Low-dimensional numerical integration | Adaptive cubature, Genz–Malik, Gauss–Kronrod, nested Gaussian and tanh-sinh rules | Backend dimension and precision limits apply. |
|
|
170
|
+
| Higher-dimensional numerical integration | Scrambled Sobol, randomized lattices, VEGAS+, sparse grids and native Cuba methods | Statistical or heuristic uncertainty depends on the method. |
|
|
171
|
+
| Oscillatory numerical integration | Levin collocation, periodic rules and supported multidimensional phase reductions | Coupled Levin blocks support two or three dimensions; arbitrary stationary manifolds are difficult. |
|
|
172
|
+
| Rigourous numerical enclosures | Exact rational and outward-rounded interval bounds on supported charts | Supported function ranges, pole exclusion and resource limits must be proved. |
|
|
173
|
+
|
|
174
|
+
See the [symbolic capability guide](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/capabilities.md), [numerical method matrix](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/implemented-capabilities.md) and [limitations](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/limitations.md) for precise boundaries. Rigorous charts use package-owned rational arithmetic and outward dyadic rounding.
|
|
175
|
+
|
|
176
|
+
## Results, assumptions and prescriptions
|
|
177
|
+
|
|
178
|
+
For symbolic integration, use `assumptions=` or symbol-attached assumptions to state the prerequisites of the requested parameter cell. Temporary SymPy `assuming(...)` facts are excluded from package proof queries and refinement, keeping cached evidence inside its declared scope.
|
|
179
|
+
|
|
180
|
+
Convergence evidence can be summarised across parameter cases only when those cases provably cover the requested domain. Missing equality fibers, conflicting facts and unresolved cells prevent a global conclusion. For example, the whole-plane integral of `exp(-x**2-y**2+x/a)` has value `pi*exp(1/(4*a**2))` for real `a!=0`. The structured result retains `Ne(a, 0)` and the unresolved `a=0` fiber. Nonzero conditions cannot replace positivity conditions required for Gaussian decay. [Structured results](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/structured-results.md) explains these distinctions.
|
|
181
|
+
|
|
182
|
+
Principal values and Hadamard finite parts require an explicit prescription. Their finite values do not establish ordinary convergence. The [regularization guide](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/regularization.md) explains cutoff semantics.
|
|
183
|
+
|
|
184
|
+
`Boole(condition)` constructs the SymPy indicator `Piecewise((1, condition), (0, True))`; both forms use supported geometry and first-match branch rules.
|
|
185
|
+
|
|
186
|
+
## Limits and evidence
|
|
187
|
+
|
|
188
|
+
General symbolic multiple integration has no universal algorithm. Integrals involving arbitrary implicit surfaces, unresolved parameter geometry, nonseparable singularities and general oscillatory improper tails can remain unsupported or unevaluated. Nested rules and polynomial geometry can become expensive as dimension grows, while sampling methods can miss narrow features.
|
|
189
|
+
|
|
190
|
+
Certificates reconstruct their mathematical claims during replay. Exact results, conditional formulas, ordinary convergence, prescribed regularization, numerical consistency and rigourous enclosure are separate claims. [Certification](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/certification.md) and [domain requirements](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/domain-requirements.md) explain the checks.
|
|
191
|
+
|
|
192
|
+
## Guides and examples
|
|
193
|
+
|
|
194
|
+
The [executable method example catalog](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/method-examples.md) has a representative example for every documented method.
|
|
195
|
+
|
|
196
|
+
The [method reference guide](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/method-references.md) maps mathematical methods to sources and implementation modules.
|
|
197
|
+
|
|
198
|
+
- [Supported regions and measures](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/supported-regions.md)
|
|
199
|
+
- [Bounded series evaluation](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/series-evaluation.md)
|
|
200
|
+
- [Selected symbolic families](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/selected-symbolic-families.md)
|
|
201
|
+
- [Exact fast methods and budgets](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/performance-methods.md)
|
|
202
|
+
- [Parameterized integration](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/parameterized-integration.md)
|
|
203
|
+
- [Result semantics and certification](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/certification.md)
|
|
204
|
+
- [Regularization](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/regularization.md)
|
|
205
|
+
- [Polygon and polytope boundary reduction](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/boundary-reduction.md)
|
|
206
|
+
- [Nonseparable improper integration](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/nonseparable-improper.md)
|
|
207
|
+
- [Laurent moments, clips and tangencies](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/laurent-clips-and-tangencies.md)
|
|
208
|
+
- [Nonlinear moments and singularities](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/nonlinear-moments-and-singularities.md)
|
|
209
|
+
- [Sectors and contact charts](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/sectors-and-contact-charts.md)
|
|
210
|
+
- [Limitations and known issues](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/limitations.md)
|
|
211
|
+
|
|
212
|
+
Executable examples live in [examples](https://github.com/BhuvaneshBhatt/multiple_integrate/tree/main/examples), and the [demo notebook](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/notebooks/multiple_integration.ipynb) connects the mathematical formulas to calls.
|
|
213
|
+
|
|
214
|
+
The following guides cover public interfaces, certified transformations and numerical evaluation:
|
|
215
|
+
|
|
216
|
+
- [Quick start](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/quickstart.rst)
|
|
217
|
+
- [API reference](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/api.md)
|
|
218
|
+
- [Polynomial polytopes and reusable moments](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/polynomial-polytopes.md)
|
|
219
|
+
- [Symbolic coarea reductions](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/coarea.md)
|
|
220
|
+
- [Numerical integration](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/numerical-integration.md)
|
|
221
|
+
- [Certified numerical coarea](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/numerical-coarea.md)
|
|
222
|
+
- [Numerical backends and uncertainty](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/numerical-backends.md)
|
|
223
|
+
- [Numerical method controls](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/numerical-method-controls.md)
|
|
224
|
+
- [Numerical precision and dimension limits](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/implemented-capabilities.md)
|
|
225
|
+
- [Prepared symbolic and numerical kernels](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/prepared-kernel-performance.md)
|
|
226
|
+
- [Design, performance contracts and measurements](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/design-and-performance.md)
|
|
227
|
+
- [Domain requirements and counterexamples](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/domain-requirements.md)
|
|
228
|
+
- [Worked values and convergence prescriptions](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/worked-integral-identities.md)
|
|
229
|
+
- [Stratified maps and truncated Gaussians](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/stratified-maps-and-truncated-gaussians.md)
|
|
230
|
+
- [Polynomial folds and certified moments](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/polynomial-folds-and-certified-moments.md)
|
|
231
|
+
- [Sheared folds and boundary formulas](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/sheared-folds-and-boundary-formulas.md)
|
|
232
|
+
- [Fold products and simplex enclosures](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/fold-products-and-simplex-enclosures.md)
|
|
233
|
+
|
|
234
|
+
## Worked examples
|
|
235
|
+
|
|
236
|
+
### Layer-cake identity
|
|
237
|
+
|
|
238
|
+
For a nonnegative density `f`, the layer-cake identity is
|
|
239
|
+
`integral(f) = integral_0^infinity volume({f > t}) dt`, with infinite values
|
|
240
|
+
allowed by Tonelli's theorem. For `f=exp(-g)` and `g>=0`, an equivalent form is `integral(exp(-g)) = integral_0^infinity exp(-t)*volume({g < t}) dt`.
|
|
241
|
+
For the positive-quadrant superellipse `g=x**4+y**4`, the sublevel area is
|
|
242
|
+
`Gamma(1/4)**2*sqrt(t)/(8*sqrt(pi))`:
|
|
243
|
+
|
|
244
|
+
<!-- layer-cake-start -->
|
|
245
|
+
```python
|
|
246
|
+
import sympy as sp
|
|
247
|
+
|
|
248
|
+
from multiple_integrate import integrate_result
|
|
249
|
+
|
|
250
|
+
x, y = sp.symbols("x y", real=True)
|
|
251
|
+
t = sp.Symbol("t", positive=True)
|
|
252
|
+
area = sp.gamma(sp.Rational(1, 4)) ** 2 * sp.sqrt(t) / (8 * sp.sqrt(sp.pi))
|
|
253
|
+
layer_value = sp.integrate(sp.exp(-t) * area, (t, 0, sp.oo))
|
|
254
|
+
result = integrate_result(sp.exp(-(x**4 + y**4)), (x, 0, sp.oo), (y, 0, sp.oo))
|
|
255
|
+
assert sp.simplify(result.value - layer_value) == 0
|
|
256
|
+
assert sp.simplify(layer_value - sp.gamma(sp.Rational(1, 4)) ** 2 / 16) == 0
|
|
257
|
+
```
|
|
258
|
+
<!-- layer-cake-end -->
|
|
259
|
+
|
|
260
|
+
This demonstrates the identity and its value; the automatic planner may choose
|
|
261
|
+
another proved route for the same density. See [selected symbolic families](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/selected-symbolic-families.md) for endpoint factors and shifted or truncated gamma moments, and [worked integral identities](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/worked-integral-identities.md) for additional derivations.
|
|
262
|
+
|
|
263
|
+
<!-- geometry-casebook-start -->
|
|
264
|
+
## Geometry casebook
|
|
265
|
+
|
|
266
|
+
The examples share these imports:
|
|
267
|
+
|
|
268
|
+
```python
|
|
269
|
+
from dataclasses import replace
|
|
270
|
+
import mpmath as mp
|
|
271
|
+
import semialg
|
|
272
|
+
import sympy as sp
|
|
273
|
+
from multiple_integrate import IntegrationOutcome, integrate_result, regularized_result
|
|
274
|
+
from multiple_integrate.parameter_cells import ParameterCell, integrate_cells
|
|
275
|
+
from multiple_integrate.regularization import HadamardFinitePart, verify_regularization_result
|
|
276
|
+
```
|
|
277
|
+
|
|
278
|
+
### Parameter cells and graph contact
|
|
279
|
+
|
|
280
|
+
```python
|
|
281
|
+
x, y, a, b = sp.symbols("x y a b", real=True)
|
|
282
|
+
result = integrate_cells(
|
|
283
|
+
1,
|
|
284
|
+
region=sp.And(x >= 0, x <= a, y >= 0, y <= b - x**2),
|
|
285
|
+
variables=(x, y),
|
|
286
|
+
parameters=(a, b),
|
|
287
|
+
assumptions=sp.And(a > 0, b >= a**2),
|
|
288
|
+
cells=(ParameterCell(b > a**2), ParameterCell(sp.Eq(b, a**2), {b: a**2})),
|
|
289
|
+
)
|
|
290
|
+
assert sp.simplify(result.cases[0].value - (a * b - a**3 / 3)) == 0
|
|
291
|
+
assert sp.simplify(result.cases[1].value - 2 * a**3 / 3) == 0
|
|
292
|
+
```
|
|
293
|
+
|
|
294
|
+
### Cusp contact and divergence
|
|
295
|
+
|
|
296
|
+
```python
|
|
297
|
+
x, y = sp.symbols("x y", real=True)
|
|
298
|
+
base = x**3 - y**2
|
|
299
|
+
horn = sp.And(x > 0, x < 1, y**2 <= x**3)
|
|
300
|
+
result = integrate_result(base ** -sp.Rational(1, 2), region=horn, variables=(x, y))
|
|
301
|
+
divergent = integrate_result(x**2 / base, region=horn, variables=(x, y))
|
|
302
|
+
assert sp.simplify(sp.expand_func(result.value) - sp.pi) == 0
|
|
303
|
+
assert result.absolute_convergent is True
|
|
304
|
+
assert divergent.outcome is IntegrationOutcome.DIVERGENT
|
|
305
|
+
```
|
|
306
|
+
|
|
307
|
+
### Exact finite radial series
|
|
308
|
+
|
|
309
|
+
```python
|
|
310
|
+
x, y, z = sp.symbols("x y z", real=True)
|
|
311
|
+
rho = x**2 + y**2 + z**2
|
|
312
|
+
result = integrate_result(
|
|
313
|
+
sp.exp(-rho) / (2 + rho), region=semialg.Ball((0, 0, 0), 1), variables=(x, y, z)
|
|
314
|
+
)
|
|
315
|
+
assert result.value.has(sp.Sum) and result.absolute_convergent is True
|
|
316
|
+
with mp.workdps(35):
|
|
317
|
+
reference = 4 * mp.pi * mp.quad(lambda r: r**2 * mp.exp(-r * r) / (2 + r * r), [0, 1])
|
|
318
|
+
assert abs(mp.mpf(str(result.value.evalf(30))) - reference) < mp.mpf("1e-25")
|
|
319
|
+
```
|
|
320
|
+
|
|
321
|
+
### Clipped polygon finite part
|
|
322
|
+
|
|
323
|
+
```python
|
|
324
|
+
x, y = sp.symbols("x y", real=True)
|
|
325
|
+
polygon = sp.And(x >= 0, y >= 0, x <= sp.Rational(1, 2), x + y <= 1)
|
|
326
|
+
result = regularized_result(
|
|
327
|
+
1 / (x * y),
|
|
328
|
+
region=polygon,
|
|
329
|
+
variables=(x, y),
|
|
330
|
+
regularization=HadamardFinitePart(hypersurface=x * y),
|
|
331
|
+
)
|
|
332
|
+
assert sp.simplify(result.value + sp.pi**2 / 12 - sp.log(2) ** 2) == 0
|
|
333
|
+
assert verify_regularization_result(result).valid
|
|
334
|
+
assert not verify_regularization_result(replace(result, value=result.value + 1)).valid
|
|
335
|
+
```
|
|
336
|
+
|
|
337
|
+
For an ordinary result inspect `result.outcome`, `result.complete`, `result.coverage`, and `result.convergence_evidence`; for a family inspect each child in `result.diagnostics['cell_results']`. A finite-part answer describes its specified cutoff and does not prove ordinary convergence.
|
|
338
|
+
<!-- geometry-casebook-end -->
|
|
339
|
+
|
|
340
|
+
## Contributing
|
|
341
|
+
|
|
342
|
+
Contributions – whether they are bug reports, suggestions, or code for bugfixes or improvements – are welcome!
|
|
343
|
+
|
|
344
|
+
For development setup, architecture and extension guidance, see [Contributing](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/contributing.md). The [testing guide](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/testing.md) describes the mathematical, property, slow and packaging checks.
|
|
345
|
+
|
|
346
|
+
See the [release notes](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/CHANGELOG.md) for changes and the [limitations and known issues](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/limitations.md) for unresolved cases.
|
|
347
|
+
|
|
348
|
+
MultipleIntegrate is licensed under the GNU General Public License version 3 only (GPL-3.0-only). See [LICENSE](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/LICENSE).
|
|
@@ -0,0 +1,265 @@
|
|
|
1
|
+
# MultipleIntegrate
|
|
2
|
+
|
|
3
|
+
MultipleIntegrate evaluates definite multiple/multivariate integrals by combining SymPy-based evaluation with geometric reductions, moment rules, coordinate changes and some selected regularization prescriptions. It is useful when the structure of a density or domain supplies more information than a generic antiderivative search. The package supports both symbolic and numerical results.
|
|
4
|
+
|
|
5
|
+
## Why use it?
|
|
6
|
+
|
|
7
|
+
A multiple integral is often easier after recognizing a region, separating a radial coordinate, integrating polynomial coordinates exactly or reducing a Gaussian potential to one dimension. MultipleIntegrate performs these reductions before falling back to general integration. Prepared regions and numerical plans reuse validated geometry and compilation across related requests.
|
|
8
|
+
|
|
9
|
+
The [comparison with SymPy](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/why-multipleintegrate.md) gives independently checked examples of branch cuts, singularities and coupled domains. It distinguishes wrong answers, unevaluated calls, convergent series and time limits, and includes a comparison with SymPy's `polytope_integrate`.
|
|
10
|
+
|
|
11
|
+
## Installation
|
|
12
|
+
|
|
13
|
+
```sh
|
|
14
|
+
pip install multiple-integrate
|
|
15
|
+
pip install 'multiple-integrate[numeric]'
|
|
16
|
+
```
|
|
17
|
+
|
|
18
|
+
Python 3.11 or newer is required. SymPy supplies expressions and fallback integration; `semialg` supplies region geometry and decomposition; `funcprops` supplies function properties; mpmath supplies arbitrary-precision evaluation. The `numeric` extra installs NumPy and SciPy. The `numeric-all` extra also installs VEGAS+ and randomised lattice support. Native Cuba methods require a separately installed Cuba library. See [installation](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/installation.rst) and [numerical backends](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/numerical-backends.md).
|
|
19
|
+
|
|
20
|
+
## Symbolic integration
|
|
21
|
+
|
|
22
|
+
```python
|
|
23
|
+
import sympy as sp
|
|
24
|
+
from multiple_integrate import integrate, integrate_result
|
|
25
|
+
|
|
26
|
+
x, y = sp.symbols("x y", real=True)
|
|
27
|
+
assert integrate(x**2 * y, (x, 0, 1), (y, 0, 2)) == sp.Rational(2, 3)
|
|
28
|
+
|
|
29
|
+
triangle = sp.And(x >= 0, y >= 0, x + y <= 1)
|
|
30
|
+
assert integrate(sp.exp(x + y), region=triangle, variables=(x, y)) == 1
|
|
31
|
+
|
|
32
|
+
result = integrate_result(sp.sin(1/x)/x, (x, 0, 1))
|
|
33
|
+
assert result.value == sp.pi/2 - sp.Si(1)
|
|
34
|
+
assert result.ordinary_convergent is True
|
|
35
|
+
assert result.absolute_convergent is False
|
|
36
|
+
```
|
|
37
|
+
|
|
38
|
+
Integration bounds follow SymPy's innermost-to-outermost order, not the outer-to-inner ordering used, for example, by Mathematica. Reversing explicit bounds changes orientation. A `region=` describes a geometric set with unsigned measure, so an empty fiber contributes zero. Use explicit `variables=` with region objects, and use `measure_dimension` to distinguish ambient volume from curve or surface measure. [Ranges and regions](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/concepts/ranges-and-regions.rst) explains these conventions.
|
|
39
|
+
|
|
40
|
+
Canonical region objects and parameter families use the same coordinate conventions:
|
|
41
|
+
|
|
42
|
+
```python
|
|
43
|
+
import semialg
|
|
44
|
+
from multiple_integrate.parameter_cells import integrate_cells
|
|
45
|
+
|
|
46
|
+
a = sp.Symbol("a", real=True)
|
|
47
|
+
assert integrate(1, region=semialg.Box(((0, 1), (0, 2))), variables=(x, y)) == 2
|
|
48
|
+
family = integrate_cells(
|
|
49
|
+
1, region=x**2 <= a, variables=(x,), bounds={x: (-1, 1)}, parameters=(a,),
|
|
50
|
+
)
|
|
51
|
+
assert family.complete and family.value.subs(a, sp.Rational(1, 4)) == 1
|
|
52
|
+
```
|
|
53
|
+
|
|
54
|
+
`integrate` returns the mathematical value. `integrate_result` adds status, parameter cases, convergence evidence, transformations and unresolved obligations. Conditional results can contain SymPy `Piecewise` expressions; [structured results](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/structured-results.md) explains their coverage and meaning.
|
|
55
|
+
|
|
56
|
+
## Numerical integration
|
|
57
|
+
|
|
58
|
+
```python
|
|
59
|
+
from multiple_integrate import nintegrate, nintegrate_result
|
|
60
|
+
|
|
61
|
+
value = nintegrate(sp.exp(x*y), (x, 0, 1), (y, 0, 1))
|
|
62
|
+
result = nintegrate_result(
|
|
63
|
+
sp.exp(x*y), (x, 0, 1), (y, 0, 1),
|
|
64
|
+
absolute_tolerance=1e-9, relative_tolerance=1e-9,
|
|
65
|
+
)
|
|
66
|
+
assert result.success
|
|
67
|
+
assert abs(float(result.value) - 1.3179021514544039) < 1e-9
|
|
68
|
+
```
|
|
69
|
+
|
|
70
|
+
Automatic dispatch uses expression features, dimension, region charts, requested precision and singularities. [Certified coarea preprocessing](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/numerical-coarea.md) can eliminate radial or affine-profile fiber coordinates before quadrature. It first considers exact formulas or lower-dimensional reductions, then chooses a numerical engine with bounded fallback. Explicit method selection and counted pilot selection are available. [Numerical integration](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/numerical-integration.md) describes controls, reusable plans and batches.
|
|
71
|
+
|
|
72
|
+
`nintegrate` returns a numerical value and raises when the request cannot meet its contract. `nintegrate_result` reports the value, estimated error, error kind, tolerance status, evaluation count, precision, method and stopping reason. Domain and integrability evidence are separate from numerical uncertainty. A small estimated error does not prove convergence or provide a rigorous enclosure.
|
|
73
|
+
|
|
74
|
+
## Capabilities and requirements
|
|
75
|
+
|
|
76
|
+
| Integral or region | Support | Main requirements and limits |
|
|
77
|
+
|---|---|---|
|
|
78
|
+
| Boxes and nested bounds | Symbolic reductions and numerical quadrature | Bound order, orientation and singularities must be resolved. |
|
|
79
|
+
| Polynomial polygons and polytopes | Exact moments, prepared geometry and batches, including higher dimensions | Supported convex rational geometry; complexity grows with dimension and degree. |
|
|
80
|
+
| Balls, disks and ellipsoids | Polynomial moments, radial reductions, selected exponential and trig kernels | Each formula checks its shape, parameter and convergence hypotheses. |
|
|
81
|
+
| Gaussian densities and potentials | Rectangle probabilities, polygon and ellipse reductions, screened and softened attraction kernels | Selected covariance, clipping and kernel families; some answers use named probability functions or one-dimensional integrals. |
|
|
82
|
+
| Piecewise densities and Boolean regions | First-match branches, supported disjoint partitions and parameter cases | Incomplete partitions and unproved branch domains retain unresolved results. |
|
|
83
|
+
| Curves, surfaces and flux | Certified charts, graph surfaces, selected implicit surfaces and ellipsoid densities | Regularity, coverage, Jacobians and orientation require evidence. |
|
|
84
|
+
| Singular and improper integrals | Supported endpoint transformations, tails and geometric reductions | Arbitrary intersecting singular sets are not generally resolved. |
|
|
85
|
+
| Principal values, finite parts and distributions | Explicit prescriptions and selected exact reductions | Prescriptions have distinct semantics, ordinary quadrature cannot supply them implicitly. |
|
|
86
|
+
| Low-dimensional numerical integration | Adaptive cubature, Genz–Malik, Gauss–Kronrod, nested Gaussian and tanh-sinh rules | Backend dimension and precision limits apply. |
|
|
87
|
+
| Higher-dimensional numerical integration | Scrambled Sobol, randomized lattices, VEGAS+, sparse grids and native Cuba methods | Statistical or heuristic uncertainty depends on the method. |
|
|
88
|
+
| Oscillatory numerical integration | Levin collocation, periodic rules and supported multidimensional phase reductions | Coupled Levin blocks support two or three dimensions; arbitrary stationary manifolds are difficult. |
|
|
89
|
+
| Rigourous numerical enclosures | Exact rational and outward-rounded interval bounds on supported charts | Supported function ranges, pole exclusion and resource limits must be proved. |
|
|
90
|
+
|
|
91
|
+
See the [symbolic capability guide](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/capabilities.md), [numerical method matrix](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/implemented-capabilities.md) and [limitations](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/limitations.md) for precise boundaries. Rigorous charts use package-owned rational arithmetic and outward dyadic rounding.
|
|
92
|
+
|
|
93
|
+
## Results, assumptions and prescriptions
|
|
94
|
+
|
|
95
|
+
For symbolic integration, use `assumptions=` or symbol-attached assumptions to state the prerequisites of the requested parameter cell. Temporary SymPy `assuming(...)` facts are excluded from package proof queries and refinement, keeping cached evidence inside its declared scope.
|
|
96
|
+
|
|
97
|
+
Convergence evidence can be summarised across parameter cases only when those cases provably cover the requested domain. Missing equality fibers, conflicting facts and unresolved cells prevent a global conclusion. For example, the whole-plane integral of `exp(-x**2-y**2+x/a)` has value `pi*exp(1/(4*a**2))` for real `a!=0`. The structured result retains `Ne(a, 0)` and the unresolved `a=0` fiber. Nonzero conditions cannot replace positivity conditions required for Gaussian decay. [Structured results](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/structured-results.md) explains these distinctions.
|
|
98
|
+
|
|
99
|
+
Principal values and Hadamard finite parts require an explicit prescription. Their finite values do not establish ordinary convergence. The [regularization guide](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/regularization.md) explains cutoff semantics.
|
|
100
|
+
|
|
101
|
+
`Boole(condition)` constructs the SymPy indicator `Piecewise((1, condition), (0, True))`; both forms use supported geometry and first-match branch rules.
|
|
102
|
+
|
|
103
|
+
## Limits and evidence
|
|
104
|
+
|
|
105
|
+
General symbolic multiple integration has no universal algorithm. Integrals involving arbitrary implicit surfaces, unresolved parameter geometry, nonseparable singularities and general oscillatory improper tails can remain unsupported or unevaluated. Nested rules and polynomial geometry can become expensive as dimension grows, while sampling methods can miss narrow features.
|
|
106
|
+
|
|
107
|
+
Certificates reconstruct their mathematical claims during replay. Exact results, conditional formulas, ordinary convergence, prescribed regularization, numerical consistency and rigourous enclosure are separate claims. [Certification](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/certification.md) and [domain requirements](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/domain-requirements.md) explain the checks.
|
|
108
|
+
|
|
109
|
+
## Guides and examples
|
|
110
|
+
|
|
111
|
+
The [executable method example catalog](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/method-examples.md) has a representative example for every documented method.
|
|
112
|
+
|
|
113
|
+
The [method reference guide](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/method-references.md) maps mathematical methods to sources and implementation modules.
|
|
114
|
+
|
|
115
|
+
- [Supported regions and measures](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/supported-regions.md)
|
|
116
|
+
- [Bounded series evaluation](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/series-evaluation.md)
|
|
117
|
+
- [Selected symbolic families](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/selected-symbolic-families.md)
|
|
118
|
+
- [Exact fast methods and budgets](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/performance-methods.md)
|
|
119
|
+
- [Parameterized integration](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/parameterized-integration.md)
|
|
120
|
+
- [Result semantics and certification](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/certification.md)
|
|
121
|
+
- [Regularization](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/regularization.md)
|
|
122
|
+
- [Polygon and polytope boundary reduction](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/boundary-reduction.md)
|
|
123
|
+
- [Nonseparable improper integration](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/nonseparable-improper.md)
|
|
124
|
+
- [Laurent moments, clips and tangencies](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/laurent-clips-and-tangencies.md)
|
|
125
|
+
- [Nonlinear moments and singularities](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/nonlinear-moments-and-singularities.md)
|
|
126
|
+
- [Sectors and contact charts](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/sectors-and-contact-charts.md)
|
|
127
|
+
- [Limitations and known issues](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/limitations.md)
|
|
128
|
+
|
|
129
|
+
Executable examples live in [examples](https://github.com/BhuvaneshBhatt/multiple_integrate/tree/main/examples), and the [demo notebook](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/notebooks/multiple_integration.ipynb) connects the mathematical formulas to calls.
|
|
130
|
+
|
|
131
|
+
The following guides cover public interfaces, certified transformations and numerical evaluation:
|
|
132
|
+
|
|
133
|
+
- [Quick start](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/quickstart.rst)
|
|
134
|
+
- [API reference](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/api.md)
|
|
135
|
+
- [Polynomial polytopes and reusable moments](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/polynomial-polytopes.md)
|
|
136
|
+
- [Symbolic coarea reductions](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/coarea.md)
|
|
137
|
+
- [Numerical integration](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/numerical-integration.md)
|
|
138
|
+
- [Certified numerical coarea](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/numerical-coarea.md)
|
|
139
|
+
- [Numerical backends and uncertainty](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/numerical-backends.md)
|
|
140
|
+
- [Numerical method controls](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/numerical-method-controls.md)
|
|
141
|
+
- [Numerical precision and dimension limits](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/implemented-capabilities.md)
|
|
142
|
+
- [Prepared symbolic and numerical kernels](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/prepared-kernel-performance.md)
|
|
143
|
+
- [Design, performance contracts and measurements](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/design-and-performance.md)
|
|
144
|
+
- [Domain requirements and counterexamples](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/domain-requirements.md)
|
|
145
|
+
- [Worked values and convergence prescriptions](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/worked-integral-identities.md)
|
|
146
|
+
- [Stratified maps and truncated Gaussians](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/stratified-maps-and-truncated-gaussians.md)
|
|
147
|
+
- [Polynomial folds and certified moments](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/polynomial-folds-and-certified-moments.md)
|
|
148
|
+
- [Sheared folds and boundary formulas](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/sheared-folds-and-boundary-formulas.md)
|
|
149
|
+
- [Fold products and simplex enclosures](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/fold-products-and-simplex-enclosures.md)
|
|
150
|
+
|
|
151
|
+
## Worked examples
|
|
152
|
+
|
|
153
|
+
### Layer-cake identity
|
|
154
|
+
|
|
155
|
+
For a nonnegative density `f`, the layer-cake identity is
|
|
156
|
+
`integral(f) = integral_0^infinity volume({f > t}) dt`, with infinite values
|
|
157
|
+
allowed by Tonelli's theorem. For `f=exp(-g)` and `g>=0`, an equivalent form is `integral(exp(-g)) = integral_0^infinity exp(-t)*volume({g < t}) dt`.
|
|
158
|
+
For the positive-quadrant superellipse `g=x**4+y**4`, the sublevel area is
|
|
159
|
+
`Gamma(1/4)**2*sqrt(t)/(8*sqrt(pi))`:
|
|
160
|
+
|
|
161
|
+
<!-- layer-cake-start -->
|
|
162
|
+
```python
|
|
163
|
+
import sympy as sp
|
|
164
|
+
|
|
165
|
+
from multiple_integrate import integrate_result
|
|
166
|
+
|
|
167
|
+
x, y = sp.symbols("x y", real=True)
|
|
168
|
+
t = sp.Symbol("t", positive=True)
|
|
169
|
+
area = sp.gamma(sp.Rational(1, 4)) ** 2 * sp.sqrt(t) / (8 * sp.sqrt(sp.pi))
|
|
170
|
+
layer_value = sp.integrate(sp.exp(-t) * area, (t, 0, sp.oo))
|
|
171
|
+
result = integrate_result(sp.exp(-(x**4 + y**4)), (x, 0, sp.oo), (y, 0, sp.oo))
|
|
172
|
+
assert sp.simplify(result.value - layer_value) == 0
|
|
173
|
+
assert sp.simplify(layer_value - sp.gamma(sp.Rational(1, 4)) ** 2 / 16) == 0
|
|
174
|
+
```
|
|
175
|
+
<!-- layer-cake-end -->
|
|
176
|
+
|
|
177
|
+
This demonstrates the identity and its value; the automatic planner may choose
|
|
178
|
+
another proved route for the same density. See [selected symbolic families](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/selected-symbolic-families.md) for endpoint factors and shifted or truncated gamma moments, and [worked integral identities](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/worked-integral-identities.md) for additional derivations.
|
|
179
|
+
|
|
180
|
+
<!-- geometry-casebook-start -->
|
|
181
|
+
## Geometry casebook
|
|
182
|
+
|
|
183
|
+
The examples share these imports:
|
|
184
|
+
|
|
185
|
+
```python
|
|
186
|
+
from dataclasses import replace
|
|
187
|
+
import mpmath as mp
|
|
188
|
+
import semialg
|
|
189
|
+
import sympy as sp
|
|
190
|
+
from multiple_integrate import IntegrationOutcome, integrate_result, regularized_result
|
|
191
|
+
from multiple_integrate.parameter_cells import ParameterCell, integrate_cells
|
|
192
|
+
from multiple_integrate.regularization import HadamardFinitePart, verify_regularization_result
|
|
193
|
+
```
|
|
194
|
+
|
|
195
|
+
### Parameter cells and graph contact
|
|
196
|
+
|
|
197
|
+
```python
|
|
198
|
+
x, y, a, b = sp.symbols("x y a b", real=True)
|
|
199
|
+
result = integrate_cells(
|
|
200
|
+
1,
|
|
201
|
+
region=sp.And(x >= 0, x <= a, y >= 0, y <= b - x**2),
|
|
202
|
+
variables=(x, y),
|
|
203
|
+
parameters=(a, b),
|
|
204
|
+
assumptions=sp.And(a > 0, b >= a**2),
|
|
205
|
+
cells=(ParameterCell(b > a**2), ParameterCell(sp.Eq(b, a**2), {b: a**2})),
|
|
206
|
+
)
|
|
207
|
+
assert sp.simplify(result.cases[0].value - (a * b - a**3 / 3)) == 0
|
|
208
|
+
assert sp.simplify(result.cases[1].value - 2 * a**3 / 3) == 0
|
|
209
|
+
```
|
|
210
|
+
|
|
211
|
+
### Cusp contact and divergence
|
|
212
|
+
|
|
213
|
+
```python
|
|
214
|
+
x, y = sp.symbols("x y", real=True)
|
|
215
|
+
base = x**3 - y**2
|
|
216
|
+
horn = sp.And(x > 0, x < 1, y**2 <= x**3)
|
|
217
|
+
result = integrate_result(base ** -sp.Rational(1, 2), region=horn, variables=(x, y))
|
|
218
|
+
divergent = integrate_result(x**2 / base, region=horn, variables=(x, y))
|
|
219
|
+
assert sp.simplify(sp.expand_func(result.value) - sp.pi) == 0
|
|
220
|
+
assert result.absolute_convergent is True
|
|
221
|
+
assert divergent.outcome is IntegrationOutcome.DIVERGENT
|
|
222
|
+
```
|
|
223
|
+
|
|
224
|
+
### Exact finite radial series
|
|
225
|
+
|
|
226
|
+
```python
|
|
227
|
+
x, y, z = sp.symbols("x y z", real=True)
|
|
228
|
+
rho = x**2 + y**2 + z**2
|
|
229
|
+
result = integrate_result(
|
|
230
|
+
sp.exp(-rho) / (2 + rho), region=semialg.Ball((0, 0, 0), 1), variables=(x, y, z)
|
|
231
|
+
)
|
|
232
|
+
assert result.value.has(sp.Sum) and result.absolute_convergent is True
|
|
233
|
+
with mp.workdps(35):
|
|
234
|
+
reference = 4 * mp.pi * mp.quad(lambda r: r**2 * mp.exp(-r * r) / (2 + r * r), [0, 1])
|
|
235
|
+
assert abs(mp.mpf(str(result.value.evalf(30))) - reference) < mp.mpf("1e-25")
|
|
236
|
+
```
|
|
237
|
+
|
|
238
|
+
### Clipped polygon finite part
|
|
239
|
+
|
|
240
|
+
```python
|
|
241
|
+
x, y = sp.symbols("x y", real=True)
|
|
242
|
+
polygon = sp.And(x >= 0, y >= 0, x <= sp.Rational(1, 2), x + y <= 1)
|
|
243
|
+
result = regularized_result(
|
|
244
|
+
1 / (x * y),
|
|
245
|
+
region=polygon,
|
|
246
|
+
variables=(x, y),
|
|
247
|
+
regularization=HadamardFinitePart(hypersurface=x * y),
|
|
248
|
+
)
|
|
249
|
+
assert sp.simplify(result.value + sp.pi**2 / 12 - sp.log(2) ** 2) == 0
|
|
250
|
+
assert verify_regularization_result(result).valid
|
|
251
|
+
assert not verify_regularization_result(replace(result, value=result.value + 1)).valid
|
|
252
|
+
```
|
|
253
|
+
|
|
254
|
+
For an ordinary result inspect `result.outcome`, `result.complete`, `result.coverage`, and `result.convergence_evidence`; for a family inspect each child in `result.diagnostics['cell_results']`. A finite-part answer describes its specified cutoff and does not prove ordinary convergence.
|
|
255
|
+
<!-- geometry-casebook-end -->
|
|
256
|
+
|
|
257
|
+
## Contributing
|
|
258
|
+
|
|
259
|
+
Contributions – whether they are bug reports, suggestions, or code for bugfixes or improvements – are welcome!
|
|
260
|
+
|
|
261
|
+
For development setup, architecture and extension guidance, see [Contributing](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/contributing.md). The [testing guide](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/testing.md) describes the mathematical, property, slow and packaging checks.
|
|
262
|
+
|
|
263
|
+
See the [release notes](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/CHANGELOG.md) for changes and the [limitations and known issues](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/docs/limitations.md) for unresolved cases.
|
|
264
|
+
|
|
265
|
+
MultipleIntegrate is licensed under the GNU General Public License version 3 only (GPL-3.0-only). See [LICENSE](https://github.com/BhuvaneshBhatt/multiple_integrate/blob/main/LICENSE).
|