0

I would like some help in elaborating a formula for a service I will be providing to a retailer's client.

In simple terms, I would be paid a $5\%$ percentage over the price of the client's purchase, with a minimum cost of service of $2$ and a maximum of $10$.

It is important to say the comission would be paid by the client, so the amount would be added to the client's total cost.

Here are some examples:

If a client makes a purchase of $20$ and picks the service, he will pay a total of $22$;

If a client makes a purchase of $40$, he will pay a total of $42$.

If a client makes a purchase of $80$, he will pay a total of $84$.

If a client makes a purchase of $199$, he will pay a total of $208.95$.

If a client makes a purchase of $1000$, he will pay a total of $1010$.

InqX
  • 9
  • Ignoring the fact that this has nothing to do with 'logic' as far as the tag description goes: Why don't you just define your function precisely the way you described them to us? I.e. $f(x) = x+2$ for $0 \le x <40$, $f(x) = 1.05 \cdot x$ for $40 \le x < 200$ and $f(x) = x+10$ otherwise. – Stefan Mesken Jun 04 '16 at 03:52
  • Thank you very much, for your help. – InqX Jun 04 '16 at 12:27

1 Answers1

1

If I well understand the cost of your service is: $$ \begin{cases} y=2 \qquad \qquad \qquad\qquad \quad for\qquad 0<x\le 40\\ y=2+0.05(x-40) \qquad for \qquad 40<x\le 200\\ y=10 \qquad \qquad \qquad\qquad for\qquad x>200 \end {cases} $$ If you want you can express this with asingle expression as $$ y=10+0.5(2+0.5(0.05(x-40)+|0.05(x-40)|)-10-|2+0.5(0.05(x-40)+|0.05(x-40)|)-10|) $$ ( see the graph here) and add this to the purchase, but it does not seems a good idea to me.

Emilio Novati
  • 62,675