Cadabra
a field-theory motivated approach to computer algebra

Manual pages

Every algorithm and every property has a manual page with examples, which you can view online, or by pressing F1 in the Cadabra notebook interface.

For a description of the basics of Cadabra, you may be better off first reading or skimming through the reference guide.

Packages

warning: not yet available, coming soon! Cadabra comes with various add-on packages, which can be imported in the usual Python way with import. Their content is listed below.

cdb.core.manip

Manipulating equations, inequalities and similar expressions

eq_to_subrule Create substitution rule from an equation.
multiply_through Multiply all terms by the same factor.
get_lhs Return left-hand side of an expression
get_rhs Return right-hand side of an expression
swap_sides Swap the left and right-hand sides of an expression.
to_rhs Move the indicated term of the expression to the right-hand side.
to_lhs Move the indicated term of the expression to the left-hand side.

Core algorithms

Aasym Anti-symmetrise or symmetrise an expression in indicated indices or arguments
Ccanonicalise Bring a tensorial expression to canonical form by re-ordering indices.
collect_factors Collect identical factors in a product.
collect_terms Collect identical terms in a sum.
combine Combine two consecutive indexbracket objects
complete Complete a set of substitution rules to cover related objects.
Ddecompose Decompose a tensor monomial on a given basis of monomials.
decompose_product Decompose a product of tensors by using Young projectors.
distribute Distribute factors over sums.
drop_weight Drop terms with given weight
Eeinsteinify Raise or lower indices of pairs which are both upper or lower.
eliminate_kronecker Eliminate Kronecker delta symbols.
eliminate_metric Eliminate metrics by raising or lowering indices.
epsilon_to_delta Replace a product of two epsilon tensors with a generalised delta
evaluate Evaluate components of a tensor expression.
expand Write out products of objects with implicit indices.
expand_delta Expand generalised Kronecker delta symbols
expand_diracbar Simplify the Dirac bar of a composite object.
expand_power Expand powers into repeated products
Ffactor_in Collect terms in a sum that differ only by given pre-factors.
factor_out Isolate common factors in a sum of products
fierz Perform a Fierz transformation on a product of four spinors
Iintegrate_by_parts Integrate by parts away from the indicated expression
Jjoin_gamma Work out the product of two generalised Dirac gamma matrices.
Kkeep_weight Keep terms with indicated weight
Llower_free_indices Make all free indices in an expression subscripts.
lr_tensor Compute the tensor project of two Young tableaux
Mmap_sympy Map Sympy algorithms to Cadabra expressions
Pproduct_rule Apply the Leibnitz rule to a derivative of a product
Rraise_free_indices Make all free indices in an expression superscripts.
reduce_delta Simplify a self-contracted generalised delta.
rename_dummies Rename dummy indices, within a set or from one set to another.
replace_match Put the result of a sub-computation back into the original expression
rewrite_indices Rewrite indices by contracting with vielbein or metric.
Ssimplify Simplify the scalar part of an expression.
sort_product Sort factors in a product
sort_spinors Sort Majorana spinor bilinears
sort_sum Sort terms in a sum.
split_gamma Split a Dirac gamma matrix off a generalised product of gamma matrices.
split_index Split the range of an index into two subsets
substitute Generic substitution algorithm.
Ttake_match Select a subset of terms in a sum for further computations.
Uunwrap Move objects out of derivatives or accents.
Vvary Generic variation algorithm for functional derivatives.
Yyoung_project_product Project all tensors in a product with their Young tableau projector.
young_project_tensor Project tensors with their Young projector.
Zzoom Only show selected terms in a sum, and restrict subsequent algorithms to these terms.

Core properties

AAccent Turn a symbol into an accent.
AntiCommuting Make objects anti-commuting.
AntiSymmetric Make an object anti-symmetric in all indices.
CCommuting Make components commuting.
CommutingAsProduct Makes an object behave as a product when commuting.
CommutingAsSum Makes an object behave as a sum when commuting.
Coordinate Declare a symbol to be a coordinate label.
DDAntiSymmetric Gives object the symmetries of the derivative of a fully antisymmetric tensor.
Depends Makes an object implicitly dependent on other objects.
Derivative Declare an operator to satisfy the Leibnitz rule.
Diagonal Declares a tensor to only have non-zero diagonal entries.
DiracBar An accent representing the Dirac conjugation operation.
EEpsilonTensor A fully anti-symmetric tensor with constant components.
FFilledTableau A Young tableau with labelled boxes.
GGammaMatrix A generalised generator of a Clifford algebra.
IImplicitIndex Indicates that an object carries indices which are not written out.
Indices Declare names to be used as indices.
Integer Indicates that an object takes integer values.
InverseMetric Make a two-tensor an inverse metric.
KKroneckerDelta Turns an object into a generalised Kronecker delta symbol.
LLaTeXForm Changes the way in which symbols are displayed.
MMetric Makes a two-tensor a metric.
NNonCommuting Makes components non-commuting.
PPartialDerivative Makes an object a partial derivative.
RRiemannTensor Make an object a Riemann curvature tensor.
SSatisfiesBianchi Make an object satisfy the generalised Bianchi identity.
SelfAntiCommuting Make components of tensors anti-commute.
SelfCommuting Make tensor components commute.
SelfNonCommuting Make tensor components non-commuting.
SortOrder Set sorting order of objects.
Spinor Declares an object to transform as a spinor.
Symbol Make an object not count as index when it is a sub- or super-script
Symmetric Make an object symmetric in all indices.
TTableau Make object a Young tableau
TableauSymmetry Gives a tensor a generic Young tableau symmetry.
WWeightInherit Make object inherit weights from child nodes
Copyright © 2001-2018 Kasper Peeters
Questions? info@cadabra.science