Question: I have included the slides also for help. Question 1: For each of the following functions, show that it is primitive recursive. Use a relaxed

I have included the slides also for help.  I have included the slides also for help. Question 1: For
each of the following functions, show that it is primitive recursive. Use

Question 1: For each of the following functions, show that it is primitive recursive. Use a "relaxed" mathematical argument such as we did starting on slide 7 on February 26. You do not have to provide a precise proof as we did on the earlier slides, but you can if you like. In your arguments, you can use any functions that we have already shown in class to be primitive recursive without having to prove it again. (a) ged(xi, x2) (greatest common divisor; let us define that gcd(0, 0) 0) (b) -V (c) R,")-min(Here, min returns the smaller of its two inputs). (d) k(nz) s the number of twin primes whose smaller twin is greater than x, and less than X2. Twin primes are pairs of primes whose difference is two. For example, (3, 5) and (1, 13) are twin primes Example 3: h(x)-x! Here are the recursion equations: h(0) 1 h(t+1) h(t) s(t) This can be rewritten as: h(0) (n(t) h(t+1) g(t, h(t) where g(x1, x2) = s(x10 x2 , which can be written as: g(xl, x2) s(ul2(xl, x2)) u22(x1, x2). Multiplication is already known to be primitive recursive. Therefore. h(x) -x! is primitive recursive. Lecture 7: Primative Recunive Functions Some Primitive Recursive Functions In the following examples, we just show the recursive mechanism without developing the precise form of the recursion equations. Example 4: xy The recursion equations are: Febnuary 26, 2019Theery of Lecture 7: Primitive Recursive Punctions I Some Primitive Recursive Functions Example 5: The predecessor function p(x) It is defined as follows: p(x)= x-l if X 0 ifx=0 The recursion equations are: p(0) =0 Question 1: For each of the following functions, show that it is primitive recursive. Use a "relaxed" mathematical argument such as we did starting on slide 7 on February 26. You do not have to provide a precise proof as we did on the earlier slides, but you can if you like. In your arguments, you can use any functions that we have already shown in class to be primitive recursive without having to prove it again. (a) ged(xi, x2) (greatest common divisor; let us define that gcd(0, 0) 0) (b) -V (c) R,")-min(Here, min returns the smaller of its two inputs). (d) k(nz) s the number of twin primes whose smaller twin is greater than x, and less than X2. Twin primes are pairs of primes whose difference is two. For example, (3, 5) and (1, 13) are twin primes Example 3: h(x)-x! Here are the recursion equations: h(0) 1 h(t+1) h(t) s(t) This can be rewritten as: h(0) (n(t) h(t+1) g(t, h(t) where g(x1, x2) = s(x10 x2 , which can be written as: g(xl, x2) s(ul2(xl, x2)) u22(x1, x2). Multiplication is already known to be primitive recursive. Therefore. h(x) -x! is primitive recursive. Lecture 7: Primative Recunive Functions Some Primitive Recursive Functions In the following examples, we just show the recursive mechanism without developing the precise form of the recursion equations. Example 4: xy The recursion equations are: Febnuary 26, 2019Theery of Lecture 7: Primitive Recursive Punctions I Some Primitive Recursive Functions Example 5: The predecessor function p(x) It is defined as follows: p(x)= x-l if X 0 ifx=0 The recursion equations are: p(0) =0

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!