  We present a strengthening of the lemma on the lower bound of the slice rank
by Tao (2016) motivated by the Croot-Lev-Pach-Ellenberg-Gijswijt bound on cap
sets (2017, 2017). The Croot-Lev-Pach-Ellenberg-Gijswijt method and the lemma
of Tao are based on the fact that the rank of a diagonal matrix is equal to the
number of non-zero diagonal entries. Our lemma is based on the rank of
upper-triangular matrices. This stronger lemma allows us to prove the following
extension of the Ellenberg-Gijswijt result (2017). A tricolored ordered
sum-free set in $\mathbb F_p^n$ is a collection
$\{(a_i,b_i,c_i):i=1,2,\ldots,m\}$ of ordered triples in $(\mathbb F_p^n )^3$
such that $a_i+b_i+c_i=0$ and if $a_i+b_j+c_k=0$, then $i\le j\le k$. By using
the new lemma, we present an upper bound on the size of a tricolored ordered
sum-free set in $\mathbb F_p^n$.
