Let K be a field equipped with a valuation. Tropical varieties over K can be
defined with a theory of Groebner bases taking into account the valuation of K.
Because of the use of the valuation, the theory of tropical Groebner bases has
proved to provide settings for computations over polynomial rings over a p-adic
field that are more stable than that of classical Groebner bases.
Beforehand, these strategies were only available for homogeneous polynomials. In this article, we extend the F5 strategy to a new definition of tropical
Groebner bases in an affine setting. We also provide a competitor with an adaptation of the F4 strategy to tropical Groebner bases computations.
We provide numerical examples to illustrate time-complexity and p-adic stability of this tropical F5 algorithm. We also illustrate its merits as a first step
before an FGLM algorithm to compute (classical) lex bases over p-adics.