Patio

You are planning to put in a square backyard patio, but haven't decided yet just how big to make it.  The paving 6"x6" paving stones cost $0.80 each, and the treated wood for the edges is $1.60 per foot.  Express the cost of the stones and wood depending on the length (and width) of the patio.