diff --git a/xml/chapter3/section3/subsection4.xml b/xml/chapter3/section3/subsection4.xml index 9d5ca6f62..311d55674 100755 --- a/xml/chapter3/section3/subsection4.xml +++ b/xml/chapter3/section3/subsection4.xml @@ -570,21 +570,6 @@ function logical_and(s1, s2) { } - - logical_or - -function logical_or(s1, s2) { - return s1 === 0 && s2 === 0 - ? 0 - : s1 === 0 || s1 === 1 - ? s2 === 0 || s2 === 1 - ? 1 - : error(s2, "invalid signal") - : error(s1, "invalid signal"); -} - - - @@ -673,12 +658,32 @@ function and_gate(a1, a2, output) { and_gate. - - or_gate - get_signal - after_delay - logical_or - + + + diff --git a/xml/chapter3/section3/subsection5.xml b/xml/chapter3/section3/subsection5.xml index ab5b57998..c20841f95 100755 --- a/xml/chapter3/section3/subsection5.xml +++ b/xml/chapter3/section3/subsection5.xml @@ -1561,6 +1561,53 @@ const answer = v_prod(v_sum("a", "b"), v_sum("c", "d")); expression-oriented style in terms of the imperative implementation, it is very difficult to do the converse. propagation of constraints