CircuitGate Type
This type provides basic gates for implementing arithmetic circuits. In particular, we have:
- AND(x1,x2) = x1∧x2
- XOR(x1,x2) = x1⊕x2
- OR(x1,x2) = x1∨x2
- HA(x1,x2) = [|x1⊕x2;x1∧x2|]
- FA(x1,x2,x3) = [|x1⊕x2⊕x3;x1∧x2∨x3∧(x1⊕x2)|]
- PG(g1,p1,g2,p2) = [|p2∧p1;g2∨(p2∧g1)|]
- MX(c,x0,x1) = [|(c?x1[0]:x0[0]);...;(c?x1[n]:x0[n]);|]
- SW(c,x0,x1) = [|(c?x1[0]:x0[0]);...;(c?x1[n]:x0[n]); (c?x0[0]:x1[0]);...;(c?x0[n]:x1[n])|]
Union cases
Union case | Description |
Full Usage:
AND(string, string)
Parameters:
string
Item2 : string
|
|
Full Usage:
FA(string, string, string)
Parameters:
string
Item2 : string
Item3 : string
|
|
Full Usage:
HA(string, string)
Parameters:
string
Item2 : string
|
|
Full Usage:
MX(string, string[], string[])
Parameters:
string
Item2 : string[]
Item3 : string[]
|
|
Full Usage:
NOT string
Parameters:
string
|
|
Full Usage:
OR(string, string)
Parameters:
string
Item2 : string
|
|
Full Usage:
PG(string, string, string, string)
Parameters:
string
Item2 : string
Item3 : string
Item4 : string
|
|
Full Usage:
SW(string, string[], string[])
Parameters:
string
Item2 : string[]
Item3 : string[]
|
|
Full Usage:
XOR(string, string)
Parameters:
string
Item2 : string
|
|
Instance members
Instance member | Description |
Full Usage:
this.IsAND
Returns: bool
|
|
Full Usage:
this.IsFA
Returns: bool
|
|
Full Usage:
this.IsHA
Returns: bool
|
|
Full Usage:
this.IsMX
Returns: bool
|
|
Full Usage:
this.IsNOT
Returns: bool
|
|
Full Usage:
this.IsOR
Returns: bool
|
|
Full Usage:
this.IsPG
Returns: bool
|
|
Full Usage:
this.IsSW
Returns: bool
|
|
Full Usage:
this.IsXOR
Returns: bool
|
|