# Using constraints in Solve[] [on hold]

I'm not sure if the title fits.

I'm basically just looking for a way to define a value and constrain it to $[a,b]$ when I use Solve later.

More specifically, I have a set of three equations where both sides are normalized to be in $[0, 1]$.

The right hand side is just a Ratio $\dfrac{b_i}{\sum{b_i}}$.

The left hand side is similar because it is also normalized to be in $[0, 1]$. I have an index which is based on a multiplicative function where I have a product of some variables which are all to the power of some exponent and then divided by the sum of the indices, therefore $[0, 1]$. Since Solve is not able to solve this and for context reasons, I would like to restrict the exponents to values from $[-1, 1]$. Can I do this?

n = 3;
ebau[1] = Ebau - Sum[ebau[i], {i, 2, n}];
a[1] = A - Sum[a[i], {i, 2, n}];
b[1] = B - Sum[b[i], {i, 2, n}];
Fair = Table[a[i]^(\[Alpha])*ebau[i]^(-\[Beta])*b[i]^(\[Gamma]), {i, 1, n}];
Weight = Simplify[Fair/Sum[Fair[[i]], {i, n}]];
phiSO = {b[1]/B, b[2]/B, b[3]/B};
Solve[Table[ phiSO[[i]] == Weight[[i]], {i, 1, n}],
{\[Alpha], \[Beta], \[Gamma]}, Reals]

-
What, precisely, are these equations? Solve[] and Reduce[] do support constraining the variables (via inequalities), but unless you give a more concrete example, we can't be very helpful... –  Ｊ. Ｍ. Aug 24 '12 at 10:28
I still dont get how to properbly include mathematica code, someone told me it was CRTL+K, but that does not seem to work, so heres my problem: n = 3; ebau[1] = Ebau - Sum[ebau[i], {i, 2, n}]; a[1] = A - Sum[a[i], {i, 2, n}]; b[1] = B - Sum[b[i], {i, 2, n}]; Fair = Table[ a[i]^([Alpha])*ebau[i]^(-[Beta])*b[i]^([Gamma]), {i, 1, n}]; Weight = Simplify[Fair/Sum[Fair[[i]], {i, n}]]; phiSO = {b[1]/B, b[2]/B, b[3]/B}; Solve[Table[ phiSO[[i]] == Weight[[i]], {i, 1, n}], {[Alpha], [Beta], [Gamma]}, Reals] –  Max M Aug 24 '12 at 10:37
ctrl-k is not used to paste code, but to format as a code block code you already pasted. So the flow is: paste MMA code (preferably as InputForm or so), select block, hit ctrl-k (or the code block icon above the edit field). –  Sjoerd C. de Vries Aug 24 '12 at 11:24
You can replace the first argument of Solve in your code with Join[Table[phiSO[[i]] == Weight[[i]], {i, 1, n}], (-1 <= # <= 1) & /@ {\[Alpha], \[Beta], \[Gamma]}] to include the constraints on \[Alpha], \[Beta], \[Gamma]. –  kguler Aug 24 '12 at 11:25
This question should be put on hold because Solve indicates that it cannot solve even a single one of the equations for a single variable, and the OP has not been seen at the site in over a six months. –  Michael E2 Mar 8 at 3:25