kripke: more symbols

This commit is contained in:
2025-02-22 11:19:22 +09:00
parent d8e03512ad
commit adfae65138
2 changed files with 24 additions and 6 deletions

View File

@@ -50,17 +50,35 @@ const generateAlt = (words: string[]) =>
export const topSymbols = ["", "T", "1", "\\top", "top"];
export const botSymbols = ["⊥", "F", "0", "\\bot", "bot"];
export const notSymbols = ["¬", "~", "\\neg", "\\lnot", "not"];
export const boxSymbols = ["□", "[]", "!", "L", "\\Box", "box"];
export const diamondSymbols = ["⋄", "<>", "?", "M", "\\Diamond", "dia"];
export const boxSymbols = ["□", "◻", "[]", "!", "L", "\\Box", "box"];
export const diamondSymbols = [
"◇",
"◊",
"♢",
"⋄",
"<>",
"?",
"M",
"\\Diamond",
"dia",
];
export const andSymbols = ["∧", "^", "&", "\\wedge", "\\land", "and"];
export const orSymbols = ["", "v", "|", "\\vee", "\\lor", "or"];
export const toSymbols = ["→", "->", ">", "\\rightarrow", "\\to", "to"];
export const eqSymbols = ["↔", "<->", "=", "\\leftrightarrow", "\\equiv", "eq"];
export const toSymbols = ["→", "->", "⊃", ">", "\\rightarrow", "\\to", "to"];
export const eqSymbols = [
"↔",
"<->",
"≡",
"=",
"\\leftrightarrow",
"\\equiv",
"eq",
];
export const lParenSymbols = ["(", "\\left"];
export const rParenSymbols = [")", "\\right"];
const lexer = buildLexer([
[true, /^[pqrs]/g, TokenKind.PropVar],
[true, generateAlt(propVars), TokenKind.PropVar],
[true, generateAlt(topSymbols), TokenKind.Top],
[true, generateAlt(botSymbols), TokenKind.Bot],
[true, generateAlt(notSymbols), TokenKind.Not],

View File

@@ -70,7 +70,7 @@ export const unicodeSymbols: Symbols = {
top: "",
bot: "⊥",
box: "□",
diamond: "",
diamond: "",
not: "¬",
and: "∧",
or: "",