Calculate percentage dependant on a range

HelpNoob

New member
Joined
Jan 19, 2021
Messages
6
I wish I'd paid attention more in school, but that was decades ago and I'm not sure I'm smart enough to have retained what I need, so let's get to the question.

I need to calculate a bonus percentage based on a score from 1 to 45.
If I have a score of 1 then I get 4%
If I have a score of 45 then I get 6%
If my score is between 1 and 45 then I get the portion of a calculation. e.g. if my score is 22.5 (halfway between 1 and 45?) then I get 5% (halfway between 4% and 6%).
If my score is 2 then I'd get a smidgeon over 4%
If my score is 44 then I'd get a smidgeon below 6%

Is there a formula to calculate this?
 
I wish I'd paid attention more in school, but that was decades ago and I'm not sure I'm smart enough to have retained what I need, so let's get to the question.

I need to calculate a bonus percentage based on a score from 1 to 45.
If I have a score of 1 then I get 4%
If I have a score of 45 then I get 6%
If my score is between 1 and 45 then I get the portion of a calculation. e.g. if my score is 22.5 (halfway between 1 and 45?) then I get 5% (halfway between 4% and 6%).
If my score is 2 then I'd get a smidgeon over 4%
If my score is 44 then I'd get a smidgeon below 6%

Is there a formula to calculate this?
Yes There is!

Do you remember the equation of a straight line passing through two points?

Do a Google search to refresh your memory - then tell us what you found.
 
Last edited by a moderator:
Another way to look at it, rather than go through the more formal mathematical way, is to consider the following table. I'll walk you through converting 1-10 to 4-6. You can then try it for 1-45. Basically you want to complete the second column of the table below.
First question for you: How many increments (steps) are there from 1 to 10 in the left column?
14
2
3
4
5
6
7
8
9
106
 
Yes There is!

Do you remember the equation of a straight line passing through two points?

Do a Google search to refresh your memory - then tell us what you found.

No, I don't remember (it was 50 years ago) but the interweb tells me
y=mx+b

I see m=(y2−y1) / (x2−x1)
so m= (45-1) / (6-4)
so the slope m=22

I don't understand the other unknowns so let's pick a y halfway between my score, 22.5.
Where does it go in the y=22x+b ?
 
Another way to look at it, rather than go through the more formal mathematical way, is to consider the following table. I'll walk you through converting 1-10 to 4-6. You can then try it for 1-45. Basically you want to complete the second column of the table below.
First question for you: How many increments (steps) are there from 1 to 10 in the left column?
14
2
3
4
5
6
7
8
9
106

Yes please, show me how to calculate.
A1: There's 9 increment steps in the first column.
 
No, I don't remember (it was 50 years ago) but the interweb tells me
y=mx+b

I see m=(y2−y1) / (x2−x1)
so m= (45-1) / (6-4)
so the slope m=22

I don't understand the other unknowns so let's pick a y halfway between my score, 22.5.
Where does it go in the y=22x+b ?
One of your points on the line is (6, 45). Then using the equation of the line:

45 = 22 * 6 + b ..... b = ?

And you are done! Almost...

check your answer using the other known point (4 , 1)

now you are done!!
 
Last edited by a moderator:
One of your points on the line is (6, 45). Then using the equation of the line:

45 = 22 * 6 + b ..... b = ?

And you are done! Almost...

check your answer using the other known point (1, 4)

now you are done!!

So if 45 = 22 * 6 + b
then
45 = 132 + b
and if I subtract 132 from both sides
-87=b
So b = -87 ?
That's not right :-(
 
So if 45 = 22 * 6 + b
then
45 = 132 + b
and if I subtract 132 from both sides
-87=b
So b = -87 ?
That's not right :-(
Why do you think so? Why do you think it is NOT RIGHT?
 
Why do you think so?

Because for a value of 1 through 45 I want the equivalent value between 4% and 6%.
If I try 22.5 I expect 5%
For y=mx+b we calculated
m=22
b=-87
So y=(22x)+ -87

I'm still not sure if my sample midpoint test of 22.5 is the x or the y so let's try both:
22.5=(22x)+ -87
add 87 to both sides
109.5=22x
divide both sides by 22 gives
x = 4.9773
Close but no cigar! So let's try
y=(22 * 22.5)+ -87
y=495-87
y=408
Nope!
 
Because for a value of 1 through 45 I want the equivalent value between 4% and 6%.
If I try 22.5 I expect 5%
For y=mx+b we calculated
m=22
b=-87
So y=(22x)+ -87

I'm still not sure if my sample midpoint test of 22.5 is the x or the y so let's try both:
22.5=(22x)+ -87
add 87 to both sides
109.5=22x
divide both sides by 22 gives
x = 4.9773
Close but no cigar! So let's try
y=(22 * 22.5)+ -87
y=495-87
y=408
Nope!
"I'm still not sure if my sample midpoint test of 22.5 is the x or the y so let's try both:"

Sample midpoint is NOT 22.5. The midpoint of (6,45) & (4,1) is:

((6+4)/2 , (45+1)/2) → (5, 23)
 
Top