I'll add that cows have extremely poor depth perception thanks to horizontal pupils and weak eye muscles, as a result they only have a vertical vision range of about 60 degrees, to contrast the same range in humans is around 140 degrees. As a result of this almost all cows tend to be thrown off by shadows of any type, and most will stop and avoid them if at all possible. Standard cattleguard installation on a road is to dig a pit maybe 3-4 feet deep in the desired location, large concrete bases are then placed perpendicular to the road traveling surface, and the cattleguard grid (the part that becomes the road traveling surface across the top of the structure) is then placed on top of those bases, though it's not uncommon to find especially older cattleguards that are built of old railroad rail or similar scrap iron and metal pieces. The wings- the triangular pieces rising up from the cattleguard at 45 degree angles- are normally affixed at the bottom to the end of the grid, with the point attached to the H brace at the end of each fence segment on either side of the cattleguard. In road applications cattleguards typically work not by making walking difficult but by cows getting thrown off by the alternating shadow and light pattern across the cattleguard, that alone will usually stop almost all cows from trying to walk on or across the cattleguard. The difficulty of walking across the surface is actually rarely tested. It's for this reason that painted cattleguards- alternate black and white stripes simply painted on a highway surface- are usually effective alternatives to normal cattleguards on paved surfaces, as the stripes create an illusion of shadows that will stop most cows in their tracks.
Railroad cattleguards are a bit more complicated in as much as its not really possible to get the same shadow/highlight effect that road and highway cattleguards rely upon to deter cattle egress given the nature of railroad infrastructure, so they really have to go with the making it physically difficult for cattle to cross the structure. The pit shown in the Eureka-Nevada image is one way to go, most of the other designs I've seen involve metal sheets with raised sharp metal edges that really give cows no place to put a hoof solidly on the ground. There was at least one design that was going to be placed on the Nevada Northern main line back in the later 1990s that if I'm remembering it correctly was going to use a series of rollers placed between the rails, but BHP Nevada Rail shut down before the fence got built and so I think there is just a gate across the tracks until such time as the railroad reopens.
None of these, of course, will stop determine athletic cows from simply jumping across the cattleguard. Which does happen.
Jeff Moore
Elko, NV