How to calculate $\text{P}\left(k\mid j\,\biggl|\,k\mid n\right)$ for $1\leq j,k \leq n$? Let $n$ be a natural number, and let $1\leq j,k\leq n$ be two randoms.
Show that if $k\mid n$ ($k$ divides $n$) then the probabilty of
$k$ also dividing $j$ is $\frac{1}{k}$, that is $\text{P}\left(k\mid j\right)=\frac{1}{k}$.
One way i was thinking about is to look straight forward for 
$$\text{P}\left(k\mid j\,\biggl|\,k\mid n\right)=\frac{\text{P}\left(k\mid j\,\cap\,k\mid n\right)}{\text{P}\left(k\mid n\right)}
$$But i dont really know how to find any of those on the right side
(Any help with that?)
Other way i was thinking about is that if $k\mid n$ then there is
an $s\in\mathbb{N}$ such that $n=k\cdot s$, so we can divide $\left\{ 1,\ldots,n\right\} $
to $s$ distinct sets or to $k$ distinct sets in these ways for example:
$$\begin{aligned}(1)\quad & \left\{ 1,\ldots,k\right\} ,\left\{ k+1,\ldots,2k\right\} ,\dots,\left\{ \left(s-1\right)k+1,\ldots,sk\right\} \\
(2)\quad & \left\{ 1,k+1,\ldots,\left(s-1\right)k+1\right\} ,\left\{ 2,k+2,\ldots,\left(s-1\right)k+2\right\} ,\ldots,\left\{ k,2k,\ldots sk\right\} 
\end{aligned}
$$Somehow i think that using the 2nd way would be more helpful. I know
that the probabilty of choosing a random $j$ from $\left\{ 1,\ldots,n\right\} $
is $\frac{1}{n}$, but how do i find the probabilty that it is also
from the last set $\left\{ k,2k,\ldots,sk\right\} $ ?
 A: I have a partial solution for you. First, you should know that $\sigma(n)$ is the sum of divisors of n, and $\tau(n)$ is the number of divisors of n.
Define $K$ as the random variable which takes on the value $k$ in our experiment.
Now let's find $E[K]$. There are $\tau(n)$ ways to select a divisor of $n$, and for each of those the value for $K = k$.
Then 
$$E[K] = \frac{\sum_{k \mid n}k}{\tau(n)} = \frac{\sigma(n)}{\tau(n)}$$
This means your RHS becomes
$$\frac{1}{k} = \frac{\tau(n)}{\sigma(n)}$$
With this out of the way, now let's count $k \mid j\ \land k \mid n$. We'll count the pairs $(k, j)$ for which this is true for a given n. This is equal to
$$\sum_{k\ \mid\ n}{\left \lfloor \frac{n}{k} \right\rfloor} = \sum_{\frac{n}{k}\ \mid\ n}{k} = \sigma(n)$$
So I'm tempted to conclude that $$\text{P}\left(k\mid j\,\cap\,k\mid n\right) = \frac{\sigma(n)}{n^2}$$ and that $$\text{P} \left( k\mid n \right) = \frac{\tau(n)}{n}$$
But it does not give the correct answer. I think I'm making some error with the probabilities. I have also written a program running a simulation to verify that the probability value indeed does seem to be $\frac{\tau(n)}{\sigma(n)}$ so I'm certain that the error is in my LHS attempt
A: I realized eventually that it is quite simple to show it from where I got.
Since our sample space is $\left\{ 1,\ldots,n\right\} $
and $n=s\cdot k$ then $$\text{P}\left(k\mid j\right)=\text{P}\left(j\in\left\{ k,2k,\ldots,sk\right\} \right)=\frac{\left|\left\{ k,2k,\ldots,sk\right\} \right|}{\left|\left\{ 1,\ldots,n\right\} \right|}=\frac{s}{n}=\frac{s}{s\cdot k}=\frac{1}{k}$$
