Let $G$ be a finite group, $k$ be a field whose characteristic divides $|G|$, and $\rho:G\hookrightarrow\operatorname{GL}\_n(k)$ be a faithful representation of $G$. Let $V$ be a $k$-space of dimension $n$ with ring of invariants $k[V]^G$. Suppose further that $k[V]^G$ is Cohen-Macaulay, so that there are primary invariants $f\_1,\ldots,f\_n$ and secondary invariants $h\_1,\ldots,h\_m$ such that $k[V]^G$ is a free module over $k[f\_1,\ldots,f\_n]$ with basis given by $1,h\_1,\ldots,h\_m$.


Given a list $f\_1,\ldots,f\_n$ of invariant functions on $V$, one may check to see if they form a set of primary invariants using the sufficient condition (which is also necessary) that the variety defined by the $f\_i$ over $\overline{k}$ is $\{\bf{0}\}$.


Given primary invariants $f\_1,\ldots,f\_n$, I'm looking for sufficient conditions for a list of invariant functions $h\_1,\ldots,h\_m$ to be secondary invariants. Since $k[V]^G$ is Cohen-Macaulay, a necessary condition is that
$$
m=\frac{\prod\_{i=1}^n\operatorname{deg}(f\_i)}{|G|}.
$$
In the non-modular case, one could make use of Molien's formula for the Hilbert series to determine the degrees of the secondary invariants, and then show that
$$
k[V]^G\_{\operatorname{deg}(h\_i)}\subset k[f\_1,\ldots,f\_n]\cdot 1\oplus k[f\_1,\ldots,f\_n]\cdot h\_1\oplus\ldots\oplus k[f\_1,\ldots,f\_n]\cdot h\_m
$$
for all $i=1,\ldots,m$, where $k[V]^G\_{\operatorname{deg}(h\_i)}$ is the $k$-space of homogeneous invariant functions of degree $\operatorname{deg}(h\_i)$ (which is presumably computable given $\rho$).


What can be said about the modular case? If I write down $h\_1,\ldots,h\_m$, how can I test that they are secondary invariants?



Sufficient conditions for secondary invariants
Since you don't know the Hilbert series of $k[V]^G$, I don't see any way of avoiding computing all homogeneous invariants of some degrees and checking if they all lie in the $k[f\_1,\ldots,f\_n]$-module $M$ generated by the $h\_i$. I'd proceed as follows: for rising degree $d$, compute a $k$-basis of $k[V]\_d^G$. Test if they lie in $M$. You do this either up to degree $\sum\_{i=1}^n \deg(f\_i) - n$ (Symond's degree bound), or until you have found a set of $m$ invariants of minimal degree that are linerly independent over $k[f\_1,\ldots,f\_n]$ (these will be guaranteed to be secondary invariants).


I don't think there is an easier way, unless you have additional information. The good news is that only linear algebra (and polynomial arithmetic) are needed; and even when you know the Hilbert series, checking the directness of the sum you mention requires linear algebra. By the way, in that case checking the directness suffices, since that will show that the module $M$ has the same Hilbert series as $k[V]^G$.


