Actually I think I've managed it. I had to activate calculations on site wide settings then identified both categories as item and finally add a custom calculation on the course total in the form of:
I just thought this could be achieved without the need of a custom calculation.
Thank you
Hugo Ribeiro