Stream: Google Code-in

Topic: sand


view this post on Zulip Sean (Jan 08 2018 at 15:53):

@Rahil Malik so you are in the right direction, but you only made a "line" of super big sand

view this post on Zulip Rahil Malik (Jan 08 2018 at 15:54):

So , should i just copy them ?

view this post on Zulip Sean (Jan 08 2018 at 15:54):

I can accept the task and you can move on, which leaves us with an unusable model; or you can try to make it better ... which do you want to do?

view this post on Zulip Rahil Malik (Jan 08 2018 at 15:54):

I will make it better

view this post on Zulip Sean (Jan 08 2018 at 15:55):

okay, so first up -- how big is a grain of sand?

view this post on Zulip Rahil Malik (Jan 08 2018 at 15:55):

very small

view this post on Zulip Sean (Jan 08 2018 at 15:55):

we're a CAD system -- numbers matter :)

view this post on Zulip Sean (Jan 08 2018 at 15:56):

what's very small?

view this post on Zulip Rahil Malik (Jan 08 2018 at 15:56):

maybe 1mm ?

view this post on Zulip Sean (Jan 08 2018 at 15:56):

maybe

view this post on Zulip Sean (Jan 08 2018 at 15:56):

maybe not

view this post on Zulip Rahil Malik (Jan 08 2018 at 15:56):

no, 0.1mm

view this post on Zulip Sean (Jan 08 2018 at 15:56):

you shouldn't be guessing

view this post on Zulip Sean (Jan 08 2018 at 15:57):

this isn't a guessing question

view this post on Zulip Rahil Malik (Jan 08 2018 at 15:57):

because it depends on the size of my hourglass right ?

view this post on Zulip Rahil Malik (Jan 08 2018 at 15:57):

and my hourglass is about 125mm , so it ,must be around 0.1

view this post on Zulip Sean (Jan 08 2018 at 15:57):

that's better thinking, but if you take it a step further, there must be a formal definition for what constitutes sand

view this post on Zulip Rahil Malik (Jan 08 2018 at 15:58):

I didn't get it

view this post on Zulip Jeff Sieu (Jan 08 2018 at 15:58):

Silicon dioxide?

view this post on Zulip Sean (Jan 08 2018 at 15:59):

if I asked you how tall are people, what would you say?

view this post on Zulip Sean (Jan 08 2018 at 16:00):

@Jeff Sieu so a huge 1m x 1m x 1m cube of silicon dioxide is sand?

view this post on Zulip Jeff Sieu (Jan 08 2018 at 16:01):

Okay, jokes aside sand is constituted of sand particles, right?

view this post on Zulip Rahil Malik (Jan 08 2018 at 16:01):

I am really not getting what you're trying to Imply ?

view this post on Zulip Jeff Sieu (Jan 08 2018 at 16:01):

According to Wikipedia, a sand particle is about 0.0625 mm to 2 mm

view this post on Zulip Sean (Jan 08 2018 at 16:01):

i've asked a technical question and am getting non-technical answers

view this post on Zulip Sean (Jan 08 2018 at 16:01):

@Jeff Sieu bingo, that's a better answer

view this post on Zulip Jeff Sieu (Jan 08 2018 at 16:02):

And can probably be modelled as a sphere?

view this post on Zulip Sean (Jan 08 2018 at 16:02):

so now you have a range of possibilities

view this post on Zulip Rahil Malik (Jan 08 2018 at 16:02):

According to Wikipedia, a sand particle is about 0.0625 mm to 2 mm

Ohh, ok :thumbs_up:

view this post on Zulip Rahil Malik (Jan 08 2018 at 16:03):

So, i have to make group of thousands of such 0.0625mm spheres

view this post on Zulip Rahil Malik (Jan 08 2018 at 16:03):

that would totally come out as sand

view this post on Zulip Sean (Jan 08 2018 at 16:03):

this is how you should be thinking when you're doing engineering, bounded by analysis

view this post on Zulip Sean (Jan 08 2018 at 16:03):

why 0.0625?

view this post on Zulip Sean (Jan 08 2018 at 16:04):

it's certainly in range, but 0.0625 to 2 is a pretty huge difference ... three orders of magnitude different

view this post on Zulip Sean (Jan 08 2018 at 16:04):

so your next question should be where in that range might be appropriate for YOUR needs

view this post on Zulip Rahil Malik (Jan 08 2018 at 16:04):

i mean between 0.0625 - 2mm because i have to go according of the size of my model

view this post on Zulip Sean (Jan 08 2018 at 16:05):

right! :) your model

view this post on Zulip Sean (Jan 08 2018 at 16:05):

so how big is your hole?

view this post on Zulip Rahil Malik (Jan 08 2018 at 16:05):

exactly 1mm (from front view)

view this post on Zulip Sean (Jan 08 2018 at 16:05):

if your hole is < 2mm, then you'd have to be super careful how small/big you choose

view this post on Zulip Sean (Jan 08 2018 at 16:06):

is that exterior or interior?

view this post on Zulip Sean (Jan 08 2018 at 16:06):

and really 1mm?? I don't recall it being that small

view this post on Zulip Rahil Malik (Jan 08 2018 at 16:06):

interior ,

view this post on Zulip Rahil Malik (Jan 08 2018 at 16:06):

I must have made amends later on

view this post on Zulip Rahil Malik (Jan 08 2018 at 16:07):

