profit function

Calculate Profit based on cost:margin ratio