割れる and 割る: broken glass and division
Compare glass breaking with someone breaking it, then examine 割る in division and dilution.
Start with the broken object
コップが割れました。 reports that a glass broke. 割れる is read われる; this sentence alone does not say who dropped it.
洗っているとき、コップを割ってしまいました。 means that the speaker accidentally broke a glass while washing it. 割る becomes 割って, and を marks the affected glass.
Break into pieces or divide a number
チョコレートを二つに割りました。 means that someone broke the chocolate into two pieces. 割る is not limited to damaging something beyond use.
In 十二を三で割ると四になります。, を marks the number divided and で marks the divisor: twelve divided by three is four. This is arithmetic, not a description of breaking an object.
Dilute with another ingredient
ジュースを水で割りました。 means that someone diluted juice with water. Here で marks the diluting ingredient, not a numerical divisor.
割れた皿には触らないでください。 asks someone not to touch the broken plate. 割れた describes the plate, so the speaker need not know who broke it.
What do を and で mark in 十二を三で割る?
Show the answer and why
十二を marks twelve as the dividend; 三で marks three as the divisor. The result is four, and で does not refer to a physical tool here.

