t, let's talk about randomness. Randomness is a problem in computing because digital computers are deterministic. If you give them the exact same instructions they always end up with the exact same result. It turns out to be mathematically impossible to generate true random numbers using a digital computer, but it is fairly easy to generate pseudo-random numbers. This is actually not bad news as pseudo-random numbers -unlike real random numbers- can be generated again and again and you'll end up with the same random numbers every time. Being able to get the same random numbers on demand increases the reliability of these number sequences which in turn makes them easier to use.
Pseudo-random numbers are numbers that have certain characteristics. Note that when we talk about random numbers we are really talking about numbers. Plural. It's easy to generate only a single one, as xkcd so eloquently put it:
So what are these characteristics that define pseudo-randomness? Without being actually correct, I can sum them up as follows:
The sequence of generated numbers should never repeat itself*
The numbers in the sequence ought to be spread evenly across the numeric domain**
There are a lot of different algorithms out there, some better than others, some faster than others, some solving very specific problems while others are more generic. The generator used in Grasshopper is the standard Microsoft .NET Random, based on Donald Knuth's subtractive algorithm.
So let's imagine we want random integers between 0 and 10. What would a bad random sequence look like?
3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 (about as bad as it gets)
0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 (not random at all)
1 3 2 5 3 9 1 2 4 2 5 1 1 2 8 1 5 2 3 4 (too many low numbers)
2 8 4 6 0 9 8 2 4 8 6 4 2 2 5 1 4 8 6 2 (too many even numbers)
So what about good sequences? Well, here's a few:
6 9 1 2 0 4 2 8 5 7 2 9 1 9 2 5 3 1 9 2 (sure, why not)
6 2 5 3 4 1 9 7 8 0 2 1 6 4 5 8 9 5 0 9 (looks about right)
1 8 5 2 3 4 5 7 9 5 2 1 0 2 1 0 9 7 6 4 (I suppose)
9 0 6 4 8 3 1 5 2 7 6 1 4 6 0 1 9 7 5 6 (whatever)
There are a lot of valid pseudo-random sequences. (Seriously, loads). So even if we have a good pseudo-random generator we may be given a random sequence that isn't entirely to our liking. The shorter the sequence we need, the more likely it is that statistical aberrations invalidate that particular sequence for us. What we need is some control over the generator so we don't just get a repeatable sequence, but a repeatable sequence we actually like.
Enter seed values. The random generator requires a seed value before it can generate a random sequence. These seed values are always integers, and they can be any valid 32-bit integer. Every unique seed value results in the same sequence. Every time.
Unfortunately there is no clear relationship between seeds and sequences. Changing the seed value from 5 to 6 will result in a completely difference random sequence, and two sequences that are very similar may well have to wildly different seeds. There is therefore no way to guess a good seed value, it is completely trial-and-error. Also because of this extremely discontinuous nature, you cannot use tools like Galapagos to optimize a seed value.
If you are looking for a pseudo-random sequence which has custom characteristics, you may well end up having to write your own generator algorithm. Ask questions about this on the Grasshopper main forum or the VB/C# forum.
Conclusion: Seed values are integers that define the exact sequence of pseudo-random numbers, but there's no way of knowing ahead of time what sequence it will be and there's no way of tweaking a sequence by slightly changing the seed. Even the tiniest change in seed value will result in a radically different random sequence.
--
David Rutten
david@mcneel.com
Poprad, Slovakia
* This is not actually possible. A finite amount of numbers always repeats itself eventually.
** This should only be true for long enough sequences, short sequences are allowed to cluster their values somewhat.
Interesting links for further reading:
Coding Horror: Computers are Louse Random Number Generators
StackOverflow: When do random numbers start repeating?…
Added by David Rutten at 9:52am on October 20, 2012
ectural project, the efficiency of design communication and the control of information-flow are as important as the creativity of ideas. In response to the concurrent digital evolution emerging in the architectural industry world-wide, the Faculty of Architecture at The University of Hong Kong will host a two week intensive summer program named Digital Practice.Led by professors from The University of Hong Kong, as well as invited practitioners with expertise in practice of cutting edge digital techniques, the program offers participants opportunities to experience applications of computational tools during different stages of an architectural project, i.e. concept design, form finding and optimization, delivery, management and communication of design information under the team-based working environment. By learning advanced computational techniques through case studies in the context of Hong Kong, participants are expected to go beyond the conventional perception of technology, considering users and tools as a feedback-based entity instead of a dichotomy. The program, which is taught in English, includes a series of evening lectures related delivered by teaching staff and invited local architects.對於高品質的建築專案,創意之外,專案過程中高效的設計資訊管理和交流成為項目設計深化和實施必不可少的環節。今天,數字化技術不但改變了建築師的繪圖工具,影響了設計的過程,而且提供了工程建造和管理實施的更有效、更高效的手段。針對建築的數位化演進,香港大學建築學院將於2011年暑假期間,在香港大學建築學院舉辦“數位化實踐”國際研習班。在香港大學建築學院教授及有著相關豐富經驗的外聘實踐建築師的指導下,學員將有機會體驗在專案的不同階段(如概念設計、設計形式的生成、優化,設計資訊的管理和交流),如何有效地應用各種運算智慧化技術(從設計的數位化生成和建築資訊類比到物理模型),提升設計實施的品質,增加設計團隊對於方案的控制。我們將挑戰對於“技術”的傳統認知,即相對於使用者它不僅是工具,更是與使用者互動的媒介,二者形成一個有機的合體。研習班期間會安排系列講座,展現數位化技術在實踐工程中的廣泛應用。…
zed like this:
{0}
0 Surface 1
{1}
0 Surface 2
1 Surface 3
2 Surface 4
{2}
0 Surface 5
1 Surface 6
{3}
0 Surface 7
1 Surface 8
2 Surface 9
And not like this (which is what i have when select tehm with "multiple surfaces")
{0}
0 Surface 1
1 Surface 2
.....
7 Surface 8
8 Surface 9
Thanks a lot for your help: it is a very frequent issue and i would like to fix it.
Regards
…
Looks good, How can I then select those circles as a branch? For example,
I want to divide all the Radius 3 circles into 8 parts, all radius 9 into 6 parts etc.
Many Thanks for your help
etc.
Group 2 - 1, 6, 11, 16, 21 etc.
Group 3 - 2, 7, 12, 17, 22 etc.
Group 4 - 3, 8, 13, 18, 23 etc.
Group 5 - 4, 9, 14, 19, 24 etc. "
except in data, the branches start at 0, so 'group 1' is branch 0
as for the order of your points, that depends on the input prior sorting...
yrs …
cy of design communication and the control of information-flow are as important as the creativity of ideas. In response to the concurrent digital evolution emerging in the architectural industry world-wide, the Faculty of Architecture at The University of Hong Kong will host a two week intensive summer program named Digital Practice.Led by professors from The University of Hong Kong, as well as invited practitioners with expertise in practice of cutting edge digital techniques, the program offers participants opportunities to experience applications of computational tools during different stages of an architectural project, i.e. concept design, form finding and optimization, delivery, management and communication of design information under the team-based working environment. By learning advanced computational techniques through case studies in the context of Hong Kong, participants are expected to go beyond the conventional perception of technology, considering users and tools as a feedback-based entity instead of a dichotomy. The program, which is taught in English, includes a series of evening lectures related delivered by teaching staff and invited local architects.對於高品質的建築專案,創意之外,專案過程中高效的設計資訊管理和交流成為項目設計深化和實施必不可少的環節。今天,數字化技術不但改變了建築師的繪圖工具,影響了設計的過程,而且提供了工程建造和管理實施的更有效、更高效的手段。針對建築的數位化演進,香港大學建築學院將於2011年暑假期間,在香港大學建築學院舉辦“數位化實踐”國際研習班。在香港大學建築學院教授及有著相關豐富經驗的外聘實踐建築師的指導下,學員將有機會體驗在專案的不同階段(如概念設計、設計形式的生成、優化,設計資訊的管理和交流),如何有效地應用各種運算智慧化技術(從設計的數位化生成和建築資訊類比到物理模型),提升設計實施的品質,增加設計團隊對於方案的控制。我們將挑戰對於“技術”的傳統認知,即相對於使用者它不僅是工具,更是與使用者互動的媒介,二者形成一個有機的合體。研習班期間會安排系列講座,展現數位化技術在實踐工程中的廣泛應用。…