CAT 2022 Slot 1 — QA Question 22

ModulusEasy

Let 0 ≤ a ≤ x ≤ 100 and f(x) = |x - a| + |x - 100| + |x - a - 50|. Then the maximum value of f(x) becomes 100 when a is equal to

Answer & solution

Correct answer: 50

  • A

    0

  • B

    25

  • 50

  • D

    100

Solution

Easy

On the given range a≤x≤100a\le x\le 100 two of the moduli open cleanly: ∣x−a∣=x−a|x-a|=x-a and ∣x−100∣=100−x|x-100|=100-x. They cancel the xx, leaving f(x)=(100−a)+∣x−a−50∣f(x)=(100-a)+|x-a-50|. Test each option to see which keeps the maximum at exactly 100100.

1

Simplify on a≤x≤100a\le x\le 100:

f(x)=(x−a)+(100−x)+∣x−a−50∣⇒ f(x)=(100−a)+∣x−a−50∣\begin{aligned} &f(x)=(x-a)+(100-x)+|x-a-50|\\ &\Rightarrow\ f(x)=(100-a)+|x-a-50| \end{aligned}
A

a=0a=0: f(x)=100+∣x−50∣f(x)=100+|x-50|. At x=100x=100, f=150>100f=150\gt 100. Rejected.

B

a=25a=25: f(x)=75+∣x−75∣f(x)=75+|x-75|. At x=100x=100, f=100f=100 but at e.g. x=100x=100 it is 100100; however the simplified form only holds for x≥ax\ge a, and checking the full range gives values exceeding 100100 near the other end. Rejected.

C

a=50a=50:

f(x)=50+∣x−100∣for 50≤x≤100: ∣x−100∣=100−x≤50⇒ f(x)≤50+50=100, equality at x=50\begin{aligned} &f(x)=50+|x-100|\\ &\text{for }50\le x\le 100:\ |x-100|=100-x\le 50\\ &\Rightarrow\ f(x)\le 50+50=100,\ \text{equality at }x=50 \end{aligned}

Maximum is exactly 100100. Correct.

D

a=100a=100: the range forces x=100x=100 only, giving f(x)=0+∣100−150∣=50f(x)=0+|100-150|=50. Maximum is 5050, not 100100. Rejected.

a=50a=\mathbf{50}. Option (c).

Related Modulus questions

See all Inequalities & Modulus questions →
CAT 2022 Slot 1 QA Q22 — Modulus solution | TheCATExam