I was experimenting the whole dayon how i could make such a large group fit in perfectly under the upper section of the hourglass

view this post on Zulip Sean (Jan 08 2018 at 16:08):

so you're sure it's 1mm in diameter or radius?

view this post on Zulip Rahil Malik (Jan 08 2018 at 16:08):

diameter

view this post on Zulip Rahil Malik (Jan 08 2018 at 16:08):

the area would be around 0.725 mm^2

view this post on Zulip Sean (Jan 08 2018 at 16:09):

okay, so then you can consider how many grains need to fit so that they don't get "stuck"

view this post on Zulip Sean (Jan 08 2018 at 16:10):

as you can imagine, if you have marbles in a funnel, you can get them all to stick so none fall out if the hole is too small

view this post on Zulip Rahil Malik (Jan 08 2018 at 16:10):

okay, so then you can consider how many grains need to fit so that they don't get "stuck"

4-5 grains at a time would be perfect because , its less chance that 5 spheres come at the same time and get stuck

view this post on Zulip Rahil Malik (Jan 08 2018 at 16:10):

so the size of the grain will be around 0.3mm

view this post on Zulip Sean (Jan 08 2018 at 16:10):

that's good thinking -- so let's test that hypothesis with a little thought exercise

view this post on Zulip Sean (Jan 08 2018 at 16:11):

lets say you made it so 10 fit across ... what would likely happen

view this post on Zulip Sean (Jan 08 2018 at 16:11):

(compared with, say 4 grains)

view this post on Zulip Sean (Jan 08 2018 at 16:11):

(or 1 grain)

view this post on Zulip Rahil Malik (Jan 08 2018 at 16:12):

the grains will flow ?

view this post on Zulip Sean (Jan 08 2018 at 16:12):

sure, but how will they flow?

view this post on Zulip Sean (Jan 08 2018 at 16:12):

slower?

view this post on Zulip Rahil Malik (Jan 08 2018 at 16:12):

yes

view this post on Zulip Sean (Jan 08 2018 at 16:13):

what will be slower?

view this post on Zulip Rahil Malik (Jan 08 2018 at 16:13):

the flow

view this post on Zulip Sean (Jan 08 2018 at 16:13):

which?

view this post on Zulip Rahil Malik (Jan 08 2018 at 16:13):

more grains, the slower the flow of the grains

view this post on Zulip Sean (Jan 08 2018 at 16:13):

10 will be slower?

view this post on Zulip Rahil Malik (Jan 08 2018 at 16:13):

yes, 10 > 4 > 1 grains

view this post on Zulip Rahil Malik (Jan 08 2018 at 16:13):

10 < 4 < 1*

view this post on Zulip Sean (Jan 08 2018 at 16:13):

you have a 1mm hole, so 10 grains across is a 0.1mm grain size

view this post on Zulip Rahil Malik (Jan 08 2018 at 16:13):

Yess

view this post on Zulip Sean (Jan 08 2018 at 16:14):

1mm hole with 1 grain across is a 1mm grain size

view this post on Zulip Rahil Malik (Jan 08 2018 at 16:14):

i didn't understand the last statement

view this post on Zulip Sean (Jan 08 2018 at 16:14):

:)

view this post on Zulip Rahil Malik (Jan 08 2018 at 16:15):

1mm hold with 1 grain across is a 1mm grain size

what do you mean by hold ?(stuck ?)

view this post on Zulip Sean (Jan 08 2018 at 16:16):

you have a 1mm hole I meant hole, not hold

view this post on Zulip Rahil Malik (Jan 08 2018 at 16:16):

YESsss, i get it

view this post on Zulip Sean (Jan 08 2018 at 16:16):

so if you wanted 2 grains across, that'd be .5mm diameter grains

view this post on Zulip Sean (Jan 08 2018 at 16:18):

we could calculate the area, but say 2 grains across means it lets 10 grains per second flow through the hole (and we assume it doesn't get stuck, which doesn't seem likely)

view this post on Zulip Sean (Jan 08 2018 at 16:18):

so 0.5 mm diameter grains is 10 grains per second

view this post on Zulip Rahil Malik (Jan 08 2018 at 16:18):

yes

view this post on Zulip Sean (Jan 08 2018 at 16:19):

would would 10 grains across be?

view this post on Zulip Sean (Jan 08 2018 at 16:19):

(you can assume a square hole for simplicity)

view this post on Zulip Rahil Malik (Jan 08 2018 at 16:20):

is there a typo ? in the above statement ?

view this post on Zulip Sean (Jan 08 2018 at 16:20):

not that I see, what's confusing?

view this post on Zulip Sean (Jan 08 2018 at 16:21):

how big are the grains if you can fit 10 across the hole?

view this post on Zulip Rahil Malik (Jan 08 2018 at 16:21):

if the hole is 1mm is diameter then 0.1

view this post on Zulip Sean (Jan 08 2018 at 16:21):

perfect

view this post on Zulip Sean (Jan 08 2018 at 16:21):

(did you think you'd be doing some math when you woke up today?)

view this post on Zulip Rahil Malik (Jan 08 2018 at 16:21):

:)

view this post on Zulip Rahil Malik (Jan 08 2018 at 16:22):

:laughing: Too Much ; I had my physics exam today , had to do many numericals :rolling_on_the_floor_laughing:

view this post on Zulip Sean (Jan 08 2018 at 16:22):

so if 0.5mm is 10 grains per second, how fast would 0.1mm grains likely flow?

