Write the predicate formulas for the given predicates

  • Comp Sci
  • Thread starter favq
  • Start date
  • Tags
    Formulas
In summary, you have attempted to express various mathematical concepts and properties using logical predicates and quantifiers, such as equality, multiplication, addition, primes, even numbers, twin primes, and the infinitude of twin primes. These attempts involve breaking down the expressions into smaller components and using logical operators and quantifiers to connect them.
  • #1
favq
8
0
Homework Statement
In this problem we’ll examine predicate logic formulas where the domain of discourse is [itex]\mathbb{N}[/itex]. In addition to the logical symbols, the formulas may contain ternary predicate symbols A and M, where:

[itex]A(k,m,n)[/itex] means [itex]k = m + n[/itex]

[itex]M(k,m,n)[/itex] means [itex]k = mn[/itex]


For example, a formula [itex]Zero(n)[/itex] meaning that n is zero could be defined as


[itex]Zero(n)=A(n,n,n)[/itex]


Having defined Zero, it is now OK to use it in subsequent formulas. So a formula for Greater(m,n) meaning m > n could be defined as

[itex]Greater(m,n) = \exists k \left( \neg \left( Zero(k) \right) \wedge A(m,n,k) \right)[/itex]

This makes it OK to use Greater in subsequent formulas.

Write predicate formulas using only the allowed predicates A, M that define the following predicates:

(a) [itex]Equal(m,n)[/itex] meaning that [itex]m = n[/itex].

(b) [itex]One(n)[/itex] meaning that [itex]n = 1[/itex].

(c) [itex]n = i(m \cdot j + k^2)[/itex].

(d) [itex]Prime(p)[/itex] meaning [itex]p[/itex] is a prime number.

(e) [itex]Two(n)[/itex] meaning that [itex]n = 2[/itex].

(f) [itex]Even(n)[/itex] meaning [itex]n[/itex] is even.

(g) (Goldbach Conjecture) Every integer [itex]n \geq 4[/itex] can be expressed as the sum of two primes.

(h) (Fermat's Last Theorem) Now suppose we also have

[itex]X(k,m,n)[/itex] means [itex]k = m^n[/itex]

Express the assertion that there are no positive integer solutions to the equation:

[itex]x^n + y^n = z^n[/itex]

when [itex]n > 2[/itex].

(i) (Twin Prime Conjecture) There are infinitely many primes that differ by two.
Relevant Equations
[itex]A(k,m,n)[/itex] means [itex]k = m + n[/itex]
[itex]M(k,m,n)[/itex] means [itex]k = mn[/itex]
Attempts for each item:

a) Since [itex]m=n[/itex] if and only if [itex]m \leq n[/itex] and [itex]n \leq m[/itex]:

[itex]Equal(m,n) = \left( \neg Greater(m,n) \right) \wedge \left( \neg Greater(n,m) \right)[/itex]b) Any natural number [itex]n[/itex] multiplied by 1 is equal to [itex]n[/itex], so:[itex]One(n) = \forall k \left(M(k,n,k)\right)[/itex]c) What I've attempted here is to break down the expression as follows: [itex]n = i \cdot x_1[/itex] for some [itex]x_1[/itex], [itex]x_1 = (x_2 + x_3)[/itex] for some [itex]x_2[/itex] and some [itex]x_3[/itex], [itex]x_2 = (m \cdot j)[/itex] for some [itex]m[/itex] and some [itex]j[/itex], and [itex]x_3 = k^2[/itex]. So the attempt becomes:

[itex]C(n) = \exists i \exists x_1 \exists x_2 \exists x_3 \exists j \exists k \left(M(n,i,x_1) \wedge A(x_1,x_2,x_3) \wedge M(x_2,m,j) \wedge M(x_3,k,k)\right)[/itex]

d)
There are two ways that seem to work:

