0% found this document useful (0 votes)
19 views

Mock-end_solution

Uploaded by

Varun Ambadi
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
19 views

Mock-end_solution

Uploaded by

Varun Ambadi
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 25

End semester Mock

Mathematics for Data Science - 1

1 Instructions:
ˆ There are some questions which have functions with discrete valued domains (such as
day, month, year etc). For simplicity, we treat them as continuous functions.

ˆ Notations:

• R= Set of real numbers


• N= Set of natural numbers

ˆ The set of natural numbers includes 0.

ˆ If a question has more than one answer, any one answer will be acceptable.

1
1. Let the curves represented by the three degree polynomials f (x), g(x), and h(x) meet at
points A and B. Given that

g(x) = x3 − 9x2 + 20x

h(x) = x3 − 7x2 + 10x


f (2) = 2g(2)
3f (7) = g(7)
Find the value of f (10). (NAT)

Solution:
Given,
g(x) = x3 − 9x2 + 20x = x(x2 − 9x + 20) = x(x − 5)(x − 4)
h(x) = x3 − 7x2 + 10x = x(x2 − 7x + 10) = x(x − 5)(x − 2)
It is clear that A ≡ (0, 0) and B ≡ (5, 0). If curve represented by f (x) passes through
these two points, then 0 and 5 are the X− intercepts of f (x). And we can write

f (x) = αx(x − 5)(x − β)

Now
f (2) = 2g(2) =⇒ α × 2(−3)(2 − β) = 2(23 − 9 × 22 + 20 × 2)
=⇒ −6α(2 − β) = 24
=⇒ α(2 − β) = −4 ..............(i)
And
3f (7) = g(7)
=⇒ α(7 − β) = 1 ..............(ii)
Solving (i) and (ii)
α = 1, β = 6
f (10) = 10(10 − 5)(10 − 6) = 200

2
2. Suppose Dijkstra’s algorithm is run on the graph below, starting at node A. In what
order do the shortest distances to the other vertices get finalized? (MCQ)
0
A A

1 3 1 3

2 2
B C 1 B C 3

3 3
6 4 6 4

E D 7 E D 4
4 4

3 1 3 1

F F
5
Options:

1. A,C,B,D,E,F
2. A,C,B,D,F,E
3. A,B,C,D,E,F
4. A,B,C,D,F,E

Answer: Option 4.

Solution: It is clear the order will be ABCDF E.

3
3. A company manufactures 10 chemicals c1 , c2 , c3 , ....c10 . A relation R is defined as

R = {(Xi , A) | A ⊂ {c1 , c2 , c3 , ....c10 }}

Elements of A belongs to the Xi (i ∈ {1, 2, 3, 4, 5}) type of hazardous chemicals and


any pair of elements from A is incompatible and would cause explosions if brought into
contact.

Given that,
(X1 , {c1 , c4 , c5 , c10 }), (X2 , {c2 , c3 , c5 }), (X3 , {c3 , c2 , c9 }), (X4 , {c4 , c2 , c7 }), and (X5 , {c5 , c8 , c10 })
are the elements of R.

As a precautionary measure the company wishes to partition its warehouse into com-
partments, and store incompatible chemicals in different compartments. What is the
least number of compartments into which the warehouse should be partitioned? (NAT)

Solution: If we draw a graph assuming nodes as the chemicals and two chemicals are
incompatible if they share an edge, then (One color edge represent one type of chemical,
for example red is for X1 and if an edge has more than one color, then take any color)

C7 C2

C1 C4
C6

C10 C5 C9

C3
C8

Now number of compartment can be found by using the method of coloring. The rectan-
gle in the middle shows that we need four different colors which means four compartment.