view this post on Zulip Rahil Malik (Jan 08 2018 at 16:22):

20

view this post on Zulip Sean (Jan 08 2018 at 16:23):

you originally said "slower"

view this post on Zulip Rahil Malik (Jan 08 2018 at 16:23):

I wasn't thinking straight

view this post on Zulip Rahil Malik (Jan 08 2018 at 16:23):

Now, i got it

view this post on Zulip Sean (Jan 08 2018 at 16:23):

so 20 isn't the right number, but you got the idea

view this post on Zulip Rahil Malik (Jan 08 2018 at 16:26):

so what is ? i jdid a cross multiplication

view this post on Zulip Sean (Jan 08 2018 at 16:26):

0.5 to 0.1 is 1/5th the size, so you might think 50 grains per second except that's in only 1 dimension and we'd need to calculate areas

view this post on Zulip Sean (Jan 08 2018 at 16:27):

suffice it to say that 10 grains across will flow faster than 1 grain across, and we just need enough so that they don't get stuck

view this post on Zulip Sean (Jan 08 2018 at 16:27):

for that, your guess of 4-5 grains across will be grains about how big?

view this post on Zulip Sean (Jan 08 2018 at 16:31):

1 is 1mm, 10 is .1mm ... what's 4 or 5?

view this post on Zulip Rahil Malik (Jan 08 2018 at 16:31):

4 - 0.25mm 5 -0.2mm

view this post on Zulip Sean (Jan 08 2018 at 16:32):

excellent, so if we had a 1mm^2 hole, that would be how many grains of sand going through simultaneously

view this post on Zulip Rahil Malik (Jan 08 2018 at 16:33):

5 grains of 0.2 mm^2 area ?

view this post on Zulip Sean (Jan 08 2018 at 16:33):

5 grains across

view this post on Zulip Sean (Jan 08 2018 at 16:33):

yes, 0.2mm^2

view this post on Zulip Rahil Malik (Jan 08 2018 at 16:33):

:)

view this post on Zulip Sean (Jan 08 2018 at 16:34):

figured it out yet?

view this post on Zulip Rahil Malik (Jan 08 2018 at 16:34):

Totally !

view this post on Zulip Rahil Malik (Jan 08 2018 at 16:35):

I will complete this in 2 hours max

view this post on Zulip Sean (Jan 08 2018 at 16:35):

so what's the number then? or did you miss the question? :)

view this post on Zulip Sean (Jan 08 2018 at 16:35):

if you had a 1mm square hole, how many of those 0.2mm square grains are going to fit through it simultaneously?

view this post on Zulip Rahil Malik (Jan 08 2018 at 16:36):

square as in mm^2 ?

view this post on Zulip Sean (Jan 08 2018 at 16:36):

yes

view this post on Zulip Rahil Malik (Jan 08 2018 at 16:36):

5 ?

view this post on Zulip Sean (Jan 08 2018 at 16:36):

no...

view this post on Zulip Sean (Jan 08 2018 at 16:37):

there's 5 across one dimension, but the hole is square

view this post on Zulip Rahil Malik (Jan 08 2018 at 16:37):

tthe hole is circular

view this post on Zulip Rahil Malik (Jan 08 2018 at 16:37):

the*

view this post on Zulip Rahil Malik (Jan 08 2018 at 16:37):

I am so sorry for that one

view this post on Zulip Sean (Jan 08 2018 at 16:37):

it is, but I said assume it's square for (mathematical) simplicity

view this post on Zulip Sean (Jan 08 2018 at 16:38):

you can figure it out for a round hole if you want :)

view this post on Zulip Sean (Jan 08 2018 at 16:38):

it's definitely not 5 either way :)

view this post on Zulip Rahil Malik (Jan 08 2018 at 16:38):

15.7

view this post on Zulip Sean (Jan 08 2018 at 16:38):

zulip needs a whiteboard

view this post on Zulip Sean (Jan 08 2018 at 16:39):

well done, and if the hole were square?

view this post on Zulip Rahil Malik (Jan 08 2018 at 16:39):

5

view this post on Zulip Sean (Jan 08 2018 at 16:39):

heh

view this post on Zulip Sean (Jan 08 2018 at 16:39):

no

view this post on Zulip Sean (Jan 08 2018 at 16:39):

it's 5 ... times 5

view this post on Zulip Sean (Jan 08 2018 at 16:39):

5 square

view this post on Zulip Rahil Malik (Jan 08 2018 at 16:39):

Area of Square = l^2

view this post on Zulip Sean (Jan 08 2018 at 16:39):

25

view this post on Zulip Rahil Malik (Jan 08 2018 at 16:40):

How ??

view this post on Zulip Rahil Malik (Jan 08 2018 at 16:41):

square is the hole ?

view this post on Zulip Sean (Jan 08 2018 at 16:41):

if you have a 1mm square hole

view this post on Zulip Sean (Jan 08 2018 at 16:41):

the hole is 1mm^2 in area

view this post on Zulip Sean (Jan 08 2018 at 16:41):

if the grains are 0.2mm in length (and square, thus 0.2mm^2 in area)

view this post on Zulip Sean (Jan 08 2018 at 16:42):

that means you can fit 5 across the hole

view this post on Zulip Sean (Jan 08 2018 at 16:42):

and 5 up the hole

view this post on Zulip Sean (Jan 08 2018 at 16:42):

5x5=25

view this post on Zulip Rahil Malik (Jan 08 2018 at 16:43):

