occam-furtle 2.0.197 → 2.0.199
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -35,10 +35,10 @@ Boolean isVariableBound(Node termNode, Node statementNode) {
|
|
|
35
35
|
String variableNameFromTermNode(Node termNode) {
|
|
36
36
|
String variableName = "";
|
|
37
37
|
|
|
38
|
-
Node
|
|
38
|
+
Node variableIdentifierTerminalNode = nodeQuery(termNode, /term/variable/@identifier);
|
|
39
39
|
|
|
40
|
-
If (
|
|
41
|
-
{ String content } =
|
|
40
|
+
If (variableIdentifierTerminalNode != null) {
|
|
41
|
+
{ String content } = variableIdentifierTerminalNode;
|
|
42
42
|
|
|
43
43
|
variableName = content;
|
|
44
44
|
}
|
|
@@ -61,10 +61,10 @@ String boundVariableNameFromStatementNode(Node statementNode) {
|
|
|
61
61
|
If ((content == "∀") || (content == "∃")) {
|
|
62
62
|
[ _, Node argumentNode ] = childNodes;
|
|
63
63
|
|
|
64
|
-
Node
|
|
64
|
+
Node boundVariableIdentifierTerminalNode = nodeQuery(argumentNode, /argument/term/variable!/@identifier);
|
|
65
65
|
|
|
66
|
-
If (
|
|
67
|
-
{ String content } =
|
|
66
|
+
If (boundVariableIdentifierTerminalNode != null) {
|
|
67
|
+
{ String content } = boundVariableIdentifierTerminalNode;
|
|
68
68
|
|
|
69
69
|
boundVariableName = content;
|
|
70
70
|
}
|
|
@@ -3,14 +3,14 @@
|
|
|
3
3
|
"name": "Default",
|
|
4
4
|
"termBNF": "term. ::= \"(\" argument \")\"\n\n | variable \n \n ;",
|
|
5
5
|
"statementBNF": "statement. ::= \"(\" metaArgument \")\" \n \n | equality\n\n | judgement\n\n | typeAssertion \n \n | definedAssertion \n\n | containedAssertion \n \n | satisfyingAssertion\n\n | subproofAssertion \n\n | propertyAssertion \n\n | metavariable ( frameSubstitution | termSubstitution )?\n\n ;\n\nequality ::= term \"=\" term ;\n\njudgement ::= frame \"|-\" declaration ;\n\ntypeAssertion ::= term \":\" type ;\n\ndefinedAssertion ::= ( frame | term ) \"is\" ( \"defined\" | \"undefined\" );\n\ncontainedAssertion ::= ( frame | term ) \"is\" ( \"present\" | \"missing\" ) \"in\" statement ;\n\nsatisfyingAssertion ::= ( ( term \"satisfies\" ) | ( term ( \",\" term )+ \"satisfy\" ) ) metavariable ; \n\nsubproofAssertion ::= \"[\" statement ( \",\" statement )* \"]\" \"...\" statement ;\n\npropertyAssertion ::= term \"is\" ( \"a\" | \"an\" ) propertyRelation ;\n\npropertyRelation ::= property \"of\" term ;\n\nframe ::= \"[\" ( ( declaration | metavariable ) ( \",\" ( declaration | metavariable ) )* )? \"]\" ;\n \ndeclaration ::= metavariable \"::\" statement ;\n\ntermSubstitution ::= \"[\" term \"for\" term \"]\";\n\nframeSubstitution ::= \"[\" frame \"for\" frame \"]\";\n\nstatementSubstitution ::= \"[\" statement \"for\" statement \"]\";\n\nreferenceSubstitution ::= \"[\" reference \"for\" reference \"]\";",
|
|
6
|
-
"
|
|
7
|
-
"
|
|
6
|
+
"typeVocabulary": "_\n",
|
|
7
|
+
"symbolVocabulary": ""
|
|
8
8
|
},
|
|
9
9
|
{
|
|
10
10
|
"name": "first-order-logic",
|
|
11
|
-
"termBNF":
|
|
11
|
+
"termBNF": "",
|
|
12
12
|
"statementBNF": "\n\n statement ::= ( \"∀\" | \"∃\" ) ( frameArgument | argument ) metaArgument \n\n | ( frameArgument | argument ) \"is\" ( \"bound\" | \"free\" ) \"in\" metaArgument\n\n ;\n\n",
|
|
13
|
-
"
|
|
14
|
-
"
|
|
13
|
+
"typeVocabulary": "",
|
|
14
|
+
"symbolVocabulary": "\uD835\uDE23\uD835\uDE30\uD835\uDE36\uD835\uDE2F\uD835\uDE25\n\uD835\uDE27\uD835\uDE33\uD835\uDE26\uD835\uDE26\n∀\n∃\n"
|
|
15
15
|
}
|
|
16
16
|
]
|
|
@@ -12,8 +12,8 @@ var _occamentities = require("occam-entities");
|
|
|
12
12
|
var _necessary = require("necessary");
|
|
13
13
|
var readFile = _necessary.fileSystemUtilities.readFile;
|
|
14
14
|
function furtleFileFromNothing() {
|
|
15
|
-
var filePath = "/Users/djalbat/Logic/first-order-logic/
|
|
15
|
+
var filePath = "/Users/djalbat/Logic/first-order-logic/Functions/Free and bound variables.ftl", fileContent = readFile(filePath), path = filePath, content = fileContent, released = false, file = _occamentities.File.fromPathContentAndReleased(path, content, released), furtleFile = file; ///
|
|
16
16
|
return furtleFile;
|
|
17
17
|
}
|
|
18
18
|
|
|
19
|
-
//# sourceMappingURL=data:application/json;base64,
|
|
19
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIi4uLy4uLy4uL3NyYy9leGFtcGxlL3V0aWxpdGllcy9mdXJ0bGUuanMiXSwic291cmNlc0NvbnRlbnQiOlsiXCJ1c2Ugc3RyaWN0XCI7XG5cbmltcG9ydCB7IEZpbGUgfSBmcm9tIFwib2NjYW0tZW50aXRpZXNcIjtcbmltcG9ydCB7IGZpbGVTeXN0ZW1VdGlsaXRpZXMgfSBmcm9tIFwibmVjZXNzYXJ5XCI7XG5cbmNvbnN0IHsgcmVhZEZpbGUgfSA9IGZpbGVTeXN0ZW1VdGlsaXRpZXM7XG5cbmV4cG9ydCBmdW5jdGlvbiBmdXJ0bGVGaWxlRnJvbU5vdGhpbmcoKSB7XG4gIGNvbnN0IGZpbGVQYXRoID0gXCIvVXNlcnMvZGphbGJhdC9Mb2dpYy9maXJzdC1vcmRlci1sb2dpYy9GdW5jdGlvbnMvRnJlZSBhbmQgYm91bmQgdmFyaWFibGVzLmZ0bFwiLFxuICAgICAgICBmaWxlQ29udGVudCA9IHJlYWRGaWxlKGZpbGVQYXRoKSxcbiAgICAgICAgcGF0aCA9IGZpbGVQYXRoLCAgLy8vXG4gICAgICAgIGNvbnRlbnQgPSBmaWxlQ29udGVudCwgIC8vL1xuICAgICAgICByZWxlYXNlZCA9IGZhbHNlLFxuICAgICAgICBmaWxlID0gRmlsZS5mcm9tUGF0aENvbnRlbnRBbmRSZWxlYXNlZChwYXRoLCBjb250ZW50LCByZWxlYXNlZCksXG4gICAgICAgIGZ1cnRsZUZpbGUgPSBmaWxlOyAgLy8vXG5cbiAgcmV0dXJuIGZ1cnRsZUZpbGU7XG59XG4iXSwibmFtZXMiOlsiZnVydGxlRmlsZUZyb21Ob3RoaW5nIiwicmVhZEZpbGUiLCJmaWxlU3lzdGVtVXRpbGl0aWVzIiwiZmlsZVBhdGgiLCJmaWxlQ29udGVudCIsInBhdGgiLCJjb250ZW50IiwicmVsZWFzZWQiLCJmaWxlIiwiRmlsZSIsImZyb21QYXRoQ29udGVudEFuZFJlbGVhc2VkIiwiZnVydGxlRmlsZSJdLCJtYXBwaW5ncyI6IkFBQUE7Ozs7K0JBT2dCQTs7O2VBQUFBOzs7NkJBTEs7eUJBQ2U7QUFFcEMsSUFBTSxBQUFFQyxXQUFhQyw4QkFBbUIsQ0FBaENEO0FBRUQsU0FBU0Q7SUFDZCxJQUFNRyxXQUFXLGlGQUNYQyxjQUFjSCxTQUFTRSxXQUN2QkUsT0FBT0YsVUFDUEcsVUFBVUYsYUFDVkcsV0FBVyxPQUNYQyxPQUFPQyxtQkFBSSxDQUFDQywwQkFBMEIsQ0FBQ0wsTUFBTUMsU0FBU0MsV0FDdERJLGFBQWFILE1BQU8sR0FBRztJQUU3QixPQUFPRztBQUNUIn0=
|
package/package.json
CHANGED
|
@@ -6,7 +6,7 @@ import { fileSystemUtilities } from "necessary";
|
|
|
6
6
|
const { readFile } = fileSystemUtilities;
|
|
7
7
|
|
|
8
8
|
export function furtleFileFromNothing() {
|
|
9
|
-
const filePath = "/Users/djalbat/Logic/first-order-logic/
|
|
9
|
+
const filePath = "/Users/djalbat/Logic/first-order-logic/Functions/Free and bound variables.ftl",
|
|
10
10
|
fileContent = readFile(filePath),
|
|
11
11
|
path = filePath, ///
|
|
12
12
|
content = fileContent, ///
|