diff --git a/README.md b/README.md index 72e46df..8279fda 100644 --- a/README.md +++ b/README.md @@ -5,7 +5,7 @@ html:左中右结构 -左:点击添加命题变元和减少命题变元,命题变元个数由参数num存储,命题变元由布尔数组variable存储。(P,Q,R,S,T) +左:点击添加命题变元和减少命题变元,命题变元个数由参数num存储,命题变元由布尔数组variable存储。(26) 中:上方由用户输入合式公式,点击确定后在下方显示主析取范式和主合取范式 diff --git a/css/index.css b/css/index.css new file mode 100644 index 0000000..cf8b0c3 --- /dev/null +++ b/css/index.css @@ -0,0 +1,11 @@ +*{ + margin:10px; + border:0; + box-sizing: border-box; + border:1px solid red; +} + +body{ + display:flex; + justify-content: center; +} \ No newline at end of file diff --git a/html/index.html b/html/index.html index 1989878..ff1305f 100644 --- a/html/index.html +++ b/html/index.html @@ -1,12 +1,41 @@ - + - Document + 利用真值表求取主合取范式和主析取范式 + - +
+ +
显示命题变元数量
+ + + +
+ +
+
有关命题公式的输入 + +
+
确定
+
+
+

显示答案

+
+ +
+ +
+ + \ No newline at end of file diff --git a/js/index.js b/js/index.js new file mode 100644 index 0000000..a599b99 --- /dev/null +++ b/js/index.js @@ -0,0 +1,23 @@ +let input = "";//输入 +let res = "";//输出 +let num = 0; +let variable = new boolean[26]; +let resultOr ; +let resultAnd; +let isNot = new boolean[26]; + + +let cal = new function(){//监听确定按钮 + //清零操作 + if(eval(input));// resultOr.add(); + else ;//resultAnd.add(); + //……打印 +} + +let addX = new function(){ + num++; + //显示…… +} + +//let deleteX …… +