3,515 research outputs found
Efficient Pattern Matching in Python
Pattern matching is a powerful tool for symbolic computations. Applications
include term rewriting systems, as well as the manipulation of symbolic
expressions, abstract syntax trees, and XML and JSON data. It also allows for
an intuitive description of algorithms in the form of rewrite rules. We present
the open source Python module MatchPy, which offers functionality and
expressiveness similar to the pattern matching in Mathematica. In particular,
it includes syntactic pattern matching, as well as matching for commutative
and/or associative functions, sequence variables, and matching with
constraints. MatchPy uses new and improved algorithms to efficiently find
matches for large pattern sets by exploiting similarities between patterns. The
performance of MatchPy is investigated on several real-world problems
Tactics for Reasoning modulo AC in Coq
We present a set of tools for rewriting modulo associativity and
commutativity (AC) in Coq, solving a long-standing practical problem. We use
two building blocks: first, an extensible reflexive decision procedure for
equality modulo AC; second, an OCaml plug-in for pattern matching modulo AC. We
handle associative only operations, neutral elements, uninterpreted function
symbols, and user-defined equivalence relations. By relying on type-classes for
the reification phase, we can infer these properties automatically, so that
end-users do not need to specify which operation is A or AC, or which constant
is a neutral element.Comment: 16
MatchPy: A Pattern Matching Library
Pattern matching is a powerful tool for symbolic computations, based on the
well-defined theory of term rewriting systems. Application domains include
algebraic expressions, abstract syntax trees, and XML and JSON data.
Unfortunately, no lightweight implementation of pattern matching as general and
flexible as Mathematica exists for Python Mathics,MacroPy,patterns,PyPatt.
Therefore, we created the open source module MatchPy which offers similar
pattern matching functionality in Python using a novel algorithm which finds
matches for large pattern sets more efficiently by exploiting similarities
between patterns.Comment: arXiv admin note: substantial text overlap with arXiv:1710.0007
Graph products of spheres, associative graded algebras and Hilbert series
Given a finite, simple, vertex-weighted graph, we construct a graded
associative (non-commutative) algebra, whose generators correspond to vertices
and whose ideal of relations has generators that are graded commutators
corresponding to edges. We show that the Hilbert series of this algebra is the
inverse of the clique polynomial of the graph. Using this result it easy to
recognize if the ideal is inert, from which strong results on the algebra
follow. Non-commutative Grobner bases play an important role in our proof.
There is an interesting application to toric topology. This algebra arises
naturally from a partial product of spheres, which is a special case of a
generalized moment-angle complex. We apply our result to the loop-space
homology of this space.Comment: 19 pages, v3: elaborated on connections to related work, added more
citations, to appear in Mathematische Zeitschrif
Constructions of free commutative integro-differential algebras
In this survey, we outline two recent constructions of free commutative
integro-differential algebras. They are based on the construction of free
commutative Rota-Baxter algebras by mixable shuffles. The first is by
evaluations. The second is by the method of Gr\"obner-Shirshov bases.Comment: arXiv admin note: substantial text overlap with arXiv:1302.004
Coherence in monoidal track categories
We introduce homotopical methods based on rewriting on higher-dimensional
categories to prove coherence results in categories with an algebraic
structure. We express the coherence problem for (symmetric) monoidal categories
as an asphericity problem for a track category and we use rewriting methods on
polygraphs to solve it. The setting is extended to more general coherence
problems, seen as 3-dimensional word problems in a track category, including
the case of braided monoidal categories.Comment: 32 page
- …