[SOLVED] Calculate car values

I'm not really a student but this is part of my "homework" for my job. I have an assignment at work to come up with a formula to help us calculate car values based on 3 inputs. I'm sorry if this is not the best place to put this but was unsure where. If moderators object, please direct me to the correct topic and I'll happily move it there.

Anyway, here's the problem. I have the starting price of the car, the value as a percentage of the car at 36, 48 and 60 months old. These percentages assume the car is driven 10,000 per year. I'm assuming this is some type of a non-linear problem.

So for example, say the car is $20,000 new. The value at 36 months is 55% of it's original value. So assuming the car was driven 10,000 miles each year, it's now worth $11,000. Does this make sense? Hope so.

So here's the solution I need to figure out. I need to do a spread sheet that I can put the original value of the car, number of months old, and number of miles on it. I need the result to be the correct current value of the car based on those 3 inputs. All help is very appreciated!

define variables:
P: current car price. O: original car price.
miles: mile record of the car. months: age of the car.

10,000 miles each year, driven 36 months, that is 30,000miles in total. And the price difference is $9,000. So the car lost $0.3 for its each mile to go. Then we can have a price function according to the miles:
P(miles) = O - 0.3*miles (miles<66,666)

I assume the P is also propotional to (1/months), so here is a price function according to months as well:
P(months) = O * (19.8/months) (months>19.8)

Finally, the average price P = (P(miles) + P(months))/2

Actually you can choose the price which the most benifits to you. This is totally up to you.