0.2 mm^2 x 5 = 1mm^2

view this post on Zulip Rahil Malik (Jan 08 2018 at 16:43):

the

5x5=25

5 up the hole ?

view this post on Zulip Sean (Jan 08 2018 at 16:43):

ah, sorry! there's the mistake

view this post on Zulip Sean (Jan 08 2018 at 16:43):

if the grains are 0.2mm in length

view this post on Zulip Sean (Jan 08 2018 at 16:44):

they're not 0.2mm^2 area

view this post on Zulip Rahil Malik (Jan 08 2018 at 16:44):

ya

view this post on Zulip Rahil Malik (Jan 08 2018 at 16:44):

its 0.04 mm^2

view this post on Zulip Sean (Jan 08 2018 at 16:44):

0.2 x 0.2 = 0.04mm^2 ;)

view this post on Zulip Sean (Jan 08 2018 at 16:44):

so the chances of 25 (or 15 grains) all getting stuck .. seems improbable

view this post on Zulip Rahil Malik (Jan 08 2018 at 16:44):

but still the answer is 25 :)

view this post on Zulip Sean (Jan 08 2018 at 16:45):

yes :)

view this post on Zulip Rahil Malik (Jan 08 2018 at 16:45):

1mm^2/0.04mm^2 = 25

view this post on Zulip Rahil Malik (Jan 08 2018 at 16:45):

got it

view this post on Zulip Sean (Jan 08 2018 at 16:45):

that means you could possibly go sightly bigger grain, but 0.2 seems adequate

view this post on Zulip Sean (Jan 08 2018 at 16:45):

if anything what it means will happen is that the sand will flow more quickly

view this post on Zulip Rahil Malik (Jan 08 2018 at 16:45):

that means you could possibly go sightly bigger grain, but 0.2 seems adequate

ya

view this post on Zulip Sean (Jan 08 2018 at 16:45):

than it would if, say, you used 0.3mm grains

view this post on Zulip Sean (Jan 08 2018 at 16:46):

so go with that 0.2 or 0.25 mm diameter spheres

view this post on Zulip Rahil Malik (Jan 08 2018 at 16:46):

ya 0.1 mm radius

view this post on Zulip Sean (Jan 08 2018 at 16:46):

so you make one sphere somewhere in that upper space, then clone it

view this post on Zulip Sean (Jan 08 2018 at 16:47):

make sure to leave a little bit of spacing when you clone

view this post on Zulip Sean (Jan 08 2018 at 16:47):

you want to make a cube or cylinder of sand

view this post on Zulip Rahil Malik (Jan 08 2018 at 16:47):

clone -n 100 -t 1 0 0 sand.s

view this post on Zulip Sean (Jan 08 2018 at 16:47):

that's a pretty big gap, no?

view this post on Zulip Rahil Malik (Jan 08 2018 at 16:48):

clone -n 100 -t 1 0 0 sand.s

here in translate the one is in mm

view this post on Zulip Sean (Jan 08 2018 at 16:48):

the grains are .2mm

view this post on Zulip Sean (Jan 08 2018 at 16:48):

so that'll leave .8mm gap

view this post on Zulip Rahil Malik (Jan 08 2018 at 16:48):

-t 0.3 0 0 ?

view this post on Zulip Rahil Malik (Jan 08 2018 at 16:48):

leaving 0.1 mm gap

view this post on Zulip Sean (Jan 08 2018 at 16:48):

that sounds better, maybe 0.4

view this post on Zulip Rahil Malik (Jan 08 2018 at 16:48):

so clone 100 then clone those 100

view this post on Zulip Sean (Jan 08 2018 at 16:49):

and then clone those 100

view this post on Zulip Rahil Malik (Jan 08 2018 at 16:49):

I have to make in 1000s right ?

view this post on Zulip Sean (Jan 08 2018 at 16:49):

that will make a 100 x 100 x 100 grains

view this post on Zulip Sean (Jan 08 2018 at 16:49):

a million grains seems appropriate

view this post on Zulip Sean (Jan 08 2018 at 16:49):

assuming they fit in the space

view this post on Zulip Sean (Jan 08 2018 at 16:50):

does 100 across with a 0.3 or 0.4 spacing fit the space?

view this post on Zulip Rahil Malik (Jan 08 2018 at 16:51):

got it but they will stay in the upper deck's uppermost part . So, the grains won't be visible in the image

view this post on Zulip Sean (Jan 08 2018 at 16:51):

what do you mean?

view this post on Zulip Sean (Jan 08 2018 at 16:51):

why wouldn't they be visible?

view this post on Zulip Rahil Malik (Jan 08 2018 at 16:51):

So , first i make 100 clones then make a region of them and then clone the region ?

view this post on Zulip Sean (Jan 08 2018 at 16:51):

not a region, but yes

view this post on Zulip Rahil Malik (Jan 08 2018 at 16:51):

why wouldn't they be visible?

in the raytraced at ae 45 45

view this post on Zulip Rahil Malik (Jan 08 2018 at 16:52):

so i should hold one sand and clone that only ?

not a region, but yes

view this post on Zulip Sean (Jan 08 2018 at 16:52):

if you want to be correct, you make a region with 1 grain, then clone that region N times... group them, then clone that group N times, group them, then clone that group N times

view this post on Zulip Rahil Malik (Jan 08 2018 at 16:53):

Okay :)

