In written prose, the first mention of a display element must be specific—e.g., Fig. 5, Table 2, Eq. 14, etc.—and one omits the definite article 'the'. Furthermore, a specific reference is treated as a proper noun; therefore, you capitalize the words Figure (or Fig.), Table, Equation (or Eq.), etc.
After the first, specific mention of a display element, a nearby subsequent mention of the same display element uses the definite article 'the' with figure, table, equation, etc. Subsequent mention of a display element that is not nearby the first mention—e.g., on an overleaf page, or in a different section of the document—should again be a specific reference without the definite article 'the' (e.g., "Referring back to Fig. 5 (p. 12), .…").
EXAMPLES
The functional block diagram shown in Fig. 5 identifies the functional elements that comprise the Main Engine Gimbal Control assembly 22A5, and shows how those elements interrelate. As shown in the figure, …
The test results obtained by performing the Main Engine Gimbal Control Test Plan are summarized in Table 2. The table's far right column Test Result shows the pass|fail outcome for each test procedure in the test plan.
When analyzing the data, Eq. 14 was used to combine the measurement uncertainties in quadrature. The equation yields a statistical estimate of …
As a side note, within written prose I consider it a best practice to insert a non-breaking space, rather than an ordinary space, between a caption label and its number:
Fig.{NBSP}5
Table{NBSP}2
Eq.{NBSP}14
Doing so ensures a caption label and its number always stay together as a single lexical element; they cannot be separated by a line break or page break:
blah blah Fig. // line 9
5 shows ... // line 10
or
blah blah Fig. // <- last line on page 4
--page break--
5 shows ... // <- first line on page 5
And by the way, the definite article 'the' commonly precedes proper nouns/names—e.g., the United States, the C++ programming language, the North Pole, etc. So I take issue with the statement "You do not use articles with proper names" which appears in the accepted answer. The more correct statement, in my opinion, is that the English language has many grammar and usage exceptions. Omitting the definite article 'the' when mentioning a specific display element (e.g., Fig. 5) within written prose seems to be one of those exceptions.