# When $\frac{\xi x}{\xi -x}$ is an integer

I'm working on a function $$\lambda(\xi)$$ that takes in input an intger $$\xi$$ and calculate for how many values of $$x\in N$$, with $$0\leq x < \xi$$, the ratio: $$\psi = \frac{\xi x}{\xi -x}$$ is an integer $$(\psi \in N)$$.

Here there is a graph of $$\lambda(\xi)$$ for $$2\leq \xi \leq113$$, created in Excel: I have tried in a lot of diferent ways (supposing for example $$\xi$$ is odd and $$x$$ is even), but I can't faind a solution. Any idea?

• This is equal to the number of positive integer divisors of $\xi^2$. Jul 20, 2019 at 13:02
• Why it's equal to the number of divisors of $\xi^2$? Jul 20, 2019 at 13:04
• Because $\psi = \frac{\xi^2}{\xi-x}-\xi\in\mathbb{N}\iff \frac{\xi^2}{\xi-x}\in\mathbb{N}$ and the latter is true only when $(\xi-x)|\xi^2$ i.e. once for each divisor of $\xi^2$. Jul 20, 2019 at 13:08
• I think it's not correct because if you put $\xi = 60$, $\xi^2$ have 45 not between 20 and 25 Jul 20, 2019 at 13:18
• Sorry, we need to emit the divisors which are greater than $\xi$ so the value is equal to $\frac{d(\xi^2)+1}2$ where $d(n)$ is the number of divisors of $n$. For $\xi=60$ this gives $\frac{45+1}{2}=23$. Jul 20, 2019 at 13:27

To prove the assertion of Peter Foreman in its comment, that's $$\lambda(\xi)=\frac{d(\xi^2)+1}2$$ let consider the sets \begin{align*} D&=\{d>0:d|\xi^2\}\\ L&=\{d\in D:d\leq\xi\}\\ U&=\{d\in D:d>\xi\} \end{align*} and the function \begin{align*} &\varphi:D\to D&&d\mapsto\xi^2/d \end{align*} Then \begin{align} D&=L\cup U& L\cap U&=\varnothing\\ &\text{\varphi is bijective}&\varphi[U]&=L-\{\xi\} \end{align} Consequently, $$d(\xi^2)=|D|=|L|+|U|$$ and $$|U|=|L|-1$$ from which $$\lambda(\xi)=|L|=\frac{|D|+1}2=\frac{d(\xi^2)+1}2$$ thus proving the assertion.