view this post on Zulip Sean (Jan 08 2018 at 16:53):

note that the last clone will likely take a little time to draw unless you turn on Display Lists on the menu

view this post on Zulip Rahil Malik (Jan 08 2018 at 16:53):

okay

view this post on Zulip Rahil Malik (Jan 08 2018 at 16:55):

so making the 100 x 100 x100 sphere Square(Shape) shouldn't my model be atleast 110 mm so it would stay in the upperdeck

view this post on Zulip Rahil Malik (Jan 08 2018 at 17:24):

cloning a region is a nightmare instead i am cloning solids and making thier region

view this post on Zulip Rahil Malik (Jan 08 2018 at 18:00):

so if i just fill up whole layer this way wont the other half get out of the hourglasss
HALFway.PNG

view this post on Zulip Sean (Jan 08 2018 at 18:45):

looks like it -- so maybe try a bit tighter spacing?

view this post on Zulip Sean (Jan 08 2018 at 18:46):

you could use the pattern tool as it will do cylindrical/circular patterns

view this post on Zulip Sean (Jan 08 2018 at 18:47):

@Rahil Malik fyi, you don't need a tcl loop to draw -- you can use wildcards: draw sand.rI? sand.rI??

view this post on Zulip Sean (Jan 08 2018 at 18:47):

or draw sand.r*

view this post on Zulip Rahil Malik (Jan 08 2018 at 18:50):

btw how much sand do you need ? :laughing:

view this post on Zulip Rahil Malik (Jan 08 2018 at 18:51):

tried.PNG

view this post on Zulip Rahil Malik (Jan 08 2018 at 18:53):

wouldn't that be enough for you use ?

view this post on Zulip Rahil Malik (Jan 08 2018 at 18:59):

Also, i couldn't understand the pdf , so i really don't know how to use pattern tool or that would've been great

view this post on Zulip Sean (Jan 08 2018 at 19:04):

the principles of effective modeling?

view this post on Zulip Sean (Jan 08 2018 at 19:04):

which pdf?

view this post on Zulip Rahil Malik (Jan 08 2018 at 19:04):

ya

view this post on Zulip Rahil Malik (Jan 08 2018 at 19:05):

specially the spherical patterns, as they didn't show a correct way to use it , niether is the screenshot of how the patterns in the fig. were formed

view this post on Zulip Sean (Jan 08 2018 at 19:05):

ah, well you probably would've needed to read it from the beginning as it covers more advanced topics

view this post on Zulip Rahil Malik (Jan 08 2018 at 19:06):

i've done it from the beginning

view this post on Zulip Sean (Jan 08 2018 at 19:06):

but if you follow the other patterns they do show, doing spherical is the same

view this post on Zulip Rahil Malik (Jan 08 2018 at 19:06):

okay , i'll try once more (my mom is telling me to sleep its past my bedtime :( but i 'll tryy my best)

view this post on Zulip Sean (Jan 08 2018 at 19:07):

clone is fine too, looks like you've got that working

view this post on Zulip Rahil Malik (Jan 08 2018 at 19:08):

but its too much work, i have made far too little progress in some 1-2 hours

view this post on Zulip Sean (Jan 08 2018 at 19:08):

what's the work? you must be doing something manually again

view this post on Zulip Rahil Malik (Jan 08 2018 at 19:08):

yes, i had to

view this post on Zulip Sean (Jan 08 2018 at 19:08):

it should have been three clone calls

view this post on Zulip Rahil Malik (Jan 08 2018 at 19:08):

can you show me the code

view this post on Zulip Rahil Malik (Jan 08 2018 at 19:09):

i have to keep the sand inside the hourglass too

view this post on Zulip Sean (Jan 08 2018 at 19:09):

yes, so just create as much as fits

view this post on Zulip Rahil Malik (Jan 08 2018 at 19:10):

then it 4 rows and is fine ?

view this post on Zulip Sean (Jan 08 2018 at 19:10):

how many is that?

view this post on Zulip Sean (Jan 08 2018 at 19:10):

you have other options too

view this post on Zulip Rahil Malik (Jan 08 2018 at 19:11):

this one
HALFway.PNG

view this post on Zulip Rahil Malik (Jan 08 2018 at 19:11):

you have other options too

thats why I came here , to learn the pattern tool

view this post on Zulip Sean (Jan 08 2018 at 19:11):

that looks great, but is not an optimal fill pattern

view this post on Zulip Sean (Jan 08 2018 at 19:11):

optimal pattern is a square in the middle

view this post on Zulip Sean (Jan 08 2018 at 19:12):

if you make them all the way across, then you're out of room after just a couple rows

view this post on Zulip Sean (Jan 08 2018 at 19:13):

you also have other options -- you could decrease the spacing so they are closer together

view this post on Zulip Rahil Malik (Jan 08 2018 at 19:13):

i can go on making rows but the some of the edge sand particles will go out of the hourglass

view this post on Zulip Sean (Jan 08 2018 at 19:13):

you could decrease the grain size slightly so you can fit more while still being pretty close to the original estimates

view this post on Zulip Rahil Malik (Jan 08 2018 at 19:13):

you mean scale them ?

you also have other options -- you could decrease the spacing so they are closer together

view this post on Zulip Rahil Malik (Jan 08 2018 at 19:14):

you could decrease the grain size slightly so you can fit more while still being pretty close to the original estimates

0.19/0.18

view this post on Zulip Sean (Jan 08 2018 at 19:14):

