I have 132 potential positions in a wind farm layout and I have to place 66 turbines on these positions. I want to know how to make combinations to place these 66 turbines.

조회 수: 2 (최근 30일)
My wind farm dimension is 11220X1360 and it is divided into grids with dimensions 340X340. There are 132 potential positions for 66 turbines in them. How to determine the ways in which they can be placed on 132 positions?
  댓글 수: 4
Walter Roberson
Walter Roberson 2021년 7월 28일
편집: Walter Roberson 2021년 7월 28일
David answered the question you asked. If you need more precision then
n = sym(66);
numpositions = simplify(exp(gammaln(2*n)-2*gammaln(n)))
numpositions = 
12453858983462851457071547625632459816100
double(numpositions)
ans = 1.2454e+40
crosscheck = factorial(sym(132))/factorial(sym(66))^2
crosscheck = 
377389666165540953244592352291892721700
The crosscheck is dpb's value, and I have to say it looks reasonable to me. Hmmm... seems to me that David's formula should probably be
n = sym(66);
numpositions = simplify(exp(gammaln(2*n+1)-2*gammaln(n+1)))
numpositions = 
377389666165540953244592352291892721700
Ah, that's better.
Anyhow... if knowing the number of ways you can position them is not what you need, you should expand on your question.
In a duplicate question it looked like you might be asking for code to produce all of the possible solutions. Although I could produce code for that purpose, as David showed, the code would take on the order of 10^20 years to finish. As in roughly 100000000000000000000 years.
David Goodmanson
David Goodmanson 2021년 7월 29일
Walter is correct, I forgot to add 1 when converting the gamma function to a factorial. A couple of previous comments are modified accordingly.

댓글을 달려면 로그인하십시오.

답변 (1개)

Jan
Jan 2021년 7월 17일
편집: Jan 2021년 7월 17일
The notes of dpb and David mean, that the number of possible solutions is too large to be useful, if you want to test all of them. In your case testing all 132 over 66 solutions would take many years.
So you have to concentrate on a small subset. There are different ways to find "good" solutions in a huge set, e.g. randomly:
pos = randperm(1:132, 66);
Other methods of global optimizations allows to improve solutions iteratively from different starting points. This does not require to check all possible solutions, but to find a sufficiently good solution in a bearable amount of time.
  댓글 수: 4
David Goodmanson
David Goodmanson 2021년 7월 18일
편집: David Goodmanson 2021년 7월 29일
Assuming 3.8e38 cases [this number has been corrected per Walter's comment], if one could do a case every picosecond it would take about 1.2e19 years, not counting meal breaks (the age of the universe is about 1.4e10 years). "Many years", indeed!
Walter Roberson
Walter Roberson 2021년 7월 18일
"I bet I could get there in one day, if I didn't sleep!"
(Will anyone else know what this refers to? Will I still know what this refers to a year from now?)

댓글을 달려면 로그인하십시오.

카테고리

Help CenterFile Exchange에서 Wind Power에 대해 자세히 알아보기

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by