4
4. Seema wants to draw a rangoli on the floor. She has an idea of drawing some √ zig-zig
line. If she starts from a point named as (1), she draws a line segment of 2 2f t at an
angle of 45 with respect to drn2 and reach till point (2). From point (2) she draws a line
segment of 1f t towards the opposite direction of drn2. From there she again repeats the
above procedure to reach till point (3). If her final point is point (10) then what should
be the minimum length of floor in the direction of drn1? (Note that figure is not for
scale purpose and tan45 = 1.) (NAT)

• (10)

drn1
(3)
drn2
• • (2)
45

(1)

Solution: Let the coordinate of point (1) is (0, 0). The slope of line segment passing
from point (1) is 1 which means y = x would be the equation of line segment. Let
coordinate of (2) is (k, k) then the distance between (1) and (2)
√ √ √ √
k 2 + k 2 = 2 2 =⇒ k 2 = 2 2 =⇒ k = 2

This means (2) is 2 unit vertically away from (1). Similarly (3) is 2 unit away vertically
away form (2). Therefore, (3) is 2+2=2 × 2 unit away from (1) in direction of drn1.
Therefore, (10) would 9 × 2 = 18 unit away in drn1.
Answer: 18

5
5. Let for some fixed x > 0, p(x)q(x) = 1, where m > 1. Given that
2
p(x) = mlog5 x

q(x) = xlog5 m
Find the value of x. (NAT)

