Cadabra
Computer algebra system for field theory problems
Public Member Functions | Public Attributes | List of all members
cadabra::pattern Class Reference

#include <Props.hh>

Public Member Functions

 pattern ()
 
 pattern (const Ex &)
 
bool match (const Properties &, const Ex::iterator &, bool ignore_parent_rel=false, bool ignore_properties=false) const
 Match a pattern to an expression. More...
 
bool children_wildcard () const
 

Public Attributes

Ex obj
 

Constructor & Destructor Documentation

◆ pattern() [1/2]

pattern::pattern ( )

◆ pattern() [2/2]

pattern::pattern ( const Ex o)

Member Function Documentation

◆ children_wildcard()

bool pattern::children_wildcard ( ) const

◆ match()

bool pattern::match ( const Properties properties,
const Ex::iterator &  it,
bool  ignore_parent_rel = false,
bool  ignore_properties = false 
) const

Match a pattern to an expression.

If ignore_parent_rel is true, this will match regardless of the parent_rel of the top node. If ignore_properties is true, property information will not be used to match symbols anywhere (in which case A_{a} and A_{b} will no longer match even when 'a' and 'b' have the same Indices property, for example). The latter feature is mostly used to do pattern matching when the property for which we need it cannot rely on such child node properties, e.g. Accent; see the specialisation in get_composite below.

Member Data Documentation

◆ obj

Ex cadabra::pattern::obj

The documentation for this class was generated from the following files: