1 / 18

מבנה מחשבים

מבנה מחשבים. תרגול מספר 4. Definition: A Boolean function f :{0,1} n  {0,1} is monotone if x  y  f ( x )  f ( y ) (where x  y means : for every i x i  y i ). Prove the following claim:

slora
Download Presentation

מבנה מחשבים

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. מבנה מחשבים תרגול מספר 4

  2. Definition: A Boolean function f :{0,1}n{0,1} is monotone if xy f (x)f ( y) (where x y means : for every i xiyi). Prove the following claim: f :{0,1}n{0,1} is monotone iff f can be implemented by a combinational circuit that contains only AND-gates and OR-gates.

  3. Sum of products

  4. Associative Boolean functions A Boolean function f : {0,1}2 →{0,1} is associative if f(f(1,2),3) = f(1,f(2,3)) for every 1,2,3 {0,1}

  5. Question 3.3 Design a zero-tester defined as follows. Input: x[n-1 : 0]. Output: y Functionality: y = 1 iff x[n-1 : 0] = 0n: 1. Suggest a design based on an or-tree. 2. Suggest a design based on an and-tree. 3. What do you think about a design based on a tree of nor-gates?

  6. balanced partition Two positive integers a,b are a balanced partition of n if: • a+b = n, • Max{ }

  7. Question 3.7 Prove that if n = 2k-r, where 0r<2k-1, then any partition in which 2k-1-r  a  2k-1 and b = n - a is a balanced partition.

  8. Question 3.8 Consider the following recursive algorithm for constructing a binary tree Tn with n2 leaves. Prove that the depth of Tn is . 1. The case that n2 is trivial (two leaves connected to a root). 2. If n > 2, then let a, b be balanced partition of n. 3. Compute trees Ta and Tb. Connect their roots to a new root to obtain Tn.

More Related