[itex]Prime(p) = \forall a \forall i (One(a) \rightarrow \left( \neg Equal(i,a) \wedge \neg Equal(i,p) \rightarrow \neg \exists k \left( M(p,i,k) \right) \right)[/itex]
[itex]Prime(p) = \forall i \exists a (One(a) \wedge \left( \neg Equal(i,a) \wedge \neg Equal(i,p) \rightarrow \neg \exists k \left( M(p,i,k) \right) \right)[/itex]

e) There are two ways that I thought of that seem to work for this one, based on the fact that 2 = 1 + 1:

[itex]Two(n) = \exists k \left( One(k) \wedge A(n,k,k) \right)[/itex]
[itex]Two(n) = \forall k \left( One(k) \rightarrow A(n,k,k) \right)[/itex]

f)
[itex]Even(n) = \exists a \exists b \left( Two(a) \wedge M(n,a,b) \right) [/itex]

The idea is that, if there exists a and b such that a is the number 2, and n = a*b, then n is even.

g) My attempt:

[itex]\forall n \forall a \left( Four(a) \wedge \left(Greater(n,a) \lor Equal(n,a)\right) \wedge Even(n) \rightarrow \exists p_1p_2\left( Prime(p_1) \wedge Prime(p_2) \wedge A(n,p_1,p_2) \right ) \right)[/itex]

h)

[itex]\forall n \forall a \left( Two(a) \wedge Greater(n,a) \rightarrow \left( \neg \exists x,y,z,x_n,y_n,z_n \left ( X(x_n,x,n) \wedge X(y_n, y, n) \wedge X(z_n, z, n) \wedge A(z_n,x_n,y_n) \right ) \right ) \right)[/itex]

i)

First, define a predicate that tests whether two numbers m and n are twin primes by checking that they are primes and they differ by 2:

[itex]TwinPrime(m,n) = Prime(m) \wedge Prime(n) \wedge \exists t \left( Two(t) \wedge \left( A(q,n,t) \lor A(n,q,t) \right) \right )[/itex]

Then, the conjecture could be expressed as below:

[itex]\left( \exists n,m \left( TwinPrime(n,m) \right) \right) \wedge (\forall n,m \left( TwinPrime(n,m) \rightarrow \exists q,p \left ( Greater(q,n) \wedge Greater(p,m) \wedge TwinPrime(q,p) \right ) \right ) )[/itex]

As an attempt to express that there are infinitely many twin primes, I'm stating two things: (1) there exist two numbers that are twin primes, (2) if there are two numbers m, n that are twin primes, there are two numbers p,q that are greater than m,n and are also twin primes.

Could someone please verify if these attempts make sense?
 
Last edited:
Physics news on Phys.org
  • #2
Yes, your attempts make sense. They look good and capture the conditions that you are trying to express in each item.
 

What is a predicate formula?

A predicate formula is a statement that contains a predicate, which is a function that takes in one or more inputs and returns a truth value (either true or false). It is used in mathematical logic to represent relationships between variables.

How do you write a predicate formula?

To write a predicate formula, you first need to identify the predicate and its variables. Then, you can use logical symbols such as AND (&), OR (|), and NOT (~) to represent logical operations. For example, "x is greater than y" can be written as "x > y".

Can you give an example of a predicate formula?

Yes, for the predicate "x is a prime number", the formula would be "P(x) = x is only divisible by 1 and itself". In this case, P(x) is the predicate function and x is the input variable.

How do you use predicate formulas in science?

Predicate formulas are used in science to represent logical relationships between variables in experiments and theories. They are especially useful in fields such as physics and biology, where complex relationships can be represented in a concise and precise manner.

What is the difference between a predicate and a proposition?

A predicate is a function that takes in one or more inputs and returns a truth value, while a proposition is a statement that can be either true or false. In other words, a proposition can be seen as a simple predicate formula with no variables.

Similar threads

Replies
3
Views
736
Replies
1
Views
164
Replies
5
Views
391
  • Math Proof Training and Practice
Replies
10
Views
1K
Replies
11
Views
1K
  • Calculus and Beyond Homework Help
Replies
9
Views
797
  • Calculus and Beyond Homework Help
Replies
3
Views
553
Replies
9
Views
923
Replies
1
Views
2K
  • Calculus and Beyond Homework Help
Replies
7
Views
1K
Back
Top