Talk:Ternary logic: Difference between revisions

m
m (→‎another ternary truth table: added indentations.)
 
(13 intermediate revisions by 6 users not shown)
Line 7:
 
: On first reading, it seems like you are implementing an analogue of the cmp function from C and C based languages. Or am I completely misunderstanding? --[[User:Thundergnat|Thundergnat]] 11:03, 26 August 2011 (UTC)
 
: It's entirely possible (and probably κῦδος-worthy) to produce a terminating solution of the Halting problem in ternary logic; anything where your code can't definitely figure it out within some reasonable bound on effort becomes a “maybe”. We know we can do this: we can exhibit examples with minimal effort. –[[User:Dkf|Donal Fellows]] 12:45, 8 September 2011 (UTC)
:: Certainly -- the simplest implementation would be code that always returns "maybe". Going deeper would require an implementation which handles code in the language being used (which would have greatly varying complexity, depending on the target language). --[[User:Rdm|Rdm]] 12:49, 8 September 2011 (UTC)
 
==Task structure==
Line 31 ⟶ 34:
 
Note: ⊃ is the same as → and ⇒ operations. c.f. [[wp:List of logic symbols|List of logic symbols]]
 
Also ⇔, ≡ and ↔ are equivalent.
Also ⇔, ≡ and ↔ are "equivalent", '''and''' equivalent to each other and to '''if and only if''' and '''iff'''.
 
BTW: the operators /\ and \/ were originally part of the [[wp:C programming language|C programming language]], they appear to be borrowed from the ALGOL ∧ and ∨ operators. Indeed the character "\" was included in ASCII for this specific purpose.
 
[[User:NevilleDNZ|NevilleDNZ]] 04:04, 27 August 2011 (UTC)
 
== Any need for this task to remain draft? ==
 
By example count, diversity and clarity, it seems like it's reasonably well-understood. --[[User:Short Circuit|Michael Mol]] 19:19, 7 September 2011 (UTC)
 
== Variable_truthfulness ==
 
I feel the C [[Ternary_logic#Variable_truthfulness|Variable Truthfulness]] code warrants it's own Task Page. This is because the task:
* Is sufficiently different to warrant a different page.
* Is not <u>Ternary logic</u> ''per se'', rather it might actually be a '''super set''' of some form.
* Would benefit from some citations and/or link to actual theory.
* Needs to go through "draft" phase to determine an appropriate test case.
* Is sufficiently interesting to warrant a different page.
 
[[User:NevilleDNZ|NevilleDNZ]] 09:57, 10 October 2011 (UTC)
: Well, for now it doesn't have a good place to go to. As to not being ternary logic per se, it can be reduced to one pretty easily though: define 1 as TRUE, 0 as FALSE, and anything in between as MAYBE, then the operator tables can be reproduced exactly. Since the "variable truths" are just [[wp:Probability|probabilities]], I'm not sure what more refs are needed without making it appear more complicated than necessary.
: This C entry was sort of targeting the kudos part of the task. To me, the most interesting place to use a "maybe" would be at the control flows (<code>if3</code>), but that requires knowledge of ''how'' ambiguous such an ambiguity is, hence the numeric values. --[[User:Ledrug|Ledrug]] 14:51, 13 October 2011 (UTC)
 
<s>I suggest: A good place for it to go to is as a "Draft Task" with appropriate details of what the task is rather then complicate [[Ternary_logic]]. Also: A brief description of "variable truths" (or even [[wp:Qubit|Qubit]]s) might help the draft task.</s> On rethinking, your point about the ''"C entry was sort of targeting the kudos"'' is about right. Indeed I have yet to see a more pratical use for Ternary Logic. ¢ However - maybe - [[wp:Balanced_ternary|Balanced Ternary]] Arithmetic appears to have an advantage, as Binary Addition is takes 58% more iterations, and Binary Multiplication takes 150% more iterations then Balanced Ternary. ¢
 
[[User:NevilleDNZ|NevilleDNZ]] 09:16, 14 October 2011 (UTC)
: Eh which C code are we talking about? This topic was about using floating point to represent probability (or so I thought), so the natural thing is using range 0 to 1. I don't see how -1 got in here? --[[User:Ledrug|Ledrug]] 11:56, 14 October 2011 (UTC)
 
==another ternary truth table==
 
I found another ternary truth table that I used for validation of some of the other functions for the REXX example (which shows more functions) at:
::: http://www.scribd.com/doc/78370674/31/A-6-2-AND-XOR-OR-XNOR-NAND
:::::: ''Ternary Computing Testbed 3-Trit Computer Architecture'' &nbsp; by &nbsp; Jeff Connelly
:::::: Computer Engineering Department &nbsp; &nbsp; &nbsp; August 29<sup>th</sup>, 2008
:::::: which is on page 59: &nbsp; &nbsp; A.6.2. &nbsp; &nbsp; AND, XOR, OR, XNOR, NAND
:::::::::::::::::::: -- [[User:Gerard Schildberger|Gerard Schildberger]] 06:48, 3 March 2013 (UTC)