I assume you carry a stick when out walking. All you need to do is to fling your arms in the air, wave the stick angrily and shout "Waoahoagh" and "Gerrupthur" at them. I see farmers doing it all the time, and it definitely works. Of course it helps if you have rolled up shirt sleeves, a flat cap and bandy legs. The cows might be daft, but they're not that daft.
;o)