f is 0 the "domain" shrinks to a given dList value.
So searchMode 1 does a proximity search for each "domain" whilst searchMode 2 does a search for distances between the total min/max domains value. Depending on topology and dList values results may (or may not) differ.
Example: assume that you search proximity for 2, 4, 13 meters. Using the domainContol these "expand" to, say, 1.5-2.5, 3.5-4.5 and 12.5-13.5. Mode 1 finds prox distances within the 3 "domains" (excluding 2.5-3.5 and 4.5-12.5) whilst mode 2 finds distances within the 1.5-13.5 range.
Mind overlaps.
NOTE: David's excellent Populate thingy yields "even" distributions ... meaning that this may be not the ideal tool for that type of search.…
elated with the Topology outputs:
So let's try to do (via components) the face reconstruction stage (the missing 4 as above):
Alias crenelatedEdgesTree as polylineTree.
Imagine a Lst that samples all the edges per Face ("changed" and "unchanged") as Curves.
1. Let's take face 3: this is surrounded by edges 10,11,12,13 and 37.
2. Has edge 10 "changed" (to polyline) ? No because in the polylineTree there's no branch {10} ... thus sample edge 10 from the EList (Note: apparently that's a boundary edge). Has edge 11 "changed" ? No ... blah, blah.
3. Has edge 12 "changed" ? Yes because in the polylineTree there's a branch {12} ... thus sample the item from that branch. Same for 13 ... etc etc.
4. Thus we have sampled all the surrounding edges as Curves and the next step is to join them > yielding a closed Curve.
5. Then we must "planarize" that Curve (by projecting it into the corresponding Brep Face plane) ... and the rest are history.
So ... try it and report any issue encountered.…
掌握编程过程中遇到的思路方面和技术方面的问题. 内容包括以下几个方面:
反向逻辑思维能力的培养;
建立清晰的编程逻辑思维能力;
GH 的程序设计理念;
并行数据结构深入理解和控制.
Grasshopper course of McNeel Asia focus on the cultivation of students flexible use of programming techniques, the ability to solve practical problems. Our course deep into the whole process of programming, from programming thinking model, the components principle to usage details do detailed explanation, help students complete mastery programming encountered in the process of thinking and technical aspects, include the following content:
Ability of reverse logical thinking;
Establishment of clear programming logical thinking ability;
The program design concept of Grasshopper;
Understanding parallel data tree structure and how to control it.
更多详细内容... More details…
授课讲师 Instructor 课程由Grasshopper原厂McNeel公司在中国地区的两位 Rhino 原厂技术推广工程师 – Dixon、Jessesn联合授课。课程结束后对达到授课预定目标的学员颁发唯一由Grasshopper原厂认证的结业证书.
Dixon & Jessesn, McNeel Asia Support engineer, by the end of course student who achieve the intended target will get the authentication certificate from McNeel Asia.
课程报名 Register this course 课程即日开始报名, 开课一周前停止报名, 名额满提前报名结束. This course begin to sign up, stop sign up a week ago, with the quota ahead over.
在线报名参加课程...
Sign up to this course…
课程日期 Schedule 7/15-7/20 Beijing 北京 7/26-7/31 Shanghai 上海 7/07-7/12 Shenzhen 深圳
课程范例演示 Samples of Grasshopper course demo
Note: pls follow below comments by Jessesn to see the samples…
he start point.
Generation (2) i have 4 points + (3*3points) = 13 points.
Generation (3) i have 13 points + (9*3points) = 50 points.
But when i bake the python component i have 157 points ? Why ?
What's the logic behind this ?
Also how can i have in a, lists of points according to generations and for exemple in b lines according to generations too ??
Here's the code:
import rhinoscriptsyntax as rsimport random as rr.seed(seed)
def Main():....allGenerations = []....allGenerations.append(startPt)....curGeneration = []....curGeneration.append(startPt)....for i in range(gens):........newGeneration = []........for pt in curGeneration:............ang1 = r.randint(-30,30) ............ang2 = r.randint(90,150) ............ang3 = r.randint(210,270) ............dist1 = r.randint(10,40) ............dist2 = r.randint(10,40) ............dist3 = r.randint(10,40) ............zV = -1 ............newPoints = branch(pt, ang1, ang2, ang3, dist1/(i+1), dist2/(i+1), dist3/(i+1), zV) ............newGeneration.extend(newPoints) ............curGeneration = newGeneration ............allGenerations.extend(newGeneration)....return allGenerations
def branch(pt, ang1, ang2, ang3, dist1, dist2, dist3, zV):....ptP1 = rs.Polar(pt, ang1, dist1)....ptP2 = rs.Polar(pt, ang2, dist2) ....ptP3 = rs.Polar(pt, ang3, dist3) ....ptA1 = rs.AddPoint(ptP1)....ptA2 = rs.AddPoint(ptP2)....ptA3 = rs.AddPoint(ptP3) ....pt1 = rs.MoveObject(ptA1, [0,0,zV])....pt2 = rs.MoveObject(ptA2, [0,0,zV])....pt3 = rs.MoveObject(ptA3, [0,0,zV]) ....ln1 = rs.AddLine(pt, pt1)....ln2 = rs.AddLine(pt, pt2)....ln3 = rs.AddLine(pt, pt3) ....return [pt1, pt2, pt3]
a = Main()
Thanks for you replies and sorry for my noob questions...
…
ctorial component to go to higher factorials/permutations just to determine easily permutations. For instance I have 30 tile colors and I wanted to see their permutations quickly, I realize I can use 30*29*28 etc but I thought I could do this using the simple definition that one can see in the pic.
RM
…
ies though...I was wondering whether there was a quick fix in grasshopper but I don't think it's out there yet.
I've put together a very basic GH code that will convert a two digit number into a set of curves. This could be increased to larger number without much problem.
My knowledge of tree structures is still limited (as you can see from the code!) so it could be tidied easily enough I imagine. The main reason the code is so large is because I was having difficulty differenciating in lists between e.g. 1 which is 1 curve and 8 which is two curves. In a list, this lead to about 13 curves for the ten digits.
Anyway, it's a start and may help people with some CNC work in the future!…
as follows.
We have a grid which consists of a collection of columns, where each column consists of a list of points. You said flattening is out of the question, so we need to cull items from each list individually.
Let's say our culling pattern is KDDDKDD (repeat as needed). K = Keep, D = Ditch. If a column contains 18 points, the pattern needs to be repeated until it is 18 items long. In this case:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18
K D D D K D D K D D D K D D K D D D
We can now cull each column, but they will all be culled in the same way. By shifting the pattern one more index for each column, we can cycle the culling.
The fix incidentally is to Shift the pattern PRIOR to repeating it. Then it works as expected:
--
David Rutten
david@mcneel.com
Tirol, Austria…
Added by David Rutten at 2:49pm on October 2, 2013
them into one solid).
By the reversed order of the Loft Curves, the SolidDifference is still not working when I trim the surface by a box1 which is scaled over the z axis. But it does work around the problem of the deleting curve number 13 or 11 or 5 or 4 or 0. Strange, strange strange..... Maybe something for David?
Is there an explanation why the reversed order of the lofting curves is working better?
Cheers,
Bas…
ells new products like the Firefly Interactive Prototyping Shield which mounts on top of your Arduino Uno and provides access to a number of useful input (ie. sensors) and output (ie. motors) devices. It includes features like:
Three linear slide potentiometers connected to analog pins 0, 1, and 2
Two-axis joystick connected to analog pins 3 and 4
Light sensor (photocell) connected to analog pin 5
Three push buttons connected to digital pins 2, 4, and 7
Red LED connected to digital pin 13
RGB LED connected to digital pins 3, 5, and 6
Two servo connections on digital pins 8 and 9
A connection to the Easy Stepper Driver (co-designed by Sparkfun Electronics and Brian Schmalz) to control stepper motors. The direction of the motor is controlled through digital pin 10 and the number of steps through digital pin 12
High-voltage MOSFET circuit capable of driving lights, valves, DC motors, solenoids, or anything else requiring higher voltage or current. The gate of the MOSFET is connected to digital pin 11 (PWM).
Some come take a look and let us know what you think!
…