Words of trees, tests and prefixes of lists #
The brackets of a tree in preorder (Interpreter.wordT, computed by Interpreter.wordF, and as
bits Interpreter.tbits), the test whether a binary number is nonzero (Interpreter.nzB), and the
program Interpreter.takeB that splits off a prefix of a list whose length is a binary number.
From VP ≠ VNP over every field [Ant26], module NS1.Util.
Main definitions #
Main results #
Interpreter.wordT_eq_map_tbits: the brackets of a tree are the letters of its bits.Interpreter.wordF_gives,Interpreter.nzB_gives,Interpreter.takeB_gives.
The brackets of a tree, in preorder: 0 = empty, 1 = a node.
Write the brackets of a tree in front of a list. The argument is (this program, (tree, list)).
The brackets of a tree.
Is a number not 0? The argument is (this program, number).
Take elements from a list, as many as a binary number says. The argument is (this program, (number, (elements taken, in reversed order, list))); the value is (elements taken, rest).