3

Say I have a $K$-component alloy system, where the $K$ components are chosen from $N$ possible metal elements ($N>K$), and the concentration of each component always ranges from $a$% to $b$% (only consider integer percentages). Two alloys are considered to be different if any metal content differs by 1%. If we don't distinguish the arrangement of the components (i.e. the order doesn't matter), what is the total number of unique alloy compositions?

For now I only know if we assume the concentrations of all compoenents are always equal, the total number of unique alloy compositions is $\displaystyle{N \choose K} = \frac{N!}{(N-K)!K!}$. But how should we take into account the percentage constraint?

Edit: To make a component considered as "exists" in the alloy, obviously it has to be at least having a percentage of 1%, thus we always have $K−1 \le a \le b \le 100−K+1$.

To give you some idea: let's say $K=3,a=2,b=98$, the first component can take a percentage equal to $2,3,\ldots,98$, but when the first component takes a percentage of 98% for example, the other two components have to both take a percentage of 1%.

  • You should never change a material aspect of a question after answer(s) have been received as it may invalidate posted answer(s). – true blue anil Feb 28 '23 at 19:52
  • @trueblueanil Sorry about that, but I don't think my edit changes the question, as it only makes sense to restrict to integers. – Shaun Han Feb 28 '23 at 19:57

3 Answers3

2

Too long for a comment. I suspect that your question does not have a nice closed form answer.

There are ${N}\choose{K}$ ways to choose the metals. Then you want to multiply that by the number of compositions of $100$ into $K$ parts, where the parts are restricted to the integers in $[a,b]$.

Start with the wikipedia page on compositions. For the restriction to $[a,b]$ this article linked there might help: Compositions of $n$ with parts in a set.

Ethan Bolker
  • 95,224
  • 7
  • 108
  • 199
  • Initially, I felt that the second part of the question - allocating integer weights to each alloy can be done using stars and bars. But, here we are constrained to use the positive integers $a$ through $b$, – Quasar Feb 28 '23 at 21:37
  • Please see my edit – Shaun Han Feb 28 '23 at 21:39
  • 1
    To complete you can use formulas in the answers here, after normalizing all percentages in the composition by subtracting $a$. – Fabius Wiesner Feb 28 '23 at 21:42
2

You want to find the number of ways to distribute $100$ percentage points into $N$ boxes, of which $N-K$ are empty and the remaining $K$ have between $a$ and $b$ percentage points.

First, fix $K$. We can use a generating function $G(z)$ to count the number of possibilities.

$$\tag{1} G(z)=(z^{a}+z^{a+1}+\cdots+z^{b})^K=z^{aK}(1-z^{1-a+b})^K(1-z)^{-K} $$

By appealing to the binomial theorem, we may write

$$\tag{2} G(z)=z^{aK}\left[\sum\limits_{m=0}^K\left(\begin{matrix}K \\ m \end{matrix}\right) (-z^{1-a+b})^{m}\right]\left[\sum\limits_{n=0}^\infty \left(\begin{matrix}-K \\ n\end{matrix}\right) (-z)^n\right] $$

The coefficient of $z^{100}$ in the Maclaurin expansion of $G$ corresponds to the number of possibilities $\Omega_K$. By setting $aK+m(1-a+b)+n=100$ we can collapse one sum to find

$$\tag{3} \Omega_K=\sum\limits_{m=0}^M(-1)^{aK+m(b-a)} \left(\begin{matrix}K \\ m \end{matrix}\right) \left(\begin{matrix}-K \\ 100-aK-m(1-a+b)\end{matrix}\right) $$

Where $M=\operatorname{floor}(\frac{100-aK}{1-a+b})$. The total number of combinations $\Omega(N,K)$ is then $\Omega_K$ weighted by the number of ways to choose $K$ boxes out of $N$, which is again a binomial coefficient.

$$\tag{4} \Omega(N,K)=\left(\begin{matrix}N \\ K\end{matrix}\right)\Omega_K $$

Sal
  • 4,822
1

Only integer percentages are allowed to each component which must have a minimum of $a$% and maximum of $b$ %, and the %ages for the $K$ components must sum to $100$%, then the best way I see is to use generating functions.

Firstly, we put $a$ into each of the $K$ components, then $100-Ka$ are left to distribute

then in the most rudimentary form of generating functions, we want to find the coefficient of $(100-Ka)$ in the expansion of $(1 + x + x^2 + .... + x^(b-a))^K$

and multiply by the $\binom{N}{K}$ varieties of components possible in the alloy.

PS

OP has remarked that the term for the base is called the "host" metal, and also clarified that all percebtages are integers, and that they must add up to 100% So I have simplified the answer.

  • Restricting to integer percentages clearly makes sense. If these really are percentages they must sum to $1$. Your count does not take that into account. – Ethan Bolker Feb 28 '23 at 19:37
  • @trueblueanil The concentrations of the $K$ components must sum to 1. – Shaun Han Feb 28 '23 at 19:49
  • @trueblueanil I think there is some misunderstanding here. To be clear, there doesn't need to be a "base metal" (actually it's called a $host$ $metal$). I am studying a system called $high$-$entropy$ $alloy$, where equal or large proportions of 5 or more elements are mixed together into a single phase. – Shaun Han Feb 28 '23 at 20:11
  • Let's say $K=2$, $a=1$, $b=99$, then for the first component we can take a percentage equal to $1,2,3…99$, and the second component fills that up to 100, so there will only be ${N\choose 2}{99\choose 1}$ distinct alloys, this is obviously not equal to ${N\choose 2}\cdot 2 \cdot(99-1+1)$ – Shaun Han Feb 28 '23 at 20:55
  • The important thing to note here is, once the concentrations of all $K-1$ components are known, the concentration of the $K$th component is automatically known. – Shaun Han Feb 28 '23 at 20:59
  • 1
    This still doesn't seem right. Just think of when $K=3, a=2, b=98$, the first component can take a percentage equal to $2,3,...,98$, but when it takes for example 98, the other two components have to be all taking a percentage of 1. – Shaun Han Feb 28 '23 at 21:14
  • Obviously to make a component considered as "exists" in the alloy, it has to be at least have a pecentage of 1%, thus $a \ge K-1$. This is not stated in the question but I hope this is clear. – Shaun Han Feb 28 '23 at 21:18