Question Number 35071 by Rasheed.Sindhi last updated on 15/May/18
$$\mathrm{A}\:\mathrm{20}-\mathrm{digit}\:\mathrm{decimal}\:\mathrm{number}\:\mathrm{has}\:\mathrm{been} \\ $$$$\mathrm{converted}\:\mathrm{into}\:\mathrm{octal}\:\mathrm{system}.\mathrm{Say}\:\mathrm{it}\:\mathrm{has}\: \\ $$$$\mathrm{n}\:\mathrm{digits}.\:\mathrm{What}\:\mathrm{can}\:\mathrm{be}\:\mathrm{minimum}\:\mathrm{and} \\ $$$$\mathrm{maximum}\:\mathrm{possible}\:\mathrm{values}\:\mathrm{of}\:\mathrm{n}? \\ $$$$ \\ $$
Answered by candre last updated on 15/May/18
$${m}={l}\alpha^{{k}} +{d};\mathrm{0}<{l}\leqslant\alpha−\mathrm{1}\wedge\mathrm{0}\leqslant{d}<\alpha^{{k}} \wedge\left({l},{d},{k},\alpha\right)\in\mathbb{N}^{\mathrm{4}} \wedge\alpha>\mathrm{1} \\ $$$${m}=\left({l}+{d}\alpha^{−{k}} \right)\alpha^{{k}} \\ $$$$\mathrm{log}_{\alpha} {m}=\mathrm{log}_{\alpha} \left[\left({l}+{d}\alpha^{−{k}} \right)\alpha^{{k}} \right] \\ $$$$=\mathrm{log}_{\alpha} \alpha^{{k}} +\mathrm{log}_{\alpha} \left({l}+{d}\alpha^{−{k}} \right) \\ $$$$={k}\mathrm{log}_{\alpha} \alpha+\mathrm{log}_{\alpha} \left({l}+{d}\alpha^{−{k}} \right) \\ $$$$={k}+\mathrm{log}_{\alpha} \left({l}+{d}\alpha^{−{k}} \right) \\ $$$$\mathrm{0}\leqslant{d}<\alpha^{{k}} \Rightarrow\mathrm{0}\leqslant{d}\alpha^{−{k}} <\mathrm{1} \\ $$$$\mathrm{0}<{l}+{d}\alpha^{−{k}} <\alpha \\ $$$$\mathrm{log}_{\alpha} \left({l}+{d}\alpha^{−{k}} \right)<\mathrm{1} \\ $$$$\alpha^{{k}} \leqslant{m}<\alpha^{{k}+\mathrm{1}} \Rightarrow{k}\leqslant\mathrm{log}_{\alpha} {m}<{k}+\mathrm{1} \\ $$$${m}={a}_{{k}} …{a}_{\mathrm{0}} \Rightarrow{k}−\mathrm{0}+\mathrm{1}={k}+\mathrm{1} \\ $$$${min}\Rightarrow{num}=\mathrm{10}^{\mathrm{19}} \\ $$$${min}=\lfloor\mathrm{log}_{\mathrm{8}} \mathrm{10}^{\mathrm{19}} \rfloor+\mathrm{1}=\lfloor\mathrm{19log}_{\mathrm{8}} \mathrm{10}\rfloor+\mathrm{1}=\mathrm{22} \\ $$$${max}\Rightarrow{num}=\mathrm{10}^{\mathrm{20}} −\mathrm{1} \\ $$$${max}=\lfloor\mathrm{log}_{\mathrm{8}} \left(\mathrm{10}^{\mathrm{20}} −\mathrm{1}\right)\rfloor+\mathrm{1}=\mathrm{23} \\ $$
Commented by Rasheed.Sindhi last updated on 15/May/18
†ђД₪k§ Д ℓø† §îЯ