Defining the costs
q
c
w
p