added sum stuff