In this paper,we present an algorithm to accurately compute the exponential of a triangular essentially nonnegative matrix.We first scale the matrix to a matrix with close diagonal elements,and then use Taylor expansion to compute the exponential of this scaled matrix,finally obtain the exponential of the original matrix by squaring.New stopping criteria are adopted in the Taylor expansion.We choose the scaling number by minimizing the cost of the algorithm.Error analysis shows that each entry of the computed solution has high relative accuracy.Numerical examples are presented to show the accuracy of the algorithm. |