Algebras for Tree Algorithms

This thesis presents an investigation into the properties of various algebras of trees. In particular, we study the influence that the structure of a tree algebra has on the solution of algorithmic problems about trees in that algebra. The investigation is conducted within the framework provided by...

ver descrição completa

Detalhes bibliográficos
Autor principal: Gibbons, J
Formato: Tese
Publicado em: 1991
_version_ 1826312137283207168
author Gibbons, J
author_facet Gibbons, J
author_sort Gibbons, J
collection OXFORD
description This thesis presents an investigation into the properties of various algebras of trees. In particular, we study the influence that the structure of a tree algebra has on the solution of algorithmic problems about trees in that algebra. The investigation is conducted within the framework provided by the Bird-Meertens formalism, a calculus for the construction of programs by equational reasoning from their specifications. We present three different tree algebras: two kinds of binary tree and a kind of general tree. One of the binary tree algebras, called \"hip trees\", is new. Instead of being built with a single ternary operator, hip trees are built with two binary operators which respectively add left and right children to trees which do not already have them; these operators enjoy a kind of associativity property. Each of these algebras brings with it with a class of \"structure-respecting\" functions called catamorphisms; the definition of a catamorphism and a number of its properties come for free from the definition of the algebra, because the algebra is chosen to be initial in a class of algebras induced by a (cocontinuous) functor. Each algebra also brings with it, but not for free, classes of \"structure-preserving\" functions called accumulations. An accumulation is a function that preserves the shape of a structured object such as a tree, but replaces each element of that object with some catamorphism applied to some of the other elements. The two classes of accumulation that we study are the \"upwards\" and \"downwards\" accumulations, which pass information from the leaves of a tree towards the root and from the root towards the leaves, respectively. Upwards and downwards accumulations turn out to be the key to the solution of many problems about trees. We derive accumulation-based algorithms for a number of problems; these include the parallel prefix algorithm for the prefix sums problem, algorithms for bracket matching and for drawing binary and general trees, and evaluators for decorating parse trees according to an attribute grammar.
first_indexed 2024-03-07T08:24:34Z
format Thesis
id oxford-uuid:5dffbea2-c4fb-46e9-bf7c-755853b8edb1
institution University of Oxford
last_indexed 2024-03-07T08:24:34Z
publishDate 1991
record_format dspace
spelling oxford-uuid:5dffbea2-c4fb-46e9-bf7c-755853b8edb12024-02-12T11:31:00ZAlgebras for Tree AlgorithmsThesishttp://purl.org/coar/resource_type/c_db06uuid:5dffbea2-c4fb-46e9-bf7c-755853b8edb1Department of Computer Science1991Gibbons, JThis thesis presents an investigation into the properties of various algebras of trees. In particular, we study the influence that the structure of a tree algebra has on the solution of algorithmic problems about trees in that algebra. The investigation is conducted within the framework provided by the Bird-Meertens formalism, a calculus for the construction of programs by equational reasoning from their specifications. We present three different tree algebras: two kinds of binary tree and a kind of general tree. One of the binary tree algebras, called \"hip trees\", is new. Instead of being built with a single ternary operator, hip trees are built with two binary operators which respectively add left and right children to trees which do not already have them; these operators enjoy a kind of associativity property. Each of these algebras brings with it with a class of \"structure-respecting\" functions called catamorphisms; the definition of a catamorphism and a number of its properties come for free from the definition of the algebra, because the algebra is chosen to be initial in a class of algebras induced by a (cocontinuous) functor. Each algebra also brings with it, but not for free, classes of \"structure-preserving\" functions called accumulations. An accumulation is a function that preserves the shape of a structured object such as a tree, but replaces each element of that object with some catamorphism applied to some of the other elements. The two classes of accumulation that we study are the \"upwards\" and \"downwards\" accumulations, which pass information from the leaves of a tree towards the root and from the root towards the leaves, respectively. Upwards and downwards accumulations turn out to be the key to the solution of many problems about trees. We derive accumulation-based algorithms for a number of problems; these include the parallel prefix algorithm for the prefix sums problem, algorithms for bracket matching and for drawing binary and general trees, and evaluators for decorating parse trees according to an attribute grammar.
spellingShingle Gibbons, J
Algebras for Tree Algorithms
title Algebras for Tree Algorithms
title_full Algebras for Tree Algorithms
title_fullStr Algebras for Tree Algorithms
title_full_unstemmed Algebras for Tree Algorithms
title_short Algebras for Tree Algorithms
title_sort algebras for tree algorithms
work_keys_str_mv AT gibbonsj algebrasfortreealgorithms