Quantrex Quantrex AcademyJEE · NEET · NDA PYQs with solutions Open app
Olympiad workbook
Exam
Olympiad workbook
Subject
IOQM
Chapter
Permutation and Combination

Olympiad workbook · IOQM · Permutation and Combination

Let d(m) denote the number of positive integer divisors of a...

Let d(m)d(m) denote the number of positive integer divisors of a positive integer mm. If rr is the number of integers n≤2023n \leq 2023 for which ∑i=1nd(i)\sum_{i=1}^n d(i) is odd, find the sum of the digits of rr.

Correct answer

18

Step-by-step solution

∑i=1nd(i)\sum_{i=1}^n d(i) is odd ⇒d(1)+d(2)+d(3)+….+d(n)\Rightarrow d(1)+d(2)+d(3)+\ldots .+d(n) is odd dd (square number) = odd for n=1n=1 ∑i=1nd(i)= odd \sum_{i=1}^n d(i)=\text { odd } For n=3n=3 ∑i=1nd(i)=d(1)+d(2)+d(3) odd + even + even = odd ⇒n∈[1,3]\begin{aligned} & \sum_{i=1}^n d(i)=d(1)+d(2)+d(3) \\ & \quad \text { odd }+ \text { even }+ \text { even }=\text { odd } \\ & \Rightarrow n \in[1,3] \end{aligned} Similarly, For n=4n=4 ⇒∑i=1nd(i)= even as d(4)= odd ⇒n∈[4,8]∈ even ⇒n∈[1,3]∪[9,15]∪[…[12,22−1]∪[32,42−1]∪[52,62−1]…[432,442−1]\begin{aligned} \Rightarrow & \sum_{i=1}^n d(i)=\text { even as } d(4)=\text { odd } \\ \Rightarrow & n \in[4,8] \in \text { even } \\ \Rightarrow & n \in[1,3] \cup[9,15] \cup[\ldots \\ & {\left[1^2, 2^2-1\right] \cup\left[3^2, 4^2-1\right] \cup\left[5^2, 6^2-1\right] \ldots\left[43^2, 44^2-1\right] } \end{aligned} ⇒\Rightarrow Number of element. (22−1−12+1)=3(42−1−32+1)=7\begin{aligned} & \left(2^2-1-1^2+1\right)=3 \\ & \left(4^2-1-3^2+1\right)=7 \end{aligned} ⇒(22−12)+(42−32)+…+(442−432)⇒3+7+11+…22 terms ⇒222[2×3+(22−1)⋅4]=11×[6+84]=90×11=990\begin{aligned} & \Rightarrow \quad\left(2^2-1^2\right)+\left(4^2-3^2\right)+\ldots+\left(44^2-43^2\right) \\ & \Rightarrow \quad 3+7+11+\ldots 22 \text { terms } \\ & \Rightarrow \quad \frac{22}{2}[2 \times 3+(22-1) \cdot 4] \\ & \quad=11 \times[6+84]=90 \times 11 \\ & \quad=990 \end{aligned} ∴\therefore Sum of digits =18=18.
Practice Permutation and Combination on Quantrex Academy →

More from Permutation and Combination

All Permutation and Combination questions Full Permutation and Combination list All Olympiad workbook PYQs