 ##  [Term Algebra](/term-algebra-0) 

 Definition

The free algebra of syntactic terms built from a given signature and set of variables: elements are formal term trees and operations are term-forming function symbols; it satisfies the universal property of free objects in the category of algebras for that signature.

 

 

 

 

 

 





## Principle

Principle

Syntactic generation and substitution: terms are formed inductively from variables and function symbols, and substitution/evaluation defines the unique homomorphism from the term algebra into any algebra interpreting the signature.

 

 

 

 

 





## Demonstration

Demonstration

For signature with a binary symbol * and variables {x,y}, the term *(x,*(y,x)) is an element of the term algebra; given any algebra A interpreting *, any assignment of x,y in A induces a unique homomorphism evaluating the term to an element of A.

 

 

 

 

## Misapplication

Misapplication

Confusing the term algebra with the algebra of all functions on a set of variables or with a quotient of the term algebra by nontrivial equations; the raw term algebra encodes pure syntax, not semantic identifications unless quotiented.

 

 

 

 

 





## Consequence

Consequence

Term algebras provide initial models, underpin unification and matching algorithms, and furnish syntactic representatives for free algebras and for presenting quotients that implement equational theories.

 

 

 

 

## Reversal

Reversal

A quotient of the term algebra by the smallest congruence generated by a set of equations produces the free algebra in the corresponding equational theory; the quotient collapses syntactic distinctions into semantic equalities.

 

 

 

 

 





## Boundary

Boundary

Pure term algebras contain no imposed identities beyond syntactic equality; any imposed axioms produce quotients—so the term algebra is outside varieties defined by nontrivial identities until quotiented.

 

 

 

 

 





## Semantic Tension

Semantic Tension

Between syntax and semantics: the term algebra is purely syntactic and reflects derivation trees, while semantic algebras interpret symbols and may identify distinct terms; reconciling the two uses quotients by equational theories.

 

 

 

 

 





## Synthesis

Synthesis

The term algebra is the syntactic universe of terms for a signature that, via its universal mapping property, both generates free algebras and serves as the source for quotients presenting equational and Horn theories; it is the bridge from syntax to algebraic semantics.