Use definite article, when a singular noun is meant to express a whole class:
The cow is a useful animal for the mankind The cow is an animal species useful for the homo sapiens (The) cows are useful animals for farmers
Here you are talking about classes (the cow species, the mankind, the farmers): "the cows (all of them as a group) are useful for the human beings (again all of them)".
Use indefinite article, in the sense of any, to single out an individual as the representative of a class:
A cow is a useful animal for a farmer A herd of cows is useful for a farmer
In the last case you are not talking about class of the cows or the farmers, but about a single, indefinite (unknown or irrelevant the actual identity) cow (or herd of cows) and farmer.