i can go on making rows but the some of the edge sand particles will go out of the hourglass

NO... you're not understanding... the rows are too long .. make them stay in the hourglass

view this post on Zulip Sean (Jan 08 2018 at 19:14):

I do not mean scale them

view this post on Zulip Rahil Malik (Jan 08 2018 at 19:14):

the rows right now , stay perfectly in (cut to cut)

view this post on Zulip Sean (Jan 08 2018 at 19:14):

I mean maybe use .09 radius grains instead of .1 radius

view this post on Zulip Sean (Jan 08 2018 at 19:15):

they do not fill it though

view this post on Zulip Rahil Malik (Jan 08 2018 at 19:16):

ok, i ';ll try

view this post on Zulip Sean (Jan 08 2018 at 19:17):

in that screenshot, you're making a grid like this:https://galeascience.files.wordpress.com/2016/03/circle_in_box.png?w=300&h=300

view this post on Zulip Rahil Malik (Jan 08 2018 at 19:18):

yess so instead ?

view this post on Zulip Sean (Jan 08 2018 at 19:18):

view this post on Zulip Sean (Jan 08 2018 at 19:18):

and in reality, even smaller because the hourglass tapers downward

view this post on Zulip Rahil Malik (Jan 08 2018 at 19:20):

OHH k, so this one would be fine , irght ?

view this post on Zulip Rahil Malik (Jan 08 2018 at 19:20):

http://i48.tinypic.com/25qw2s3.jpg

:arrow_up:

view this post on Zulip Sean (Jan 08 2018 at 19:20):

yes ... you want a cube of grains

view this post on Zulip Sean (Jan 08 2018 at 19:21):

goal is to fit 1M grains

view this post on Zulip Sean (Jan 08 2018 at 19:21):

that will be a very interesting simulation

view this post on Zulip Sean (Jan 08 2018 at 19:22):

if you can't fit that many, see how many you can fit

view this post on Zulip Sean (Jan 08 2018 at 19:22):

again with just a few clone calls .. if you're doing it manually, that's not right

view this post on Zulip Sean (Jan 08 2018 at 19:23):

you could do 1 big cube and 6 smaller cubes in the adjacent gaps but not necessary

view this post on Zulip Rahil Malik (Jan 08 2018 at 20:03):

by the way there are too many warnings appearing and my PC has started to hang. and mged is not responding every once in a while

view this post on Zulip Rahil Malik (Jan 08 2018 at 20:10):

again with just a few clone calls .. if you're doing it manually, that's not right

but once , i have 2 rows i dont know how much to translate other clones

view this post on Zulip Sean (Jan 08 2018 at 20:10):

don't understand

view this post on Zulip Sean (Jan 08 2018 at 20:10):

the translation amount is the same, just along different axes

view this post on Zulip Sean (Jan 08 2018 at 20:12):

clone 1 to 1 line, clone 1 line to N lines (1 square), clone 1 square to N squares

view this post on Zulip Rahil Malik (Jan 08 2018 at 20:12):

first i take a solid then make 80 clones (-t 0.4 0 0) then i make a group of those 80 clones using for loop

view this post on Zulip Rahil Malik (Jan 08 2018 at 20:12):

then now when i have to make a clone, how do i know how much translate so they are exaclty next to each other?

view this post on Zulip Sean (Jan 08 2018 at 20:14):

so that first clone is copies along with X axis (-t X Y Z)

view this post on Zulip Sean (Jan 08 2018 at 20:14):

the second clone that made a square would have been along Y or Z axis

view this post on Zulip Sean (Jan 08 2018 at 20:14):

the remaining clone is the one remaining

view this post on Zulip Sean (Jan 08 2018 at 20:15):

so -t .4 0 0 , then -t 0 .4 0, then -t 0 0 .4

view this post on Zulip Sean (Jan 08 2018 at 20:16):

if you put them into groups as you go, you wouldn't need a for loop

view this post on Zulip Rahil Malik (Jan 08 2018 at 20:16):

i would need a loop , to keep 80 in a group , irght ?

view this post on Zulip Rahil Malik (Jan 08 2018 at 20:16):

how else can i group 80 solids ?

view this post on Zulip Sean (Jan 08 2018 at 20:16):

clone sphere to a line, group them. clone line to a square, group them. clone square to cube, group them.

view this post on Zulip Sean (Jan 08 2018 at 20:17):

you just group them... what do you mean?

view this post on Zulip Rahil Malik (Jan 08 2018 at 20:17):

group them means to create a region ?

view this post on Zulip Sean (Jan 08 2018 at 20:18):

not specifically no -- region means you're grouping them AND saying they occupy space

view this post on Zulip Rahil Malik (Jan 08 2018 at 20:18):

so , how to group them ?

view this post on Zulip Sean (Jan 08 2018 at 20:18):

saying they occupy space is irrelevant right now

view this post on Zulip Sean (Jan 08 2018 at 20:18):

the g command

view this post on Zulip Rahil Malik (Jan 08 2018 at 20:19):

btw what command can let me delete everything except some solids ?

view this post on Zulip Sean (Jan 08 2018 at 20:19):

for example: g line.c sph.*

view this post on Zulip Sean (Jan 08 2018 at 20:19):

when you say delete, do you mean remove them from the display or remove them from the file

view this post on Zulip Rahil Malik (Jan 08 2018 at 20:19):

file

view this post on Zulip Sean (Jan 08 2018 at 20:19):

