Grasshopper

algorithmic modeling for Rhino

Hi All,

I am looking to create a Series that does not start at '0'...it starts at a number defined by a slider, but the next consecutive number in the Series needs to be zero...then it will count upwards to the number before the start number...

i.e. 9, 0, 1, 2, 3, 4, 5, 6, 7, 8

then it will need to repeat this pattern (continuing to count upwards) and the repeat number is based on a slider (for example 3 in the case illustrated below):

9, 0, 1, 2, 3, 4, 5, 6, 7, 8
19, 10, 11, 12, 13, 14, 15, 16, 17, 18,
29, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29,

if anyone has any ideas on how to create this series it would be great

M.

Views: 402

Replies to This Discussion

You could make the series normally, then shift the list with a shift component with wrapping set to true.
Hi Luis,

thanks I'll try it out

M.
Asuming the last number you posted is a typo, it's very simple, you'll have to split the list in different paths before shifting the numbers:

Hi Vicente, yup the last number is a typo...

thanks for this...it's exactly what I am looking for...

M.

RSS

About

Translate

Search

Photos

  • Add Photos
  • View All

Videos

  • Add Videos
  • View All

© 2024   Created by Scott Davidson.   Powered by

Badges  |  Report an Issue  |  Terms of Service