Discrete Mathematics – 1458558

Discrete Mathematics

Name

Institution

                                                                     Question 1.                                                                    

We will proceed by induction on the numbers E of edges in the tree. If E (T) = 1, then we know exactly what T looks like, so we find that V (T) – E (T) = 2-1 = 1 as required.

Hence suppose we know the result for any tree with no more than n edges, and let T be a tree with nt, edges. Let T’ be a subtree of T with n edges. Then V (T) – E (T’) = 1. Now clearly we have E (T) = E (T’) + 1. On the other hand, the edge in T T’ must share at least one vertex with T’ (because otherwise T would not be connected), but cannot share both with it (because otherwise there would be a loop formed by the new edge and any path in T’ joining the two vertices to which the ends of the new edge are attached (such a path exists because T’ is connected). Thus V (T) = V (T’) + 1 the result follows.

The existence of such a subtree requires some just fication in particulars. We cannot just remove any old edge, for this may disconnect T, so that T’ is not a tree, but rather a disjoint union of two trees. To show that it exists we need to show that there is at least one edge is T that has a free vertex; i.e. a vertex not contained in any other edge. To find it, pick any edge E, if it has a free vertex, you are done. If not, move to an adjacent edge E, repeat being role never to reverse direction. These are only n + 1.

Question 2.

(a).

 = 1  

k  n Now for k = n +1

 =  +      +

                            =  

                            =  *     *  

                            = 

Hence,      the result is thus by induction.

(b).

  /      

When k = 1, the result is thus, /

(Hence, we use the identity of Fibonacci number for n m  II, n m  1,  +,  = )

Now suppose we assume that  divides  and we prove that  divides                          

 =  – n+1  + – n -1

            =  +

           =  + q  by (induction hypothesis)

           = [  + q ]

Hence  divides  Therefore, is true for all  by induction.

(c)

 =

n = 0, then,  +  +  +

                  = 1*1 + 1*2 + 2*3 + 3*5

                  = 1+2+6+15

                  = 0*1 + 1*1 + 1*2 + 2*3

 =

n = 1, then,  +  +  +

                  = 0+1+2+6 = 9 =

Hence because is valid we assume that;

 =  and show that

 =

 =  +  +

                     =  +  +

                     =  +

                     =

                     =

Hence the result is true by induction.

Question 3.

(a)

p(n) = + )

Step-1

p(1) = + )

p(1) = +16)

p(1) = +16)

p(1) = ) is divided by 241          

p(1) is true

Step-2

Let p(k) is true

p(k) = + ) is divided by 241

We shall now show that p(k+1) is true. It is shown that + -1

p(k+1) = +

            = +

            = .15+ – +

            = 15 + + -15

            = 15 + +

            = 15 + + *241

Both terms are divisible by 241 so their sum is also divided by 241

Hence, p(k+1) is true

Therefore,  p(n) is true for all n

(b)

   1+nx +  , hold for n 3

p(n) =    1+nx +  

p(3) =    1+3x +  

        =  + 3  + 3n  1+3n +3

p(3) is true for n = 3

Step-2

Put n = k

p(k) =    1+kx +  is true

We shall now show that p(k+1) is true. It is shown that    1+ (k+1)n +  is true.

p(k) is true,

   1+ kn +   multiply (1+n) on both sides,

   (1+ kn +  ) (1+n)

   1+ (k+1)n +     +

Therefore;

   (1+ (k+1)n + )

 Given is right for )

So, given declaration is correct for all

(c)

p(n) =  + , given that (x + ) is an integer.

Step i

p(1) =(  +  = (x + )

p(1) is correct

Step ii

Let the given declaration is correct for h = k

p(k) =(  +  is an integer

We shall now show that p(k+1) is true

p(k+1) =(  +

            =  +  +  +

            = x  +  +

p(k+1) is correct

Given declaration is correct for all n

Question 4

(a)

In order to compute the value of f (5)

n = 5 (here)

So,

f (0) = -1

f (1) = 0

f (n) = n.f (n-1) +  

f (2) = 2.f (1) +

        = 2*0 – (-1)2

        = 1

f (3) = 3.f (2) +

        = 3

f (4) = 4.f (3) +

        = 4*3 + (1)2

        = 13

f (5) = 5.f (4) +

        = 5*13 + (3)2

        = 74

f (5) = 74

(b)

g (5, -1, 0, 0) =?

g (0, m, x, k) =m

g (n, m, x, k) =g (n-1, x, (k+2)x +m2, k+1) 

g (5, -1, 0, 0) =g (4, 0, 1, 1)

We will compute the corresponding value of m for which n = 0

 g (4, 0, 1, 1) =g (3, 1, 3, 2) for n = 4, x = 1, m = 0, k = 1

g (3, 1, 3, 2) =g (2, 3, 13, 3)

    n  m  x k

g (2, 3, 13, 3) =g (1, 13, 74, 4)

    n  m  x k

g (1, 13, 74, 4) =g (0, 74, 613, 5)

    n  m  x k

Now on comparing it with base case

for n = 0

g (0, m, x, k) =m

g (0, 74, 613, 5) = 74

Therefore;

g (5, -1, 0, 0) = 74 all the computation give

(c)

To evaluate the expansion of

g (n, m, x, k) for some fixed natural numbers n, m, x, k we require (n-1) computations on steps and then finally use base step case for the computations.

As in (b) for n = 5, four computation steps were required.

(d)

First, we need to know what recursive function theory which is a functional approach to computation. Each computational theory start with computation is described in term of what is to accomplished instead of how to accomplish g may be written as g( o) = F( ),

g( , n+1) = H( ,n,g( ,n)) this is exactly what is formed hence, we say that g is obtained from F and H by the permutive recursive restating the above we get formal. 

(e)

Definition; permutive recursion

For k, o a function

f NK+1  Nm

Is said to be constructed using permutive from the function

 f( , o) = g( ,)

A function f(n) is permutive recursive function if and only (f) either is one of the initial function.

(f)

For h(n, m, r, k) = h(n-1, r, (k+2)r + m2,k+1)

n!  1n

Multiply both sides with (n+1) and we then know

(n+1) h(n, m, r, k)  h(n-1, r, (k+2)r + m2,k+1)

Note that (n+1)  2, so for sure (n+1)2n we can therefore conclude that

(n+1)!  2n+1

Thus we have proved

h(n, m, r, k) = h(n-1, r, (k+2)r + m2,k+1)

(g)

Functions h and g are equal because they have same the same domain and codomain i.e. h(a) = g(a)

(h)

In this function dominion and codomain are the set means (the natural number)

(i)

Expression in form of g(n, -1, 0, 0) cannot be used in coding because it is in conical form.