The definition given below is present in the exercise of the text Database System Concepts by Korth et. al.
Let $\alpha$ and $\beta$ be sets of attributes such that $\alpha \rightarrow \beta$ holds, but $\beta \rightarrow \alpha$ does not hold. Let $A$ be an attribute that is not in $\alpha$, is not in $\beta$, and for which $\beta → A$ holds. We say that $A$ is transitively dependent on $\alpha$ .
The definition given below is from the text Fundamentals of Database Systems by Navathe et. al.
A functional dependency $X → Y$ in a relation schema $R$ is a transitive dependency if there exists a set of attributes $Z$ in $R$ that is neither a candidate key nor a subset of any key of $R^\dagger$ and both $X → Z$ and $Z → Y$ hold.
$\dagger:$ This is the general definition of transitive dependency. Because we are concerned only with primary keys in this section, we allow transitive dependencies where $X$ is the primary key but $Z$ may be (a subset of) a candidate key.
The above two definitions are not exactly the same apparently. Now with the analogy of mathematical relations, I get the rough idea that if $X\rightarrow Z$ and $Z\rightarrow Y$ are functional dependencies then $X\rightarrow Y$ is a transitive functional dependency. [Just as we have in mathematics $(a,b)\in R$ and $(b,c)\in R$ and if a relation is transitive then we have $(a,c)\in R$.] But the thing is that, here these $X$, $Y$ and $Z$ have some added conditions to them. But in the definitions given in Navathe text and Korth text these conditions seem different.
The first definition says that if $\alpha \rightarrow \beta$ holds then $\beta \rightarrow \alpha$ should not hold. Also, $A$ should not be a part of either $\alpha$ or $\beta$. While the second definition talks about $Z$ being neither a candidate key nor a subset of a candidate key. Neither can I figure out the equivalence between them, [except that if $Z$ is not candidate key, then if $X\rightarrow Z$ then $Z \rightarrow X$ should not hold] nor the intuition behind these conditions.