\P Version of December 30, 2018; reformatted and the last \P two partial algebras added on May 7, 2019. % This is a sample data file. Do not change its STRUCTURE! % In particular, do not change the order of the command, % and do not leave a command. % For instruction, see the end of this file, and see the comment % lines in the data part. \verbose=false % You may also choose: \verbose=true; but the difference is minimal. \subtrahend-in-exponent=8 % Small natural number, for another form of |Sub(A)| \operationsymbols=+* % Only for information; % Although this this command is obligatory, the program does NOT % use any property of the operations; only the syntax is checked. % Empty lines are allowed but neglected. Everything is % case-sensitive. "%" introduces comments that are dropped, but % P introduces comments that are copied into the % output file. Both forms of comments are optional, of course. % There is a third form of comment but only in the list of % constraints; it is carried over the output file and it % starts with "\w"; see later for examples. % And, only in the "constraints part", there is a fourth way: % namely, we can use a "parenthesized command"; see later. \beginjob % \P First, we are dealing with the pentagon lattice. % Any line containing the P command is printed into the % output file and to the screen. P is suggested only % after places where the program automatically prints a line-break. \name N_5 %The name of the algebra % Here a backslash>P line is not suggested because of the % possibility of an ugly line-break, even if such a line would not % disturb the computation. \size 5 %The size of the algebra \elements 01abc % the elements of the algebra; a single character each, % case-sensitive, without spaces \constraints (Case-name1) a*b=0, a+b=1 \w Explanation/1 (to be output). % In this "constraints" part, use \w, because \P is not allowed here! % the constraints are separated by spaces or commas, multiple % separators are allowed. The "\w "command is allowed only here, % in the scope of the \constraints command The parenthesized comment % is optional; if it is present then it is printed. Note the syntax: % either there are no parentheses, or there are exactly one opening % one and exactly one closing one in the same line later (Subcase-name) c*b=0 \w Explanation/2 to be printed % (Sub-subcase-name) c+b=1 \w Explanation/3 to be printed % % The spaces preceding the opening parenthesis are also printed. % This feature and the parenthesized part are very appropriate to % organize our work. \endofjob \P Comments on the result above (free text) \P (free text, continued) \beginjob \name M_3 %The name of the algebra \size 5 %size of the algebra \elements 01abc \constraints (C1) a*b=0 \w %The empty print gives only a colon and a line break. (C1a) a+b=1 \w but this algebra needs no cases to distinguish! (C1a.1) b*c=0 \w "C" in parentheses stands for "Case" (C1a.1b) b+c=1 c*a=0, c+a=1 \endofjob \beginjob \P We are dealing with the 6-element modular lattice of length 2 \name M_4 %The name of the algebra \size 6 %size of the algebra \elements 01abcd \constraints a*b=0 a+b=1 a*c=0 a+c=1 a*d=0 a+d=1 \w No cases are needed. b*c=0 b+c=1 b*d=0 b+d=1 c*d=0 c+d=1 \endofjob \P \P The next two partial algebras together are to indicate \P the difficulty in the paper \beginjob \name without x \size 7 \elements cdefgoi \constraints c+e=g, f*g=d \endofjob \beginjob \name with x \size 8 \elements cdefgoix \constraints c+e=x, f*g=d \endofjob \enddata The rest of the file will not be processed by the program! INSTRUCTION %******************************************************************* In such a file, arbitrarily many partial algebras can be given. (Here, we give only five.) Percentage sign (%) means that the rest of the line is only a comment, which does not influence the computation. Note that if we have a unary operation f and f(x)=y, then we have to type the corresponding constraint as xfx=y . Notes on the syntax: no line can exceed 250 characters but it is suggested that 80 characters should not be exceeded. The constraints are separated by commas of spaces, in a single line or in more lines. The elements of the algebra should be denoted by letters or decimals; some characters are forbidden, and the characters are case-sensitive. Also, study the comments on the syntax in the comment lines that occur among the data above. Improper data will lead to irregular termination of the program. ALGORITHM %******************************************************************* The program lists ALL subsets of the base set and counts those that are closed with respect to all constraints. No property of the operations are taken into account. In fact, even multiple valued partial operations are allowed; for example, xfy=u and xfy=v can both occur among the constraints. Since the running time is exponential, the program is not effective for large partial algebras. For |A|<26, the program is likely to compute the result in a reasonable time in any reasonable computer. For |A|>30, this is not always so. In addition to |A|, the running time depends also on the constraints. AS IT IS The program is for Windows 10; it is likely to run under Windows 7 or higher. The program is "as it is", nothing is guaranteed.