Skip to main content

Questions tagged [logic]

For challenges pertaining to mathematical logic and boolean algebra.

13 votes
15 answers
1k views

If A and B are two nonempty sets (so two lists that have no repetition, where order is not important), a set f is a function from set A to set B, if and only if f is a subset of AxB if x∊A then there ...
Rosario's user avatar
  • 2,020
5 votes
2 answers
238 views

Say there are three multisets A, B, C. An infix condition has form <ON|FACING|NEAR> <a multiset> where ON requires ...
l4m2's user avatar
  • 32.9k
1 vote
1 answer
323 views

Taken from lesswrong.com Once upon a time, there was a court jester who dabbled in logic. The jester presented the king with two boxes. Upon the first box was inscribed: "Either this box ...
NeRoboto's user avatar
  • 268
7 votes
2 answers
349 views

In the smallest amount of steps, prove $$(p\Longrightarrow q)\iff\lnot p\lor q$$ We base the proof system on this website. The related functionalities are: Assumption. Assume that some statement is ...
Number Basher's user avatar
19 votes
23 answers
2k views

Given the truth table of a non-trivial symmetric 2-input logic gate, output its name. The 6 possible input/output pairs are: ...
aeh5040's user avatar
  • 2,082
8 votes
0 answers
496 views

This originally came from Give the best Chaitin incompleteness bound, but I realized that there was a fragment of this problem which still potentially gives a good coding challenge. First Order Logic ...
Charles Wang's user avatar
8 votes
0 answers
279 views

This was originally a pure mathematics question, but I think I've got the best chance for an answer here. The Challenge For concreteness, consider Peano Arithmetic (PA). For some language L of your ...
Charles Wang's user avatar
2 votes
2 answers
397 views

The Quine-McCluskey algorithm merges disjunctors in a disjunction like $$ \lnot x_0 \land \lnot x_1 \land \lnot x_2 \land \lnot x_3 \lor\\ x_0 \land \lnot x_1 \land x_2 \land \lnot x_3 \...
Roman Czyborra's user avatar
16 votes
26 answers
2k views

Your task, should you choose to accept it, is to take two input values \$a\$ and \$b\$, where \$a\$ and \$b\$ are in the set \$\{T, U, F\}\$, and compute and output their logical conjunction in a ...
Qaziquza's user avatar
  • 1,693
14 votes
5 answers
845 views

Please help me automate my discrete mathematics homework. Given a valid propositional formula, check if it is an instance of one of Łukasiewicz's axioms. Here's how it works. A term can be defined ...
KeizerHarm's user avatar
  • 1,373
3 votes
3 answers
1k views

I'm currently working with a branchless language which does not have native Less-Than, Greater-Than or Equal-To functions. I do however have min, ...
Eliseo D'Annunzio's user avatar
26 votes
21 answers
6k views

Our boolean operators are AND, OR, XOR, NAND, ...
simonalexander2005's user avatar
14 votes
8 answers
1k views

The challenge is to golf a program that checks if a statement of propositional calculus/logic is a logical tautology (i.e. it is true for all possible values of the variables). Input Input formulas ...
nph's user avatar
  • 1,446
12 votes
2 answers
476 views

Background Mathematicians are interested in all kinds of algebraic structures, e.g. groups, rings, boolean algebras. Generally, we have several operations (addition, multiplication, meet, join, etc.), ...
Trebor's user avatar
  • 805
22 votes
1 answer
875 views

Modern mathematics has been formalised using set theory by various systems of axioms. Zermelo Frankel set theory with the axiom of choice (ZFC) forms an intuitive set of axioms and is hence most ...
ghosts_in_the_code's user avatar

15 30 50 per page