Question

Choose the most appropriate equation for the function drawn as a thick line, in the plot below.

Plot of function with a ray along the positive y-axis and a ray through (2, -1) in the fourth quadrant
Function plot
Choose one option
Official answer and solution
Official answer
B
From
Official GATE 2015 answer key

Solution

Determine the piecewise behavior of the graph across the quadrants and match with the given absolute value formulations.

Examine the thick line in the plot:

  1. For y≥0y \ge 0: The graph is a vertical ray coincident with the positive y-axis, meaning x=0x = 0.
  2. For y<0y < 0: The graph is a straight ray passing through the origin (0,0)(0, 0) and the point (2,−1)(2, -1) in the fourth quadrant.
    The slope is ΔxΔy=2−0−1−0=−2\frac{\Delta x}{\Delta y} = \frac{2 - 0}{-1 - 0} = -2, so x=−2yx = -2y.

Analyze Option B: x=−(y−∣y∣)x = -(y - |y|):

  • When y≥0y \ge 0: ∣y∣=y|y| = y, so x=−(y−y)=0x = -(y - y) = 0.
  • When y<0y < 0: ∣y∣=−y|y| = -y, so x=−(y−(−y))=−(2y)=−2yx = -(y - (-y)) = -(2y) = -2y.
    This gives x=0x = 0 for y≥0y \ge 0 and x=−2yx = -2y for y<0y < 0, perfectly reproducing the graph (at y=−1y = -1, x=−2(−1)=2x = -2(-1) = 2).

Testing other options for comparison:

  • Option A: x=y−∣y∣  ⟹  x=2yx = y - |y| \implies x = 2y for y<0y < 0, giving x=−2x = -2 at y=−1y = -1 (wrong quadrant).
  • Option C: x=y+∣y∣  ⟹  x=2yx = y + |y| \implies x = 2y for y≥0y \ge 0 and x=0x = 0 for y<0y < 0.
  • Option D: x=−(y+∣y∣)  ⟹  x=−2yx = -(y + |y|) \implies x = -2y for y≥0y \ge 0 and x=0x = 0 for y<0y < 0.
    Hence, option B is correct.
Final answer

B

Common trap

Confusing the sign in −(y−∣y∣)-(y - |y|), which gives positive xx coordinates for negative yy values.

The answer is the one in the official GATE answer key. The solution is this site's own explanation.

Source

Paper
GATE 2015 Computer Science and Information Technology (CS) Session 3
Question
8 of 65, printed as GA Q.8
Section
General Aptitude

Report an error in this question

GATE questions are the work of the organising institutes. This site is independent and is not affiliated with them.