Sum calculation within a repeat-group to get subtotal

@sergiousme, this post discussed previously should help you solve your issue: