Was the teacher providing one on one tutoring to your daughter during recess, or was your daughter required to miss recess and do nothing? If she was provided with one on one tutoring, I think it was a good thing, and more of a misunderstanding than anything else.
Actually, modern education is much more in tune with the student's individual learning styles and needs (not cookie cutter). It's possible the teacher thought your daughter needed a little extra individual attention, and that she was taking her time - usually a much needed coffee break - to assist. She may have recognized that your daughter had a problem with calculations that was easily remedied with a few minutes of individual instruction.
I get the impression that the use of the word "detention" is the source of the problem. It may be the word that children use when someone has to stay in class rather than go out to play. It may be that your daughter needs to see this as the teacher giving up her coffee break to give her a little individual time because the teacher cares about her, believes she has potential, and doesn't want to see her "left behind" in a subject that builds on itself.
Usually, I completely agree that teachers are idiots, but I think that in this case, if we remove the term "detention", and give the benefit of the doubt, your daughter may actually be receiving something above and beyond the other children.
I don't think you should do anything, but instead support the teacher's decision, which also fosters a healthy attitude towards learning in your child.