Algebra and natural languages have two different paradigms for creating names[Gr??, SIGPLAN]. Thus "x" is clearly an algebraic name, and "cats" an English name. Programming languages do not include a list of valid English words because they predate the existence of spelling checkers and because of the divine right of programmers to confuse their colleagues.
MATHS allows both to be used in formulae. A natural MATHS name is an unabbreviated phrase in a natural language with spaces replaced by an underline symbol. It will be constructed from words that are in a dictionary of that language. However to keep formula and proofs manageable, short algebraic variables or symbolic names are needed.
A public name, or parameter needs to be easy to retrieve or spot by eye. They are always introduced (defined or declared) by using two colons:
The above forms are used inside documents and should be interspersed with comments. The keyword "following" above means that the following closed piece of document forms the expression.
A MATHS environment needs to be able to keep an index of names that are current.
A name that is not in the index is free:
At each point in a piece of documentation there exists a set of bound symbolic names (the current index). Bindings, definitions and declarations add to this set. Variables are removed at the end of their scope. At the start no names are bound.
A binding always creates a new variable or name - even when the symbol or identifier is already bound. The old meaning is recovered at the end of the new symbols scope. Variables are uniquely identified by their name and the place where they were bound. Compare [ notn_12_Expressions.html#Free Variables ] for more examples.
A mathematical symbol can be a character in another alphabet represented, in ASCII, by a word - typically prefixed by a backslash. Notice that in keeping with mathematical tradition single character identifiers are used for local variables. Identifiers like 'sin', 'cos', 'abs', 'sinh', 'asin', 'sqrt', 'pr', 'id'... etc can also be found in mathematical dictionaries, and can be used as mathematical symbols. Significantly they have not been typeset in italics as variables however. Thus there is an exception to the rule that names that are words must be in a standard dictionary. A (short) glossary of mathematical words can therefore be included as part of a document - and a tool should be made that scans a document and extracts names that are defined but are not in the standard dictionary.
x'+yboth x and y are free but x is dynamic and y is static. (For more see [ notn_12_Expressions.html#Free Variables ] , [ intro_dynamics.html ] , [ math_14_Dynamics.html ] , and [ math_75_Programs.html ] )
To make reuse easier, natural names whose scope is larger than a single formula. This is especially true for ideas that someone else may want to remember.. Some f these can be given internal algebraic abbreviations are used inside a piece of documentation.
The words should exist in a standard a dictionary of the user's and client's natural language. The use of underline to link words is incompatible with Τ_{Ε}Χ subscripting. A preprocessor that outputs Τ_{Ε}Χ must therefore escape underlines within natural identifiers. It will also have to insert formatting of sub- and super-scripts.
Strings like "I" and "a" are ambiguous - they are both in the English dictionary and are algebraic variables. Within a formal piece of documentation they are taken to be algebraic. Within informal commentary they are taken to be words. However, inside a comment, a reverse quotes should enclose a formula. Identifiers of defined terms may be preceded by a dollar sign to indicate a cross-reference or hypertext link. Note. This is not really necessary outside comments if suitable tools are available for interpreting formulae.
|- tweedle_dee <> tweedle_dum.
. . . . . . . . . ( end of section Names) <<Contents | End>>
Proofs follow a natural deduction style that start with assumptions ("Let") and continue to a consequence ("Close Let") and then discard the assumptions and deduce a conclusion. Look here [ Block Structure in logic_25_Proofs ] for more on the structure and rules.
The notation also allows you to create a new network of variables and constraints. A "Net" has a number of variables (including none) and a number of properties (including none) that connect variables. You can give them a name and then reuse them. The schema, formal system, or an elementary piece of documentation starts with "Net" and finishes "End of Net". For more, see [ notn_13_Docn_Syntax.html ] for these ways of defining and reusing pieces of logic and algebra in your documents. A quick example: a circle = Net{radius:Positive Real, center:Point}.
For a complete listing of pages in this part of my site by topic see [ home.html ]
For a more rigorous description of the standard notations see