Algorithm to define min-Max ranges with some defined bound
$begingroup$
Having to populate the following table of MIN-MAX cells, starting with only the knowledge of the IC value
I was thinking about a formula to get the values of A, B, C, D, E, F, G
which works also for the values of IC and 2xIC
I'm able to get the values from 0 to IC using the following formula:
$$K = 3$$
$$LEVEL.MIN = frac{IC}{K} times (LEVEL-1)$$
$$LEVEL.MAX = frac{IC}{K} times (LEVEL)$$
I need another similar formula for the values of E, F, G, 2xIC.
Maybe, since $E=IC$, the formula should have $+IC$ as a fxed part.
algorithms
$endgroup$
add a comment |
$begingroup$
Having to populate the following table of MIN-MAX cells, starting with only the knowledge of the IC value
I was thinking about a formula to get the values of A, B, C, D, E, F, G
which works also for the values of IC and 2xIC
I'm able to get the values from 0 to IC using the following formula:
$$K = 3$$
$$LEVEL.MIN = frac{IC}{K} times (LEVEL-1)$$
$$LEVEL.MAX = frac{IC}{K} times (LEVEL)$$
I need another similar formula for the values of E, F, G, 2xIC.
Maybe, since $E=IC$, the formula should have $+IC$ as a fxed part.
algorithms
$endgroup$
$begingroup$
What do the different levels mean? What is IC? So I understand that "MIN" is the minimum value of some set, and "MAX" is the maximum value of some set, but what are these sets? Could you give more context to your problem? And how did you obtain the formulae that you wrote?
$endgroup$
– Matti P.
Jan 30 at 10:41
$begingroup$
Each level is a rang of economic values, and I have the IC value as input. They are needed to know in which level to put an item based on its value.
$endgroup$
– 1Z10
Jan 30 at 10:44
$begingroup$
Are there some conditions for the values of A, B, C, D, E, F, G .... ?
$endgroup$
– Matti P.
Jan 30 at 10:45
$begingroup$
Each level from 1 to 3 needs to have the same width = max - min Each level from 4 to 5 needs to have the same width = max - min and Level[N].min = Level[N-1].max
$endgroup$
– 1Z10
Jan 30 at 10:49
add a comment |
$begingroup$
Having to populate the following table of MIN-MAX cells, starting with only the knowledge of the IC value
I was thinking about a formula to get the values of A, B, C, D, E, F, G
which works also for the values of IC and 2xIC
I'm able to get the values from 0 to IC using the following formula:
$$K = 3$$
$$LEVEL.MIN = frac{IC}{K} times (LEVEL-1)$$
$$LEVEL.MAX = frac{IC}{K} times (LEVEL)$$
I need another similar formula for the values of E, F, G, 2xIC.
Maybe, since $E=IC$, the formula should have $+IC$ as a fxed part.
algorithms
$endgroup$
Having to populate the following table of MIN-MAX cells, starting with only the knowledge of the IC value
I was thinking about a formula to get the values of A, B, C, D, E, F, G
which works also for the values of IC and 2xIC
I'm able to get the values from 0 to IC using the following formula:
$$K = 3$$
$$LEVEL.MIN = frac{IC}{K} times (LEVEL-1)$$
$$LEVEL.MAX = frac{IC}{K} times (LEVEL)$$
I need another similar formula for the values of E, F, G, 2xIC.
Maybe, since $E=IC$, the formula should have $+IC$ as a fxed part.
algorithms
algorithms
edited Jan 30 at 11:30
1Z10
asked Jan 30 at 10:38
1Z101Z10
1105
1105
$begingroup$
What do the different levels mean? What is IC? So I understand that "MIN" is the minimum value of some set, and "MAX" is the maximum value of some set, but what are these sets? Could you give more context to your problem? And how did you obtain the formulae that you wrote?
$endgroup$
– Matti P.
Jan 30 at 10:41
$begingroup$
Each level is a rang of economic values, and I have the IC value as input. They are needed to know in which level to put an item based on its value.
$endgroup$
– 1Z10
Jan 30 at 10:44
$begingroup$
Are there some conditions for the values of A, B, C, D, E, F, G .... ?
$endgroup$
– Matti P.
Jan 30 at 10:45
$begingroup$
Each level from 1 to 3 needs to have the same width = max - min Each level from 4 to 5 needs to have the same width = max - min and Level[N].min = Level[N-1].max
$endgroup$
– 1Z10
Jan 30 at 10:49
add a comment |
$begingroup$
What do the different levels mean? What is IC? So I understand that "MIN" is the minimum value of some set, and "MAX" is the maximum value of some set, but what are these sets? Could you give more context to your problem? And how did you obtain the formulae that you wrote?
$endgroup$
– Matti P.
Jan 30 at 10:41
$begingroup$
Each level is a rang of economic values, and I have the IC value as input. They are needed to know in which level to put an item based on its value.
$endgroup$
– 1Z10
Jan 30 at 10:44
$begingroup$
Are there some conditions for the values of A, B, C, D, E, F, G .... ?
$endgroup$
– Matti P.
Jan 30 at 10:45
$begingroup$
Each level from 1 to 3 needs to have the same width = max - min Each level from 4 to 5 needs to have the same width = max - min and Level[N].min = Level[N-1].max
$endgroup$
– 1Z10
Jan 30 at 10:49
$begingroup$
What do the different levels mean? What is IC? So I understand that "MIN" is the minimum value of some set, and "MAX" is the maximum value of some set, but what are these sets? Could you give more context to your problem? And how did you obtain the formulae that you wrote?
$endgroup$
– Matti P.
Jan 30 at 10:41
$begingroup$
What do the different levels mean? What is IC? So I understand that "MIN" is the minimum value of some set, and "MAX" is the maximum value of some set, but what are these sets? Could you give more context to your problem? And how did you obtain the formulae that you wrote?
$endgroup$
– Matti P.
Jan 30 at 10:41
$begingroup$
Each level is a rang of economic values, and I have the IC value as input. They are needed to know in which level to put an item based on its value.
$endgroup$
– 1Z10
Jan 30 at 10:44
$begingroup$
Each level is a rang of economic values, and I have the IC value as input. They are needed to know in which level to put an item based on its value.
$endgroup$
– 1Z10
Jan 30 at 10:44
$begingroup$
Are there some conditions for the values of A, B, C, D, E, F, G .... ?
$endgroup$
– Matti P.
Jan 30 at 10:45
$begingroup$
Are there some conditions for the values of A, B, C, D, E, F, G .... ?
$endgroup$
– Matti P.
Jan 30 at 10:45
$begingroup$
Each level from 1 to 3 needs to have the same width = max - min Each level from 4 to 5 needs to have the same width = max - min and Level[N].min = Level[N-1].max
$endgroup$
– 1Z10
Jan 30 at 10:49
$begingroup$
Each level from 1 to 3 needs to have the same width = max - min Each level from 4 to 5 needs to have the same width = max - min and Level[N].min = Level[N-1].max
$endgroup$
– 1Z10
Jan 30 at 10:49
add a comment |
2 Answers
2
active
oldest
votes
$begingroup$
Let's look at the conditions that you gave. You say that the MIN of level $n$ should be equal to the MAX of level $n-1$. Using this condition, we should rename the variables like so:
- Level 1: MIN = 0, MAX = A
- Level 2: MIN = A, MAX = D
- Level 3: MIN = D, MAX = E= IC
- Level 4: MIN = E, MAX = G
- Level 5: MIN = G, MAX = 2IC = 2E
The next condition is that each level from 1 to 3 needs to have the same difference between MAX and MIN. In other words,
$$
A = D-A = IC-D
$$
From this condition we see that $D = 2A$ and of course $$A=IC-D qquad Rightarrow qquad D = 2IC - 2D qquad Rightarrow qquad 3D=2IC$$
The next condition is that levels 4 and 5 need to have the same difference between MAX and MIN. In other words,
$$
G-E = 2E - G
$$
Adding $E+G$ to boths sides, this is the same as $2G = 3E$. Now we can plug in these results to get the new level hierarchy:
- Level 1: MIN = $0$, MAX = $A$
- Level 2: MIN = $A$, MAX = $2A$
- Level 3: MIN = $2A$, MAX = $IC$
- Level 4: MIN = $IC$, MAX = $frac{3}{2} IC$
- Level 5: MIN = $frac{3}{2} IC$, MAX = $2IC$
With these conditions, the hierarchy is left with two free variables, IC and A. But otherwise, the hierarchy now follows the conditions that you gave.
$endgroup$
$begingroup$
$$A=frac{IC}{K}=frac{IC}{3}$$ I think I found the equivalent formula for the other values.
$endgroup$
– 1Z10
Jan 30 at 11:25
add a comment |
$begingroup$
Ok, I finally got it.
The values from E to 2xIC can be calculated using the following formula:
$$W=2$$
$$LEVEL.MIN = frac{LEVEL-1-1}{W} times IC$$
$$LEVEL.MAX = frac{LEVEL-1}{W} times IC$$
$endgroup$
add a comment |
Your Answer
StackExchange.ifUsing("editor", function () {
return StackExchange.using("mathjaxEditing", function () {
StackExchange.MarkdownEditor.creationCallbacks.add(function (editor, postfix) {
StackExchange.mathjaxEditing.prepareWmdForMathJax(editor, postfix, [["$", "$"], ["\\(","\\)"]]);
});
});
}, "mathjax-editing");
StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "69"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});
function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
noCode: true, onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});
}
});
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fmath.stackexchange.com%2fquestions%2f3093362%2falgorithm-to-define-min-max-ranges-with-some-defined-bound%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
2 Answers
2
active
oldest
votes
2 Answers
2
active
oldest
votes
active
oldest
votes
active
oldest
votes
$begingroup$
Let's look at the conditions that you gave. You say that the MIN of level $n$ should be equal to the MAX of level $n-1$. Using this condition, we should rename the variables like so:
- Level 1: MIN = 0, MAX = A
- Level 2: MIN = A, MAX = D
- Level 3: MIN = D, MAX = E= IC
- Level 4: MIN = E, MAX = G
- Level 5: MIN = G, MAX = 2IC = 2E
The next condition is that each level from 1 to 3 needs to have the same difference between MAX and MIN. In other words,
$$
A = D-A = IC-D
$$
From this condition we see that $D = 2A$ and of course $$A=IC-D qquad Rightarrow qquad D = 2IC - 2D qquad Rightarrow qquad 3D=2IC$$
The next condition is that levels 4 and 5 need to have the same difference between MAX and MIN. In other words,
$$
G-E = 2E - G
$$
Adding $E+G$ to boths sides, this is the same as $2G = 3E$. Now we can plug in these results to get the new level hierarchy:
- Level 1: MIN = $0$, MAX = $A$
- Level 2: MIN = $A$, MAX = $2A$
- Level 3: MIN = $2A$, MAX = $IC$
- Level 4: MIN = $IC$, MAX = $frac{3}{2} IC$
- Level 5: MIN = $frac{3}{2} IC$, MAX = $2IC$
With these conditions, the hierarchy is left with two free variables, IC and A. But otherwise, the hierarchy now follows the conditions that you gave.
$endgroup$
$begingroup$
$$A=frac{IC}{K}=frac{IC}{3}$$ I think I found the equivalent formula for the other values.
$endgroup$
– 1Z10
Jan 30 at 11:25
add a comment |
$begingroup$
Let's look at the conditions that you gave. You say that the MIN of level $n$ should be equal to the MAX of level $n-1$. Using this condition, we should rename the variables like so:
- Level 1: MIN = 0, MAX = A
- Level 2: MIN = A, MAX = D
- Level 3: MIN = D, MAX = E= IC
- Level 4: MIN = E, MAX = G
- Level 5: MIN = G, MAX = 2IC = 2E
The next condition is that each level from 1 to 3 needs to have the same difference between MAX and MIN. In other words,
$$
A = D-A = IC-D
$$
From this condition we see that $D = 2A$ and of course $$A=IC-D qquad Rightarrow qquad D = 2IC - 2D qquad Rightarrow qquad 3D=2IC$$
The next condition is that levels 4 and 5 need to have the same difference between MAX and MIN. In other words,
$$
G-E = 2E - G
$$
Adding $E+G$ to boths sides, this is the same as $2G = 3E$. Now we can plug in these results to get the new level hierarchy:
- Level 1: MIN = $0$, MAX = $A$
- Level 2: MIN = $A$, MAX = $2A$
- Level 3: MIN = $2A$, MAX = $IC$
- Level 4: MIN = $IC$, MAX = $frac{3}{2} IC$
- Level 5: MIN = $frac{3}{2} IC$, MAX = $2IC$
With these conditions, the hierarchy is left with two free variables, IC and A. But otherwise, the hierarchy now follows the conditions that you gave.
$endgroup$
$begingroup$
$$A=frac{IC}{K}=frac{IC}{3}$$ I think I found the equivalent formula for the other values.
$endgroup$
– 1Z10
Jan 30 at 11:25
add a comment |
$begingroup$
Let's look at the conditions that you gave. You say that the MIN of level $n$ should be equal to the MAX of level $n-1$. Using this condition, we should rename the variables like so:
- Level 1: MIN = 0, MAX = A
- Level 2: MIN = A, MAX = D
- Level 3: MIN = D, MAX = E= IC
- Level 4: MIN = E, MAX = G
- Level 5: MIN = G, MAX = 2IC = 2E
The next condition is that each level from 1 to 3 needs to have the same difference between MAX and MIN. In other words,
$$
A = D-A = IC-D
$$
From this condition we see that $D = 2A$ and of course $$A=IC-D qquad Rightarrow qquad D = 2IC - 2D qquad Rightarrow qquad 3D=2IC$$
The next condition is that levels 4 and 5 need to have the same difference between MAX and MIN. In other words,
$$
G-E = 2E - G
$$
Adding $E+G$ to boths sides, this is the same as $2G = 3E$. Now we can plug in these results to get the new level hierarchy:
- Level 1: MIN = $0$, MAX = $A$
- Level 2: MIN = $A$, MAX = $2A$
- Level 3: MIN = $2A$, MAX = $IC$
- Level 4: MIN = $IC$, MAX = $frac{3}{2} IC$
- Level 5: MIN = $frac{3}{2} IC$, MAX = $2IC$
With these conditions, the hierarchy is left with two free variables, IC and A. But otherwise, the hierarchy now follows the conditions that you gave.
$endgroup$
Let's look at the conditions that you gave. You say that the MIN of level $n$ should be equal to the MAX of level $n-1$. Using this condition, we should rename the variables like so:
- Level 1: MIN = 0, MAX = A
- Level 2: MIN = A, MAX = D
- Level 3: MIN = D, MAX = E= IC
- Level 4: MIN = E, MAX = G
- Level 5: MIN = G, MAX = 2IC = 2E
The next condition is that each level from 1 to 3 needs to have the same difference between MAX and MIN. In other words,
$$
A = D-A = IC-D
$$
From this condition we see that $D = 2A$ and of course $$A=IC-D qquad Rightarrow qquad D = 2IC - 2D qquad Rightarrow qquad 3D=2IC$$
The next condition is that levels 4 and 5 need to have the same difference between MAX and MIN. In other words,
$$
G-E = 2E - G
$$
Adding $E+G$ to boths sides, this is the same as $2G = 3E$. Now we can plug in these results to get the new level hierarchy:
- Level 1: MIN = $0$, MAX = $A$
- Level 2: MIN = $A$, MAX = $2A$
- Level 3: MIN = $2A$, MAX = $IC$
- Level 4: MIN = $IC$, MAX = $frac{3}{2} IC$
- Level 5: MIN = $frac{3}{2} IC$, MAX = $2IC$
With these conditions, the hierarchy is left with two free variables, IC and A. But otherwise, the hierarchy now follows the conditions that you gave.
answered Jan 30 at 11:09
Matti P.Matti P.
2,2811514
2,2811514
$begingroup$
$$A=frac{IC}{K}=frac{IC}{3}$$ I think I found the equivalent formula for the other values.
$endgroup$
– 1Z10
Jan 30 at 11:25
add a comment |
$begingroup$
$$A=frac{IC}{K}=frac{IC}{3}$$ I think I found the equivalent formula for the other values.
$endgroup$
– 1Z10
Jan 30 at 11:25
$begingroup$
$$A=frac{IC}{K}=frac{IC}{3}$$ I think I found the equivalent formula for the other values.
$endgroup$
– 1Z10
Jan 30 at 11:25
$begingroup$
$$A=frac{IC}{K}=frac{IC}{3}$$ I think I found the equivalent formula for the other values.
$endgroup$
– 1Z10
Jan 30 at 11:25
add a comment |
$begingroup$
Ok, I finally got it.
The values from E to 2xIC can be calculated using the following formula:
$$W=2$$
$$LEVEL.MIN = frac{LEVEL-1-1}{W} times IC$$
$$LEVEL.MAX = frac{LEVEL-1}{W} times IC$$
$endgroup$
add a comment |
$begingroup$
Ok, I finally got it.
The values from E to 2xIC can be calculated using the following formula:
$$W=2$$
$$LEVEL.MIN = frac{LEVEL-1-1}{W} times IC$$
$$LEVEL.MAX = frac{LEVEL-1}{W} times IC$$
$endgroup$
add a comment |
$begingroup$
Ok, I finally got it.
The values from E to 2xIC can be calculated using the following formula:
$$W=2$$
$$LEVEL.MIN = frac{LEVEL-1-1}{W} times IC$$
$$LEVEL.MAX = frac{LEVEL-1}{W} times IC$$
$endgroup$
Ok, I finally got it.
The values from E to 2xIC can be calculated using the following formula:
$$W=2$$
$$LEVEL.MIN = frac{LEVEL-1-1}{W} times IC$$
$$LEVEL.MAX = frac{LEVEL-1}{W} times IC$$
answered Jan 30 at 11:22
1Z101Z10
1105
1105
add a comment |
add a comment |
Thanks for contributing an answer to Mathematics Stack Exchange!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
Use MathJax to format equations. MathJax reference.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fmath.stackexchange.com%2fquestions%2f3093362%2falgorithm-to-define-min-max-ranges-with-some-defined-bound%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
$begingroup$
What do the different levels mean? What is IC? So I understand that "MIN" is the minimum value of some set, and "MAX" is the maximum value of some set, but what are these sets? Could you give more context to your problem? And how did you obtain the formulae that you wrote?
$endgroup$
– Matti P.
Jan 30 at 10:41
$begingroup$
Each level is a rang of economic values, and I have the IC value as input. They are needed to know in which level to put an item based on its value.
$endgroup$
– 1Z10
Jan 30 at 10:44
$begingroup$
Are there some conditions for the values of A, B, C, D, E, F, G .... ?
$endgroup$
– Matti P.
Jan 30 at 10:45
$begingroup$
Each level from 1 to 3 needs to have the same width = max - min Each level from 4 to 5 needs to have the same width = max - min and Level[N].min = Level[N-1].max
$endgroup$
– 1Z10
Jan 30 at 10:49