The minimum number of variables to represent a 3D line in a unique way To my best understanding, the minimum number of variables to represent a line in 3D space is four. It means you need at least four values to identify a 3D line. For example from here 

$$a x + b y + c z = d \tag{1}$$

defines a line with four variables. However, this is not a unique representation of the line, and by scaling the equation you may still represent the same line:

$$k a x + k b y + k c z = k d \, , \{k \neq 0\} \tag{2}$$

So my question is that what is the minimum number of variables to represent a line in a unique way? In other words, if 

$$l_1 \equiv L\{ a_1, a_2, \cdots , a_n \} \tag{3}$$ 

and 

$$l_2 \equiv L\{ b_1, b_2, \cdots , b_n \} \tag{4}$$ 

then 

$$l_1 \equiv l_2 \tag{5}$$ 

only and if only 

$$ \{a_i = b_i, \forall i \in 1,\cdots,n\} \tag{6}$$

Or, if I want to ask my question differently, what is the best way to mathematically represent a line in a 3D space, in a unique way, with the minimum number of degrees of freedom? 

P.S.1. I think I have my answer, and it is shamefully simple. Just divide the first equation by $d$. So it seems the minimum number of variables to represent a line (or DOF) in a 3D space in a unique way should be 3:

$$a' x + b' y + c' z = 1 \tag{7}$$

where $\alpha' = \frac{\alpha}{d}$!

P.S.2. The above method doesn't work if $d = 0$, so one needs at least a boolean variable $d' = 0 \, or \, 1$:

$$a' x + b' y + c' z = d' \tag{8}$$

to represent all possible lines in a 3D space. 

P.S.3. I made a very silly mistake. Eq.1. represents a plane, not a line!
An answer to the question the user really meant to ask, according to the comments

I'm actually writing a code where I want to define a 3D line class.
and I want to have an equality method. So I need literal uniqueness.

This is the real problem.
You're mistaken about uniqueness and equality testing.
Representational uniqueness is neither required for equality testing nor universally the best way to do equality testing.
Suppose you specify a line using a pair of distinct points on the line. Now you need to test whether $(P, Q)$ is the same line as $(A, B)$. Here's a solution: test whether $A$ is on the line $PQ$, and $B$ is on the line $PQ$. If so (and only if so), the lines are the same, even though their representations are different. Just to close the loop here, you can test whether $A$ is on $PQ$ by checking whether
(i) $A = P$ or
(ii) $A \ne P$, but $A-P$ and $Q-P$ are proportional (nonzero) vectors.
At this point, there's likely to be some muttering about how this is bad because of numerical issues and IEEE floating point standards and you can't test equality of floats, etc. You really need uniqueness of representation.
Well, consider this: I can write down pairs of distinct points in the plane (or 3-space, but the plane is simpler) $A,B$ and $P, Q$ that mathematically characterize the same line, but which, when mapped into any &quot;unique&quot; representation like @Empy2's excellent one, will produce different results, if the mapping is carried out with any standard floating point representation. So your floating point nightmare is present from the very moment you compute your &quot;unique&quot; representation.
Deep in the heart of things, the problem is that you're hoping to represent a line in 3-space using a computer, and the pigeonhole principle says you're going to lose: there are uncountably many lines, and only countably many representation options. Even if you restrict to line that contain two representable points, you're going to need to use floating-point equality testing to determine whether some point $P$ lies on the line $L$, and that's going to give the wrong answer some of the time. It's probably best (but very difficult) to decide what properties of lines-in-3-space you really like and want to preserve in your representation, and then prove that your representation actually preserves those properties. As I say, that's really hard. Then again, so is debugging programs with numerical errors in the 14th digit. I've been there. &quot;Proving&quot; turns out to actually be easier. :(
Maybe $5$? $x,y,z$ of the reference point and a unit vector, which needs $\theta$ and $\phi$?