Approximate cost calculation

Hello!

I have the following formula -

a*k1 + b*k2 + c*k3 = P

This is a formula i'm trying to build. It will be used to calculate price of a specific good (P) according to criterions k1,k2,k3. Every k have its own value, thats why its being multiplied by coefficients a,b and c.

I have a history of many previous purchases where k1,k2,k3 and P are known and i need to approximately calculate a,b and c according to this.

Hope i explained this well.

Can someone help me with this?