I came across this problem while surfing internet. The problem would be stated as follows, which is equivalent of asking whether given system of linear equations is solvable :
Let $F$ be a field. On choosing $A\in M_{n\times n}(F)$ and $b\in F^n$, what is the probability that $b \in \text{Im } A$?(thinking $A$ as linear map from $F^n$ to $F^n$)
As I lack understanding in concept of probability, I'm not even sure if the given conditions are sufficient to define probability for arbitrary fields. So I first consider only the cases with finite fields.
Let $|F|=q$. Total possibility would be $q^{n(n+1)}$ as one chooses an $n\times n $ matrix and a size n column vector. Classifying the elements of $M_{n \times n}(F)$ by the rank, let $\rho(k)$ denote the number of matrices in $M_{n \times n}(F)$ with rank $k$. If $A$ has rank $k$, image of $A$ is $F$-vector space of dimension $k$ and thus the possibility in consideration is calculated as $$\sum_{i=0}^{n} \rho(i)q^i$$
Thus counting $\rho(k)$ for integers $k$ yields the probability in question, but I can't quite come out with the way to calculate it. What method would there be to calculate $\rho(k)$? If in someway we have calculated the probability for finite fields, how can it be generalized to arbitrary fields?
This is a partial answer. I tried to find the number of $M_n$ matrices of rank $k$.
Let $M$ be one such matrix. $M$ is completely and uniquely determined by the images of $e_i = \pmatrix{0 & \dots & 0 & 1 & 0 & \dots & 0}^\top$
Let $k_i$ be the dimension of $\text{Vect} (e_1,\dots, e_i)$
We have $k_0 = 0,\ k_n = k,$ and $k_i$ is an increasing sequence.
So $k_i$ is characterized by the $k$ points at which it increases: $d_1\lt \dots\lt d_k$
We additionally define $d_0 = 0, d_{k+1} = n+1$
For $i=d_j$, $Me_i$ can take $q^n-q^j$ values
For $d_j<i<d_{j+1}$, $Me_i$ can take $q^j$ values
So we get a total of $$\sum_{1\leq d_1\lt \dots \lt d_k \leq n} \prod_{j=1}^{k} (q^n-q^j) q^{j(d_{j+1}-d_j - 1)} $$
matrices of rank $k$. I doubt a simple closed form expression exists, but I could be wrong.