Small formula for calculation

Ramballah

Active Member
Joined
Sep 25, 2018
Messages
334
Office Version
  1. 365
Platform
  1. Windows
Hello Everyone,

Today I feel stupid once again, I feel like this answer is probably really easy but I just cannot figure this out.
I have a sheet which has lvl 1 to lvl 100 noted down and the XP needed to gruduate the level.
For example to "achieve" lvl 1 i need 500 xp. Now the issue with this little game is that there is no total xp mentioned anywhere.
All I know is how much xp it takes to the next lvl, and once you reach the level your XP get's reset to 0.
So I have figured out the total XP by now. But now first look at my sheet then Ill explain my question.

15002613,0005125,5007638,000
21,0002713,5005226,0007738,500Level59
31,5002814,0005326,5007839,000XP in Level9,750
42,0002914,5005427,0007939,500XP needed1,659,750
52,5003015,0005527,5008040,000
63,0003115,5005628,0008140,500
73,5003216,0005728,5008241,000
84,0003316,5005829,0008341,500
94,5003417,0005929,5008442,000
105,0003517,5006030,0008542,500
115,5003618,0006130,5008643,000
126,0003718,5006231,0008743,500
136,5003819,0006331,5008844,000
147,0003919,5006432,0008944,500
157,5004020,0006532,5009045,000
168,0004120,5006633,0009145,500
178,5004221,0006733,5009246,000
189,0004321,5006834,0009346,500
199,5004422,0006934,5009447,000
2010,0004522,5007035,0009547,500
2110,5004623,0007135,5009648,000
2211,0004723,5007236,0009748,500
2311,5004824,0007336,5009849,000
2412,0004924,5007437,0009949,500
2512,5005025,0007537,50010050,000
2,525,000
Here you can see the lvls with the XP going up by 500 each time.
On the right you see a little section where it says Level 59, XP in level 9,750 and XP needed 1,659,750.
What I want is to just fill in which level I am (59 for example) and that I have 9,750 XP already into the 29,500. And then it calculates exactly how much XP I need till 2,525,000 total XP.
So I did it manually for now but I rather want it to be automated if possible. So if I were to be lvl 75 I would only need: 1,137,500 XP till lvl 100 if I don't have any XP in the level.
I hope I was clear enough, if not please ask away!

Thanks in advance
 

Excel Facts

Remove leading & trailing spaces
Save as CSV to remove all leading and trailing spaces. It is faster than using TRIM().
Noting that there is a consistent increase of 500 each time
Book1
A
259
39,750
41,659,750
Sheet1
Cell Formulas
RangeFormula
A4A4=SUMPRODUCT(500*ROW(INDIRECT("1:100")))-IFERROR(SUMPRODUCT(500*ROW(INDIRECT("1:"&A2-1))),0)-A3
 
Upvote 0
Noting that there is a consistent increase of 500 each time
Book1
A
259
39,750
41,659,750
Sheet1
Cell Formulas
RangeFormula
A4A4=SUMPRODUCT(500*ROW(INDIRECT("1:100")))-IFERROR(SUMPRODUCT(500*ROW(INDIRECT("1:"&A2-1))),0)-A3
It looks like a solid formula but it does not give me the correct answer. If I change my lvl to 16, and xp in level to 5315 for example the result should be: 2,459,685 but ur formula gives 2,524,497 which is only 503 xp from lvl 100 (2,525,000 xp)
While I am at it, do you think theres also a possibility to add a few questions?
If i am lvl 16 and got 5,315 xp can u add A5 to show my current total XP which is: 65,315 and have another cell in A6 for example that if my current xp is 65315 and I would gain let's say 1,000,000 xp on top of that it would calculate which LVL i will end up with which should be: 64
 
Upvote 0
That's what I get
Book1
A
216
35,315
42,459,685
Sheet1
Cell Formulas
RangeFormula
A4A4=SUMPRODUCT(500*ROW(INDIRECT("1:100")))-IFERROR(SUMPRODUCT(500*ROW(INDIRECT("1:"&A2-1))),0)-A3
My bad, I used a wrong cell reference. Also can you look at my previous reply, I editted that one with a new question...
 
Upvote 0
Some simpler formulas:

Book1
AB
1Level59
2XP in level9750
3XP needed for next level20250
4XP needed to get to level 1001630250
Sheet2
Cell Formulas
RangeFormula
B3B3=(B1+1)*500-B2
B4B4=2525000-B2-(250*B1*(B1+1))


These seem to work in my testing, but try them and let us know.
 
Upvote 0
Some simpler formulas:

Book1
AB
1Level59
2XP in level9750
3XP needed for next level20250
4XP needed to get to level 1001630250
Sheet2
Cell Formulas
RangeFormula
B3B3=(B1+1)*500-B2
B4B4=2525000-B2-(250*B1*(B1+1))


These seem to work in my testing, but try them and let us know.
These work nicely I think I might use this one in stead. Now just for my last questions remain which I asked for in my first reply. I hope its possible.
 
Upvote 0
Oh, the magic of triangle numbers! ?

Try this:

Book1
AB
1Level3
2XP in level22
3Total XP3022
4XP needed for next level1978
5XP needed to get to level 1002521978
Sheet2
Cell Formulas
RangeFormula
B3B3=(B1+1)*B1*250+B2
B4B4=(B1+1)*500-B2
B5B5=2525000-B3
 
Upvote 0
Here's the last part:

Book1
AB
1Level34
2XP in level22
3Total XP297522
4XP needed for next level17478
5XP needed to get to level 1002227478
6
7Additional points:500000
8Gets you to level:55
Sheet2
Cell Formulas
RangeFormula
B3B3=(B1+1)*B1*250+B2
B4B4=(B1+1)*500-B2
B5B5=2525000-B3
B8B8=INT((SQRT(1+(B7+B3)/62.5)-1)/2)
 
Upvote 0

Forum statistics

Threads
1,223,884
Messages
6,175,175
Members
452,615
Latest member
bogeys2birdies

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top