Solution: Given,
2
p(x)q(x) = mlog5 x × xlog5 m = 1
2
=⇒ mlog5 x × mlog5 x = 1
2 +log x)
=⇒ m(log5 x 5
=1
=⇒ log5 x2 + log5 x = 0
=⇒ log5 (x2 × x) = 0
=⇒ x3 = 1 =⇒ x = 1
Answer: 1

6
6. Let functions f (x) = x2 − 8, g(x) = log10 x, and h(x) = g(f (x)) respectively. Choose the
set of correct options regarding h(x). (MSQ)
√ √
1. Domain of h(x) will be (−∞, −2 2) ∪ (2 2, ∞).
2. Domain of h(x) will be (−∞, −3) ∪ (3, ∞).
√ √
3. If h(x) is positive then, x ∈ (−∞, −2 2] ∪ [2 2, ∞).
4. If h(x) is positive then, x ∈ (−∞, −3) ∪ (3, ∞).
5. h(x) has only one asymptote.
6. h(x) has at least three asymptotes.

Solution: If h(x) = g(f (x)) is defined, then first f (x) should be defined. As f (x) =
x2 − 8 is a quadratic function which is defined for x ∈ R. Now

h(x) = g(f (x)) = log10 (x2 − 8)

=⇒ x2 − 8 > 0
√ √
=⇒ x ∈ (−∞, −2 2) ∪ (2 2, ∞)
For asymptote, √
x2 − 8 = 0 =⇒ x = ±2 2
If we draw a rough diagram,

√ √
x = −2 2 x=2 2

Answer: Options 1 and 4.

7
7. Polynomial fit for the data given in the table recorded by a student is
x5 −5x3 +4x 5 −5x3 +4x
y = f (x) = log101 11log1001 101 + K5x

Find the value of K, so that SSE (sum squared error) will be minimum? (NAT)

x -2 -1 1 1 2
y 1 1 −1 1 1

Solution: Given,
x5 −5x3 +4x 5 −5x3 +4x
y = f (x) = log101 11log1001 101 + K5x

Calculating f (x) for given values of x,


0
f (−2) = log101 11log1001 101 +K50 = log101 11log1001 1 +K×1 = log101 110 +K = log101 1+K = 0+K = K
0
f (−1) = log101 11log1001 101 + K50 = K
0
f (0) = log101 11log1001 101 + K50 = K
0
f (1) = log101 11log1001 101 + K50 = K
0
f (2) = log101 11log1001 101 + K50 = K

Therefore,

SSE = (K − 1)2 + (K − 1)2 + (K + 1)2 + (K − 1)2 + (K − 1)2

SSE = 5K 2 + 2K(−1 − 1 + 1 − 1 − 1) + 5
SSE = 5K 2 − 6K + 5
−6
SSE will be minimum at K = − = 0.6
2×5
Answer: 0.6

8
8. Choose the option which has the most possible representation of function
1
f (x) =
1 + ex
(MCQ) [Marks:3]

f (x)

1.

f (x)

2.

9
f (x)

3.

f (x)

4.

Solution: Given,
1
f (x) =
1 + ex
Now
1
f (0) = >0
2
10
1
f (−1) = 1 > f (0)
1+ e
Answer: Option 2

11
9. Let f (x) and g(x) be two functions defined from R to R such that

4 2
x − 20x + 64
 if x ∈ (−∞, −4) ∪ (−2, 2) ∪ (4, ∞)
4 2
f (x) = −(x − 20x + 64) if x ∈ (−4, −2) ∪ (2, 4)

1 if x ∈ {−4, −2, 2, 4}

,
g(x) = log2 x
Find the value of f (g(4)) + g(f (0)) + g( f (3)
7
− 1). (NAT)

Solution: If we solve
f (g(4)) = f (log2 4) = f (2) = 1
In this case f (x) = 1. So f (2) = 1

Now
g(f (0)) = g(0 − 0 + 64) = log2 64 = 6
In this case f (x) = x4 − 20x2 + 64. So f (0) = 64

And
f (3) −(34 − 20 × 32 + 64) 35
g( − 1) = g( − 1) = g( − 1) = g(5 − 1) = g(4) = 2
7 7 7

Therefore,
f (3)
f (g(4)) + g(f (0)) + g( − 1) = 1 + 6 + 2 = 9
7
Solution: Answer: 9

12
10. Consider two sets A, B defined as A = {(a, b) ∈ R × R | |a − 3| < 1, |b − 3| < 1},
B = {(a, b) ∈ R × R | b − 1 ≤ (a − 3)2 }. Choose the correct option. (MCQ)

1. A ∪ B = B
2. A ∩ B = φ
3. A ∪ B = A
4. A ∩ B = B

Solution: Given,

A = {(a, b) ∈ R × R | |a − 3| < 1, |b − 3| < 1}

If

|a − 3| < 1 =⇒ (a − 3)2 < 1 =⇒ a2 − 6a + 9 < 1 =⇒ a2 − 6a + 8 < 0 =⇒ a ∈ (2, 4)

Similarly,
|b − 3| < 1 =⇒ b ∈ (2, 4)
Therefore,
A = {(a, b) | a ∈ (2, 4), b ∈ (2, 4)}

Next,
B = {(a, b) ∈ R × R | b − 1 ≤ (a − 3)2 }
Given,
b − 1 ≤ (a − 3)2 =⇒ b ≤ (a − 3)2 + 1
Let a ∈ (2, 4), then a−3 ∈ (−1, 1) which means (a−3)2 ∈ (0, 1) =⇒ (a−3)2 +1 ∈ (1, 2)
Therefore,
b ≤ (a − 3)2 + 1 =⇒ b < 2 Based on value of a
Therefore, if a ∈ (2, 4), then b ∈
/ (2, 4). That is why A ∩ B = φ.

Answer: Option 2

13
11. What is the weight of a minimum cost spanning tree of the graph given below? (NAT)
[Marks: 3]

G
5
B E 9
1 7

8
A 3 3 6 F

2 8 11
C D H
4 14

Solution: MCST will be

G
B E 9
1 7

8
A 3 F

2
C D H
4

Answer: 34

14
12. In an undirected graph G, the number of vertices having odd and even degrees are M
and N respectively. Which of these values are possible for M and N ? (MCQ)

1. M = 96, N = 11
2. M = 101, N = 10
3. M = 97, N = 31
4. M = 103, N = 12

Solution: Let Sum of degree of all vertices having odd degree and even degree be Mv
and Nv respectively, then

Mv + Nv = even
We know that Nv is even therefore, Mv should be even too. This means M should be
even.

Answer: Option 1

15
13. We use matrix multiplication to find A2 from A1 . What is the value of 2α + β?

A1 i j k l m A2 i j k l m
i 0 0 0 0 1 i 0 α 0 0 0
j 0 0 1 0 1 j 0 0 0 1 0 (NAT)
k 0 0 0 1 0 k 0 0 0 0 β
l 0 0 0 0 1 l 0 0 0 0 0
m 0 0 0 0 0 m 0 0 0 0 0

Solution:

α = A2 (i, j) = ith row of A1 × j th column of A1 = 0 × 0 + 0 × 0 + 0 × 0 + 0 × 0 + 0 × 1 = 0

And

β = A2 (k, m) = k th row of A1 ×mth column of A1 = 0×1+0×1+0×0+1×1+0×0 = 1

Therefore
2α + β = 1
Answer: 1

16
14. Liala and Vinay both have to travel to various locations for advertising their company’s
products. The company reimburses their expenses such as accommodation, food etc.
The company also blacklists an employee whenever the employee’s expenditure in a given
month exceeds | 12000. The accounts department fits the data of monthly expenditure
to the polynomial El (x) and Ev (x) (in |) for Liala and Vinay respectively, where x
is the number of months since they joined the company (i.e., x = 1 represents the
completion of one month). The polynomial fit is known to be applicable for a period of
30 months (i.e., x ≤ 30). If El (x) − 12, 000 = a(x − 5.1)(x − 11)(x − 20.5), a > 0 and
Ev (x) − 12, 000 = a(x − 2)2 (x − 8)(x − 25.5), a > 0. Let Nv , Nl , and Nvl are the sets
defined as
Nv = {x | x is the month number when Vinay got blacklisted}
Nl = {x | x is the month number when Liala got blacklisted}
Nvl = {x | x is the month number when Liala and Vinay both got blacklisted}
Find the cardinality of Nl ∪ Nv . (NAT)

Solution: If we draw a rough diagram for both the functions, then (Figure is not for
scale purpose)

El (x) Ev (x)

Y
• • • • • • y = 12, 000
2 5.1 8 11 20.5 25.5

We can see that


Nv = {1, 3, 4, 5, 6, 7, 26, 27, 28, 29, 30}
Nl = {6, 7, 8, 9, 10, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30}
Nvl = Nv ∩ Nl = {6, 7, 26, 27, 28, 29, 30}
Therefore,
cardinality(Nv ∪Nl ) = cardinality(Nv )+ cardinality(Nl )− cardinality(Nv ∩Nl ) = 11+15−7 = 19
Answer: 19

17
15. Let A be the set of positive integers divisible by both 2 and 3 but not by 12, B be the set
of positive integers divisible by both 3 and 5 but not by 15, and C be the set of positive
integers strictly less than 100 and divisible by both 5 and 2 but not by 20 or 30. Find
the cardinality of set G where

G = {x | x ∈ A ∩ B ∩ C}

(NAT)

Solution: Here it is clear that B = φ therefore, A ∩ B ∩ C = φ. This means G = φ.


Therefore, cardinality of G would be 0.

Answer : 0

18
16. Consider the path of a ball thrown upwards is represented in the form:

S(t) = − g2 t2 + v0 t + h0

where S is the vertical distance of the ball from the ground (ground is S = 0), t is time
elapsed since the ball was thrown (t = 0 when the ball is thrown), g is the acceleration
due to gravity of the Earth, v0 is the initial velocity of the ball and h0 is the initial height.
h0 = 0 means the ball is thrown from the ground, h0 = 1 means the ball is thrown from
a height of 1 unit from the ground. Note that all the variables are consistent in their
units. Take g = 10 for all the calculations. Which of the following options are correct?
(MSQ)
Options:

1. Two balls thrown with the same initial velocity must reach the same maximum
height
2. Two balls thrown with the same initial velocity and initial height must reach the
same maximum height
3. Two balls thrown with the same initial velocity may not reach the same maximum
height but must reach their respective maximum heights after the same time t
4. Time taken by a ball thrown from the ground to reach back to the ground is given
by 2v0 /g
5. Time taken by a ball thrown from the ground to reach back to the ground is given
by v0 /g
6. A ball is thrown with an initial velocity of 10 units and from a height of 2 units.
Another ball is thrown with an initial velocity of 10 units and from the ground.
Both the balls reach the ground at the same time.
7. It is never possible that one ball thrown from the ground and another thrown from
a finite height h reach the ground at the same time
8. Maximum height reached by a ball with an initial velocity v and thrown from a
height h is always higher than that reached by the ball thrown with an initial
velocity v and from the ground

Solution: Given,
g
S(t) = − t2 + v0 t + h0
2
D v0 2 − 4 × g2 × h0 v0 2 − 2gh0
M aximum height = − = − g =
4a 4 × −2 2g
As maximum height reached depends on both v0 and h0 therefore, option 1 is incorrect
while 2 is correct.

19
Time taken by the ball to reach maximum height would be
b v0 v0
t=− =− =
2a −g g
Time taken by the ball to reach maximum height depends only on v0 , therefore two balls
will reach there respective maximum after same time t if initial velocity is same.

Time taken by the ball to reach the ground again if the ball is initially thrown from
ground, would be
v0
t = 2 ....because of symmetry
g
In option 6, for first ball
S(t) = −5t2 + 10t + 2
Let the first ball will reach ground when t = t1 ,
S(t1 ) = 0 =⇒ −5t21 + 10t1 + 2 = 0
For the second ball
S(t) = −5t2 + 10t
Let the Second ball will reach ground when t = t2 ,
S(t) = 0 =⇒ −5t2 (t2 − 2) = 0 =⇒ t2 = 2
Clearly t1 6= t2 . Therefore, option 6 is incorrect.

In option 7, according to the first case h0 = 0 then time taken by ball to reach the
ground would be t = 2vg0 . Let another ball be thrown from a height h with an initial
velocity v and assume that it takes the same time t = 2vg0 to reach the ground, then
g 2v0 2 2v0
S(t) = − ( ) + v( )+h=0
2 g g
2v0 2 vv0
S(t) = − + +h=0
g2 g
2v0 2 vv0
=⇒ h = 2 −
g g
Which means if the ball is thrown from the height h, it can take the same time to reach
the ground.

In option 8, if initial velocity is same, then the maximum height attained by the ball
thrown from height h would be h unit more than that of the ball thrown from the ground.

Answer: Options 2, 3, 4, 8

20
17. If A and B are two sets such that the cardinality of A × B is 6. If three elements of
A × B are (4, 5) (1, 2) (7, 2), then A × B is (MCQ)

1. {(5, 4), (5, 1), (5, 7), (2, 4), (2, 1), (2, 7)}
2. {(4, 5), (2, 4), (5, 1), (1, 2), (5, 7), (7, 2)}
3. {(4, 5), (2, 4), (5, 1), (1, 2), (5, 7), (7, 2)}
4. {(4, 5), (4, 2), (1, 5), (1, 2), (7, 5), (7, 2)}

Solution: From the given elements of A×B, it is clear that A = {4, 1, 7} and B = {5, 2}.
Therefore, only option 4 could be the correct A × B.

Answer: Option 4

21
18. Consider the relation R = {(x, y) ∈ R × R | 0 < |x − y| < 2} on the set of real numbers.
Which of the option(s) is(are) correct?

1. R is a reflexive relation.
2. R is a symmetric relation.
3. R is a transitive relation.
4. R is an equivalence relation.

Solution: Given,
R = {(x, y) ∈ R × R | 0 < |x − y| < 2|}
Reflexive:
If (x, y) ∈ R, 0 < |x − y| < 2
If (x, x) ∈ R, |x − x| ∈
/ (0, 2)

Symmetric:
If (x, y) ∈ R, 0 < |x − y| < 2
If (y, x) ∈ R, |y − x| = |x − y| ∈ (0, 2)

Transitive:
If (x, y) ∈ R, 0 < |x − y| < 2
If (y, z) ∈ R, 0 < |y − z| < 2
If (x, z) ∈ R, |x − z| ∈
/ (0, 2)
For simplicity take x = 2, y = 3, and z = 4.

Therefore, relation is only symmetric.

Answer: Option 2

22
19. A mobile company offers two plans. Plan A costs |300 and offers 1000 free minutes per
month with a charge of 15 paise per minute for every additional minute. Plan B costs
|400 and offers 1500 free minutes per month with a charge of 10 paise per minute for
every additional minute. Let CA (t) and CB (t) represent the total cost per month for the
plan A and the plan B respectively, where t represents the number of minutes used. If
Riya uses 1800 minutes per month, then choose the set of correct options with respect
to Riya. (MSQ)

1. Plan A costs less than plan B.


2. Plan B costs less than plan A.
3. CA (t) = 300, for all t ∈ [0, 1000].
4. CB (t) = 400, for all t ∈ [0, 1500].
5. CA (t) = 0.1t + 400, for all t ∈ [1500, 1800].
6. CA (t) = 0.15t + 150, for all t ∈ [1000, 1500].

Solution:

Plan A : (
300 if t ∈ (0, 1000]
CA (t) =
0.15(t − 1000) + 300 if t > 1000
(
300 if t ∈ (0, 1000]
CA (t) =
0.15t + 150 if t > 1000

Plan B : (
400 if t ∈ (0, 1500]
CB (t) =
0.10(t − 1500) + 400 if t > 1500
(
400 if t ∈ (0, 1500]
CB (t) =
0.1t + 250 if t > 1500

For t = 1800,

CA (1800) = 0.15 × 1800 + 150 = 420


CB (1800) = 0.1 × 1800 + 150 = 430
Answer: Options 1, 3,4

23
20. A parabolic banner of a company XY Z is supported by two rods OAT and P BS on the
terrace of the company. The lowest point H of the banner is 5f t above from the terrace.
Both the rods OAT and P BS touch the banner at points A and B only. Both the
points are horizontally 2f t away from H. Both the points are at the height of 9f t from
the terrace. To increase the strength of the support, a small rod KL is fixed between
the terrace and the point where both the rods meet. If the rod KL is 0.5f t inside the
terrace, then find the total length of rod KL in f t. (Note that the figure is not for scale
purpose and for simplicity assume all the parts of banner and the all the rods are in the
same plane.)

O P
A• • B

H

Terrace surface
S T
L

Solution:

Let H be the origin and vertical direction be the Y − axis and horizontal direction be
the X− axis then,
H ≡ (0, 0), B ≡ (2, 4), and A ≡ (−2, 4)
Because the vertical distance of B from H would be 9 − 5 = 4.

The parabola will be symmetric around Y − axis which means the equation of parabola
would be f (x) = ax2 . Given if x = 2, then f (2) = a(2)2 = 4. Therefore, a = 1. So,
f (x) = x2 .

Let the equation of line SB be (y − 4) = m(x − 2), where m is the slope of parabola at
x = 2. We know that the slope of parabola is 2ax + b, therefore, m = 2 × (2) = 4. So,
equation of line would be y = 4x − 4.

Because of symmetricity, line segments AT and BS will intersect at x = 0 (below the


vertex). For x = 0, y = 4 × 0 − 4 = −4. Therefore, K ≡ (0, −4).

24
As H is 5 fit away from the terrace surface then yterrace = −5. Therefore, KL = 1+0.5 =
1.5.

Answer: 1.5

25

You might also like