Question: should I keep communion from my child if he has unrepentant sin from that morning?
The short answer is: no.
Why? Two quick reasons:
1. Lack of repentance should usually be given time to harden into stubbornness (hopefully it turns into repentance, instead!) before withholding communion.
2. It is the elders' role to keep communion from a church member, not the parents.
The longer answer:
It is your job as a parent to lead your child to repentance and reconciliation with the Lord before (or even during) the worship service, before the bread and wine are given him. If you are unable to do this for some reason, talk with an elder that Sunday morning and ask them what to do. The elders may let your child commune or may ask them not to. This is a difficult decision, so respect and follow what they tell you.
Theologically, on the one hand keeping your children (or yourself) from the Table because you don't feel him (or you) repentant enough takes the keys of the kingdom from the elders and shuts yourself out of the Kingdom of God as a form of self-flagellation. On the other hand, letting unrepentant sinners partake of the Lord's Supper defiles the person, and they eat and drink judgment on themselves.
In the abstract, I come down on the first hand above. One thing communion "does" is fight against low-grade defiance. When you are in a funk for a few days, God often hands you circumstances to draw you out of it, and one of those is communion. If you think you need to withhold yourself from the Table in that funk, you are pursuing a perfectionism that is not attainable. Why not let the Supper lift you out of the sin, as it is partly meant to do? Do you hold back if you find one waft of sinful desire within? Is there a time limit on that - no sin in the last 30 minutes, since you woke up, last 4 days? God is patient with us while we cling to sin for a while. Consider how He dealt with Israel. We MUST drop it, and the either/or choice between the sin and the Lord’s Table is made clear every time your church celebrates communion. But we also cannot expect complete repentance and perfection in ourselves or our children at the moment of receiving the bread and wine.
Pastorally, it helps alleviate tension and pressure to "do it right," to remember that the Supper is a MEANS of Christ's grace, not the source. Doing it wrong does not endanger your soul. The decision should hinge on the message you and the elders are sending to your child by having them partake or not. Will it help her more to be warned that she is outside of God's grace the way she is behaving, or to be comforted that even sin cannot separate her from God's love? Practically, as I administer communion every week and observe the congregation partaking, my thoughts are on God's goodness to us in Christ generally, not checking to see if anyone is not partaking, and wondering why.
Whatever is decided about your son or daughter, it's probably a good idea to meet with your pastor or elders later to lay out the situation, and seek their input in how to disciple your child in the future.