Formula to find % discount, giving as input the Full Price and the Net Price, with rules.

Amoldavskii

New Member
Joined
Jan 19, 2021
Messages
7
Office Version
  1. 365
Platform
  1. Windows
Hello,

I need help please for an automatic/ semi automatic % finder.
I Need to find which % of discount is a Net price, from a Full price.
We have 5 possible groups:
A. Under 49.99%
B. From 50% to 50+5%
C. from 50+5+1% to 50+5+5% (to 50+10%)
D from 50+10% to 50+10+5% (to 50+15%)
E. from 50+15+1% to 50+15+5 and higher. at 50+15 rule break and can higher will be 50+15+18 or 50+15+26 ect. (NO more 50+20+1!)

Considering the upper rules, I want to ask if it's possible to find from the input of full and net price, to exactly which % it's =?
I attach my actual Excel Formula and some examples, please view it to understand better.

So, a % discount finder considering the logic of the discount groups.

Help file.xlsx
ABCDEFGHIJKLMNOPQRSTUVWXYZAAABACADAEAF
1
2
3FULLNET50 + …FULLNET50 + …
417,163,4060,4%17,168,194,5%
5
6
7
8FULLNET0+ / 50 + …LISTINONetto0+ / 50 + …
910,645,8545,0%<<I need similar to D9 formula (it's italian, SE = IF)Can find EVEN SIMILAR SITUATIONS with ,%, ?10,644,9453,6%= 50+5+2,2%
10Editable = my XEditable = my YResult (don't touch)
11
12
13
14
15
16
17FULLNET0+ / 50 + …….+3° sconto
1810,644,945,00%2,2%
19
20
21FULLNET0+ / 50 + …….+3° sconto
2214,683,6750%
23
24
25
26EXAMPLES Group 1Group 2Group 3Group 4Group 5
27Full price45%46%47%48%49%50%50+1%50+2%50+3%50+4% 50%+5%50+5+1%50+5+2%50+5+3%50+5+4%50+5+5% 50% + 10%50+10+1%50+10+2%50+10+3%50+10+4%50+10+5% 50% + 15%50+15+1%50+15+2%50+15+3%50+15+4%50+15+5%50+15+750+15+28 ect
28Product A10,645,855,755,645,535,435,325,275,215,165,115,055,004,954,904,854,804,794,744,694,644,604,554,524,484,434,394,344,30
29Product B8,484,664,584,494,414,324,244,204,164,114,074,033,993,953,913,873,833,823,783,743,713,673,633,603,573,533,503,463,42
Foglio1
Cell Formulas
RangeFormula
C4,I4C4=B4*0.5*(1-D4)
D9,J9D9=IF((1-(C9/B9/0.5)<1),(1-(C9/B9)),(1-(C9/B9/0.5)))
C18,C22C18=B18*0.5*(1-D18)*(1-E18)
C28:C29C28=B28*0.55
D28:D29D28=B28*0.54
E28:E29E28=B28*0.53
F28:F29F28=B28*0.52
G28:G29G28=B28*0.51
H28:H29H28=B28*0.5
I28:I29,N28:N29,T28:T29,Z28:Z29I28=H28*0.99
J28:J29,O28:O29,U28:U29,AA28:AA29J28=H28*0.98
K28:K29,P28:P29,V28:V29,AB28:AB29K28=H28*0.97
L28:L29,Q28:Q29,W28:W29,AC28:AC29L28=H28*0.96
M28:M29,R28:R29,X28:X29,AD28:AD29M28=H28*0.95
S28S28=H28*0.9
Y28:Y29Y28=H28*0.85
 

Excel Facts

Spell Check in Excel
Press F7 to start spell check in Excel. Be careful, by default, Excel does not check Capitalized Werds (whoops)
Check formula at E4 , E9 , K4 & K9 for grouping. this formula is in E4 for Cell D4
Excel Formula:
=IF(D4<0.5,D4,IF(D4<=0.55,"50 + "&ROUND((D4-0.5)*100,1)&"%",IF(D4<=0.6,"50 + 5 + "&ROUND((D4-0.55)*100,1)&"%",IF(D4<=0.65,"50 + 10 + "&ROUND((D4-0.6)*100,1)&"%","50 + 15 + "&ROUND((D4-0.65)*100,1)&"%"))))

Book1
ABCDEFGHIJKLM
1
2
3FULLNET50 + …FULLNET50 + …
417.163.3976860%50 + 10 + 0.4%17.168.19394.5%4.5%
5
6
7
8FULLNET0+ / 50 + …LISTINONetto0+ / 50 + …
910.645.8545.0%45.0%Can find EVEN SIMILAR SITUATIONS with ,%, ?10.644.9453.57%50 + 3.6%
10Editable = my XEditable = my YResult (don't touch)
11
12
13
14
15
16
17FULLNET0+ / 50 + …….+3° sconto
1810.644.9428125%2%
19
20
21FULLNET0+ / 50 + …….+3° sconto
2214.683.6750%
23
24
25
26EXAMPLES Group 1Group 2
27Full price0.450.460.470.480.490.550+1%50+2%50+3%50+4% 50%+5%
28Product A10.645.8525.74565.63925.53285.42645.325.26685.21365.16045.10725.054
29Product B8.484.6644.57924.49444.40964.32484.244.19764.15524.11284.07044.028
Sheet1
Cell Formulas
RangeFormula
C4,I4C4=B4*0.5*(1-D4)
E4,K9,E9,K4E4=IF(D4<0.5,D4,IF(D4<=0.55,"50 + "&ROUND((D4-0.5)*100,1)&"%",IF(D4<=0.6,"50 + 5 + "&ROUND((D4-0.55)*100,1)&"%",IF(D4<=0.65,"50 + 10 + "&ROUND((D4-0.6)*100,1)&"%","50 + 15 + "&ROUND((D4-0.65)*100,1)&"%"))))
D9,J9D9=IF((1-(C9/B9/0.5)<1),(1-(C9/B9)),(1-(C9/B9/0.5)))
C18,C22C18=B18*0.5*(1-D18)*(1-E18)
C28:C29C28=B28*0.55
D28:D29D28=B28*0.54
E28:E29E28=B28*0.53
F28:F29F28=B28*0.52
G28:G29G28=B28*0.51
H28:H29H28=B28*0.5
I28:I29I28=H28*0.99
J28:J29J28=H28*0.98
K28:K29K28=H28*0.97
L28:L29L28=H28*0.96
M28:M29M28=H28*0.95
 
Upvote 0
Unless I'm missing something, try entering =B9 into B28, then
Excel Formula:
=XLOOKUP(C9,B28:AD28,B27:AD27,"",1)
into D9.
 
Upvote 0
In my example:
The information I always have are the Full Price (B9) and Net Price (C9).
The X I need to find is D9

The data from A26 and lower are examples of possible situations, I tried by putting it, to show "which range it need to fit".
But even in this range, there can be imprecisions in prices, to give as results 50+10+4.6%. (example)
 
Upvote 0
But even in this range, there can be imprecisions in prices, to give as results 50+10+4.6%. (example)
So are you saying that you want the exact discount calculated rather than the nearest one on the scale shown?

With a simple scale, xx.xx% it would be possible, but with xx.xx%+yy.yy%+zz.zz% you are asking the impossible.
 
Upvote 0
ok let's forget about "But even in this range, there can be imprecisions in prices, to give as results 50+10+4.6%. (example)"

I believed it's possible assuming that 50+10+3% = 56.4%, so something similar to "if D9=value 56.4% = result 50+10+3%
(there are 28 standard discounts %, like in the rows from A28 to AD28)
 
Upvote 0
@Amoldavskii what about my solution?


To be honest I use for first time the Xl2bb addon and having Excel in italian, even when I translate the "if" and "round" in usual italian formulas, it doesn't read the formula correctly.

I thank you very much because I'm going to study your formula as good as I can, and translate or repair it properly.
 
Upvote 0
Did you try copying the whole XL2BB mini table using the copy icon in the top left corner, then pasting to a blank sheet?

I though that doing so would translate it automatically, unless it can translate to English, but not back again.

General rule of translation, in addition to the function names, you would need to change commas to semicolons and dots to commas.
 
Upvote 0
Did you try copying the whole XL2BB mini table using the copy icon in the top left corner, then pasting to a blank sheet?

I though that doing so would translate it automatically, unless it can translate to English, but not back again.

General rule of translation, in addition to the function names, you would need to change commas to semicolons and dots to commas.
thanks for the advice, I found an utility that translate them directly.

Now it's working, but the result is imperfect because trying some simulations, it doesn't split the second discount, but I'm sure the maabdi formula has something I can inspire.
 
Upvote 0

Forum statistics

Threads
1,223,909
Messages
6,175,315
Members
452,634
Latest member
cpostell

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