Wednesday, 20 May 2015

DISCRETE STRUCTURES

DISCRETE STRUCTURES

Q. A relation R in {1,2,3,4,5,6} is given by {(1,2),(2,3),(3,4),(4,4),(4,5)}. This relation is :

(A) reflexive

(B) symmetric

(C) transitive

(D) not reflexive, not symmetric, and not transitive

 

Ans:- D

Explanation:-

i) Reflexive : A relation R on a set A is reflexive if aRa for every a ϵ A, that is, if (a,a) ϵ R for every a ϵ A.

In the above relation, since the set contains the six elements 1,2,3,4,5 and 6. A relation R on A is reflexive if it contains the six pairs (1,1),(2,2),(3,3),(4,4),(5,5) and (6,6). Since the relation only contains (4,4) and not the rest, it is not reflexive.

ii) Symmetric : A relation R on a set A is symmetric if whenever aRb then bRa, that is if whenever (a,b) ϵ R then (b,a) ϵ R. R is not symmetric if there exists a,b ϵ A such that (a,b) ϵ R but (b,a) does not belong to R.

The above relation is not symmetric because (1,2) ϵ R but (2,1) does not belong to R. The same argument holds good for (2,3),(3,4) and (4,5) as well. So, the relation is not symmetric.

iii) Transitive: A relation R on a set A is transitive if whenever aRb and bRc then aRc, that is, whenever (a,b),(b,c) ϵ R then (a,c) ϵ R. The above relation is not transitive because (1,2), (2,3) ϵ R but (1,3) does not belong to R.

S, the above relation is not reflexive, not symmetric, and not transitive.

 

 

Thursday, 14 May 2015

JUNE 2012 - PAPER III - COMPUTER GRAPHICS

JUNE 2012 – PAPER III

 

47. The colour of an object is largely determined by its diffuse reflection coefficient. If Kd = (0.8, 0.4, 0), then what shall be the colour of the object, if the light used is blue and magenta ?

(A) White and Red

(B) Red and Blue

(C) Black and White

(D) Black and Red

Ans:- D

Explanation:-

The color of an object is largely determined by its diffuse reflection coefficient(kd). Kd is assigned a value between 0.0 and 1.0.

0.0  – for dull surface that absorbs almost all light

1.0  for shiny surface that reflects almost all light.

 

You should understand the range of kd and its meaning very clearly. For colored surfaces, there are three kd values, one for red, green and blue.

Let us consider a polygon with diffuse color(1,0,0). It reflects all of the red light it is hit with, and absorbs all of the blue and green(because red has a value 1, and green and blue has a 0).

If this red polygon is hit with a white light it will appear red. If it is hit with a blue light, or a green light, or an aqua light it will appear black(as those lights have no red component). If it is hit with a yellow light or a purple light it will appear red(as the polygon will reflect the red component of the light).

 

The kd value given in the equation is kd=(0.8,0.4,0)

What shall be the color of the object if the light used is blue and magenta?. That is the question.

Let us consider the first color. Blue light falls on the object. But the blue component of kd is 0. It means that color is going to be completely absorbed by the object and it will appear black. So, when blue light falls on the object, the object will appear black.

 

Let us consider the next color. Magenta light falls on the object. Magents is a violet-red or purplish-red color. It is midway between red and blue. Since red has a high kd value, it will get reflected more and so the color of the object will be Red.

 

So, the color of the object will be Black and Red. The correct option is D.

 

 

59. The perspective projection matrix, on the view plane z = d where the centre of projection is the origin (0, 0, 0) shall be

 

(A) 0 0 0 d

0 0 d 0

0 d 0 0

d 0 0 1

 

(B)  d 0 0 0

0 d 0 0

0 0 d 0

0 0 1 0

(C) 0 0 0 d

0 0 d 0

0 d 0 0

1 0 0 0

(D) d 0 0 0

0 d 0 0

0 0 d 0

0 0 0 1

 

Ans:- B

 

Explanation:-

 

A perspective transformation is determined by prescribing a center of projection and a view plane. The view plane is determined by its view reference point R0 and view plane normal N.

The projection transformation as a matrix

 

PerN,R0 = d0 0 0 0

0 d0 0 0

0 0 d0 0

n1 n2 n3 0

 

The plance z = d is parallel, to the xy plane. Thus the view plane normal vector N is the same as the normal vector K to the xy plance, that is N=K. Choosing the view reference point as R0(0,0,d), we can identify the parameters

N(n1,n2,n3) = (0,0,1)

R0(x0,y0,z0)=(0,0,d)

 

So,

d0 = n1x0 + n2y0 + n3z0 = d

 

and so the projection matrix is

PerK,R0 = d 0 0 0

0 d 0 0

0 0 d 0

0 0 1 0

So, the correct answer is option B. The same problem is solved in the Schaum’s outlines, Computer Graphics book(pg. no. 138).