kill

view this post on Zulip Sean (Jan 08 2018 at 20:20):

kill sph.*

view this post on Zulip Rahil Malik (Jan 08 2018 at 20:20):

if more than 1 , i have to use the for loop , right ?

view this post on Zulip Rahil Malik (Jan 08 2018 at 20:20):

if more than 100 , then ?

view this post on Zulip Sean (Jan 08 2018 at 20:20):

heh, I think you are forgetting some of your mged lessons

view this post on Zulip Rahil Malik (Jan 08 2018 at 20:20):

I might be sleepy

view this post on Zulip Sean (Jan 08 2018 at 20:20):

you shouldn't need any for loops if you name things well

view this post on Zulip Rahil Malik (Jan 08 2018 at 20:21):

its 2:00 Am here

view this post on Zulip Sean (Jan 08 2018 at 20:21):

if you can do it with a for loop, then you probably can do it without a for loop

view this post on Zulip Sean (Jan 08 2018 at 20:21):

just use a pattern

view this post on Zulip Rahil Malik (Jan 08 2018 at 20:21):

OK

view this post on Zulip Sean (Jan 08 2018 at 20:21):

the mged command line works like the unix command line -- you can specify a pattern

view this post on Zulip Sean (Jan 08 2018 at 20:22):

for example, "draw *.r" will draw everything that ends with r

view this post on Zulip Sean (Jan 08 2018 at 20:22):

"draw sph.*" is everything starts with sph

view this post on Zulip Rahil Malik (Jan 08 2018 at 20:23):

ok, cool !, got it :thumbs_up:

view this post on Zulip Rahil Malik (Jan 08 2018 at 20:44):

hey, man . got till the last step

view this post on Zulip Rahil Malik (Jan 08 2018 at 20:45):

was making clone of the square

view this post on Zulip Rahil Malik (Jan 08 2018 at 20:46):

Hey its done

view this post on Zulip Rahil Malik (Jan 08 2018 at 20:49):

Its done . Now its symmetric . I did'nt learn the group tehcnic 5074714571571200_1515407697_Hourglass.g

view this post on Zulip Rahil Malik (Jan 08 2018 at 20:50):

mehnat.PNG

view this post on Zulip Rahil Malik (Jan 08 2018 at 20:51):

Should i submit now ?

view this post on Zulip Rahil Malik (Jan 08 2018 at 20:57):

Imma goto sleep , its 2.27 AM here :sleeping:

view this post on Zulip Sean (Jan 09 2018 at 01:10):

@Rahil Malik you made sand .4 in diameter. that's why you ran out of space so quickly

view this post on Zulip Sean (Jan 09 2018 at 01:11):

it's also not a square cube and has overlaps (modeling errors) ... looks like you have a stray sliver of cloned spheres

view this post on Zulip Sean (Jan 09 2018 at 01:14):

... but you still also need to assemble this all into a scene, a final model -- not a bunch of unrelated top-level objects

view this post on Zulip Rahil Malik (Jan 09 2018 at 03:13):

well, isn't it this way :
clone -i 1 -n 60 -t 0.4 0 0 sand.s
g line.c sand.s*
clone -i 1 -n 60 -t 0 0.4 0 line.c
g square.c line.c*
clone -i 1 -n 60 -t 0 0 0.4 square.c*
g cube.c square.c*

. and it all done ?

view this post on Zulip Rahil Malik (Jan 09 2018 at 03:13):

actully i changed the -n values cause i thought i would run out of space

view this post on Zulip Sean (Jan 09 2018 at 03:14):

that's not the grain size -- that's the copy spacing

view this post on Zulip Sean (Jan 09 2018 at 03:15):

that explains why they are all touching each other... :)

view this post on Zulip Rahil Malik (Jan 09 2018 at 03:27):

you said keep the distance between them 0.4 and their diameter 0.2

view this post on Zulip Rahil Malik (Jan 09 2018 at 03:27):

that's not the grain size -- that's the copy spacing

i din't get this

view this post on Zulip Rahil Malik (Jan 09 2018 at 03:31):

the grain size , i had set to 0.2 , this is the spacing between each clone , 0.4

view this post on Zulip Sean (Jan 09 2018 at 04:10):

you made the radius 0.2

view this post on Zulip Sean (Jan 09 2018 at 04:10):

you were supposed to make the diameter .2, the radius .1 or .09

view this post on Zulip Sean (Jan 09 2018 at 04:11):

you did make the spacing between each clone 0.4, but that's why if you zoom in you'll notice the spheres all touch each other

view this post on Zulip Sean (Jan 09 2018 at 04:11):

when there should be a nice gap about as wide as the radius

view this post on Zulip Sean (Jan 09 2018 at 04:12):

do you see a gap between the spheres?

view this post on Zulip Rahil Malik (Jan 09 2018 at 06:13):

nope. but i have this problem going on after cloning a line and making it a square, when i clone the square , mged crashes

view this post on Zulip Rahil Malik (Jan 09 2018 at 06:17):

btw in the last step where i have to clone . is it ok if it isn't perfect cube ?

view this post on Zulip Rahil Malik (Jan 09 2018 at 06:18):

60 x 60 x5 or 10 ? because only 5-10 rows of square.c can be accomodated in the hourglass

view this post on Zulip Sean (Jan 09 2018 at 06:18):

crashes are super interesting

view this post on Zulip Sean (Jan 09 2018 at 06:19):

