Let Λ be a finite-dimensional hereditary algebra over a finite field k, ${\mathcal H}$(Λ) and ${\mathcal C}$(Λ) be, respectively, the Hall algebra and the composition algebra of Λ, ${\mathcal P}$ be the isomorphism classes of finite dimensional Λ-modules and I the isomorphism classes of simple Λ-modules. We define δ$_α$ and $_α$ δ, α in ${\mathcal P}$, to be the right and left derivations of ${\mathcal H}$(Λ) respectively. By using these derivations and the action of the braid group on the set of exceptional sequences of Λ-mod, we provide an effective algorithm of calculating the root vectors of real Schur roots. This means that we get an inductive method to express u$_λ$ as the combinations of elements u$_i$ in the Hall algebra, where i ∈ I and λ in ${\mathcal P}$ is any exceptional Λ-module. Because of the canonical isomorphism between the Drinfeld–Jimbo quantum group and the generic composition algebra, our algorithm is applicable directly to quantum groups. In particular, all the root vectors are obtained in this way in the finite type cases.