What is voting fraud?
Voting fraud is when a single user continually votes (up or down) on many of your posts within a short period of time. This is not considered normal behavior and the system will not allow it. If it continues to happen between two certain IP addresses (voting each other up) or from a single user, or looks just plain suspicious in general, moderators and/or developers may investigate the matter and disciplinary action may be taken against the users involved with the fraud.
When does serial upvoting occur?
Most often when you get unexpectedly serial upvoted, believe it or not, it's just a user trying to give you extra reputation. They saw a post of yours that was extraordinarily helpful to them and they feel that going through your posts systematically and upvoting them is the appropriate way of granting you additional reputation (apparently they've forgotten about the bounty system).
Occasionally, it also occurs between two users who have made an agreement to upvote each other, or between one user and a sock puppet account trying to game the system for extra reputation (which will often lead to suspension).
When does serial downvoting occur?
Pretty much any time serial downvoting occurs is when a user disagrees with something another user has posted, either as an answer or comment. The user then visits their profile and, like with serial upvoting, systematically visits their posts and downvotes them. Occasionally other reasons for this occurring will prevail, like a joke being played on the user.
What if I think I'm the victim of voting fraud?
If the voting fraud is in the progress of happening or just happened recently, don't worry about it. You should wait at least 24 hours after noticing before becoming concerned. The system should detect it and reverse it for you. Please do not try to get help on this issue on meta or by flagging for a moderator. All they will do is tell you to wait for the voting fraud script to run (they won't run it for you just this once).
If the 24 hours has already passed and the suspicious votes have not been reversed, you can then flag one of your posts and explain what happened so a moderator can look into it. It is generally preferred that you avoid asking about them on a site's Meta since details of the investigation cannot be divulged and you won't actually get any information that will be useful to other members of the community.
See also: What should you do if you're serial downvoted & it isn't automatically reversed within 24 hours?
How does the system detect voting fraud?
Every night around 03:00 UTC, a voting fraud detection script is run that looks for patterns such as these. It basically looks for users who have upvoted another user many times. The number is fairly low within a given amount of time (the exact mechanics are kept secret). When the system detects this pattern, all of the votes cast from that user to the user affected are reversed and it prints a "serial upvoting/downvoting reversed" statement in the affected user's reputation history to indicate what has occurred.
The value of the reversal could be anything, as it is the combined amount of all the votes being reversed (up and down, although most serial voting occurs in one direction). If you had reached the reputation cap, the value may show up as blank if none of the votes being reversed actually affected your reputation on that day.
Does the system detect voting fraud on deleted posts?
Yes. If you serial vote on posts and one or more of them end up deleted at a later time, the script will still reverse those votes if they are detected.
A regular user may notice this "feature" when one runs across a spam post, checks the spammer's account, then discovers and downvotes a series of "answers" having the same canned spam content. Even if all the posts are flagged and further removed, some time later one can find a series of +1 undownvote entries in their reputation history marked by the time when the vote reversal script typically runs (example).
Why don't I get to keep the reputation?
The reputation was removed because it is not proper behavior and it is not allowed. The votes were completely invalidated by the system and thus the reputation gain from them was also invalidated. The only way you can gain this reputation back is to go post some more and get some legitimate upvotes on those posts.
Should I be concerned about reversal statements on my profile?
No, not at all. It's only an indication of reputation change. After all, we can't control the actions of other users. It's very rare where we'd run across a user who was committing the voting fraud themselves on their own account, and in most instances of that, they will have already been dealt with accordingly. You should in no way be concerned with reversal statements in your reputation history.
What else should I know about this subject?
Reversals trigger a reputation recalculation.
Whenever serial voting gets reversed, all days involved in the serial voting will be recalculated as if the serial votes had never happened, and any reputation you might have lost due to those serial votes hitting the reputation cap will be given to you at that time. Serial voters will not prevent you from gaining reputation that you deserve.
The votes can be re-cast.
Votes reversed by the detection script can be re-cast by the user at a later time, so long as the user does not again engage in serial voting which causes them to be reversed (yet again).
There is no automated punishment or notifications.
Currently, serial voting reversals only reverse the votes. You can see what happened by viewing your reputation history, but that is about the extent of what the script does. There is no automated ban for users who engage in serial voting, nor do those users receive any form of notification that their votes were reversed.
Continual abuse of the system which causes multiple reversals can lead to a suspension, but the review process for such a suspension is completely manual. No automated flags are ever generated for this behavior, though moderators do have access to some statistics that can help fight repeat offenders. If you find you are the victim of serial voting multiple times within a short time span, feel free to flag one of your posts for moderator attention and explain the situation so they can investigate further.