what platform are you on?

view this post on Zulip Sean (Jan 09 2018 at 06:19):

if you can reliably get it to crash and can get a backtrace report, claim the bug report task and get credit for it

view this post on Zulip Sean (Jan 09 2018 at 06:20):

btw in the last step where i have to clone . is it ok if it isn't perfect cube ?

well, that depends... for this to be at all interesting and useful, we need a lot of grains of sand. original goal was 1M, but I think we need at least 100k

view this post on Zulip Sean (Jan 09 2018 at 06:21):

60 x 60 x5 or 10 ? because only 5-10 rows of square.c can be accomodated in the hourglass

maybe a few big layers at 60x60x5, followed by another triple cloning at something like 20x20x30

view this post on Zulip Rahil Malik (Jan 09 2018 at 06:21):

ya one square has approx. 1,00,000 grains

view this post on Zulip Rahil Malik (Jan 09 2018 at 06:22):

but isn't the crash because there are too many cubes and PC isn't capable probably

view this post on Zulip Sean (Jan 09 2018 at 06:22):

that's totally a guess

view this post on Zulip Sean (Jan 09 2018 at 06:23):

what does "PC isn't capable" mean?

view this post on Zulip Sean (Jan 09 2018 at 06:23):

that's the non programmer's view of crashes ;)

view this post on Zulip Sean (Jan 09 2018 at 06:24):

to a programmer, there is always a very specific reason

view this post on Zulip Sean (Jan 09 2018 at 06:24):

and it's rarely ever "PC isn't capable"

view this post on Zulip Rahil Malik (Jan 09 2018 at 06:24):

:) Ok

view this post on Zulip Rahil Malik (Jan 09 2018 at 06:25):

the command line goes - not responding and then i have no other option then to close the application

view this post on Zulip Sean (Jan 09 2018 at 06:25):

sure, that's just the nature of a crash

view this post on Zulip Rahil Malik (Jan 09 2018 at 06:26):

and , i can't even get one clone of it

view this post on Zulip Sean (Jan 09 2018 at 06:27):

so probably something else is wrong

view this post on Zulip Rahil Malik (Jan 09 2018 at 06:27):

it could be , let me get into it

view this post on Zulip Rahil Malik (Jan 09 2018 at 06:34):

Actually, i have more than 1,20,000 grains . so i am going to wait for 15 minutes to check if the cloning is successful , because whenever its a huge no. , mged doesn't respond for a while but is actually still runnning the code , and when the cloning is finished it goes back to normal

view this post on Zulip Rahil Malik (Jan 09 2018 at 07:47):

I think, i get it . When i tried to kill all sand grains by kill sand.s* , even then mged crashes

view this post on Zulip Rahil Malik (Jan 09 2018 at 08:11):

This means , i have too many grains , so i have to wait ro more time

view this post on Zulip Rahil Malik (Jan 09 2018 at 09:42):

i don't know why but the killing speed of mged has dropped drastically, it taks exaclty full 5 mins to kill 100 spheres while i have 1,30,000 grains

view this post on Zulip Jeff Sieu (Jan 09 2018 at 09:58):

Maybe because they were being drawn before being killed?

view this post on Zulip Rahil Malik (Jan 09 2018 at 09:58):

nope, they were all drawn

view this post on Zulip Rahil Malik (Jan 09 2018 at 09:59):

and cloning such set of grains take very much too

view this post on Zulip Rahil Malik (Jan 09 2018 at 11:15):

I have a doubt, when i change value of A,B and C of a sphere using command line (p command) then the no. given will be set as radius or diameter ?

view this post on Zulip Rahil Malik (Jan 09 2018 at 17:39):

From here on, i cannot put the next code - clone -i 1 -n 200 -t 0 0 0.2 square.c

view this post on Zulip Rahil Malik (Jan 09 2018 at 17:39):

Can anyone help me ?

view this post on Zulip Rahil Malik (Jan 09 2018 at 17:39):

i couldn't attach my .g file as it went up above 25 MB

view this post on Zulip Rahil Malik (Jan 09 2018 at 17:39):

becuase , the mged crashes after the above code , is executed

view this post on Zulip Rahil Malik (Jan 09 2018 at 17:51):

I will have to increase the grain radius or else, it would too loaded up

view this post on Zulip Rahil Malik (Jan 09 2018 at 18:11):

Is there anybody who can help ?

view this post on Zulip Rahil Malik (Jan 09 2018 at 18:55):

HEllo, sean . Is it Ok ,if i make 80 x 80 x3 ??

view this post on Zulip Sean (Jan 12 2018 at 19:20):

@Rahil Malik you of course can only submit what your machine can handle -- I don't know why it would be slowing down on you like that ... there may be some inefficiency if you are constantly cloning and killing repeatedly

view this post on Zulip Sean (Jan 12 2018 at 19:20):

you could try garbage_collect to see if that helps

view this post on Zulip Rahil Malik (Jan 13 2018 at 06:03):

so, this can be considered as a crash , right ? just while creating grains and not while killing them

view this post on Zulip Sean (Jan 13 2018 at 06:29):

I'm not sure because I've not observed that behavior. If it's a crash, mged should exit ungracefully and abruptly, or get stuck in an infinite loop.

view this post on Zulip Rahil Malik (Jan 13 2018 at 06:35):

yea, it goes not responding and then all options are unable to use except the 'X' to exit


Last updated: Oct 09 2024 at 00:44 UTC