Re: [Yade-users] [Question #699286]: Scene radius must be positive - Ignoring value

2021-11-02 Thread Mahdeyeh
Question #699286 on Yade changed:
https://answers.launchpad.net/yade/+question/699286

Mahdeyeh posted a new comment:
Thank you very much Karol, You are so good.

Some of particles moved far away and I deleted them, so every thing
going best.

Thanks alot

Best regards,
Mahdeyeh

-- 
You received this question notification because your team yade-users is
an answer contact for Yade.

___
Mailing list: https://launchpad.net/~yade-users
Post to : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


Re: [Yade-users] [Question #699286]: Scene radius must be positive - Ignoring value

2021-11-02 Thread Mahdeyeh
Question #699286 on Yade changed:
https://answers.launchpad.net/yade/+question/699286

Status: Answered => Solved

Mahdeyeh confirmed that the question is solved:
Thanks Karol Brzezinski, that solved my question.

-- 
You received this question notification because your team yade-users is
an answer contact for Yade.

___
Mailing list: https://launchpad.net/~yade-users
Post to : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


Re: [Yade-users] [Question #699286]: Scene radius must be positive - Ignoring value

2021-11-02 Thread Mahdeyeh
Question #699286 on Yade changed:
https://answers.launchpad.net/yade/+question/699286

Status: Answered => Open

Mahdeyeh is still having a problem:
> len(O.bodies)>0
> aabbDim()
All bodies are in simulation and everything goes good in running just could n`t 
see it.

> you can try to remove particles that are further than an expected radius and 
> refresh the view.
I should n`t change radius of particles due to outputs. Although the particle 
radius has n`t changed compared to before this event (event: I mean moving 
model to far away and it can not be magnified enough . In this case, in primary 
view window, the number written next to the coordinate axis is equal to 1.)

Thank you Karol for your time

-- 
You received this question notification because your team yade-users is
an answer contact for Yade.

___
Mailing list: https://launchpad.net/~yade-users
Post to : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


Re: [Yade-users] [Question #699286]: Scene radius must be positive - Ignoring value

2021-11-01 Thread Mahdeyeh
Question #699286 on Yade changed:
https://answers.launchpad.net/yade/+question/699286

Status: Answered => Open

Mahdeyeh is still having a problem:
Thank you Karol for reply.

> from yade import qt
#open the view (If you have open any other view before this, please close it 
manually.)
v = qt.View()
# and try one of these
qt.center()
#or
v.showEntireScene()

I try it but nothing change. Again I had this warninig:

In [2]:  GLViewer:248 virtual void yade::GLViewer::postDraw(): More 
than 500 grid segments (currently: 550) take too long to draw, using previous 
value: 6. If you need denser grid try calling: 
yade.qt.center(suggestedRadius,gridOrigin,suggestedCenter,gridDecimalPlaces); 
(each parameter is optional) to reduce scene grid radius. Current values are: 
yade.qt.center(suggestedRadius=13.717,gridOrigin=(0,0,0),suggestedCenter=(6.06378,9.62361,0),gridDecimalPlaces=4)
Press '-' (decrease grid density) in View window to remove this warning.

-- 
You received this question notification because your team yade-users is
an answer contact for Yade.

___
Mailing list: https://launchpad.net/~yade-users
Post to : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


Re: [Yade-users] [Question #699286]: Scene radius must be positive - Ignoring value

2021-10-31 Thread Mahdeyeh
Question #699286 on Yade changed:
https://answers.launchpad.net/yade/+question/699286

Description changed to:
Hello dear

I use yadedaily:
Yade 20210909-5909~5b11526~focal1
Using python version: 3.8.10 (default, Jun 2 2021, 10:49:15)
[GCC 9.4.0]

Ubuntu 20.04

I'm trying to generate clumps. Sometime I must save simulation of base script 
and finishing run with base script and then load saved simulation.In this run I 
run a script for restore simulation ; so in controller window  when I click 
"show 3D" or click "Reference" or "Center" to show the model in different 
direction, there will be:
In [1]: Scene radius must be positive - Ignoring value
With this notification, the scene moves strange when I adjust it through mouse.

or there will be this warning:
In [2]:  GLViewer:248 virtual void yade::GLViewer::postDraw(): More 
than 500 grid segments (currently: 550) take too long to draw, using previous 
value: 6. If you need denser grid try calling: 
yade.qt.center(suggestedRadius,gridOrigin,suggestedCenter,gridDecimalPlaces); 
(each parameter is optional) to reduce scene grid radius. Current values are: 
yade.qt.center(suggestedRadius=13.717,gridOrigin=(0,0,0),suggestedCenter=(6.06378,9.62361,0),gridDecimalPlaces=4)
Press '-' (decrease grid density) in View window to remove this warning.


I couldn`t see model and check it.


 My script has 2 files as input data .The below link shows my script for 
loading saved simulation and clump data files:
https://www.filemail.com/d/fnbgmkpuvqwgynu


Please help me about this error.
Best regards,

-- 
You received this question notification because your team yade-users is
an answer contact for Yade.

___
Mailing list: https://launchpad.net/~yade-users
Post to : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


[Yade-users] [Question #699286]: Scene radius must be positive - Ignoring value

2021-10-31 Thread Mahdeyeh
New question #699286 on Yade:
https://answers.launchpad.net/yade/+question/699286

Hello dear

I use yadedaily:
Yade 20210909-5909~5b11526~focal1
Using python version: 3.8.10 (default, Jun 2 2021, 10:49:15)
[GCC 9.4.0]

Ubuntu 20.04

I'm trying to generate clumps , I run script after uncertain iterations, in 
controller window  when I click "show 3D" or click "Reference" or "Center" to 
show the model in different direction, there will be:
In [1]: Scene radius must be positive - Ignoring value
With this notification, the scene moves strange when I adjust it through mouse.

or there will be this warning:
In [2]:  GLViewer:248 virtual void yade::GLViewer::postDraw(): More 
than 500 grid segments (currently: 550) take too long to draw, using previous 
value: 6. If you need denser grid try calling: 
yade.qt.center(suggestedRadius,gridOrigin,suggestedCenter,gridDecimalPlaces); 
(each parameter is optional) to reduce scene grid radius. Current values are: 
yade.qt.center(suggestedRadius=13.717,gridOrigin=(0,0,0),suggestedCenter=(6.06378,9.62361,0),gridDecimalPlaces=4)
Press '-' (decrease grid density) in View window to remove this warning.


I couldn`t see model and check it.




Please help me about this error.
Best regards,

-- 
You received this question notification because your team yade-users is
an answer contact for Yade.

___
Mailing list: https://launchpad.net/~yade-users
Post to : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


Re: [Yade-users] [Question #683679]: Scene radius must be positive - Ignoring value

2021-09-30 Thread Mahdeyeh
Question #683679 on Yade changed:
https://answers.launchpad.net/yade/+question/683679

Mahdeyeh posted a new comment:
Hi

this is my problem too:
In [1]: Scene radius must be positive - Ignoring value

-- 
You received this question notification because your team yade-users is
an answer contact for Yade.

___
Mailing list: https://launchpad.net/~yade-users
Post to : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


Re: [Yade-users] [Question #698672]: running on a server is slower than on a PC

2021-09-26 Thread Mahdeyeh
Question #698672 on Yade changed:
https://answers.launchpad.net/yade/+question/698672

Status: Needs information => Solved

Mahdeyeh confirmed that the question is solved:
than

-- 
You received this question notification because your team yade-users is
an answer contact for Yade.

___
Mailing list: https://launchpad.net/~yade-users
Post to : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


Re: [Yade-users] [Question #698760]: error shared_ptr.hpp:734: typename boost

2021-09-18 Thread Mahdeyeh
Question #698760 on Yade changed:
https://answers.launchpad.net/yade/+question/698760

Status: Needs information => Solved

Mahdeyeh confirmed that the question is solved:
Thank you Jan
I run script with this :  "yadedaily -j6 test.py"

sometimes when script is running, I need to "Extrction()" function, so I
write it in yade live console  .

Problem solved : with stopping run and then write "Extrction()"in yade
live console  and after it continue run

-- 
You received this question notification because your team yade-users is
an answer contact for Yade.

___
Mailing list: https://launchpad.net/~yade-users
Post to : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


[Yade-users] [Question #698760]: error shared_ptr.hpp:734: typename boost

2021-09-17 Thread Mahdeyeh
New question #698760 on Yade:
https://answers.launchpad.net/yade/+question/698760

Hello dear

I use yadedaily:
Yade 20210909-5909~5b11526~focal1 
Using python version: 3.8.10 (default, Jun  2 2021, 10:49:15) 
[GCC 9.4.0]

Ubuntu 20.04

when I define a function ("extrction()") in the 'live' Yade console, this error 
show:

python3.8: /usr/include/boost/smart_ptr/shared_ptr.hpp:734: typename 
boost::detail::sp_member_access::type boost::shared_ptr::operator->() 
const [with T = yade::Body; typename boost::detail::sp_member_access::type = 
yade::Body*]: Assertion `px != 0' failed.
Aborted (core dumped)

I write this function: "extrction()"in the 'live' Yade console.

And the function is:

def extrction():  # run when a bucket has wanted to remove
clrOre=[0.1,0.5,0.2]
clrWaste=[0.8,0.9,0.9]
M_o1=0# total ore of model befor deleting volume of 
bucket
M_w1=0# total waste of model befor deleting volume of 
bucket
for b in O.bodies:
if b.shape.color==clrOre:
M_o1 +=b.state.mass
if b.shape.color==clrWaste:
M_w1 +=b.state.mass

if b.state.pos[0]>(-11.5) and b.state.pos[0]<1.58 and 
b.state.pos[1]>0 and b.state.pos[1]<3.8:
if O.bodies[b.id].isClump or O.bodies[b.id].isClumpMember:
iter1=O.iter
ids=open("iter removedids.txt","a")
ids.write(repr(iter1)+' '+repr(b.id)+'  '"\n")
ids.close()
O.bodies.erase(b.id,True)
M_o2=0   # total ore of model after deleting volume of 
bucket
M_w2=0   # total waste of model after deleting volume of 
bucket
for b in O.bodies:
if b.shape.color==clrOre:
M_o2 +=b.state.mass
if b.shape.color==clrWaste:
M_w2 +=b.state.mass

m_o = M_o1 - M_o2
m_w = M_w1 - M_w2
   # print M_o1 , M_o2 , m_o , m_w
iter1=O.iter
Mass=open("Mass iter massore masswaste.txt","a")
Mass.write(repr(iter1)+''+repr(m_o)+'   '+repr(m_w)+'   '"\n")
Mass.close() 

 My script has 2 files as input data .The below link shows my scrip and clump 
data files:
https://www.filemail.com/d/xrqjjzwakjinvib

Please help me about this error.
Best regards,


-- 
You received this question notification because your team yade-users is
an answer contact for Yade.

___
Mailing list: https://launchpad.net/~yade-users
Post to : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


Re: [Yade-users] [Question #698672]: running on a server is slower than on a PC

2021-09-14 Thread Mahdeyeh
Question #698672 on Yade changed:
https://answers.launchpad.net/yade/+question/698672

Mahdeyeh posted a new comment:
> What does the "% of CPU" mean? how you get it?
with command "top" in terminal.

>  - where is it located? unknown cloud, your office, your institute lab, ...?
I rented it from another university.

 > who have access to it? only you? people you know? anybody? ... ?
I use it with password and AnyDesk. Just me use it.

>   Is it possible that while you are running jobs, the server is already 
> "full", using all cores for other jobs?
No and Before starting run, I check it with "top" command.

> how do you run the jobs? directly using command line? using some queuing 
> system? ... ?
with AnyDesk, I connected to their system. I type in terminal: "yade -j8 
test.py"

> do you use a GUI or just command line?
GUI

-- 
You received this question notification because your team yade-users is
an answer contact for Yade.

___
Mailing list: https://launchpad.net/~yade-users
Post to : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


Re: [Yade-users] [Question #698672]: running on a server is slower than on a PC

2021-09-13 Thread Mahdeyeh
Question #698672 on Yade changed:
https://answers.launchpad.net/yade/+question/698672

Status: Answered => Open

Mahdeyeh is still having a problem:
>You mentioned 64000 iterations in initial question, but your above timing data 
>show other numbers of iterations (possibly as different as 136 as 2079 if one 
>looks at the ForceResetter engine, that usually executes each DEM iteration).
Timing data is for about 2000 iteration above,increasing iteration does n`t 
change speed of run or anything with CPU. 


> Are you sure your comparison is meaningfully designed (applies to a constant 
> number of YADE iterations) ?
yes Jérôme. Speed of run and percent of CPU are the same for different 
iteration.

-- 
You received this question notification because your team yade-users is
an answer contact for Yade.

___
Mailing list: https://launchpad.net/~yade-users
Post to : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


Re: [Yade-users] [Question #698672]: running on a server is slower than on a PC

2021-09-12 Thread Mahdeyeh
Question #698672 on Yade changed:
https://answers.launchpad.net/yade/+question/698672

Status: Answered => Open

Mahdeyeh is still having a problem:
Thanks Jan for your reply
> what is "the server"? How much you can influence it (running other jobs, 
> setting, ...)?
I dont understand what you mean, anyway I can install every thing on this 
system and see system monitoring.

> please provide the code, as the parallelization performance is strongly 
> influenced by the code used.
my script has 2 files as input data .The below link shows my scrip and clump 
data files:
https://www.filemail.com/d/fleqwfgjmnduyzq


> provide the results of yade.timing [1] (for different -j options)
for yade test.py   (without -j)

NameCount 
TimeRel. time
---
ForceResetter   136 359251us
3.05%  
InsertionSortCollider 8 447212us
3.80%  
InteractionLoop 1368149884us
   69.23%  
NewtonIntegrator1362815098us
   23.91%  
"ZSpeed"  0  0us
0.00%  
"VTKview" 0  0us
0.00%  
"PosnTrk1"0  0us
0.00%  
"PosnTrk2"0  0us
0.00%  
"PosnTrk3"0  0us
0.00%  
"PosnTrk4"0  0us
0.00%  
"PosnTrk5"0  0us
0.00%  
"PosnTrk6"0  0us
0.00%  
"PosnTrk7"0  0us
0.00%  
"PosnTrk8"0  0us
0.00%  
"PosnTrk9"0  0us
0.00%  
"PosnTrk10"   0  0us
0.00%  
"PosnTrk11"   0  0us
0.00%  
"PosnTrk12"   0  0us
0.00%  
"PosnTrk13"   0  0us
0.00%  
"PosnTrk14"   0  0us
0.00%  
"PosnTrk15"   0  0us
0.00%  
"PosnTrk16"   0  0us
0.00%  
"PosnTrk17"   0  0us
0.00%  
"PosnTrk18"   0  0us
0.00%  
"PosnTrk19"   0  0us
0.00%  
"PosnTrk20"   0  0us
0.00%  
"PosnTrk21"   0  0us
0.00%  
TOTAL 11771446us
  100.00%  


for-j1  :


NameCount 
TimeRel. time
---
ForceResetter   196 468248us
3.36%  
InsertionSortCollider18 740741us
5.31%  
InteractionLoop 1958981191us
   64.41%  
NewtonIntegrator1953753575us
   26.92%  
"ZSpeed"  0  0us
0.00%  
"VTKview" 0  0us
   

Re: [Yade-users] [Question #698672]: running on a server is slower than on a PC

2021-09-08 Thread Mahdeyeh
Question #698672 on Yade changed:
https://answers.launchpad.net/yade/+question/698672

Description changed to:
Hello dear

I use a server and I install the yade on the server. But I find that
running on the server is slower than on the PC.

(1) The hardware and configuration of the server is
 CPU: Intel(R) Xeon(R) CPU E7-4850 v4 @ 2.10GHz
 Memory : 32GB
 OS: Ubuntu 18.04 LTS 64bits
 Yade: 2018.02b
 gcc version: 7.5.0
libcgal: 4.11-2biuld1 500

(2) The hardware and configuration of the PC
CPU : Intel(R) Pentium(R) CPU G2030 @ 3.00GHz
Memory :4GB
OS: Ubuntu 18.04 64bit
Yade: 2018.02b
gcc version: 7.5.0 (Ubuntu 7.5.0-3ubuntu1~18.04)
libcgal: 4.11-2build1
I operate the server by AnyDesk


I run the yade like this:
(1) On the server
yade -j8 test.py

(2) On the PC
yade -j2 test.py

The speed of simulation process on server is about 10% slower than on
the PC. With "top" command server use only 55-60% of CPU but my PC use
97% of CPU.

When I use -j2 for both of them, speed of simulation on server is about
30% slower than on the PC.

When I use -j12 for server: 64000 iteration in 1 hour and 16 min (60% of CPU). 
-j8 for server: 64000 iteration in 44 min (55% of CPU). -j2 for server: 64000 
iteration in 55 min (17% of CPU).
With -j2 for my PC: 64000 iteration in 33 min (97% of CPU).

My model have about 46603 sphere (the spheres were clumped, about 2600
clumps).

Is that possible, some updates in Ubuntu and some lib or version of them
in server cause this problem?

Please help me.

Thanks alot.


For server:
Command "lscpu":

Architecture:x86_64
CPU op-mode(s):  32-bit, 64-bit
Byte Order:  Little Endian
CPU(s):  12
On-line CPU(s) list: 0-11
Thread(s) per core:  1
Core(s) per socket:  1
Socket(s):   12
NUMA node(s):1
Vendor ID:   GenuineIntel
CPU family:  6
Model:   79
Model name:  Intel(R) Xeon(R) CPU E7-4850 v4 @ 2.10GHz
Stepping:1
CPU MHz: 2094.952
BogoMIPS:4189.90
Hypervisor vendor:   VMware
Virtualization type: full
L1d cache:   32K
L1i cache:   32K
L2 cache:256K
L3 cache:40960K
NUMA node0 CPU(s):   0-11
Flags:   fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca 
cmov pat pse36 clflush mmx fxsr sse sse2 ss syscall nx pdpe1gb rdtscp lm 
constant_tsc arch_perfmon nopl xtopology tsc_reliable nonstop_tsc cpuid pni 
pclmulqdq ssse3 fma cx16 pcid sse4_1 sse4_2 x2apic movbe popcnt 
tsc_deadline_timer aes xsave avx f16c rdrand hypervisor lahf_lm abm 
3dnowprefetch cpuid_fault invpcid_single pti ibrs ibpb stibp fsgsbase 
tsc_adjust bmi1 hle avx2 smep bmi2 invpcid rtm rdseed adx smap xsaveopt arat 
arch_capabilities

-- 
You received this question notification because your team yade-users is
an answer contact for Yade.

___
Mailing list: https://launchpad.net/~yade-users
Post to : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


[Yade-users] [Question #698672]: running on a server is slower than on a PC

2021-09-08 Thread Mahdeyeh
New question #698672 on Yade:
https://answers.launchpad.net/yade/+question/698672

Hello dear

I use a server and I install the yade on the server. But I find that running on 
the server is slower than on the PC.

(1) The hardware and configuration of the server is
 CPU: Intel(R) Xeon(R) CPU E7-4850 v4 @ 2.10GHz
 Memory : 32GB
 OS: Ubuntu 18.04 LTS 64bits
 Yade: 2018.02b
 gcc version: 7.5.0
 cgal: 4.11-2biuld1 500

(2) The hardware and configuration of the PC
CPU : Intel(R) Pentium(R) CPU G2030 @ 3.00GHz
Memory :4GB
OS: Ubuntu 18.04 64bit
Yade: 2018.02b

I operate the server by AnyDesk


I run the yade like this:
(1) On the server
yade -j8 test.py

(2) On the PC
yade -j2 test.py

The speed of simulation process on server is about 10% slower than on the PC. 
With "top" command server use only 55-60% of CPU but my PC use 97% of CPU.

When I use -j2 for both of them, speed of simulation on server is about 30% 
slower than on the PC.

When I use -j12 for server: 64000 iteration in 1 hour and 16 min. With -j2 for 
my PC: 64000 iteration in 33 min.
-j8 for server: 64000 iteration in 44 min. -j2 for server: 64000 iteration in 
55 min.

My model have about 46603 sphere (the spheres were clumped, about 2600 clumps).

Is that possible, some updates in Ubuntu and some lib or version of them in 
server cause this problem?

Please help me. 

Thanks alot.



For server:
Command "lscpu":

Architecture:x86_64
CPU op-mode(s):  32-bit, 64-bit
Byte Order:  Little Endian
CPU(s):  12
On-line CPU(s) list: 0-11
Thread(s) per core:  1
Core(s) per socket:  1
Socket(s):   12
NUMA node(s):1
Vendor ID:   GenuineIntel
CPU family:  6
Model:   79
Model name:  Intel(R) Xeon(R) CPU E7-4850 v4 @ 2.10GHz
Stepping:1
CPU MHz: 2094.952
BogoMIPS:4189.90
Hypervisor vendor:   VMware
Virtualization type: full
L1d cache:   32K
L1i cache:   32K
L2 cache:256K
L3 cache:40960K
NUMA node0 CPU(s):   0-11
Flags:   fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca 
cmov pat pse36 clflush mmx fxsr sse sse2 ss syscall nx pdpe1gb rdtscp lm 
constant_tsc arch_perfmon nopl xtopology tsc_reliable nonstop_tsc cpuid pni 
pclmulqdq ssse3 fma cx16 pcid sse4_1 sse4_2 x2apic movbe popcnt 
tsc_deadline_timer aes xsave avx f16c rdrand hypervisor lahf_lm abm 
3dnowprefetch cpuid_fault invpcid_single pti ibrs ibpb stibp fsgsbase 
tsc_adjust bmi1 hle avx2 smep bmi2 invpcid rtm rdseed adx smap xsaveopt arat 
arch_capabilities


-- 
You received this question notification because your team yade-users is
an answer contact for Yade.

___
Mailing list: https://launchpad.net/~yade-users
Post to : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


Re: [Yade-users] [Question #698346]: Why VTKExporter does not work?

2021-08-16 Thread Mahdeyeh
Question #698346 on Yade changed:
https://answers.launchpad.net/yade/+question/698346

Mahdeyeh posted a new comment:
Thank you Jan and Karol, both of you said true!
My mistake was defining the function in the 'live' Yade console.
When I use 'Copy-paste' approach to restore simulation, everything goes normal 
and ok.

You guys are the best.

Best regards,
Mahdeyeh

-- 
You received this question notification because your team yade-users is
an answer contact for Yade.

___
Mailing list: https://launchpad.net/~yade-users
Post to : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


Re: [Yade-users] [Question #698346]: Why VTKExporter does not work?

2021-08-16 Thread Mahdeyeh
Question #698346 on Yade changed:
https://answers.launchpad.net/yade/+question/698346

Status: Needs information => Solved

Mahdeyeh confirmed that the question is solved:


-- 
You received this question notification because your team yade-users is
an answer contact for Yade.

___
Mailing list: https://launchpad.net/~yade-users
Post to : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


Re: [Yade-users] [Question #698346]: Why VTKExporter does not work?

2021-08-13 Thread Mahdeyeh
Question #698346 on Yade changed:
https://answers.launchpad.net/yade/+question/698346

Status: Needs information => Open

Mahdeyeh gave more information on the question:
Hi Jan
I apologize for always explaining badly!

> What does "saved" mean?
 I ran a script with 'yade test.py', (in this script, VTK exported and 
everything was ok). I have saved simulation in iteration 2591000 with command = 
  O.save('iter2591000.bz2')
Then for some reason first simulation stopped.

so : 
> What does "load" mean?
I used saved file (iter2591000.bz2) and load it with command = 
O.load('iter2591000.bz2') 
to continue the simulation.

>  What does "file" mean?
'iter2591000.bz2'

> in original script? from original script?
from original script.

> what does "in saved file mean"?
When I load the scene ('iter2591000.bz2') later and resume the simulation.

 > Please be consistent
 After resume simulation with ( O.load), I import again lines below in terminal:

from yade import export,polyhedra_utils
import os
from yade import plot
import math
from yade import utils
import pylab
import matplotlib; matplotlib.rc('axes',grid=True)
from matplotlib import pyplot
from yade import qt
import numpy as np
from numpy import *
from yade import export as expt

os.mkdir(O.tags['id'])

ClumpVtkData = expt.VTKExporter(O.tags['id']+'/'+'clumpData')
def VTKview():
for b in O.bodies:
ClumpVtkData.exportSpheres(ids='all', what={('color','b.shape.color')})
ClumpVtkData.exportFacets(ids='all', what={('color','b.shape.color')})

O.engines=O.engines+[PyRunner(iterPeriod=7,command='VTKview()',label="VTKview")]


> should be self-explanatory. Did you import ClumpVtkData?
yes, as I wrote above with : 
ClumpVtkData = expt.VTKExporter(O.tags['id']+'/'+'clumpData')

> The description is a bit vague and ambiguous.
I really sorry.

Best regards,
Mahdeyeh

-- 
You received this question notification because your team yade-users is
an answer contact for Yade.

___
Mailing list: https://launchpad.net/~yade-users
Post to : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


Re: [Yade-users] [Question #698346]: Why VTKExporter does not work?

2021-08-13 Thread Mahdeyeh
Question #698346 on Yade changed:
https://answers.launchpad.net/yade/+question/698346

Description changed to:
I load a saved file of simulation and after loading it, I import every
function in original script. every thing is good but it does n`t export
VTK.

When I run main script (not saved file) , all things are ok and data
export to VTK . Here is its code:

"
from yade import export,polyhedra_utils
import os
from yade import plot
import math
from yade import utils
import pylab
import matplotlib; matplotlib.rc('axes',grid=True)
from matplotlib import pyplot
from yade import qt
import numpy as np
from numpy import *
from yade import export as expt
.
.
.

os.mkdir(O.tags['id'])

ClumpVtkData = expt.VTKExporter(O.tags['id']+'/'+'clumpData')
def VTKview():
for b in O.bodies:
ClumpVtkData.exportSpheres(ids='all', what={('color','b.shape.color')})
ClumpVtkData.exportFacets(ids='all', what={('color','b.shape.color')})

O.engines=O.engines+[PyRunner(iterPeriod=7,command='VTKview()',label="VTKview")]
 
"

But now in saved file, I could n`t export any vtk file.  (I import all codes 
above in terminal after loading saved file, but something is wrong .)
When I type VTKview()   in terminal (when saved file of simulation is 
running), it says: 

"global name 'ClumpVtkData' is not defined"

Please help me.

Best regards,

ubuntu : 18.04
yade 2018.02b

-- 
You received this question notification because your team yade-users is
an answer contact for Yade.

___
Mailing list: https://launchpad.net/~yade-users
Post to : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


Re: [Yade-users] [Question #698314]: how to use class yade.wrapper.StepDisplacer((object)arg1)

2021-08-12 Thread Mahdeyeh
Question #698314 on Yade changed:
https://answers.launchpad.net/yade/+question/698314

Status: Answered => Open

Mahdeyeh is still having a problem:
>I would always output position/displacement of all clumps.
>The output is one / a few lines of code.
>Once having the data, you can always easily do differences between any times 
>(from beginning, from last output, ...)

This seems good idea. I will try. Thanks

And what about Paraview as you said. Can I have  polar diagram of
displacements?

-- 
You received this question notification because your team yade-users is
an answer contact for Yade.

___
Mailing list: https://launchpad.net/~yade-users
Post to : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


[Yade-users] [Question #698346]: Why VTKExporter does not work?

2021-08-12 Thread Mahdeyeh
New question #698346 on Yade:
https://answers.launchpad.net/yade/+question/698346

I load a saved file of simulation and after loading it, I import every function 
in original script. every thing is good but it does n`t export VTK.

When I run main script (not saved file) , all things are ok and data export to 
VTK . Here is its code:

"
os.mkdir(O.tags['id'])   

ClumpVtkData = expt.VTKExporter(O.tags['id']+'/'+'clumpData')
def VTKview():
for b in O.bodies:
ClumpVtkData.exportSpheres(ids='all', what={('color','b.shape.color')})
ClumpVtkData.exportFacets(ids='all', what={('color','b.shape.color')})

O.engines=O.engines+[PyRunner(iterPeriod=7,command='VTKview()',label="VTKview")]
 
"

But now in saved file, I could n`t export any vtk file.  (I import all codes 
above in terminal after loading saved file, but something is wrong .)
When I type VTKview()   in terminal (when saved file of simulation is 
running), it says: 

"global name 'ClumpVtkData' is not defined"

Please help me.

Best regards,

ubuntu : 18.04
yade 2018.02b



-- 
You received this question notification because your team yade-users is
an answer contact for Yade.

___
Mailing list: https://launchpad.net/~yade-users
Post to : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


Re: [Yade-users] [Question #698314]: how to use class yade.wrapper.StepDisplacer((object)arg1)

2021-08-11 Thread Mahdeyeh
Question #698314 on Yade changed:
https://answers.launchpad.net/yade/+question/698314

Status: Needs information => Open

Mahdeyeh gave more information on the question:
Thank you for example .

> Moved from the beginning of simulation? From last output? ... ?
both of them! Moved from the beginning of simulation and also From last output.

> What is "plot or diagram"? How should it look? Picture of deformed shape? 
> Some polar diagram of displacements? ... ?
I want = Some polar diagram of displacements.

> What is "every particle"? individual particles? only clumps?
Only clumps.

> What is "whole body"?
all of clumps. All 3000 clumps in model.

> Do you have some examples to share?
I do not know how to share one image.

> Are you aware of tools like Paraview?
> Is regular exporting of the simulation into paraview and then visualizing it 
> in Paraview what you want? Why not?
yes, I use Paraview but I did n`t check this item ( Some polar diagram of 
displacements) in it.


Thanks for your time
Best regards,

-- 
You received this question notification because your team yade-users is
an answer contact for Yade.

___
Mailing list: https://launchpad.net/~yade-users
Post to : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


Re: [Yade-users] [Question #698312]: explain returns of yade.utils.psd

2021-08-11 Thread Mahdeyeh
Question #698312 on Yade changed:
https://answers.launchpad.net/yade/+question/698312

Mahdeyeh posted a new comment:
thanks a lot for your suggestion.

-- 
You received this question notification because your team yade-users is
an answer contact for Yade.

___
Mailing list: https://launchpad.net/~yade-users
Post to : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


Re: [Yade-users] [Question #698314]: how to use class yade.wrapper.StepDisplacer((object)arg1)

2021-08-11 Thread Mahdeyeh
Question #698314 on Yade changed:
https://answers.launchpad.net/yade/+question/698314

Status: Needs information => Open

Mahdeyeh gave more information on the question:
Thanks Jan


> What does "printing" mean?
I mean having their position as output.

>  What does "moved (particles)" mean? Moved from the beginning of simulation? 
> From last output? ... ? Changed position? Or also orientation? ... ?
I mean changed position or orientation.

> Why is the amount a problem? 3000 does not sound as too many..
Maybe because of my computer.

>  According to docs [1], it "applies displacement".
Any example for this? please..

I want write a code that says: if particles moved from ex-position so give 
their id and new position of everyone. 
Because I want to draw shape`s moving of every particle in plot or diagram. And 
at the end, achieve to shape`s moving of hole body.

Best regards,

-- 
You received this question notification because your team yade-users is
an answer contact for Yade.

___
Mailing list: https://launchpad.net/~yade-users
Post to : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


Re: [Yade-users] [Question #698312]: explain returns of yade.utils.psd

2021-08-11 Thread Mahdeyeh
Question #698312 on Yade changed:
https://answers.launchpad.net/yade/+question/698312

Status: Answered => Solved

Mahdeyeh confirmed that the question is solved:
Thanks Jan Stránský, that solved my question.

-- 
You received this question notification because your team yade-users is
an answer contact for Yade.

___
Mailing list: https://launchpad.net/~yade-users
Post to : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


Re: [Yade-users] [Question #698312]: explain returns of yade.utils.psd

2021-08-11 Thread Mahdeyeh
Question #698312 on Yade changed:
https://answers.launchpad.net/yade/+question/698312

Mahdeyeh posted a new comment:
Thank you Jan Stránský and Jérôme Duriez .

> Also note that yade.utils.psd counts only with spheres as such,
regardless clumps [3].

I understand , those sizes are for spheres of my clumps not size of
clumps.

-- 
You received this question notification because your team yade-users is
an answer contact for Yade.

___
Mailing list: https://launchpad.net/~yade-users
Post to : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


Re: [Yade-users] [Question #698314]: how to use class yade.wrapper.StepDisplacer((object)arg1)

2021-08-10 Thread Mahdeyeh
Question #698314 on Yade changed:
https://answers.launchpad.net/yade/+question/698314

Description changed to:
Dear all,
At first: I am beginner in YADE.

I have simulated clumps spherical particles.
I have modeled 3000 particles, I mean I have 3000 clumps.

I want to get as output (text or excel): If particles in specified range of my 
volume are moved, printing their positions continuous.
Because of having too many particles and then positions, I want to have just 
position of moved particles.
How I can get this aim?
I wrote this code: but I do not know how write code for : if particles moved 
.

def positions():
for b in O.bodies:
if b.state.pos[0]>(2.9) and b.state.pos[0]<7 and b.state.pos[1]>4 and 
b.state.pos[1]<19: # flow zone 
  
iter0=O.iter
Positions=open("Positions id iter x y.txt","a")
Positions.write(repr(id)+'  '+repr(iter0)+' 
'+repr(b.state.pos[0])+''+repr(b.state.pos[1])+''"\n")
Positions.close() 

O.engines=O.engines+[PyRunner(command='positions()',iterPeriod=30,label="flow")]


And can I use for this purpose with this code: if yes how to use and write?
class yade.wrapper.StepDisplacer((object)arg1)


Many thanks for your help.
Best regards,


ubuntu : 18.04
yade 2018.02b

-- 
You received this question notification because your team yade-users is
an answer contact for Yade.

___
Mailing list: https://launchpad.net/~yade-users
Post to : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


[Yade-users] [Question #698314]: how to use class yade.wrapper.StepDisplacer((object)arg1)

2021-08-10 Thread Mahdeyeh
New question #698314 on Yade:
https://answers.launchpad.net/yade/+question/698314

Dear all,
At first: I am beginner in YADE.

I have simulated clumps spherical particles.
I have modeled 3000 particles, I mean I have 3000 clumps.

I want to get as output (text or excel): If particles in specified range of my 
volume are moved, printing their positions continuous.
Because of having too many particles and then positions, I want to have just 
position of moved particles.
How I can get this aim?
I wrote this code: but I do not know how write code for : if particles moved 
.

def positions():
for b in O.bodies:
if b.state.pos[0]>(2.9) and b.state.pos[0]<7 and b.state.pos[1]>4 and 
b.state.pos[1]<19: # flow zone 
  
iter0=O.iter
Positions=open("Positions clumpId iter x y.txt","a")
Positions.write(repr(clumpId)+' '+repr(iter0)+' 
'+repr(b.state.pos[0])+''+repr(b.state.pos[1])+''"\n")
Positions.close() 

O.engines=O.engines+[PyRunner(command='positions()',iterPeriod=30,label="flow")]




And can I use for this purpose with this code: if yes how to use and write?
class yade.wrapper.StepDisplacer((object)arg1)



Many thanks for your help.
Best regards,



ubuntu : 18.04
yade 2018.02b

-- 
You received this question notification because your team yade-users is
an answer contact for Yade.

___
Mailing list: https://launchpad.net/~yade-users
Post to : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


[Yade-users] [Question #698312]: explain returns of yade.utils.psd

2021-08-10 Thread Mahdeyeh
New question #698312 on Yade:
https://answers.launchpad.net/yade/+question/698312

Dear all,
I have a question in returns of yade.utils.psd in simulating clumps spherical 
particles.
I have modeled 3000 particles, I mean I have 3000 clumps. 
Particle size distribution for them is 8 cm to 100 cm.
Around of particles in yade is facet.

When I want psd with yade.utils.psd(mass=True), it gives me these:

(array([0.0026, 0.055 , 0.1074, 0.1598, 0.2122, 0.2646]),
 array([0., 0.06952433, 0.30856434, 0.48348666, 0.88043175,
1.]),
 array([0.,  1259.17422258,  5588.49372188,  8756.56001507,
15945.74175232, 18111.27531567]))

I read [1] , but actually I could not understand what is these arrays! if first 
array is sizes of my particles so why it is until 26 cm?

Many thanks for your help.
Best regards,

[1] 
https://yade-dem.org/doc/yade.utils.html?highlight=yade%20utils%20psd#yade.utils.psd

ubuntu : 18.04
yade 2018.02b

-- 
You received this question notification because your team yade-users is
an answer contact for Yade.

___
Mailing list: https://launchpad.net/~yade-users
Post to : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


Re: [Yade-users] [Question #695833]: movment along z axis whiles blockedDOFs= zXY

2021-03-04 Thread Mahdeyeh
Question #695833 on Yade changed:
https://answers.launchpad.net/yade/+question/695833

Status: Answered => Solved

Mahdeyeh confirmed that the question is solved:
Thanks Karol Brzezinski, that solved my question.

-- 
You received this question notification because your team yade-users is
an answer contact for Yade.

___
Mailing list: https://launchpad.net/~yade-users
Post to : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


Re: [Yade-users] [Question #695833]: movment along z axis whiles blockedDOFs= zXY

2021-03-03 Thread Mahdeyeh
Question #695833 on Yade changed:
https://answers.launchpad.net/yade/+question/695833

Description changed to:
Dear All,
I have a problem in simulating clumps spherical particles' gravity deposition 
in 2D. I use:
b.state.blockedDOFs='zXY'
b.state.angMom[2]=0
b.state.angVel[2]=0
b.state.vel[2]=0

to fix all the particles in Z plane. But I found that, particle moves
along Z axis and when check it in  simulation inspection window (in
Bodies), I see blockedDOFs is without any value and linear velocity for
Z has value.

ubuntu : 18.04
yade 2018.02b

this is minimum of my code:


from yade import export,polyhedra_utils
import os
from yade import plot
import math
from yade import utils
import pylab
import matplotlib; matplotlib.rc('axes',grid=True)
from matplotlib import pyplot
from yade import qt
import numpy as np
from numpy import *
from yade import export as expt


Dolomite = FrictMat()
Dolomite.density = 2870 #kg/m^3 
Dolomite.young = 24.36e9 #Pa 
Dolomite.poisson = 0.2
Dolomite.frictionAngle = radians(55.12) #rad

Bound = FrictMat()
Bound.density = 2870 #kg/m^3 
Bound.young = 60e10 #Pa 
Bound.poisson = 0.2
Bound.frictionAngle = radians(55.12) #rad



v1=((-6.4993,-0.01,2),(-2,-0.01,2),(-6.4993,-0.01,-2))
v2=((-2,-0.01,2),(-2,-0.01,-2),(-6.4993,-0.01,-2))
v3=((-1.99,-0.01,2),(-1.99,-0.01,-2),(-1,-0.01,2))
v4=((-1,-0.01,2),(-1,-0.01,-2),(-1.99,-0.01,-2))
v5=((-0.99,-0.01,2),(-0.99,-0.01,-2),(1,-0.01,2))
v6=((1,-0.01,2),(1,-0.01,-2),(-0.99,-0.01,-2))
v7=((1.01,-0.01,2),(1.01,-0.01,-2),(2,-0.01,2))
v8=((2,-0.01,2),(2,-0.01,-2),(1.01,-0.01,-2))
v9=((2.01,-0.01,2),(2.01,-0.01,-2),(3,-0.01,2))
v10=((3,-0.01,2),(3,-0.01,-2),(2.01,-0.01,-2))
v11=((3.01,-0.01,2),(3.01,-0.01,-2),(4.58,-0.01,2))
v12=((4.58,-0.01,2),(4.58,-0.01,-2),(3.01,-0.01,-2))
v13=((4.7,0.0059,2),(5.3,0.93,2),(4.7,0.0059,-2))
v14=((5.3,0.93,2),(5.3,0.93,-2),(4.7,0.0059,-2))
v15=((5.3,0.94,2),(5.3,0.94,-2),(6.47,2.57,2))
v16=((6.47,2.57,2),(6.47,2.57,-2),(5.3,0.94,-2))
v17=((6.47,2.58,2),(6.47,2.58,-2),(6.85,3.01,2))
v18=((6.85,3.01,2),(6.85,3.01,-2),(6.47,2.58,-2))


O.bodies.append(utils.facet(v1,color=(1,0,1), material=Bound))
O.bodies.append(utils.facet(v2,color=(1,0,1), material=Bound))
O.bodies.append(utils.facet(v3,color=(1,0,1), material=Bound))
O.bodies.append(utils.facet(v4,color=(1,0,1), material=Bound))
O.bodies.append(utils.facet(v5,color=(1,0,1), material=Bound))
O.bodies.append(utils.facet(v6,color=(1,0,1), material=Bound))
O.bodies.append(utils.facet(v7,color=(1,0,1), material=Bound))
O.bodies.append(utils.facet(v8,color=(1,0,1), material=Bound))
O.bodies.append(utils.facet(v9,color=(1,0,1), material=Bound))
O.bodies.append(utils.facet(v10,color=(1,0,1), material=Bound))
O.bodies.append(utils.facet(v11,color=(1,0,1), material=Bound))
O.bodies.append(utils.facet(v12,color=(1,0,1), material=Bound))
O.bodies.append(utils.facet(v13,color=(1,0,1), material=Bound))
O.bodies.append(utils.facet(v14,color=(1,0,1), material=Bound))
O.bodies.append(utils.facet(v15,color=(1,0,1), material=Bound))
O.bodies.append(utils.facet(v16,color=(1,0,1), material=Bound))
O.bodies.append(utils.facet(v17,color=(1,0,1), material=Bound))
O.bodies.append(utils.facet(v18,color=(1,0,1), material=Bound))


rad = 0.2
O.materials.append(FrictMat(young=24.36e9,density=2870))


IDs=O.bodies.append([
  utils.sphere(center=(rad,2,3.5*rad),radius=rad, material=Dolomite),
  utils.sphere(center=(rad,10.75*rad,3.5*rad),radius=rad, material=Dolomite),
  utils.sphere(center=(1.75*rad,2,3.5*rad),radius=rad, material=Dolomite),
  utils.sphere(center=(1.75*rad,10.75*rad,3.5*rad),radius=rad, 
material=Dolomite),
  utils.sphere(center=(rad,2,3*rad),radius=rad, material=Dolomite),
  utils.sphere(center=(rad,10.75*rad,3*rad),radius=rad, material=Dolomite),
  utils.sphere(center=(1.75*rad,2,3*rad),radius=rad, material=Dolomite),
  utils.sphere(center=(1.75*rad,10.75*rad,3*rad),radius=rad, material=Dolomite),
  ])

O.bodies.clump(IDs)


# block z translation and block x, y rotations
for b in O.bodies:
if b.material is Dolomite:
b.state.blockedDOFs='zXY'
b.state.angMom[2]=0
b.state.angVel[2]=0
b.state.vel[2]=0


def checkUnbalanced():   
print "iter %d , unbalanced forces %f"%(O.iter, utils.unbalancedForce())  # 
%[(keyname)][flags][width][.precision]typecode : String Formatting  
iter00=O.iter
Unbalanced=open("Unbalanced iter Unbalanced forces.txt","a")
Unbalanced.write(repr(iter00)+' '+repr(utils.unbalancedForce())+'   
'+"\n")
Unbalanced.close()

def angVel():
for c in O.bodies:
if c.state.angVel!=(0,0,0) or c.state.angMom!=(0,0,0):
s1=c.id
s2=O.iter
s3=O.realtime
s4=c.state.angVel
s5=c.state.angMom
angVel=open("particle iter realtime angVel angMom.txt","a")
angVel.write(repr(s1)+' '+repr(s2)+''+repr(s3)+'
'+repr(s4)+''+repr(s5)+''+"\n")

[Yade-users] [Question #695833]: movment along z axis whiles blockedDOFs= zXY

2021-03-03 Thread Mahdeyeh
New question #695833 on Yade:
https://answers.launchpad.net/yade/+question/695833

Dear All,
I have a problem in simulating clumps spherical particles' gravity deposition 
in 2D. I use:
b.state.blockedDOFs='zXY'
b.state.angMom[2]=0
b.state.angVel[2]=0
b.state.vel[2]=0

to fix all the particles in Z plane. But I found that, particle moves along Z 
axis and when check it in  simulation inspection window (in Bodies), I see 
blockedDOFs is without any value and linear velocity for Z has value.

this is minimum of my code:


from yade import export,polyhedra_utils
import os
from yade import plot
import math
from yade import utils
import pylab
import matplotlib; matplotlib.rc('axes',grid=True)
from matplotlib import pyplot
from yade import qt
import numpy as np
from numpy import *
from yade import export as expt


Dolomite = FrictMat()
Dolomite.density = 2870 #kg/m^3 
Dolomite.young = 24.36e9 #Pa 
Dolomite.poisson = 0.2
Dolomite.frictionAngle = radians(55.12) #rad

Bound = FrictMat()
Bound.density = 2870 #kg/m^3 
Bound.young = 60e10 #Pa 
Bound.poisson = 0.2
Bound.frictionAngle = radians(55.12) #rad




v1=((-6.4993,-0.01,2),(-2,-0.01,2),(-6.4993,-0.01,-2))
v2=((-2,-0.01,2),(-2,-0.01,-2),(-6.4993,-0.01,-2))
v3=((-1.99,-0.01,2),(-1.99,-0.01,-2),(-1,-0.01,2))
v4=((-1,-0.01,2),(-1,-0.01,-2),(-1.99,-0.01,-2))
v5=((-0.99,-0.01,2),(-0.99,-0.01,-2),(1,-0.01,2))
v6=((1,-0.01,2),(1,-0.01,-2),(-0.99,-0.01,-2))
v7=((1.01,-0.01,2),(1.01,-0.01,-2),(2,-0.01,2))
v8=((2,-0.01,2),(2,-0.01,-2),(1.01,-0.01,-2))
v9=((2.01,-0.01,2),(2.01,-0.01,-2),(3,-0.01,2))
v10=((3,-0.01,2),(3,-0.01,-2),(2.01,-0.01,-2))
v11=((3.01,-0.01,2),(3.01,-0.01,-2),(4.58,-0.01,2))
v12=((4.58,-0.01,2),(4.58,-0.01,-2),(3.01,-0.01,-2))
v13=((4.7,0.0059,2),(5.3,0.93,2),(4.7,0.0059,-2))
v14=((5.3,0.93,2),(5.3,0.93,-2),(4.7,0.0059,-2))
v15=((5.3,0.94,2),(5.3,0.94,-2),(6.47,2.57,2))
v16=((6.47,2.57,2),(6.47,2.57,-2),(5.3,0.94,-2))
v17=((6.47,2.58,2),(6.47,2.58,-2),(6.85,3.01,2))
v18=((6.85,3.01,2),(6.85,3.01,-2),(6.47,2.58,-2))



O.bodies.append(utils.facet(v1,color=(1,0,1), material=Bound))
O.bodies.append(utils.facet(v2,color=(1,0,1), material=Bound))
O.bodies.append(utils.facet(v3,color=(1,0,1), material=Bound))
O.bodies.append(utils.facet(v4,color=(1,0,1), material=Bound))
O.bodies.append(utils.facet(v5,color=(1,0,1), material=Bound))
O.bodies.append(utils.facet(v6,color=(1,0,1), material=Bound))
O.bodies.append(utils.facet(v7,color=(1,0,1), material=Bound))
O.bodies.append(utils.facet(v8,color=(1,0,1), material=Bound))
O.bodies.append(utils.facet(v9,color=(1,0,1), material=Bound))
O.bodies.append(utils.facet(v10,color=(1,0,1), material=Bound))
O.bodies.append(utils.facet(v11,color=(1,0,1), material=Bound))
O.bodies.append(utils.facet(v12,color=(1,0,1), material=Bound))
O.bodies.append(utils.facet(v13,color=(1,0,1), material=Bound))
O.bodies.append(utils.facet(v14,color=(1,0,1), material=Bound))
O.bodies.append(utils.facet(v15,color=(1,0,1), material=Bound))
O.bodies.append(utils.facet(v16,color=(1,0,1), material=Bound))
O.bodies.append(utils.facet(v17,color=(1,0,1), material=Bound))
O.bodies.append(utils.facet(v18,color=(1,0,1), material=Bound))



rad = 0.2
O.materials.append(FrictMat(young=24.36e9,density=2870))


IDs=O.bodies.append([
  utils.sphere(center=(rad,2,3.5*rad),radius=rad, material=Dolomite),
  utils.sphere(center=(rad,10.75*rad,3.5*rad),radius=rad, material=Dolomite),
  utils.sphere(center=(1.75*rad,2,3.5*rad),radius=rad, material=Dolomite),
  utils.sphere(center=(1.75*rad,10.75*rad,3.5*rad),radius=rad, 
material=Dolomite),
  utils.sphere(center=(rad,2,3*rad),radius=rad, material=Dolomite),
  utils.sphere(center=(rad,10.75*rad,3*rad),radius=rad, material=Dolomite),
  utils.sphere(center=(1.75*rad,2,3*rad),radius=rad, material=Dolomite),
  utils.sphere(center=(1.75*rad,10.75*rad,3*rad),radius=rad, material=Dolomite),
  ])

O.bodies.clump(IDs)


# block z translation and block x, y rotations
for b in O.bodies:
if b.material is Dolomite:
b.state.blockedDOFs='zXY'
b.state.angMom[2]=0
b.state.angVel[2]=0
b.state.vel[2]=0


def checkUnbalanced():   
print "iter %d , unbalanced forces %f"%(O.iter, utils.unbalancedForce())  # 
%[(keyname)][flags][width][.precision]typecode : String Formatting  
iter00=O.iter
Unbalanced=open("Unbalanced iter Unbalanced forces.txt","a")
Unbalanced.write(repr(iter00)+' '+repr(utils.unbalancedForce())+'   
'+"\n")
Unbalanced.close()

def angVel():
for c in O.bodies:
if c.state.angVel!=(0,0,0) or c.state.angMom!=(0,0,0):
s1=c.id
s2=O.iter
s3=O.realtime
s4=c.state.angVel
s5=c.state.angMom
angVel=open("particle iter realtime angVel angMom.txt","a")
angVel.write(repr(s1)+' '+repr(s2)+''+repr(s3)+'
'+repr(s4)+''+repr(s5)+''+"\n")
angVel.close() 

# Engines:  

O.engines=[
   

Re: [Yade-users] [Question #694148]: why my particles don`t show in paraview?

2020-12-04 Thread Mahdeyeh
Question #694148 on Yade changed:
https://answers.launchpad.net/yade/+question/694148

Status: Answered => Solved

Mahdeyeh confirmed that the question is solved:
Thanks Jan Stránský, that solved my question.

-- 
You received this question notification because your team yade-users is
an answer contact for Yade.

___
Mailing list: https://launchpad.net/~yade-users
Post to : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


Re: [Yade-users] [Question #694148]: why my particles don`t show in paraview?

2020-12-02 Thread Mahdeyeh
Question #694148 on Yade changed:
https://answers.launchpad.net/yade/+question/694148

Mahdeyeh posted a new comment:
1- shall I set Glyph mode to All points (in Masking) for seeing spheres in 
Paraview exactly with true radius in Yade?
I did this and I think, worked!!

2- In Yade, my sphere particles are in two colour which I can
distinguish them, so in Paraview for having two colour for them: should
I set coloring to Glyphvector  (in Display (Geom))?

Thank you

-- 
You received this question notification because your team yade-users is
an answer contact for Yade.

___
Mailing list: https://launchpad.net/~yade-users
Post to : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


Re: [Yade-users] [Question #694148]: why my particles don`t show in paraview?

2020-12-02 Thread Mahdeyeh
Question #694148 on Yade changed:
https://answers.launchpad.net/yade/+question/694148

Mahdeyeh posted a new comment:
my Paraview is :

5.4.1 64-bit

-- 
You received this question notification because your team yade-users is
an answer contact for Yade.

___
Mailing list: https://launchpad.net/~yade-users
Post to : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


Re: [Yade-users] [Question #694148]: why my particles don`t show in paraview?

2020-12-02 Thread Mahdeyeh
Question #694148 on Yade changed:
https://answers.launchpad.net/yade/+question/694148

Status: Needs information => Open

Mahdeyeh gave more information on the question:
Sorry for the delay in reply.

Thank you Jan Stránský , with your link about "Rendering spherical particles. 
Glyphs" I can see spherical particles in paraview by these command: 
"Spheres will only appear as points. To make them look as spheres, you have to 
add “glyph” to the p1-spheres.* item in the pipeline using the 
paraview-glyph-icon icon. Then set (in the Object inspector)

“Glyph type” to Sphere
“Radius” to 1
“Scale mode” to Scalar (Scalar is set above to be the radii value saved in 
the file, therefore spheres with radius 1 will be scaled by their true radius)
“Set scale factor” to 1
optionally uncheck “Mask points” and “Random mode” (they make some 
particles not to be rendered for performance reasons, controlled by the 
“Maximum Number of Points”)

After clicking “Apply”, spheres will appear. They will be rendered over
the original white points, which you can disable by clicking on the eye
icon next to p1-spheres.* in the Pipeline browser."


But in the Object inspector there is not any icon for setting “Radius”
to 1 ! If I do all steps except setting "“Radius” to 1", could see
spherical particles but they do not show in real radius as be in my main
code.


What should I do to see spheres in Paraview exactly with true radius in Yade?

Thank you a lot

-- 
You received this question notification because your team yade-users is
an answer contact for Yade.

___
Mailing list: https://launchpad.net/~yade-users
Post to : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


Re: [Yade-users] [Question #694148]: why my particles don`t show in paraview?

2020-11-26 Thread Mahdeyeh
Question #694148 on Yade changed:
https://answers.launchpad.net/yade/+question/694148

Mahdeyeh posted a new comment:
Hi 
these codes are for saving data in file which can be opened with Paraview:


os.mkdir(O.tags['id'])
O.engines=O.engines+[PyRunner(iterPeriod=1,command='VTKview()',label="VTKview")]
ClumpVtkData = expt.VTKExporter(O.tags['id']+'/'+'clumpData')
def VTKview():
ClumpVtkData.exportSpheres(ids='all', what={('color','b.shape.color')})
ClumpVtkData.exportFacets(ids='all', what={('color','b.shape.color')})

-- 
You received this question notification because your team yade-users is
an answer contact for Yade.

___
Mailing list: https://launchpad.net/~yade-users
Post to : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


[Yade-users] [Question #694148]: why my particles don`t show in paraview?

2020-11-23 Thread Mahdeyeh
New question #694148 on Yade:
https://answers.launchpad.net/yade/+question/694148

Hello 
when I check model in paraview, just I see facets and there aren`t clumps or 
particles. why? 

here is codes:

from yade import export,polyhedra_utils
import os
from yade import plot
import math
from yade import utils
import pylab
import matplotlib; matplotlib.rc('axes',grid=True)
from matplotlib import pyplot
from yade import qt
import numpy as np
from numpy import *
from yade import export as expt

# Materials type:

Dolomite = FrictMat()
Dolomite.density = 2870 #kg/m^3 
Dolomite.young = 24.36e9 #Pa 
Dolomite.poisson = 0.2
Dolomite.frictionAngle = radians(55.12) #rad

Bound = FrictMat()
Bound.density = 2870 #kg/m^3 
Bound.young = 60e10 #Pa 
Bound.poisson = 0.2
Bound.frictionAngle = radians(55.12) #rad

Shale = FrictMat()
Shale.density = 2750 #kg/m^3 
Shale.young = 6e9 #Pa 
Shale.poisson = 0.23
Shale.frictionAngle = radians(42) #rad

#O.materials.append(Dolomite)

SphCordns=np.genfromtxt('ring.txt',names=True,dtype=None)
ListSph=[]
LayNo=SphCordns[0][4]
for b in SphCordns:
if LayNo!=b[4]:
LayNo=b[4]
O.bodies.appendClumped(ListSph)
ListSph=[]
ListSph.append(sphere([b[0],b[1],b[2]], radius=b[3], 
color=(0.1,0.5,0.2),material=Dolomite))


SphCordns=np.genfromtxt('waste.txt',names=True,dtype=None)
ListSph=[]
LayNo=SphCordns[0][4]
for b in SphCordns:
if LayNo!=b[4]:
LayNo=b[4]
O.bodies.appendClumped(ListSph)
ListSph=[]
ListSph.append(sphere([b[0],b[1],b[2]], radius=b[3], 
color=(0.8,0.9,0.9),material=Shale))


v1=((-2.4993,-0.01,2),(-2,-0.01,2),(-2.4993,-0.01,-2))
v2=((-2,-0.01,2),(-2,-0.01,-2),(-2.4993,-0.01,-2))
v3=((-1.99,-0.01,2),(-1.99,-0.01,-2),(-1,-0.01,2))
v4=((-1,-0.01,2),(-1,-0.01,-2),(-1.99,-0.01,-2))
v5=((-0.99,-0.01,2),(-0.99,-0.01,-2),(1,-0.01,2))
v6=((1,-0.01,2),(1,-0.01,-2),(-0.99,-0.01,-2))
v7=((1.01,-0.01,2),(1.01,-0.01,-2),(2,-0.01,2))
v8=((2,-0.01,2),(2,-0.01,-2),(1.01,-0.01,-2))
v9=((2.01,-0.01,2),(2.01,-0.01,-2),(3,-0.01,2))
v10=((3,-0.01,2),(3,-0.01,-2),(2.01,-0.01,-2))
v11=((3.01,-0.01,2),(3.01,-0.01,-2),(4.58,-0.01,2))
v12=((4.58,-0.01,2),(4.58,-0.01,-2),(3.01,-0.01,-2))
v13=((4.7,0.0059,2),(5.3,0.93,2),(4.7,0.0059,-2))
v14=((5.3,0.93,2),(5.3,0.93,-2),(4.7,0.0059,-2))
v15=((5.3,0.94,2),(5.3,0.94,-2),(6.47,2.57,2))
v16=((6.47,2.57,2),(6.47,2.57,-2),(5.3,0.94,-2))
v17=((6.47,2.58,2),(6.47,2.58,-2),(6.85,3.01,2))
v18=((6.85,3.01,2),(6.85,3.01,-2),(6.47,2.58,-2))
v19=((6.85,3.0162,2),(6.851,4,2),(6.85,3.0162,-2))
v20=((6.85,3.0162,-2),(6.851,4,-2),(6.851,4,2))
v21=((6.851,4.0079,2),(7.08,5.6,2),(6.851,4.0079,-2))
v22=((7.08,5.6,2),(7.08,5.6,-2),(6.851,4.0079,-2))
v23=((7.08,5.61,2),(7.08,5.61,-2),(7.35,7.01,2))
v24=((7.35,7.01,2),(7.35,7.01,-2),(7.08,5.61,-2))
v25=((7.35,7.02,2),(7.35,7.02,-2),(7.59,8.51,2))
v26=((7.59,8.51,2),(7.59,8.51,-2),(7.35,7.02,-2))
v27=((7.59,8.52,2),(7.59,8.52,-2),(7.85,10,2))
v28=((7.85,10,2),(7.85,10,-2),(7.59,8.52,-2))
v29=((7.85,10.01,2),(7.85,10.01,-2),(8.19,12,2))
v30=((8.19,12,2),(8.19,12,-2),(7.85,10.01,-2))
v31=((8.19,12.01,2),(8.19,12.01,-2),(8.55,14,2))
v32=((8.55,14,2),(8.55,14,-2),(8.19,12,-2))
v33=((8.55,14.01,2),(8.55,14.01,-2),(8.8,15.5,2))
v34=((8.8,15.5,2),(8.8,15.5,-2),(8.55,14.01,-2))
v35=((8.8,15.51,2),(8.8,15.51,-2),(9.1,16.9981,2))
v36=((9.1,16.9981,2),(9.1,16.9981,-2),(8.8,15.51,-2))
v37=((9.1,17.0187,2),(9.15,19,2),(9.1,17.087,-2))
v38=((9.15,19,2),(9.15,19,-2),(9.1,17.0187,-2))
v39=((9.15,19.01,2),(9.15,19.01,-2),(9.25,20.9992,2))
v40=((9.25,20.9992,2),(9.25,20.9992,-2),(9.15,19.01,-2))
v41=((9.29,21.1,2),(9.29,21.1,-2),(9.38,22.7,2))
v42=((9.38,22.7,2),(9.38,22.7,-2),(9.29,21.1,-2))
v43=((9.38,22.73,2),(9.38,22.73,-2),(9.40,25.3,2))
v44=((9.4,25.3,2),(9.4,25.3,-2),(9.38,22.73,-2))
v45=((5.45,25.3,2),(5.45,25.3,-2),(5.32,22.5,2))
v46=((5.32,22.5,2),(5.32,22.5,-2),(5.45,25.3,-2))
v47=((5.32,22.4,2),(5.32,22.4,-2),(5.32,20,2))
v48=((5.32,20,2),(5.32,20,-2),(5.32,22.4,-2))
v49=((5.32,19.96,2),(5.32,19.96,-2),(5.82,19.96,2))
v50=((5.82,19.96,2),(5.82,19.96,-2),(5.32,19.96,-2))
v51=((5.82,19.94,2),(5.82,19.94,-2),(5.57,18.5,2))
v52=((5.57,18.5,2),(5.57,18.5,-2),(5.82,19.94,-2))
v53=((5.53,18.45,2),(5.53,18.45,-2),(5.3,17.2,2))
v54=((5.3,17.2,2),(5.3,17.2,-2),(5.53,18.45,-2))
v55=((5.3,17.15,2),(5.3,17.15,-2),(5.1,16,2))
v56=((5.1,16,2),(5.1,16,-2),(5.3,17.15,-2))
v57=((5.1,15.98,2),(5.1,15.98,-2),(4.88,15,2))
v58=((4.88,15,2),(4.88,15,-2),(5.1,15.98,-2))
v59=((4.9,14.98,2),(4.9,14.98,-2),(4.77,14.3,2))
v60=((4.77,14.3,2),(4.77,14.3,-2),(4.9,14.98,-2))
v61=((4.77,14.27,2),(4.77,14.27,-2),(4.64,13.5,2))
v62=((4.64,13.5,2),(4.64,13.5,-2),(4.77,14.27,-2))
v63=((4.64,13.47,2),(4.64,13.47,-2),(4.54,13,2))
v64=((4.54,13,2),(4.54,13,-2),(4.64,13.47,-2))
v65=((4.54,12.98,2),(4.54,12.98,-2),(4.39,12.2,2))
v66=((4.39,12.2,2),(4.39,12.2,-2),(4.54,12.98,-2))
v67=((4.39,12.18,2),(4.39,12.18,-2),(4.24,11.4,2))
v68=((4.24,11.4,2),(4.24,11.4,-2),(4.39,12.18,-2))

Re: [Yade-users] [Question #688993]: polyhedrals after collide to facet, throwing away strongly

2020-03-21 Thread Mahdeyeh
Question #688993 on Yade changed:
https://answers.launchpad.net/yade/+question/688993

Mahdeyeh posted a new comment:
Thanks Jan Stransky.

I appreciate for introducing if you know any software with the ability
of event-driven particle simulation.

Best regards,
Mahdeyeh

-- 
You received this question notification because your team yade-users is
an answer contact for Yade.

___
Mailing list: https://launchpad.net/~yade-users
Post to : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


Re: [Yade-users] [Question #688993]: polyhedrals after collide to facet, throwing away strongly

2020-03-21 Thread Mahdeyeh
Question #688993 on Yade changed:
https://answers.launchpad.net/yade/+question/688993

Status: Expired => Open

Mahdeyeh is still having a problem:
Dear Jan Stransky
I have a question about:

> - try totally different method (some event-driven particle simulation


is there event-driven particle simulation in the YADE right now?

-- 
You received this question notification because your team yade-users is
an answer contact for Yade.

___
Mailing list: https://launchpad.net/~yade-users
Post to : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


Re: [Yade-users] [Question #688993]: polyhedrals after collide to facet, throwing away strongly

2020-03-04 Thread Mahdeyeh
Question #688993 on Yade changed:
https://answers.launchpad.net/yade/+question/688993

Mahdeyeh posted a new comment:
> I would like to emphasize that I really have no idea how much (if any) 
> performance you can gain.
> On the other hand, to get some basic feeling, it should not be too difficult 
> and time consuming to try e.g. clumped PFacets 

Yes Jan, I understand what you mean. I'll try it.

Thanks for your advice.

Best regards,
Mahdeyeh

-- 
You received this question notification because your team yade-users is
an answer contact for Yade.

___
Mailing list: https://launchpad.net/~yade-users
Post to : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


Re: [Yade-users] [Question #688993]: polyhedrals after collide to facet, throwing away strongly

2020-03-04 Thread Mahdeyeh
Question #688993 on Yade changed:
https://answers.launchpad.net/yade/+question/688993

Mahdeyeh posted a new comment:
>  - try different shapes, like PFacet, PotentialParticle or
PotentialBlock

Thanks a lot Jan , You right.

I want to try clump, hope to be successful.

Again Thanks for all your helps.

-- 
You received this question notification because your team yade-users is
an answer contact for Yade.

___
Mailing list: https://launchpad.net/~yade-users
Post to : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


Re: [Yade-users] [Question #688993]: polyhedrals after collide to facet, throwing away strongly

2020-03-03 Thread Mahdeyeh
Question #688993 on Yade changed:
https://answers.launchpad.net/yade/+question/688993

Status: Answered => Open

Mahdeyeh is still having a problem:
I really appreciate your patience Jan.

> Can you please provide a script (two bodies as is described) reproducing this 
> behavior?
> but it is not really a good script

I corrected the codes in question and two polyhedrons have interact
(With using your suggestion for young modules (Dolomite.young = 5e7
Bound.young = 1e300) and O.dt=10e-6). But when there are more polygons,
problem appears.

> You can decrease stiffness of polyhedrons and increase stiffness of
facets artificially (e.g. 1e300, the harmonic average in contact law
makes it ok)

You know, this works for two polyhedrons! When I checked with more
polyhedrons, the problem was still there.

> what about 1e-10? 1e-12? 1e-15? 1e-20?
In fact, I have no idea because if problem is really solved with these time 
steps, simulation will be impossible for me because my original code have 920 
particles and it takes a long time.

-- 
You received this question notification because your team yade-users is
an answer contact for Yade.

___
Mailing list: https://launchpad.net/~yade-users
Post to : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


Re: [Yade-users] [Question #688993]: polyhedrals after collide to facet, throwing away strongly

2020-03-03 Thread Mahdeyeh
Question #688993 on Yade changed:
https://answers.launchpad.net/yade/+question/688993

Description changed to:
Hi everyone
I run this code for some polyhedrals, they fall down with gravity, but when 
polyhedrals collide to facet in bottom, all of them move up with high speed and 
spread in space. While they should stay on the floor for a little while.  


note: Most of polyhedrals have sharp angle, does this have effect on this 
problem?

I would appreciate if you can help me.

ubuntu : 18.04
yade 2018.02b 

too many input data.
my codes:

from yade import export,polyhedra_utils
import os
from yade import plot
import math
from yade import utils
import pylab
import matplotlib; matplotlib.rc('axes',grid=True)
from matplotlib import pyplot
import numpy as np
from numpy import *
from yade import export as expt


Dolomite = PolyhedraMat()
Dolomite.density = 2870 #kg/m^3 
Dolomite.young = 1e7 #Pa 
Dolomite.poisson = 0.2
Dolomite.frictionAngle = radians(55.12) #rad

Bound = PolyhedraMat()
Bound.density = 2870 #kg/m^3 
Bound.young = 1e300 #Pa 
Bound.poisson = 0.2
Bound.frictionAngle = radians(55.12) #rad

p1=((3.20999113285824,4.56682535905544,0.25),(3.20999113285824,4.92812419373700,0.25),(3.34925246942789,5.13990997478261,0.25),(3.48096338587174,5.13990997478261,0.25),(3.48096338587174,4.97471882295321,0.25),(3.38909183943153,4.70539658408990,0.25),(3.20999113285824,4.56682535905544,0.25),(3.20999113285824,4.56682535905544,-0.25),(3.20999113285824,4.92812419373700,-0.25),(3.34925246942789,5.13990997478261,-0.25),(3.48096338587174,5.13990997478261,-0.25),(3.48096338587174,4.97471882295321,-0.25),(3.38909183943153,4.70539658408990,-0.25),(3.20999113285824,4.56682535905544,-0.25))
p2=((3.60265201447845,7.35103416471193,0.25),(3.61010182622721,7.35103416471193,0.25),(3.71828876180858,7.48918606800436,0.25),(3.74275101349167,7.67253715703928,0.25),(3.74275101349167,7.82185097460873,0.25),(3.67394962688404,7.75228435593977,0.25),(3.60265201447845,7.35103416471193,0.25),(3.60265201447845,7.35103416471193,-0.25),(3.61010182622721,7.35103416471193,-0.25),(3.71828876180858,7.48918606800436,-0.25),(3.74275101349167,7.67253715703928,-0.25),(3.74275101349167,7.82185097460873,-0.25),(3.67394962688404,7.75228435593977,-0.25),(3.60265201447845,7.35103416471193,-0.25))

O.bodies.append(polyhedra_utils.polyhedra(Dolomite,v=p1,fixed=False, 
color=(0.1,0.5,0.2)))
O.bodies.append(polyhedra_utils.polyhedra(Dolomite,v=p2,fixed=False, 
color=(0.1,0.5,0.2)))

v1=((-2.4993,-0.01,2),(-2,-0.01,2),(-2.4993,-0.01,-2))
v2=((-2,-0.01,2),(-2,-0.01,-2),(-2.4993,-0.01,-2))
v3=((-1.99,-0.01,2),(-1.99,-0.01,-2),(-1,-0.01,2))
v4=((-1,-0.01,2),(-1,-0.01,-2),(-1.99,-0.01,-2))
v5=((-0.99,-0.01,2),(-0.99,-0.01,-2),(1,-0.01,2))
v6=((1,-0.01,2),(1,-0.01,-2),(-0.99,-0.01,-2))
v7=((1.01,-0.01,2),(1.01,-0.01,-2),(2,-0.01,2))
v8=((2,-0.01,2),(2,-0.01,-2),(1.01,-0.01,-2))
v9=((2.01,-0.01,2),(2.01,-0.01,-2),(3,-0.01,2))
v10=((3,-0.01,2),(3,-0.01,-2),(2.01,-0.01,-2))
v11=((3.01,-0.01,2),(3.01,-0.01,-2),(4.58,-0.01,2))
v12=((4.58,-0.01,2),(4.58,-0.01,-2),(3.01,-0.01,-2))
v13=((4.6162,0.0059,2),(5.25,0.93,2),(4.6162,0.0059,-2))
v14=((5.25,0.93,2),(5.25,0.93,-2),(4.6162,0.0059,-2))
v15=((5.25,0.94,2),(5.25,0.94,-2),(6.42,2.57,2))
v16=((6.42,2.57,2),(6.42,2.57,-2),(5.25,0.94,-2))
v17=((6.42,2.58,2),(6.42,2.58,-2),(6.7906,3.01,2))
v18=((6.7906,3.01,2),(6.7906,3.01,-2),(6.42,2.58,-2))


O.bodies.append(utils.facet(v1,color=(1,0,1), material=Bound))
O.bodies.append(utils.facet(v2,color=(1,0,1), material=Bound))
O.bodies.append(utils.facet(v3,color=(1,0,1), material=Bound))
O.bodies.append(utils.facet(v4,color=(1,0,1), material=Bound))
O.bodies.append(utils.facet(v5,color=(1,0,1), material=Bound))
O.bodies.append(utils.facet(v6,color=(1,0,1), material=Bound))
O.bodies.append(utils.facet(v7,color=(1,0,1), material=Bound))
O.bodies.append(utils.facet(v8,color=(1,0,1), material=Bound))
O.bodies.append(utils.facet(v9,color=(1,0,1), material=Bound))
O.bodies.append(utils.facet(v10,color=(1,0,1), material=Bound))
O.bodies.append(utils.facet(v11,color=(1,0,1), material=Bound))
O.bodies.append(utils.facet(v12,color=(1,0,1), material=Bound))
O.bodies.append(utils.facet(v13,color=(1,0,1), material=Bound))
O.bodies.append(utils.facet(v14,color=(1,0,1), material=Bound))
O.bodies.append(utils.facet(v15,color=(1,0,1), material=Bound))
O.bodies.append(utils.facet(v16,color=(1,0,1), material=Bound))
O.bodies.append(utils.facet(v17,color=(1,0,1), material=Bound))
O.bodies.append(utils.facet(v18,color=(1,0,1), material=Bound))


for b in O.bodies:
if b.material is Dolomite:
b.state.blockedDOFs='zXY'

O.engines=[
   ForceResetter(),
   
InsertionSortCollider([Bo1_Polyhedra_Aabb(),Bo1_Facet_Aabb()],verletDist=0.05), 
   InteractionLoop(
  
[Ig2_Polyhedra_Polyhedra_PolyhedraGeom(),Ig2_Facet_Polyhedra_PolyhedraGeom()], 
  [Ip2_PolyhedraMat_PolyhedraMat_PolyhedraPhys()], 
  [Law2_PolyhedraGeom_PolyhedraPhys_Volumetric()]   
   ),
   

Re: [Yade-users] [Question #688993]: polyhedrals after collide to facet, throwing away strongly

2020-03-03 Thread Mahdeyeh
Question #688993 on Yade changed:
https://answers.launchpad.net/yade/+question/688993

Status: Needs information => Open

Mahdeyeh gave more information on the question:
Thanks Jan for your time

> what values have you tried?
O.dt=10e-8

> Can you please provide a script (two bodies as is described)
reproducing this behavior?


from yade import export,polyhedra_utils
import os
from yade import plot
import math
from yade import utils
import pylab
import matplotlib; matplotlib.rc('axes',grid=True)
from matplotlib import pyplot
import numpy as np
from numpy import *
from yade import export as expt


Dolomite = PolyhedraMat()
Dolomite.density = 2870 #kg/m^3 
Dolomite.young = 24.36e9 #Pa 
Dolomite.poisson = 0.2
Dolomite.frictionAngle = radians(55.12) #rad

Bound = PolyhedraMat()
Bound.density = 2870 #kg/m^3 
Bound.young = 60e10 #Pa 
Bound.poisson = 0.2
Bound.frictionAngle = radians(55.12) #rad

p1=((4.54097400033104,6.49184245861868,0.25),(4.65891804001884,6.58769165827740,0.25),(4.51425920185592,6.93490024048091,0.25),(4.46361293495481,6.82361276486310,0.25),(4.54097400033104,6.49184245861868,0.25),(4.54097400033104,6.49184245861868,-0.25),(4.65891804001884,6.58769165827740,-0.25),(4.51425920185592,6.93490024048091,-0.25),(4.46361293495481,6.82361276486310,-0.25),(4.54097400033104,6.49184245861868,-0.25))
p2=((3.60265201447845,7.35103416471193,0.25),(3.61010182622721,7.35103416471193,0.25),(3.71828876180858,7.48918606800436,0.25),(3.74275101349167,7.67253715703928,0.25),(3.74275101349167,7.82185097460873,0.25),(3.67394962688404,7.75228435593977,0.25),(3.60265201447845,7.35103416471193,0.25),(3.60265201447845,7.35103416471193,-0.25),(3.61010182622721,7.35103416471193,-0.25),(3.71828876180858,7.48918606800436,-0.25),(3.74275101349167,7.67253715703928,-0.25),(3.74275101349167,7.82185097460873,-0.25),(3.67394962688404,7.75228435593977,-0.25),(3.60265201447845,7.35103416471193,-0.25))

O.bodies.append(polyhedra_utils.polyhedra(Dolomite,v=p1,fixed=False, 
color=(0.1,0.5,0.2)))
O.bodies.append(polyhedra_utils.polyhedra(Dolomite,v=p2,fixed=False, 
color=(0.1,0.5,0.2)))

v1=((-2.4993,-0.01,2),(-2,-0.01,2),(-2.4993,-0.01,-2))
v2=((-2,-0.01,2),(-2,-0.01,-2),(-2.4993,-0.01,-2))
v3=((-1.99,-0.01,2),(-1.99,-0.01,-2),(-1,-0.01,2))
v4=((-1,-0.01,2),(-1,-0.01,-2),(-1.99,-0.01,-2))
v5=((-0.99,-0.01,2),(-0.99,-0.01,-2),(1,-0.01,2))
v6=((1,-0.01,2),(1,-0.01,-2),(-0.99,-0.01,-2))
v7=((1.01,-0.01,2),(1.01,-0.01,-2),(2,-0.01,2))
v8=((2,-0.01,2),(2,-0.01,-2),(1.01,-0.01,-2))
v9=((2.01,-0.01,2),(2.01,-0.01,-2),(3,-0.01,2))
v10=((3,-0.01,2),(3,-0.01,-2),(2.01,-0.01,-2))
v11=((3.01,-0.01,2),(3.01,-0.01,-2),(4.58,-0.01,2))
v12=((4.58,-0.01,2),(4.58,-0.01,-2),(3.01,-0.01,-2))
v13=((4.6162,0.0059,2),(5.25,0.93,2),(4.6162,0.0059,-2))
v14=((5.25,0.93,2),(5.25,0.93,-2),(4.6162,0.0059,-2))
v15=((5.25,0.94,2),(5.25,0.94,-2),(6.42,2.57,2))
v16=((6.42,2.57,2),(6.42,2.57,-2),(5.25,0.94,-2))
v17=((6.42,2.58,2),(6.42,2.58,-2),(6.7906,3.01,2))
v18=((6.7906,3.01,2),(6.7906,3.01,-2),(6.42,2.58,-2))
v19=((6.7906,3.0162,2),(6.7939,4,2),(6.7906,3.0162,-2))
v20=((6.7906,3.0162,-2),(6.7939,4,-2),(6.7939,4,2))
v21=((6.7953,4.0079,2),(7.02,5.6,2),(6.7953,4.0079,-2))
v22=((7.02,5.6,2),(7.02,5.6,-2),(6.7953,4.0079,-2))
v23=((7.02,5.61,2),(7.02,5.61,-2),(7.3,7.01,2))
v24=((7.3,7.01,2),(7.3,7.01,-2),(7.02,5.61,-2))
v25=((7.3,7.02,2),(7.3,7.02,-2),(7.54,8.51,2))
v26=((7.54,8.51,2),(7.54,8.51,-2),(7.3,7.02,-2))
v27=((7.54,8.52,2),(7.54,8.52,-2),(7.8,10,2))
v28=((7.8,10,2),(7.8,10,-2),(7.54,8.52,-2))
v29=((7.8,10.01,2),(7.8,10.01,-2),(8.14,12,2))
v30=((8.14,12,2),(8.14,12,-2),(7.8,10.01,-2))
v31=((8.14,12.01,2),(8.14,12.01,-2),(8.5,14,2))
v32=((8.5,14,2),(8.5,14,-2),(8.14,12,-2))
v33=((8.5,14.01,2),(8.5,14.01,-2),(8.75,15.5,2))
v34=((8.75,15.5,2),(8.75,15.5,-2),(8.5,14.01,-2))
v35=((8.75,15.51,2),(8.75,15.51,-2),(9.0615,16.9981,2))
v36=((9.0615,16.9981,2),(9.0615,16.9981,-2),(8.75,15.51,-2))
v37=((9.0621,17.0187,2),(9.09,19,2),(9.0621,17.087,-2))
v38=((9.09,19,2),(9.09,19,-2),(9.062,17.0187,-2))
v39=((9.09,19.01,2),(9.09,19.01,-2),(9.2006,20.9992,2))
v40=((9.2006,20.9992,2),(9.2006,20.9992,-2),(9.09,19.01,-2))
v41=((2.2009,21.0924,2),(2.2009,21.0924,-2),(2.22,19.01,2))
v42=((2.22,19.01,2),(2.22,19.01,-2),(2.2009,21.0924,-2))
v43=((2.22,19,2),(2.22,19,-2),(2.1538,17.043,2))
v44=((2.1538,17.043,2),(2.1538,17.043,-2),(2.22,19,-2))
v45=((2.0524,17.0104,2),(2.0524,17.0104,-2),(1.76,15.01,2))
v46=((1.76,15.01,2),(1.76,15.01,-2),(2.0524,17.0104,-2))
v47=((1.76,15,2),(1.76,15,-2),(1.42,13.01,2))
v48=((1.42,13.01,2),(1.42,13.01,-2),(1.76,15,-2))
v49=((1.42,13,2),(1.42,13,-2),(1.16,11.49,2))
v50=((1.16,11.49,2),(1.16,11.49,-2),(1.42,13,-2))
v51=((1.16,11.48,2),(1.16,11.48,-2),(0.8699,10.0876,2))
v52=((0.8699,10.0876,2),(0.8699,10.0876,-2),(1.16,11.48,-2))
v53=((1.1059,9.9916,2),(1.1059,9.9916,-2),(2.5,9.9927,2))
v54=((2.5,9.9927,2),(2.5,9.9927,-2),(1.1059,9.9916,-2))
v55=((2.51,9.9927,2),(2.51,9.9927,-2),(4.0026,9.9927,2))
v56=((2.51,9.9927,-2),(4.0026,

Re: [Yade-users] [Question #688993]: polyhedrals after collide to facet, throwing away strongly

2020-03-02 Thread Mahdeyeh
Question #688993 on Yade changed:
https://answers.launchpad.net/yade/+question/688993

Description changed to:
Hi everyone
I run this code for some polyhedrals, they fall down with gravity, but when 
polyhedrals collide to facet in bottom, all of them move up with high speed and 
spread in space. While they should stay on the floor for a little while.  


note: Most of polyhedrals have sharp angle, does this have effect on this 
problem?

I would appreciate if you can help me.

ubuntu : 18.04
yade 2018.02b 

too many input data.
my codes:

from yade import export,polyhedra_utils
import os
from yade import plot
import math
from yade import utils
import pylab
import matplotlib; matplotlib.rc('axes',grid=True)
from matplotlib import pyplot
import numpy as np
from numpy import *
from yade import export as expt


# Input data:

RawVer=np.genfromtxt('ring.txt',names=True,dtype=None)
# ListVer is list of all the vertices of ring`s polygons
Ver=()
ListVer=[]
for b in RawVer:
if b[0]=='*LWPOLYLINE':
ListVer.append(Ver)
Ver=()
continue
Cordn=b[0]
Cordn=np.fromstring(Cordn, sep=',')
Cordn=tuple(Cordn.tolist())
Cordn1=Cordn+(0,)   # add z vertex to coordinates 
Cordn2=Cordn+(0.5,)   # add z vertex to coordinates
if not Cordn1 in Ver:
Ver=Ver+(Cordn1,Cordn2)
ListVer.append(Ver)


# Materials type:

Dolomite = PolyhedraMat()
Dolomite.density = 2870 #kg/m^3 
Dolomite.young = 24.36e9 #Pa 
Dolomite.poisson = 0.2
Dolomite.frictionAngle = radians(55.12) #rad

Bound = PolyhedraMat()
Bound.density = 2870 #kg/m^3 
Bound.young = 60e10 #Pa 
Bound.poisson = 0.2
Bound.frictionAngle = radians(55.12) #rad

for ii in ListVer:
O.bodies.append(polyhedra_utils.polyhedra(Dolomite,v=ii,fixed=False, 
color=(0.1,0.5,0.2)))

v1=((-2.4993,-0.01,2),(-2,-0.01,2),(-2.4993,-0.01,-2))
v2=((-2,-0.01,2),(-2,-0.01,-2),(-2.4993,-0.01,-2))
v3=((-1.99,-0.01,2),(-1.99,-0.01,-2),(-1,-0.01,2))
v4=((-1,-0.01,2),(-1,-0.01,-2),(-1.99,-0.01,-2))
v5=((-0.99,-0.01,2),(-0.99,-0.01,-2),(1,-0.01,2))
v6=((1,-0.01,2),(1,-0.01,-2),(-0.99,-0.01,-2))
v7=((1.01,-0.01,2),(1.01,-0.01,-2),(2,-0.01,2))
v8=((2,-0.01,2),(2,-0.01,-2),(1.01,-0.01,-2))
v9=((2.01,-0.01,2),(2.01,-0.01,-2),(3,-0.01,2))
v10=((3,-0.01,2),(3,-0.01,-2),(2.01,-0.01,-2))
v11=((3.01,-0.01,2),(3.01,-0.01,-2),(4.58,-0.01,2))
v12=((4.58,-0.01,2),(4.58,-0.01,-2),(3.01,-0.01,-2))
v13=((4.6162,0.0059,2),(5.25,0.93,2),(4.6162,0.0059,-2))
v14=((5.25,0.93,2),(5.25,0.93,-2),(4.6162,0.0059,-2))
v15=((5.25,0.94,2),(5.25,0.94,-2),(6.42,2.57,2))
v16=((6.42,2.57,2),(6.42,2.57,-2),(5.25,0.94,-2))
v17=((6.42,2.58,2),(6.42,2.58,-2),(6.7906,3.01,2))
v18=((6.7906,3.01,2),(6.7906,3.01,-2),(6.42,2.58,-2))
v19=((6.7906,3.0162,2),(6.7939,4,2),(6.7906,3.0162,-2))
v20=((6.7906,3.0162,-2),(6.7939,4,-2),(6.7939,4,2))
v21=((6.7953,4.0079,2),(7.02,5.6,2),(6.7953,4.0079,-2))
v22=((7.02,5.6,2),(7.02,5.6,-2),(6.7953,4.0079,-2))
v23=((7.02,5.61,2),(7.02,5.61,-2),(7.3,7.01,2))
v24=((7.3,7.01,2),(7.3,7.01,-2),(7.02,5.61,-2))
v25=((7.3,7.02,2),(7.3,7.02,-2),(7.54,8.51,2))
v26=((7.54,8.51,2),(7.54,8.51,-2),(7.3,7.02,-2))
v27=((7.54,8.52,2),(7.54,8.52,-2),(7.8,10,2))
v28=((7.8,10,2),(7.8,10,-2),(7.54,8.52,-2))
v29=((7.8,10.01,2),(7.8,10.01,-2),(8.14,12,2))
v30=((8.14,12,2),(8.14,12,-2),(7.8,10.01,-2))
v31=((8.14,12.01,2),(8.14,12.01,-2),(8.5,14,2))
v32=((8.5,14,2),(8.5,14,-2),(8.14,12,-2))
v33=((8.5,14.01,2),(8.5,14.01,-2),(8.75,15.5,2))
v34=((8.75,15.5,2),(8.75,15.5,-2),(8.5,14.01,-2))
v35=((8.75,15.51,2),(8.75,15.51,-2),(9.0615,16.9981,2))
v36=((9.0615,16.9981,2),(9.0615,16.9981,-2),(8.75,15.51,-2))
v37=((9.0621,17.0187,2),(9.09,19,2),(9.0621,17.087,-2))
v38=((9.09,19,2),(9.09,19,-2),(9.062,17.0187,-2))
v39=((9.09,19.01,2),(9.09,19.01,-2),(9.2006,20.9992,2))
v40=((9.2006,20.9992,2),(9.2006,20.9992,-2),(9.09,19.01,-2))
v41=((2.2009,21.0924,2),(2.2009,21.0924,-2),(2.22,19.01,2))
v42=((2.22,19.01,2),(2.22,19.01,-2),(2.2009,21.0924,-2))
v43=((2.22,19,2),(2.22,19,-2),(2.1538,17.043,2))
v44=((2.1538,17.043,2),(2.1538,17.043,-2),(2.22,19,-2))
v45=((2.0524,17.0104,2),(2.0524,17.0104,-2),(1.76,15.01,2))
v46=((1.76,15.01,2),(1.76,15.01,-2),(2.0524,17.0104,-2))
v47=((1.76,15,2),(1.76,15,-2),(1.42,13.01,2))
v48=((1.42,13.01,2),(1.42,13.01,-2),(1.76,15,-2))


O.bodies.append(utils.facet(v1,color=(1,0,1), material=Bound))
O.bodies.append(utils.facet(v2,color=(1,0,1), material=Bound))
O.bodies.append(utils.facet(v3,color=(1,0,1), material=Bound))
O.bodies.append(utils.facet(v4,color=(1,0,1), material=Bound))
O.bodies.append(utils.facet(v5,color=(1,0,1), material=Bound))
O.bodies.append(utils.facet(v6,color=(1,0,1), material=Bound))
O.bodies.append(utils.facet(v7,color=(1,0,1), material=Bound))
O.bodies.append(utils.facet(v8,color=(1,0,1), material=Bound))
O.bodies.append(utils.facet(v9,color=(1,0,1), material=Bound))
O.bodies.append(utils.facet(v10,color=(1,0,1), material=Bound))
O.bodies.append(utils.facet(v11,color=(1,0,1), material=Bound))
O.bodies.append(utils.facet(v12,color=(1,0,1), 

Re: [Yade-users] [Question #688993]: polyhedrals after collide to facet, throwing away strongly

2020-03-02 Thread Mahdeyeh
Question #688993 on Yade changed:
https://answers.launchpad.net/yade/+question/688993

Description changed to:
Hi everyone
I run this code for some polyhedrals, they fall down with gravity, but when 
polyhedrals collide to facet in bottom, all of them move up with high speed and 
spread in space. While they should stay on the floor for a little while.  


note: Most of polyhedrals have sharp angle, does this have effect on this 
problem?

I would appreciate if you can help me.

ubuntu : 18.04
yade 2018.02b 

too many input data.
my codes:

from yade import export,polyhedra_utils
import os
from yade import plot
import math
from yade import utils
import pylab
import matplotlib; matplotlib.rc('axes',grid=True)
from matplotlib import pyplot
import numpy as np
from numpy import *
from yade import export as expt


# Input data:

RawVer=np.genfromtxt('ring.txt',names=True,dtype=None)
# ListVer is list of all the vertices of ring`s polygons
Ver=()
ListVer=[]
for b in RawVer:
if b[0]=='*LWPOLYLINE':
ListVer.append(Ver)
Ver=()
continue
Cordn=b[0]
Cordn=np.fromstring(Cordn, sep=',')
Cordn=tuple(Cordn.tolist())
Cordn1=Cordn+(0,)   # add z vertex to coordinates 
Cordn2=Cordn+(0.5,)   # add z vertex to coordinates
if not Cordn1 in Ver:
Ver=Ver+(Cordn1,Cordn2)
ListVer.append(Ver)


# Materials type:

Dolomite = PolyhedraMat()
Dolomite.density = 2870 #kg/m^3 
Dolomite.young = 24.36e9 #Pa 
Dolomite.poisson = 0.2
Dolomite.frictionAngle = radians(55.12) #rad

Bound = PolyhedraMat()
Bound.density = 2870 #kg/m^3 
Bound.young = 60e10 #Pa 
Bound.poisson = 0.2
Bound.frictionAngle = radians(55.12) #rad

for ii in ListVer:
O.bodies.append(polyhedra_utils.polyhedra(Dolomite,v=ii,fixed=False, 
color=(0.1,0.5,0.2)))

v1=((-2.4993,-0.01,2),(-2,-0.01,2),(-2.4993,-0.01,-2))
v2=((-2,-0.01,2),(-2,-0.01,-2),(-2.4993,-0.01,-2))
v3=((-1.99,-0.01,2),(-1.99,-0.01,-2),(-1,-0.01,2))
v4=((-1,-0.01,2),(-1,-0.01,-2),(-1.99,-0.01,-2))
v5=((-0.99,-0.01,2),(-0.99,-0.01,-2),(1,-0.01,2))
v6=((1,-0.01,2),(1,-0.01,-2),(-0.99,-0.01,-2))
v7=((1.01,-0.01,2),(1.01,-0.01,-2),(2,-0.01,2))
v8=((2,-0.01,2),(2,-0.01,-2),(1.01,-0.01,-2))
v9=((2.01,-0.01,2),(2.01,-0.01,-2),(3,-0.01,2))
v10=((3,-0.01,2),(3,-0.01,-2),(2.01,-0.01,-2))
v11=((3.01,-0.01,2),(3.01,-0.01,-2),(4.58,-0.01,2))
v12=((4.58,-0.01,2),(4.58,-0.01,-2),(3.01,-0.01,-2))
v13=((4.6162,0.0059,2),(5.25,0.93,2),(4.6162,0.0059,-2))
v14=((5.25,0.93,2),(5.25,0.93,-2),(4.6162,0.0059,-2))
v15=((5.25,0.94,2),(5.25,0.94,-2),(6.42,2.57,2))
v16=((6.42,2.57,2),(6.42,2.57,-2),(5.25,0.94,-2))
v17=((6.42,2.58,2),(6.42,2.58,-2),(6.7906,3.01,2))
v18=((6.7906,3.01,2),(6.7906,3.01,-2),(6.42,2.58,-2))
v19=((6.7906,3.0162,2),(6.7939,4,2),(6.7906,3.0162,-2))
v20=((6.7906,3.0162,-2),(6.7939,4,-2),(6.7939,4,2))
v21=((6.7953,4.0079,2),(7.02,5.6,2),(6.7953,4.0079,-2))
v22=((7.02,5.6,2),(7.02,5.6,-2),(6.7953,4.0079,-2))
v23=((7.02,5.61,2),(7.02,5.61,-2),(7.3,7.01,2))
v24=((7.3,7.01,2),(7.3,7.01,-2),(7.02,5.61,-2))
v25=((7.3,7.02,2),(7.3,7.02,-2),(7.54,8.51,2))
v26=((7.54,8.51,2),(7.54,8.51,-2),(7.3,7.02,-2))
v27=((7.54,8.52,2),(7.54,8.52,-2),(7.8,10,2))
v28=((7.8,10,2),(7.8,10,-2),(7.54,8.52,-2))
v29=((7.8,10.01,2),(7.8,10.01,-2),(8.14,12,2))
v30=((8.14,12,2),(8.14,12,-2),(7.8,10.01,-2))
v31=((8.14,12.01,2),(8.14,12.01,-2),(8.5,14,2))
v32=((8.5,14,2),(8.5,14,-2),(8.14,12,-2))
v33=((8.5,14.01,2),(8.5,14.01,-2),(8.75,15.5,2))
v34=((8.75,15.5,2),(8.75,15.5,-2),(8.5,14.01,-2))
v35=((8.75,15.51,2),(8.75,15.51,-2),(9.0615,16.9981,2))
v36=((9.0615,16.9981,2),(9.0615,16.9981,-2),(8.75,15.51,-2))
v37=((9.0621,17.0187,2),(9.09,19,2),(9.0621,17.087,-2))
v38=((9.09,19,2),(9.09,19,-2),(9.062,17.0187,-2))
v39=((9.09,19.01,2),(9.09,19.01,-2),(9.2006,20.9992,2))
v40=((9.2006,20.9992,2),(9.2006,20.9992,-2),(9.09,19.01,-2))
v41=((2.2009,21.0924,2),(2.2009,21.0924,-2),(2.22,19.01,2))
v42=((2.22,19.01,2),(2.22,19.01,-2),(2.2009,21.0924,-2))
v43=((2.22,19,2),(2.22,19,-2),(2.1538,17.043,2))
v44=((2.1538,17.043,2),(2.1538,17.043,-2),(2.22,19,-2))
v45=((2.0524,17.0104,2),(2.0524,17.0104,-2),(1.76,15.01,2))
v46=((1.76,15.01,2),(1.76,15.01,-2),(2.0524,17.0104,-2))
v47=((1.76,15,2),(1.76,15,-2),(1.42,13.01,2))
v48=((1.42,13.01,2),(1.42,13.01,-2),(1.76,15,-2))


O.bodies.append(utils.facet(v1,color=(1,0,1), material=Bound))
O.bodies.append(utils.facet(v2,color=(1,0,1), material=Bound))
O.bodies.append(utils.facet(v3,color=(1,0,1), material=Bound))
O.bodies.append(utils.facet(v4,color=(1,0,1), material=Bound))
O.bodies.append(utils.facet(v5,color=(1,0,1), material=Bound))
O.bodies.append(utils.facet(v6,color=(1,0,1), material=Bound))
O.bodies.append(utils.facet(v7,color=(1,0,1), material=Bound))
O.bodies.append(utils.facet(v8,color=(1,0,1), material=Bound))
O.bodies.append(utils.facet(v9,color=(1,0,1), material=Bound))
O.bodies.append(utils.facet(v10,color=(1,0,1), material=Bound))
O.bodies.append(utils.facet(v11,color=(1,0,1), material=Bound))
O.bodies.append(utils.facet(v12,color=(1,0,1), 

Re: [Yade-users] [Question #688993]: polyhedrals after collide to facet, throwing away strongly

2020-03-02 Thread Mahdeyeh
Question #688993 on Yade changed:
https://answers.launchpad.net/yade/+question/688993

Description changed to:
Hi everyone
I run this code for some polyhedrals, they fall down with gravity, but when 
polyhedrals collide to facet in bottom, all of them move up with high speed and 
spread in space. While they should stay on the floor for a little while.  


note: Most of polyhedrals have sharp angle, does this have effect on this 
problem?

I would appreciate if you can help me.

ubuntu : 18.04
yade 2018.02b 

too many input data.
my codes:

from yade import export,polyhedra_utils
import os
from yade import plot
import math
from yade import utils
import pylab
import matplotlib; matplotlib.rc('axes',grid=True)
from matplotlib import pyplot
import numpy as np
from numpy import *
from yade import export as expt


# Input data:

RawVer=np.genfromtxt('ring.txt',names=True,dtype=None)
# ListVer is list of all the vertices of ring`s polygons
Ver=()
ListVer=[]
for b in RawVer:
if b[0]=='*LWPOLYLINE':
ListVer.append(Ver)
Ver=()
continue
Cordn=b[0]
Cordn=np.fromstring(Cordn, sep=',')
Cordn=tuple(Cordn.tolist())
Cordn1=Cordn+(0,)   # add z vertex to coordinates 
Cordn2=Cordn+(0.5,)   # add z vertex to coordinates
if not Cordn1 in Ver:
Ver=Ver+(Cordn1,Cordn2)
ListVer.append(Ver)


# Materials type:

Dolomite = PolyhedraMat()
Dolomite.density = 2870 #kg/m^3 
Dolomite.young = 24.36e9 #Pa 
Dolomite.poisson = 0.2
Dolomite.frictionAngle = radians(55.12) #rad

Bound = PolyhedraMat()
Bound.density = 2870 #kg/m^3 
Bound.young = 60e10 #Pa 
Bound.poisson = 0.2
Bound.frictionAngle = radians(55.12) #rad

Shale = PolyhedraMat()
Shale.density = 2750 #kg/m^3 
Shale.young = 6e9 #Pa 
Shale.poisson = 0.23
Shale.frictionAngle = radians(42) #rad

for ii in ListVer:
O.bodies.append(polyhedra_utils.polyhedra(Dolomite,v=ii,fixed=False, 
color=(0.1,0.5,0.2)))

for  in ListVer2:
O.bodies.append(polyhedra_utils.polyhedra(Shale,v=,fixed=False, 
color=(0.9,0.81,0.45)))

v1=((-2.4993,-0.01,2),(-2,-0.01,2),(-2.4993,-0.01,-2))
v2=((-2,-0.01,2),(-2,-0.01,-2),(-2.4993,-0.01,-2))
v3=((-1.99,-0.01,2),(-1.99,-0.01,-2),(-1,-0.01,2))
v4=((-1,-0.01,2),(-1,-0.01,-2),(-1.99,-0.01,-2))
v5=((-0.99,-0.01,2),(-0.99,-0.01,-2),(1,-0.01,2))
v6=((1,-0.01,2),(1,-0.01,-2),(-0.99,-0.01,-2))
v7=((1.01,-0.01,2),(1.01,-0.01,-2),(2,-0.01,2))
v8=((2,-0.01,2),(2,-0.01,-2),(1.01,-0.01,-2))
v9=((2.01,-0.01,2),(2.01,-0.01,-2),(3,-0.01,2))
v10=((3,-0.01,2),(3,-0.01,-2),(2.01,-0.01,-2))
v11=((3.01,-0.01,2),(3.01,-0.01,-2),(4.58,-0.01,2))
v12=((4.58,-0.01,2),(4.58,-0.01,-2),(3.01,-0.01,-2))
v13=((4.6162,0.0059,2),(5.25,0.93,2),(4.6162,0.0059,-2))
v14=((5.25,0.93,2),(5.25,0.93,-2),(4.6162,0.0059,-2))
v15=((5.25,0.94,2),(5.25,0.94,-2),(6.42,2.57,2))
v16=((6.42,2.57,2),(6.42,2.57,-2),(5.25,0.94,-2))
v17=((6.42,2.58,2),(6.42,2.58,-2),(6.7906,3.01,2))
v18=((6.7906,3.01,2),(6.7906,3.01,-2),(6.42,2.58,-2))
v19=((6.7906,3.0162,2),(6.7939,4,2),(6.7906,3.0162,-2))
v20=((6.7906,3.0162,-2),(6.7939,4,-2),(6.7939,4,2))
v21=((6.7953,4.0079,2),(7.02,5.6,2),(6.7953,4.0079,-2))
v22=((7.02,5.6,2),(7.02,5.6,-2),(6.7953,4.0079,-2))
v23=((7.02,5.61,2),(7.02,5.61,-2),(7.3,7.01,2))
v24=((7.3,7.01,2),(7.3,7.01,-2),(7.02,5.61,-2))
v25=((7.3,7.02,2),(7.3,7.02,-2),(7.54,8.51,2))
v26=((7.54,8.51,2),(7.54,8.51,-2),(7.3,7.02,-2))
v27=((7.54,8.52,2),(7.54,8.52,-2),(7.8,10,2))
v28=((7.8,10,2),(7.8,10,-2),(7.54,8.52,-2))
v29=((7.8,10.01,2),(7.8,10.01,-2),(8.14,12,2))
v30=((8.14,12,2),(8.14,12,-2),(7.8,10.01,-2))
v31=((8.14,12.01,2),(8.14,12.01,-2),(8.5,14,2))
v32=((8.5,14,2),(8.5,14,-2),(8.14,12,-2))
v33=((8.5,14.01,2),(8.5,14.01,-2),(8.75,15.5,2))
v34=((8.75,15.5,2),(8.75,15.5,-2),(8.5,14.01,-2))
v35=((8.75,15.51,2),(8.75,15.51,-2),(9.0615,16.9981,2))
v36=((9.0615,16.9981,2),(9.0615,16.9981,-2),(8.75,15.51,-2))
v37=((9.0621,17.0187,2),(9.09,19,2),(9.0621,17.087,-2))
v38=((9.09,19,2),(9.09,19,-2),(9.062,17.0187,-2))
v39=((9.09,19.01,2),(9.09,19.01,-2),(9.2006,20.9992,2))
v40=((9.2006,20.9992,2),(9.2006,20.9992,-2),(9.09,19.01,-2))
v41=((2.2009,21.0924,2),(2.2009,21.0924,-2),(2.22,19.01,2))
v42=((2.22,19.01,2),(2.22,19.01,-2),(2.2009,21.0924,-2))
v43=((2.22,19,2),(2.22,19,-2),(2.1538,17.043,2))
v44=((2.1538,17.043,2),(2.1538,17.043,-2),(2.22,19,-2))
v45=((2.0524,17.0104,2),(2.0524,17.0104,-2),(1.76,15.01,2))
v46=((1.76,15.01,2),(1.76,15.01,-2),(2.0524,17.0104,-2))
v47=((1.76,15,2),(1.76,15,-2),(1.42,13.01,2))
v48=((1.42,13.01,2),(1.42,13.01,-2),(1.76,15,-2))


O.bodies.append(utils.facet(v1,color=(1,0,1), material=Bound))
O.bodies.append(utils.facet(v2,color=(1,0,1), material=Bound))
O.bodies.append(utils.facet(v3,color=(1,0,1), material=Bound))
O.bodies.append(utils.facet(v4,color=(1,0,1), material=Bound))
O.bodies.append(utils.facet(v5,color=(1,0,1), material=Bound))
O.bodies.append(utils.facet(v6,color=(1,0,1), material=Bound))
O.bodies.append(utils.facet(v7,color=(1,0,1), material=Bound))
O.bodies.append(utils.facet(v8,color=(1,0,1), 

Re: [Yade-users] [Question #688993]: polyhedrals after collide to facet, throwing away strongly

2020-03-02 Thread Mahdeyeh
Question #688993 on Yade changed:
https://answers.launchpad.net/yade/+question/688993

Status: Needs information => Open

Mahdeyeh gave more information on the question:
In advance thank you for your time

> can you please provide a Minimal Working Example (e.g. two polhedrons)
reproducing this?

Here is small data and input for my code, please copy in file:


*LWPOLYLINE
4.54097400033104,6.49184245861868
4.65891804001884,6.58769165827740
4.51425920185592,6.93490024048091
4.46361293495481,6.82361276486310
4.54097400033104,6.49184245861868
*LWPOLYLINE
3.38239216165079,4.01327469219457
3.43869334720801,4.27025377921128
3.31240868369778,4.27786275211975
3.18944272805255,4.21917403263651
3.17292105915418,4.00731315957292
3.38239216165079,4.01327469219457
*LWPOLYLINE
3.07472367219926,4.22146522059046
3.00951705252640,4.007100
3.15872105915418,4.007100
3.16994885128804,4.22031962661348
3.07472367219926,4.22146522059046
*LWPOLYLINE
3.19496730804472,4.54686225863838
3.10768290255748,4.56486506811422
3.08101342018444,4.41477399856679
3.07472367219926,4.23195436841659
3.1716059188,4.25583338934358
3.19496730804472,4.54686225863838
*LWPOLYLINE
3.71267645811818,4.17335865185637
3.80626391854923,4.37990041469040
3.85709007230427,4.37990041469040
3.81834238444732,4.15093746143616
3.71267645811818,4.17335865185637
*LWPOLYLINE
3.86833315936705,7.18115411676252
3.75805619368548,6.85052980253022
3.96022603149273,6.83823476145616
3.98624257576362,7.12695113182557
3.86833315936705,7.18115411676252
*LWPOLYLINE
3.75705101349167,7.68673972685043
3.75705101349167,8.04757108283743
3.89622020287160,8.25921672832907
4.02762326650518,8.25921672832907
4.02762326650518,8.09425875012654
3.93578182400268,7.82502476121894
3.75705101349167,7.68673972685043
*LWPOLYLINE
4.29367658088641,7.54996433412856
4.25127773179602,7.75135995952029
4.17124793309971,7.75135995952029
4.11338686757211,7.59716107043463
4.21414905751508,7.54996433412856
4.29367658088641,7.54996433412856
*LWPOLYLINE
3.60265201447845,7.35103416471193
3.61010182622721,7.35103416471193
3.71828876180858,7.48918606800436
3.74275101349167,7.67253715703928
3.74275101349167,7.82185097460873
3.67394962688404,7.75228435593977
3.60265201447845,7.35103416471193
*LWPOLYLINE
3.75665696623051,7.66810154888463
3.94362927435906,7.81276307636047
4.02303237072992,7.79446112714408
3.89479310068892,7.42404447036142
3.73297934687869,7.49095982637576
3.75665696623051,7.66810154888463

-- 
You received this question notification because your team yade-users is
an answer contact for Yade.

___
Mailing list: https://launchpad.net/~yade-users
Post to : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


Re: [Yade-users] [Question #688993]: polyhedrals after collide to facet, throwing away strongly

2020-03-02 Thread Mahdeyeh
Question #688993 on Yade changed:
https://answers.launchpad.net/yade/+question/688993

Status: Needs information => Open

Mahdeyeh gave more information on the question:
> please be consistent. So does it help or not?

("decreasing young module until 10e3 can help the situation"): this was a 
mistake and decreasing stiffness or time step did help at all. 
If stiffness reaches less than 10e5, then particles are passed through facet.
 
> Why? the value of time step should not depend on number of particles..
Appropriate time step for simulation with all particles is 10e-8 to avoid 
exploding particles, in this test (for saving time) 10e-5 was selected for time 
step because particles number  are small and they do not explode, whereas I 
checked, changing time step does not change situation (does not solve this 
problem).

-- 
You received this question notification because your team yade-users is
an answer contact for Yade.

___
Mailing list: https://launchpad.net/~yade-users
Post to : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


Re: [Yade-users] [Question #688993]: polyhedrals after collide to facet, throwing away strongly

2020-03-02 Thread Mahdeyeh
Question #688993 on Yade changed:
https://answers.launchpad.net/yade/+question/688993

Description changed to:
Hi everyone
I run this code for some polyhedrals, they fall down with gravity, but when 
polyhedrals collide to facet in bottom, all of them move up with high speed and 
spread in space. While they should stay on the floor for a little while.  


note: Most of polyhedrals have sharp angle, does this have effect on this 
problem?

I would appreciate if you can help me.

ubuntu : 18.04
yade 2018.02b 

too many input data.
my codes:

from yade import export,polyhedra_utils
import os
from yade import plot
import math
from yade import utils
import pylab
import matplotlib; matplotlib.rc('axes',grid=True)
from matplotlib import pyplot
import numpy as np
from numpy import *
from yade import export as expt


# Input data:

RawVer=np.genfromtxt('ring.txt',names=True,dtype=None)
# ListVer is list of all the vertices of ring`s polygons
Ver=()
ListVer=[]
for b in RawVer:
if b[0]=='*LWPOLYLINE':
ListVer.append(Ver)
Ver=()
continue
Cordn=b[0]
Cordn=np.fromstring(Cordn, sep=',')
Cordn=tuple(Cordn.tolist())
Cordn1=Cordn+(0,)   # add z vertex to coordinates 
Cordn2=Cordn+(0.5,)   # add z vertex to coordinates
if not Cordn1 in Ver:
Ver=Ver+(Cordn1,Cordn2)
ListVer.append(Ver)


# Materials type:

Dolomite = PolyhedraMat()
Dolomite.density = 2870 #kg/m^3 
Dolomite.young = 24.36e9 #Pa 
Dolomite.poisson = 0.2
Dolomite.frictionAngle = radians(55.12) #rad

Bound = PolyhedraMat()
Bound.density = 2870 #kg/m^3 
Bound.young = 60e10 #Pa 
Bound.poisson = 0.2
Bound.frictionAngle = radians(55.12) #rad

Shale = PolyhedraMat()
Shale.density = 2750 #kg/m^3 
Shale.young = 6e9 #Pa 
Shale.poisson = 0.23
Shale.frictionAngle = radians(42) #rad

for ii in ListVer:
O.bodies.append(polyhedra_utils.polyhedra(Dolomite,v=ii,fixed=False, 
color=(0.1,0.5,0.2)))

for  in ListVer2:
O.bodies.append(polyhedra_utils.polyhedra(Shale,v=,fixed=False, 
color=(0.9,0.81,0.45)))

v1=((-2.4993,-0.01,2),(-2,-0.01,2),(-2.4993,-0.01,-2))
v2=((-2,-0.01,2),(-2,-0.01,-2),(-2.4993,-0.01,-2))
v3=((-1.99,-0.01,2),(-1.99,-0.01,-2),(-1,-0.01,2))
v4=((-1,-0.01,2),(-1,-0.01,-2),(-1.99,-0.01,-2))
v5=((-0.99,-0.01,2),(-0.99,-0.01,-2),(1,-0.01,2))
v6=((1,-0.01,2),(1,-0.01,-2),(-0.99,-0.01,-2))
v7=((1.01,-0.01,2),(1.01,-0.01,-2),(2,-0.01,2))
v8=((2,-0.01,2),(2,-0.01,-2),(1.01,-0.01,-2))
v9=((2.01,-0.01,2),(2.01,-0.01,-2),(3,-0.01,2))
v10=((3,-0.01,2),(3,-0.01,-2),(2.01,-0.01,-2))
v11=((3.01,-0.01,2),(3.01,-0.01,-2),(4.58,-0.01,2))
v12=((4.58,-0.01,2),(4.58,-0.01,-2),(3.01,-0.01,-2))
v13=((4.6162,0.0059,2),(5.25,0.93,2),(4.6162,0.0059,-2))
v14=((5.25,0.93,2),(5.25,0.93,-2),(4.6162,0.0059,-2))
v15=((5.25,0.94,2),(5.25,0.94,-2),(6.42,2.57,2))
v16=((6.42,2.57,2),(6.42,2.57,-2),(5.25,0.94,-2))
v17=((6.42,2.58,2),(6.42,2.58,-2),(6.7906,3.01,2))
v18=((6.7906,3.01,2),(6.7906,3.01,-2),(6.42,2.58,-2))
v19=((6.7906,3.0162,2),(6.7939,4,2),(6.7906,3.0162,-2))
v20=((6.7906,3.0162,-2),(6.7939,4,-2),(6.7939,4,2))
v21=((6.7953,4.0079,2),(7.02,5.6,2),(6.7953,4.0079,-2))
v22=((7.02,5.6,2),(7.02,5.6,-2),(6.7953,4.0079,-2))
v23=((7.02,5.61,2),(7.02,5.61,-2),(7.3,7.01,2))
v24=((7.3,7.01,2),(7.3,7.01,-2),(7.02,5.61,-2))
v25=((7.3,7.02,2),(7.3,7.02,-2),(7.54,8.51,2))
v26=((7.54,8.51,2),(7.54,8.51,-2),(7.3,7.02,-2))
v27=((7.54,8.52,2),(7.54,8.52,-2),(7.8,10,2))
v28=((7.8,10,2),(7.8,10,-2),(7.54,8.52,-2))
v29=((7.8,10.01,2),(7.8,10.01,-2),(8.14,12,2))
v30=((8.14,12,2),(8.14,12,-2),(7.8,10.01,-2))
v31=((8.14,12.01,2),(8.14,12.01,-2),(8.5,14,2))
v32=((8.5,14,2),(8.5,14,-2),(8.14,12,-2))
v33=((8.5,14.01,2),(8.5,14.01,-2),(8.75,15.5,2))
v34=((8.75,15.5,2),(8.75,15.5,-2),(8.5,14.01,-2))
v35=((8.75,15.51,2),(8.75,15.51,-2),(9.0615,16.9981,2))
v36=((9.0615,16.9981,2),(9.0615,16.9981,-2),(8.75,15.51,-2))
v37=((9.0621,17.0187,2),(9.09,19,2),(9.0621,17.087,-2))
v38=((9.09,19,2),(9.09,19,-2),(9.062,17.0187,-2))
v39=((9.09,19.01,2),(9.09,19.01,-2),(9.2006,20.9992,2))
v40=((9.2006,20.9992,2),(9.2006,20.9992,-2),(9.09,19.01,-2))
v41=((2.2009,21.0924,2),(2.2009,21.0924,-2),(2.22,19.01,2))
v42=((2.22,19.01,2),(2.22,19.01,-2),(2.2009,21.0924,-2))
v43=((2.22,19,2),(2.22,19,-2),(2.1538,17.043,2))
v44=((2.1538,17.043,2),(2.1538,17.043,-2),(2.22,19,-2))
v45=((2.0524,17.0104,2),(2.0524,17.0104,-2),(1.76,15.01,2))
v46=((1.76,15.01,2),(1.76,15.01,-2),(2.0524,17.0104,-2))
v47=((1.76,15,2),(1.76,15,-2),(1.42,13.01,2))
v48=((1.42,13.01,2),(1.42,13.01,-2),(1.76,15,-2))


O.bodies.append(utils.facet(v1,color=(1,0,1), material=Bound))
O.bodies.append(utils.facet(v2,color=(1,0,1), material=Bound))
O.bodies.append(utils.facet(v3,color=(1,0,1), material=Bound))
O.bodies.append(utils.facet(v4,color=(1,0,1), material=Bound))
O.bodies.append(utils.facet(v5,color=(1,0,1), material=Bound))
O.bodies.append(utils.facet(v6,color=(1,0,1), material=Bound))
O.bodies.append(utils.facet(v7,color=(1,0,1), material=Bound))
O.bodies.append(utils.facet(v8,color=(1,0,1), 

Re: [Yade-users] [Question #688993]: polyhedrals after collide to facet, throwing away strongly

2020-02-29 Thread Mahdeyeh
Question #688993 on Yade changed:
https://answers.launchpad.net/yade/+question/688993

Mahdeyeh gave more information on the question:
Actually I think contact model in polyhedrals has problem!As the two
polyhedrals collide very slowly, their velocity and kinetic energy
increase abnormally!!


>> this is a typical symptom of too large time step (especially if decreasing 
>> stiffness helps)
Unfortunately decreasing stiffness or time step did help at all. :(  

Your help in this would be appreciated

-- 
You received this question notification because your team yade-users is
an answer contact for Yade.

___
Mailing list: https://launchpad.net/~yade-users
Post to : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


Re: [Yade-users] [Question #688993]: polyhedrals after collide to facet, throwing away strongly

2020-02-26 Thread Mahdeyeh
Question #688993 on Yade changed:
https://answers.launchpad.net/yade/+question/688993

Status: Answered => Open

Mahdeyeh is still having a problem:
Thank you a lot for all your helps Jan Stransky

>> this is a typical symptom of too large time step 
Do you think if I decrease time step, maybe this problem is solved?
for more particles, I set time step:10e-8.

 
 >> note: Most of polyhedrals have sharp angle, does this have effect on this 
 >> problem?

Do you have any idea about this??

-- 
You received this question notification because your team yade-users is
an answer contact for Yade.

___
Mailing list: https://launchpad.net/~yade-users
Post to : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


Re: [Yade-users] [Question #688512]: polyhedra particle is passing the wall

2020-02-09 Thread Mahdeyeh
Question #688512 on Yade changed:
https://answers.launchpad.net/yade/+question/688512

Status: Answered => Solved

Mahdeyeh confirmed that the question is solved:
Thanks Jérôme Duriez, that solved my question.

-- 
You received this question notification because your team yade-users is
an answer contact for Yade.

___
Mailing list: https://launchpad.net/~yade-users
Post to : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


Re: [Yade-users] [Question #688517]: Inclined wall??

2020-02-09 Thread Mahdeyeh
Question #688517 on Yade changed:
https://answers.launchpad.net/yade/+question/688517

Status: Answered => Solved

Mahdeyeh confirmed that the question is solved:
Thanks Jan Stránský, that solved my question.

-- 
You received this question notification because your team yade-users is
an answer contact for Yade.

___
Mailing list: https://launchpad.net/~yade-users
Post to : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


Re: [Yade-users] [Question #688517]: Inclined wall??

2020-02-05 Thread Mahdeyeh
Question #688517 on Yade changed:
https://answers.launchpad.net/yade/+question/688517

Status: Needs information => Open

Mahdeyeh gave more information on the question:
> - wall? Actual Yade Wall shape? or a flat boundary in general?
I mean this wall:

yade.utils.wall

class yade.wrapper.Wall

>  - dip for walls? the same inclination for all walls? independent?

not the same inclination for all of them. Every wall has dedicated
inclination.

-- 
You received this question notification because your team yade-users is
an answer contact for Yade.

___
Mailing list: https://launchpad.net/~yade-users
Post to : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


[Yade-users] [Question #688517]: Inclined wall??

2020-02-05 Thread Mahdeyeh
New question #688517 on Yade:
https://answers.launchpad.net/yade/+question/688517

Hello everyone

How I can create inclined wall for boundary of model?? I want to set dip for 
walls.


 Thank you!

Mahdeyeh

-- 
You received this question notification because your team yade-users is
an answer contact for Yade.

___
Mailing list: https://launchpad.net/~yade-users
Post to : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


[Yade-users] [Question #688512]: polyhedra particle is passing the wall

2020-02-04 Thread Mahdeyeh
New question #688512 on Yade:
https://answers.launchpad.net/yade/+question/688512

Hi everyone
My code has 4 polyhedra particles, 2 of them are wall and fix, the other 2 
particles should fall down and stay on walls but one of particles (green one) 
passes through the wall. The second particle does not pass the wall.
Why the green one passes the wall?What is its problem?
For testing,I has tried different properties of material, I mean increasing or 
decreasing density, young module, poisson ratio or frictionAngle, but none of 
them solve this problem.


ubuntu : 18.04
yade 2018.02b

here is my codes:

from yade import export,polyhedra_utils
import os
from yade import plot
import math
from yade import utils
import pylab
import matplotlib; matplotlib.rc('axes',grid=True)
from matplotlib import pyplot
import numpy as np
from numpy import *
from yade import export as expt

Dolomite = PolyhedraMat()
Dolomite.density = 2870 #kg/m^3 
Dolomite.young = 24.36e9 #Pa 
Dolomite.poisson = 0.2
Dolomite.frictionAngle = radians(55.12) #rad

Bound = PolyhedraMat()
Bound.density = 2870 #kg/m^3 
Bound.young = 60e10 #Pa 
Bound.poisson = 0.2
Bound.frictionAngle = radians(55.12) #rad

Shale = PolyhedraMat()
Shale.density = 2750 #kg/m^3 
Shale.young = 6e9 #Pa 
Shale.poisson = 0.23
Shale.frictionAngle = radians(42) #rad

v1=((3.80840249343969,4.0071,0.25),(4.10168443073866,4.00514568612972,0.25),(4.11564519594573,4.22873373182142,0.25),(3.83010741406799,4.13535598124846,0.25),(3.80840249343969,4.0071,0.25),(3.80840249343969,4.0071,-0.25),(4.10168443073866,4.00514568612972,-0.25),(4.11564519594573,4.22873373182142,-0.25),(3.83010741406799,4.13535598124846,-0.25),(3.80840249343969,4.0071,-0.25))
v2=((-2.49931484958066,-0.00101851609184,2),(-2.49931484958066,-1.05811862984014,2),(4.57134039401409,-1.05085707517961,2),(4.57126196395075,-0.00106929522008,2),(-2.49931484958066,-0.00101851609184,2),(-2.49931484958066,-0.00101851609184,-2),(-2.49931484958066,-1.05811862984014,-2),(4.57134039401409,-1.05085707517961,-2),(4.57126196395075,-0.00106929522008,-2),(-2.49931484958066,-0.00101851609184,-2))
v3=((6.74060748379946,3.00253856551901,2),(7.59942175653549,2.40210859046904,2),(5.30871392306244,-0.7578625393839,2),(4.5762246727,0.00588266389075,2),(6.74060748379946,3.00253856551901,2),(6.74060748379946,3.00253856551901,-2),(7.59942175653549,2.40210859046904,-2),(5.30871392306244,-0.7578625393839,-2),(4.5762246727,0.00588266389075,-2),(6.74060748379946,3.00253856551901,-2))
v4=((5.65881645402257,3.06264016950990,0.25),(5.87183172458837,3.21786437273975,0.25),(5.88119170365426,3.54514975549388,0.25),(5.83257618949696,3.6667153017607,0.25),(5.63774404261507,3.62611484,0.25),(5.58705877827044,3.34599484278801,0.25),(5.65881645402257,3.0626401695099,0.25),(5.65881645402257,3.06264016950990,-0.25),(5.87183172458837,3.21786437273975,-0.25),(5.88119170365426,3.54514975549388,-0.25),(5.83257618949696,3.6667153017607,-0.25),(5.63774404261507,3.62611484,-0.25),(5.58705877827044,3.34599484278801,-0.25),(5.65881645402257,3.0626401695099,-0.25))
O.bodies.append(polyhedra_utils.polyhedra(Dolomite,v=v1,fixed=False, 
color=(0.1,0.5,0.2), mask=3))
O.bodies.append(polyhedra_utils.polyhedra(Bound,v=v2,fixed=True, color=(1,0,1), 
mask=4))
O.bodies.append(polyhedra_utils.polyhedra(Bound,v=v3,fixed=True, color=(1,0,1), 
mask=4))
O.bodies.append(polyhedra_utils.polyhedra(Shale,v=v4,fixed=False, 
color=(0.9,0.81,0.45), mask=5))

for b in O.bodies:
if b.mask is 3:
b.state.blockedDOFs='zXY'
for b in O.bodies:
if b.mask is 5:
b.state.blockedDOFs='zXY'

def calm():
for c in O.bodies:
c.state.vel=Vector3(0,0,0)
c.state.angVel=Vector3(0,0,0)

O.engines=[
   ForceResetter(),
   InsertionSortCollider([Bo1_Polyhedra_Aabb(),],verletDist=0.05), 
   InteractionLoop(
  [Ig2_Polyhedra_Polyhedra_PolyhedraGeom(),], 
  [Ip2_PolyhedraMat_PolyhedraMat_PolyhedraPhys()], 
  [Law2_PolyhedraGeom_PolyhedraPhys_Volumetric()]   
   ),
   NewtonIntegrator(gravity=(0,-9.81,0),damping=0.2),
]

utils.calm()
O.engines=O.engines+[PyRunner(iterPeriod=20,command='calm()',label="calmRunner")]
  
O.dt=50e-7
O.run(5,True)
O.run()
calmRunner.dead=True


I would appreciate if you can help me


-- 
You received this question notification because your team yade-users is
an answer contact for Yade.

___
Mailing list: https://launchpad.net/~yade-users
Post to : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


Re: [Yade-users] [Question #687484]: decreasing speed of run after some cycle

2020-01-16 Thread Mahdeyeh
Question #687484 on Yade changed:
https://answers.launchpad.net/yade/+question/687484

Status: Answered => Solved

Mahdeyeh confirmed that the question is solved:
Thanks Jan Stránský, that solved my question.

-- 
You received this question notification because your team yade-users is
an answer contact for Yade.

___
Mailing list: https://launchpad.net/~yade-users
Post to : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


Re: [Yade-users] [Question #687484]: decreasing speed of run after some cycle

2020-01-16 Thread Mahdeyeh
Question #687484 on Yade changed:
https://answers.launchpad.net/yade/+question/687484

Mahdeyeh posted a new comment:
Thank you a lot Jan Stránský. you are so good.

Best regards,
Mahdeyeh

-- 
You received this question notification because your team yade-users is
an answer contact for Yade.

___
Mailing list: https://launchpad.net/~yade-users
Post to : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


Re: [Yade-users] [Question #687484]: decreasing speed of run after some cycle

2020-01-15 Thread Mahdeyeh
Question #687484 on Yade changed:
https://answers.launchpad.net/yade/+question/687484

Status: Answered => Open

Mahdeyeh is still having a problem:
Jan! you are so good , thanks a lot. You are solving my problem step by
step.

Another question:

How I can solve this error:
"WARN /build/yade-fDuCoe/yade-2018.02b/pkg/dem/Polyhedra_support.cpp:370 
SolveLinSys3x3: error in linear solver"

information:

In VMware
16 cores
Ram: 32 GB
ubuntu : 18.04.3 LTS
yade 2018.02b
libcgal: 4.11-2 build 1
gcc: 4:7.4.0-1 ubuntu 2.3


number of bodies : 921
size of bodies' range in X, Y axis: 15 cm til 1 m
Thickness of bodies is constant : 50 cm
The particle distribution is only along the XY axis; in other words, it is a 
two-dimensional model.


I run it with : yade -j16 filename.py

-- 
You received this question notification because your team yade-users is
an answer contact for Yade.

___
Mailing list: https://launchpad.net/~yade-users
Post to : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


Re: [Yade-users] [Question #687484]: decreasing speed of run after some cycle

2020-01-14 Thread Mahdeyeh
Question #687484 on Yade changed:
https://answers.launchpad.net/yade/+question/687484

Status: Answered => Open

Mahdeyeh is still having a problem:
Thank you Jan for your good advice and tips.

I appreciate your patience, please help me about follow questions:

1- For all polyhedars I has used blockedDOFs in 'zXY', but while I
locked particles, I saw some particles in own place rotate around Z axis
and these particle have "angMom" in Z axis. why it happens?

2- To  solve the above problem (question number 1), angMom and angVel
all particles have set zero, but again a few particles have amount in
angMom !! why??

3- Something different happens when I run this script in 2 system with  similar 
"ubuntu : 18.04, yade 2018.02b" but different number of core"2 Cores and 16 
cores": 
in system with 2 cores does n`t give follow error but in system with 16 cores 
it shows follow error continuously:
error: "WARN /build/yade-fDuCoe/yade-2018.02b/pkg/dem/Polyhedra_support.cpp:370 
SolveLinSys3x3: error in linear solver" . Why does this error occur in one 
system but not in the other? And What is the reason for this error?

-- 
You received this question notification because your team yade-users is
an answer contact for Yade.

___
Mailing list: https://launchpad.net/~yade-users
Post to : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


Re: [Yade-users] [Question #687484]: decreasing speed of run after some cycle

2020-01-14 Thread Mahdeyeh
Question #687484 on Yade changed:
https://answers.launchpad.net/yade/+question/687484

Description changed to:
Hi everyone
I run polyhedra particles in this computer:

CPU (Cores)::  xIntel(R) Xeon(TM) E5-2680 v2
20 cores 3.1 Hz
Hard disc (HDD): 150 GB ssd
Ram: 128 GB   DDR 3
ubuntu : 18.04
yade 2018.02b

number of bodies : 1511
size of bodies' range in x and y axises: 5cm til 1 m
z length of body is constant : 10 cm

I run it with : yade -j20 filename.py

it started with 97% of CPU and high velocity of running and continue (75 cycle 
in a second),  after 295 iteration I stoped it for saving simulation until 
this iter and then play it but now simulating has 30% of CPU  and velocity of 
runnig is very low (6 cycle in a second), WHY?
what is the problem?please help

Thanks,
Mahdeyeh


Here is my code:

from yade import export,polyhedra_utils
import os
from yade import plot
import math
from yade import utils
import pylab
import matplotlib; matplotlib.rc('axes',grid=True)
from matplotlib import pyplot
import numpy as np
from numpy import *
from yade import export as expt


RawVer=np.genfromtxt('ring.txt',names=True,dtype=None)
Ver=()
ListVer=[]
for b in RawVer:
if b[0]=='*LWPOLYLINE':
ListVer.append(Ver)
Ver=()
continue
Cordn=b[0]
Cordn=np.fromstring(Cordn, sep=',')
Cordn=tuple(Cordn.tolist())
Cordn1=Cordn+(0.1,) # add z vertex to coordinates
Cordn2=Cordn+(0.2,) # add z vertex to coordinates
if not Cordn1 in Ver:
Ver=Ver+(Cordn1,Cordn2)
ListVer.append(Ver)

RawVer1=np.genfromtxt('boundary.txt',names=True,dtype=None)
Ver1=()
ListVer1=[]
for b in RawVer1:
if b[0]=='*LWPOLYLINE':
ListVer1.append(Ver1)
Ver1=()
continue
Cordn=b[0]
Cordn=np.fromstring(Cordn, sep=',')
Cordn=tuple(Cordn.tolist())
Cordn1=Cordn+(-2,) # add z vertex to coordinates
Cordn2=Cordn+(2,) # add z vertex to coordinates
if not Cordn1 in Ver1:
Ver1=Ver1+(Cordn1,Cordn2)
ListVer1.append(Ver1)

RawVer2=np.genfromtxt('waste.txt',names=True,dtype=None)
Ver2=()
ListVer2=[]
for b in RawVer2:
if b[0]=='*LWPOLYLINE':
ListVer2.append(Ver2)
Ver2=()
continue
Cordn=b[0]
Cordn=np.fromstring(Cordn, sep=',')
Cordn=tuple(Cordn.tolist())
Cordn1=Cordn+(0.1,) # add z vertex to coordinates
Cordn2=Cordn+(0.2,) # add z vertex to coordinates
if not Cordn1 in Ver2:
Ver2=Ver2+(Cordn1,Cordn2)
ListVer2.append(Ver2)


Dolomite = PolyhedraMat()
Dolomite.density = 2870 #kg/m^3
Dolomite.young = 24.36e9 #Pa
Dolomite.poisson = 0.2
Dolomite.frictionAngle = radians(55.12) #rad

Shale = PolyhedraMat()
Shale.density = 2750 #kg/m^3
Shale.young = 6e9 #Pa
Shale.poisson = 0.23
Shale.frictionAngle = radians(42) #rad

for ii in ListVer:
O.bodies.append(polyhedra_utils.polyhedra(Dolomite,v=ii,fixed=False, 
color=(0.1,0.5,0.2), mask=3))

for iii in ListVer1:
O.bodies.append(polyhedra_utils.polyhedra(Dolomite,v=iii,fixed=True, 
color=(1,0,1), mask=4))

for  in ListVer2:
O.bodies.append(polyhedra_utils.polyhedra(Shale,v=,fixed=False, 
color=(0.9,0.81,0.45), mask=5))

O.bodies.erase(340)


for b in O.bodies:
if b.mask is 3:
b.state.blockedDOFs='zXY'
for b in O.bodies:
if b.mask is 5:
b.state.blockedDOFs='zXY'

def calm():
for c in O.bodies:
c.state.vel=Vector3(0,0,0)
c.state.angVel=Vector3(0,0,0)


O.engines=[
   ForceResetter(),
   InsertionSortCollider([Bo1_Polyhedra_Aabb(),]), 
   InteractionLoop(
  [Ig2_Polyhedra_Polyhedra_PolyhedraGeom(),],
  [Ip2_PolyhedraMat_PolyhedraMat_PolyhedraPhys()], 
  [Law2_PolyhedraGeom_PolyhedraPhys_Volumetric()] 
   ),
   NewtonIntegrator(gravity=(0,-9.81,0),damping=0.2),
]

utils.calm()

O.engines=O.engines+[PyRunner(iterPeriod=20,command='calm()',label="calmRunner")]

O.dt=10e-6
O.run(5,True)

O.run()

-- 
You received this question notification because your team yade-users is
an answer contact for Yade.

___
Mailing list: https://launchpad.net/~yade-users
Post to : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


Re: [Yade-users] [Question #687484]: decreasing speed of run after some cycle

2020-01-08 Thread Mahdeyeh
Question #687484 on Yade changed:
https://answers.launchpad.net/yade/+question/687484

Status: Answered => Open

Mahdeyeh is still having a problem:
Thank you Jan

Do you have any idea for this:
> Another thing: when I loaded save of 295 iteration and saw the image of 
> model , I saw particles had been passed the walls

In my model, walls are huge polyhedrons with very very little thickness
(about 1 mm). why particles (other polyhedrons) passed these walls? Has
this passing been effective in increasing interactions?

-- 
You received this question notification because your team yade-users is
an answer contact for Yade.

___
Mailing list: https://launchpad.net/~yade-users
Post to : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


[Yade-users] [Question #687614]: how install stable version of yade on CentOS 6.5 local (cluster)?

2019-12-29 Thread Mahdeyeh
New question #687614 on Yade:
https://answers.launchpad.net/yade/+question/687614

Dear all,

We want to install yade on CentOs 6.5 local  cluster (Fedora). We had problems 
in packages.
Please tell me process of installation of stable version of yade on CentOS 6.5 
local (cluster)?

Thanks
Mahdeyeh

-- 
You received this question notification because your team yade-users is
an answer contact for Yade.

___
Mailing list: https://launchpad.net/~yade-users
Post to : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


Re: [Yade-users] [Question #687484]: decreasing speed of run after some cycle

2019-12-29 Thread Mahdeyeh
Question #687484 on Yade changed:
https://answers.launchpad.net/yade/+question/687484

Mahdeyeh gave more information on the question:
Another thing: when I loaded save of 295 iteration and saw the image
of model , I saw particles had been passed the walls, I think the error
of "WARN /build/yade-
fDuCoe/yade-2018.02b/pkg/dem/Polyhedra_support.cpp:370 SolveLinSys3x3:
error in linear solver" is because of this, is it right? and solution of
that is decreasing dt???

-- 
You received this question notification because your team yade-users is
an answer contact for Yade.

___
Mailing list: https://launchpad.net/~yade-users
Post to : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


Re: [Yade-users] [Question #687484]: decreasing speed of run after some cycle

2019-12-24 Thread Mahdeyeh
Question #687484 on Yade changed:
https://answers.launchpad.net/yade/+question/687484

Description changed to:
Hi everyone
I run polyhedra particles in this computer:

CPU (Cores)::  xIntel(R) Xeon(TM) E5-2680 v2
20 cores 3.1 Hz
Hard disc (HDD): 150 GB ssd
Ram: 128 GB   DDR 3
ubuntu : 18.04
yade 2018.02b

number of bodies : 1511
size of bodies' range in x and y axises: 5cm til 1 m
z length of body is constant : 10 cm

I run it with : yade -j20 filename.py

it started with 97% of CPU and high velocity of running and continue (75 cycle 
in a second),  after 295 iteration I stoped it for saving simulation until 
this iter and then play it but now simulating has 30% of CPU  and velocity of 
runnig is very low (6 cycle in a second), WHY?
what is the problem?please help

Thanks,
Mahdeyeh


Here is my code:

from yade import export,polyhedra_utils
import os
from yade import plot
import math
from yade import utils
import pylab
import matplotlib; matplotlib.rc('axes',grid=True)
from matplotlib import pyplot
import numpy as np
from numpy import *
from yade import export as expt


RawVer=np.genfromtxt('ring.txt',names=True,dtype=None)
Ver=()
ListVer=[]
for b in RawVer:
if b[0]=='*LWPOLYLINE':
ListVer.append(Ver)
Ver=()
continue
Cordn=b[0]
Cordn=np.fromstring(Cordn, sep=',')
Cordn=tuple(Cordn.tolist())
Cordn1=Cordn+(0.1,) # add z vertex to coordinates
Cordn2=Cordn+(0.2,) # add z vertex to coordinates
if not Cordn1 in Ver:
Ver=Ver+(Cordn1,Cordn2)
ListVer.append(Ver)

RawVer1=np.genfromtxt('boundary.txt',names=True,dtype=None)
Ver1=()
ListVer1=[]
for b in RawVer1:
if b[0]=='*LWPOLYLINE':
ListVer1.append(Ver1)
Ver1=()
continue
Cordn=b[0]
Cordn=np.fromstring(Cordn, sep=',')
Cordn=tuple(Cordn.tolist())
Cordn1=Cordn+(-2,) # add z vertex to coordinates
Cordn2=Cordn+(2,) # add z vertex to coordinates
if not Cordn1 in Ver1:
Ver1=Ver1+(Cordn1,Cordn2)
ListVer1.append(Ver1)

RawVer2=np.genfromtxt('waste.txt',names=True,dtype=None)
Ver2=()
ListVer2=[]
for b in RawVer2:
if b[0]=='*LWPOLYLINE':
ListVer2.append(Ver2)
Ver2=()
continue
Cordn=b[0]
Cordn=np.fromstring(Cordn, sep=',')
Cordn=tuple(Cordn.tolist())
Cordn1=Cordn+(0.1,) # add z vertex to coordinates
Cordn2=Cordn+(0.2,) # add z vertex to coordinates
if not Cordn1 in Ver2:
Ver2=Ver2+(Cordn1,Cordn2)
ListVer2.append(Ver2)


Dolomite = PolyhedraMat()
Dolomite.density = 2870 #kg/m^3
Dolomite.young = 24.36e9 #Pa
Dolomite.poisson = 0.2
Dolomite.frictionAngle = radians(55.12) #rad

Shale = PolyhedraMat()
Shale.density = 2750 #kg/m^3
Shale.young = 6e9 #Pa
Shale.poisson = 0.23
Shale.frictionAngle = radians(42) #rad

for ii in ListVer:
O.bodies.append(polyhedra_utils.polyhedra(Dolomite,v=ii,fixed=False, 
color=(0.1,0.5,0.2), mask=3))

for iii in ListVer1:
O.bodies.append(polyhedra_utils.polyhedra(Dolomite,v=iii,fixed=True, 
color=(1,0,1), mask=4))

for  in ListVer2:
O.bodies.append(polyhedra_utils.polyhedra(Shale,v=,fixed=False, 
color=(0.9,0.81,0.45), mask=5))

O.bodies.erase(340)


for b in O.bodies:
if b.mask is 3:
b.state.blockedDOFs='zXY'
for b in O.bodies:
if b.mask is 5:
b.state.blockedDOFs='zXY'

def calm():
for c in O.bodies:
c.state.vel=Vector3(0,0,0)
c.state.angVel=Vector3(0,0,0)


def checkUnbalanced():
 iter00=O.iter
Unbalanced=open("Unbalanced iter Unbalanced forces.txt","a")
Unbalanced.write(repr(iter00)+' '+repr(utils.unbalancedForce())+' '+"\n")
Unbalanced.close()

O.engines=[
   ForceResetter(),
   InsertionSortCollider([Bo1_Polyhedra_Aabb(),]), 
   InteractionLoop(
  [Ig2_Polyhedra_Polyhedra_PolyhedraGeom(),],
  [Ip2_PolyhedraMat_PolyhedraMat_PolyhedraPhys()], 
  [Law2_PolyhedraGeom_PolyhedraPhys_Volumetric()] 
   ),
   NewtonIntegrator(gravity=(0,-9.81,0),damping=0.2),
]

utils.calm()
O.engines=O.engines+[PyRunner(iterPeriod=20,command='calm()',label="calmRunner")]
 
O.engines=O.engines+[PyRunner(command='checkUnbalanced()',iterPeriod=1,label="checker")]
 

O.dt=10e-6
O.run(5,True)


clrOre=[0.1,0.5,0.2]
clrWaste=[0.9,0.81,0.45]

def positions():
for b in O.bodies:
if b.shape.color==clrOre:
time1=O.time
Positions=open("Positions time x y z.txt","a")
Positions.write(repr(time1)+' '+repr(b.state.pos[0])+' 
'+repr(b.state.pos[1])+' '+repr(b.state.pos[2])+' '"\n")
Positions.close()

def oreAmount():
clrOre=[0.1,0.5,0.2]
M_o=0
for b in O.bodies:
if b.shape.color==clrOre:
M_o+=b.state.mass
return M_o

os.mkdir(O.tags['id']) 
O.engines=O.engines+[PyRunner(iterPeriod=20,command='VTKview()',label="VTKview")]
 
PolVtkData = expt.VTKExporter(O.tags['id']+'/'+'polData') 
def VTKview():
PolVtkData

Re: [Yade-users] [Question #687484]: decreasing speed of run after some cycle

2019-12-23 Thread Mahdeyeh
Question #687484 on Yade changed:
https://answers.launchpad.net/yade/+question/687484

Mahdeyeh gave more information on the question:
it maybe helps: always at first of run, this warning is display:

"WARN  /build/yade-
fDuCoe/yade-2018.02b/pkg/common/InsertionSortCollider.cpp:76
insertionSortParallel: Parallel insertion: only 16 thread(s) used. The
number of bodies is probably too small for allowing more threads, or the
geometry is flat. The contact detection should succeed but not all
available threads are used."


After decreasing velocity, I load saved file of simulation until 295 and 
this warning is display:

"WARN  /build/yade-
fDuCoe/yade-2018.02b/pkg/dem/Polyhedra_support.cpp:370 SolveLinSys3x3:
error in linear solver"

-- 
You received this question notification because your team yade-users is
an answer contact for Yade.

___
Mailing list: https://launchpad.net/~yade-users
Post to : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


[Yade-users] [Question #687484]: decreasing speed of run after some cycle

2019-12-23 Thread Mahdeyeh
New question #687484 on Yade:
https://answers.launchpad.net/yade/+question/687484

Hi everyone
I run polyhedra particles in this computer:

CPU (Cores)::  xIntel(R) Xeon(TM) E5-2680 v2
20 cores 3.1 Hz
Hard disc (HDD): 150 GB ssd
Ram: 128 GB   DDR 3
ubuntu : 18.04
yade 2018.02b

number of bodies : 1511
size of bodies' range in x and y axises: 5cm til 1 m
z length of body is constant : 10 cm

I run it with : yade -j20 filename.py

it started with 97% of CPU and high velocity of running and continue,  after 
295 iteration I stoped it for saving simulation until this iter and then 
play it but now simulating has 30% of CPU  and velocity of runnig is very low, 
WHY?
what is the problem?please help

Thanks,
Mahdeyeh


Here is my code:

from yade import export,polyhedra_utils
import os
from yade import plot
import math
from yade import utils
import pylab
import matplotlib; matplotlib.rc('axes',grid=True)
from matplotlib import pyplot
import numpy as np
from numpy import *
from yade import export as expt


RawVer=np.genfromtxt('ring.txt',names=True,dtype=None)
Ver=()
ListVer=[]
for b in RawVer:
if b[0]=='*LWPOLYLINE':
ListVer.append(Ver)
Ver=()
continue
Cordn=b[0]
Cordn=np.fromstring(Cordn, sep=',')
Cordn=tuple(Cordn.tolist())
Cordn1=Cordn+(0.1,) # add z vertex to coordinates
Cordn2=Cordn+(0.2,) # add z vertex to coordinates
if not Cordn1 in Ver:
Ver=Ver+(Cordn1,Cordn2)
ListVer.append(Ver)

RawVer1=np.genfromtxt('boundary.txt',names=True,dtype=None)
Ver1=()
ListVer1=[]
for b in RawVer1:
if b[0]=='*LWPOLYLINE':
ListVer1.append(Ver1)
Ver1=()
continue
Cordn=b[0]
Cordn=np.fromstring(Cordn, sep=',')
Cordn=tuple(Cordn.tolist())
Cordn1=Cordn+(-2,) # add z vertex to coordinates
Cordn2=Cordn+(2,) # add z vertex to coordinates
if not Cordn1 in Ver1:
Ver1=Ver1+(Cordn1,Cordn2)
ListVer1.append(Ver1)

RawVer2=np.genfromtxt('waste.txt',names=True,dtype=None)
Ver2=()
ListVer2=[]
for b in RawVer2:
if b[0]=='*LWPOLYLINE':
ListVer2.append(Ver2)
Ver2=()
continue
Cordn=b[0]
Cordn=np.fromstring(Cordn, sep=',')
Cordn=tuple(Cordn.tolist())
Cordn1=Cordn+(0.1,) # add z vertex to coordinates
Cordn2=Cordn+(0.2,) # add z vertex to coordinates
if not Cordn1 in Ver2:
Ver2=Ver2+(Cordn1,Cordn2)
ListVer2.append(Ver2)


Dolomite = PolyhedraMat()
Dolomite.density = 2870 #kg/m^3
Dolomite.young = 24.36e9 #Pa
Dolomite.poisson = 0.2
Dolomite.frictionAngle = radians(55.12) #rad

Shale = PolyhedraMat()
Shale.density = 2750 #kg/m^3
Shale.young = 6e9 #Pa
Shale.poisson = 0.23
Shale.frictionAngle = radians(42) #rad

for ii in ListVer:
O.bodies.append(polyhedra_utils.polyhedra(Dolomite,v=ii,fixed=False, 
color=(0.1,0.5,0.2), mask=3))

for iii in ListVer1:
O.bodies.append(polyhedra_utils.polyhedra(Dolomite,v=iii,fixed=True, 
color=(1,0,1), mask=4))

for  in ListVer2:
O.bodies.append(polyhedra_utils.polyhedra(Shale,v=,fixed=False, 
color=(0.9,0.81,0.45), mask=5))

O.bodies.erase(340) 


for b in O.bodies:
if b.mask is 3:
b.state.blockedDOFs='zXY'
for b in O.bodies:
if b.mask is 5:
b.state.blockedDOFs='zXY'

def calm():
for c in O.bodies:
c.state.vel=Vector3(0,0,0)
c.state.angVel=Vector3(0,0,0)


def checkUnbalanced():
 iter00=O.iter
Unbalanced=open("Unbalanced iter Unbalanced forces.txt","a")
Unbalanced.write(repr(iter00)+' '+repr(utils.unbalancedForce())+' '+"\n")
Unbalanced.close()

O.engines=[
   ForceResetter(),
   InsertionSortCollider([Bo1_Polyhedra_Aabb(),]), 
   InteractionLoop(
  [Ig2_Polyhedra_Polyhedra_PolyhedraGeom(),],
  [Ip2_PolyhedraMat_PolyhedraMat_PolyhedraPhys()], 
  [Law2_PolyhedraGeom_PolyhedraPhys_Volumetric()] 
   ),
   NewtonIntegrator(gravity=(0,-9.81,0),damping=0.2),
]

utils.calm()
O.engines=O.engines+[PyRunner(iterPeriod=20,command='calm()',label="calmRunner")]
 
O.engines=O.engines+[PyRunner(command='checkUnbalanced()',iterPeriod=1,label="checker")]
 

O.dt=10e-6
O.run(5,True)


clrOre=[0.1,0.5,0.2]
clrWaste=[0.9,0.81,0.45]

def positions():
for b in O.bodies:
if b.shape.color==clrOre:
time1=O.time
Positions=open("Positions time x y z.txt","a")
Positions.write(repr(time1)+' '+repr(b.state.pos[0])+' 
'+repr(b.state.pos[1])+' '+repr(b.state.pos[2])+' '"\n")
Positions.close()

def oreAmount():
clrOre=[0.1,0.5,0.2]
M_o=0
for b in O.bodies:
if b.shape.color==clrOre:
M_o+=b.state.mass
return M_o

os.mkdir(O.tags['id']) 
O.engines=O.engines+[PyRunner(iterPeriod=20,command='VTKview()',label="VTKview")]
 
PolVtkData = expt.VTKExporter(O.tags['id']+'/'+'polData') 
def VTKview():
PolVtkData.exportPolyhedra()

m_o = 0.5
m_w = 0.5
R = 0
D = 0
D_m = 0
E = 0 
M_o =

Re: [Yade-users] [Question #687145]: error in runnig

2019-12-15 Thread Mahdeyeh
Question #687145 on Yade changed:
https://answers.launchpad.net/yade/+question/687145

Status: Answered => Solved

Mahdeyeh confirmed that the question is solved:
Thanks Jan

I should do this. I try

Regards,
Mahdeyeh

-- 
You received this question notification because your team yade-users is
an answer contact for Yade.

___
Mailing list: https://launchpad.net/~yade-users
Post to : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


Re: [Yade-users] [Question #687145]: error in runnig

2019-12-15 Thread Mahdeyeh
Question #687145 on Yade changed:
https://answers.launchpad.net/yade/+question/687145

Status: Needs information => Open

Mahdeyeh gave more information on the question:
thanks Jan for reply.

I install this CGAL version that was possible on ubuntu 16.04 :
libcgal-dev:
  Installed: 4.7-4
  Candidate: 4.7-4
  Version table:
 *** 4.7-4 500


Then run model again...but again simulating stopped:

"terminate called after throwing an instance of 'CGAL::Assertion_exception'
  what():  CGAL ERROR: assertion violation!
Expr: dexp != 2047
File: /usr/include/CGAL/Mpzf.h
Line: 433
Explanation: Creating an Mpzf from infinity or NaN.
Aborted (core dumped)"

regards,
Mahdeyeh

-- 
You received this question notification because your team yade-users is
an answer contact for Yade.

___
Mailing list: https://launchpad.net/~yade-users
Post to : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


[Yade-users] [Question #687145]: error in runnig

2019-12-14 Thread Mahdeyeh
New question #687145 on Yade:
https://answers.launchpad.net/yade/+question/687145

Hi everyone
I  run polyhedra particles in this computer:

CPU (Cores):16
2.3 Hz
Hard disc (HDD): 80 GB
Ram: 32 GB
ubuntu : 16.04
yade 1.20.0

number of bodies : 1511

After 478 iteration, run stopped with this error:

"terminate called after throwing an instance of 'CGAL::Assertion_exception'
  what():  CGAL ERROR: assertion violation!
Expr: dexp != 2047
File: /usr/include/CGAL/Mpzf.h
Line: 433
Explanation: Creating an Mpzf from infinity or NaN.
Aborted (core dumped)"

what is the problem? 

Thanks,
Mahdeyeh


Here is my code:

from yade import export,polyhedra_utils
import os
from yade import plot
import math
from yade import utils
import pylab
import matplotlib; matplotlib.rc('axes',grid=True)
from matplotlib import pyplot
import numpy as np
from numpy import *
from yade import export as expt

# Input data:

RawVer=np.genfromtxt('ring.txt',names=True,dtype=None)
# ListVer is list of all the vertices of ring`s polygons
Ver=()
ListVer=[]
for b in RawVer:
if b[0]=='*LWPOLYLINE':
ListVer.append(Ver)
Ver=()
continue
Cordn=b[0]
Cordn=np.fromstring(Cordn, sep=',')
Cordn=tuple(Cordn.tolist())
Cordn1=Cordn+(0.1,) # add z vertex to coordinates
Cordn2=Cordn+(0.2,) # add z vertex to coordinates
if not Cordn1 in Ver:
Ver=Ver+(Cordn1,Cordn2)
ListVer.append(Ver)

RawVer1=np.genfromtxt('boundary.txt',names=True,dtype=None)
# ListVer1 is list of all the vertices of boundary`s polygons
Ver1=()
ListVer1=[]
for b in RawVer1:
if b[0]=='*LWPOLYLINE':
ListVer1.append(Ver1)
Ver1=()
continue
Cordn=b[0]
Cordn=np.fromstring(Cordn, sep=',')
Cordn=tuple(Cordn.tolist())
Cordn1=Cordn+(-2,) # add z vertex to coordinates
Cordn2=Cordn+(2,) # add z vertex to coordinates
if not Cordn1 in Ver1:
Ver1=Ver1+(Cordn1,Cordn2)
ListVer1.append(Ver1)

RawVer2=np.genfromtxt('waste.txt',names=True,dtype=None)
# ListVer2 is list of all the vertices of caved waste rock`s polygons
Ver2=()
ListVer2=[]
for b in RawVer2:
if b[0]=='*LWPOLYLINE':
ListVer2.append(Ver2)
Ver2=()
continue
Cordn=b[0]
Cordn=np.fromstring(Cordn, sep=',')
Cordn=tuple(Cordn.tolist())
Cordn1=Cordn+(0.1,) # add z vertex to coordinates
Cordn2=Cordn+(0.2,) # add z vertex to coordinates
if not Cordn1 in Ver2:
Ver2=Ver2+(Cordn1,Cordn2)
ListVer2.append(Ver2)

# Materials type:

Dolomite = PolyhedraMat()
Dolomite.density = 2870 #kg/m^3
Dolomite.young = 24.36e9 #Pa
Dolomite.poisson = 0.2
Dolomite.frictionAngle = radians(55.12) #rad

Shale = PolyhedraMat()
Shale.density = 2750 #kg/m^3
Shale.young = 6e9 #Pa
Shale.poisson = 0.23
Shale.frictionAngle = radians(42) #rad

for ii in ListVer:
O.bodies.append(polyhedra_utils.polyhedra(Dolomite,v=ii,fixed=False, 
color=(0.1,0.5,0.2), mask=3))

for iii in ListVer1:
O.bodies.append(polyhedra_utils.polyhedra(Dolomite,v=iii,fixed=True, 
color=(1,0,1), mask=4))

for  in ListVer2:
O.bodies.append(polyhedra_utils.polyhedra(Shale,v=,fixed=False, 
color=(0.9,0.81,0.45), mask=5))

O.bodies.erase(340) # delete wall under ring: id: 340

# block z translation and block x, y, z rotations
for b in O.bodies:
if b.mask is 3:
b.state.blockedDOFs='zXY'
for b in O.bodies:
if b.mask is 5:
b.state.blockedDOFs='zXY'

# function for calming particles
def calm():
for c in O.bodies:
c.state.vel=Vector3(0,0,0)
c.state.angVel=Vector3(0,0,0)

# returns a value that can be useful for evaluating the stability of the 
packing. It is defined as (mean force on particles)/(mean contact force), so 
that it tends to 0 in a stable packing.
def checkUnbalanced():
print "iter %d , unbalanced forces %f"%(O.iter, utils.unbalancedForce()) # 
%[(keyname)][flags][width][.precision]typecode : String Formatting
iter00=O.iter

Unbalanced=open("Unbalanced iter Unbalanced forces.txt","a")
Unbalanced.write(repr(iter00)+' '+repr(utils.unbalancedForce())+' '+"\n")
Unbalanced.close()

# Engines:



O.engines=[
   ForceResetter(),
   InsertionSortCollider([Bo1_Polyhedra_Aabb(),]), # We can set collider's 
verletDist to a fraction of the polyhedra minimum size, since it determines how 
much is each body enlarged to avoid collision detection at every step.
   InteractionLoop(
  [Ig2_Polyhedra_Polyhedra_PolyhedraGeom(),],
  [Ip2_PolyhedraMat_PolyhedraMat_PolyhedraPhys()], # collision "physics"
  [Law2_PolyhedraGeom_PolyhedraPhys_Volumetric()] # contact law -- apply 
forces
   ),
   NewtonIntegrator(gravity=(0,-9.81,0),damping=0.2),
]

utils.calm()

# the model has to calm, because there are some overlaps in particles.
O.engines=O.engines+[PyRunner(iterPeriod=20,command='calm()',label="calmRunner")]
 # because we need to calm only on the first few steps in our model.
O.engines=O.engines

Re: [Yade-users] [Question #686970]: run yade in parallel

2019-12-13 Thread Mahdeyeh
Question #686970 on Yade changed:
https://answers.launchpad.net/yade/+question/686970

Status: Answered => Solved

Mahdeyeh confirmed that the question is solved:
Thanks Jan Stránský, that solved my question.

-- 
You received this question notification because your team yade-users is
an answer contact for Yade.

___
Mailing list: https://launchpad.net/~yade-users
Post to : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


Re: [Yade-users] [Question #686970]: run yade in parallel

2019-12-12 Thread Mahdeyeh
Question #686970 on Yade changed:
https://answers.launchpad.net/yade/+question/686970

Mahdeyeh posted a new comment:

I add :  InsertionSortCollider(..., verletDist=.05), for above error  and it 
does not show but now when I run model it says this:


"WARN  /build/yade-KKgSmd/yade-1.20.0/pkg/common/InsertionSortCollider.cpp:80 
insertionSortParallel: Parallel insertion: only 2 thread(s) used. The number of 
bodies is probably too small for allowing more threads, or the geometry is 
flat. The contact detection should succeed but not all available threads are 
used."

what should I do? is that decrease speed run?

-- 
You received this question notification because your team yade-users is
an answer contact for Yade.

___
Mailing list: https://launchpad.net/~yade-users
Post to : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


Re: [Yade-users] [Question #686970]: run yade in parallel

2019-12-12 Thread Mahdeyeh
Question #686970 on Yade changed:
https://answers.launchpad.net/yade/+question/686970

Status: Answered => Open

Mahdeyeh is still having a problem:
Than you Jan
I think so.

I ran the codes with :  yade j-8 code.py, but it shows this error:

"ERROR /build/yade-
KKgSmd/yade-1.20.0/pkg/common/InsertionSortCollider.cpp:65
insertionSortParallel: Parallel insertion sort needs verletDist>0"

I think it because of my particles are polyhedra not sphere, yes? so is
this error is important? How I can solve it?

Here is my code:


from yade import export,polyhedra_utils
import os
from yade import plot
import math
from yade import utils
import pylab
import matplotlib; matplotlib.rc('axes',grid=True)
from matplotlib import pyplot
import numpy as np
from numpy import *
from yade import export as expt


# Input data:

RawVer=np.genfromtxt('ring.txt',names=True,dtype=None)
# ListVer is list of all the vertices of ring`s polygons
Ver=()
ListVer=[]
for b in RawVer:
if b[0]=='*LWPOLYLINE':
ListVer.append(Ver)
Ver=()
continue
Cordn=b[0]
Cordn=np.fromstring(Cordn, sep=',')
Cordn=tuple(Cordn.tolist())
Cordn1=Cordn+(0.1,)   # add z vertex to coordinates 
Cordn2=Cordn+(0.2,)   # add z vertex to coordinates
if not Cordn1 in Ver:
Ver=Ver+(Cordn1,Cordn2)
ListVer.append(Ver)

RawVer1=np.genfromtxt('boundary.txt',names=True,dtype=None)
# ListVer1 is list of all the vertices of boundary`s polygons
Ver1=()
ListVer1=[]
for b in RawVer1:
if b[0]=='*LWPOLYLINE':
ListVer1.append(Ver1)
Ver1=()
continue
Cordn=b[0]
Cordn=np.fromstring(Cordn, sep=',')
Cordn=tuple(Cordn.tolist())
Cordn1=Cordn+(-2,)   # add z vertex to coordinates 
Cordn2=Cordn+(2,)   # add z vertex to coordinates
if not Cordn1 in Ver1:
Ver1=Ver1+(Cordn1,Cordn2)
ListVer1.append(Ver1)

RawVer2=np.genfromtxt('waste.txt',names=True,dtype=None)
# ListVer2 is list of all the vertices of caved waste rock`s polygons
Ver2=()
ListVer2=[]
for b in RawVer2:
if b[0]=='*LWPOLYLINE':
ListVer2.append(Ver2)
Ver2=()
continue
Cordn=b[0]
Cordn=np.fromstring(Cordn, sep=',')
Cordn=tuple(Cordn.tolist())
Cordn1=Cordn+(0.1,)   # add z vertex to coordinates 
Cordn2=Cordn+(0.2,)   # add z vertex to coordinates
if not Cordn1 in Ver2:
Ver2=Ver2+(Cordn1,Cordn2)
ListVer2.append(Ver2)


# Materials type:

Dolomite = PolyhedraMat()
Dolomite.density = 2870 #kg/m^3 
Dolomite.young = 24.36e9 #Pa 
Dolomite.poisson = 0.2
Dolomite.frictionAngle = radians(55.12) #rad

Shale = PolyhedraMat()
Shale.density = 2750 #kg/m^3 
Shale.young = 6e9 #Pa 
Shale.poisson = 0.23
Shale.frictionAngle = radians(42) #rad

for ii in ListVer:
O.bodies.append(polyhedra_utils.polyhedra(Dolomite,v=ii,fixed=False, 
color=(0.1,0.5,0.2), mask=3))

for iii in ListVer1:
O.bodies.append(polyhedra_utils.polyhedra(Dolomite,v=iii,fixed=True, 
color=(1,0,1), mask=4))

for  in ListVer2:
O.bodies.append(polyhedra_utils.polyhedra(Shale,v=,fixed=False, 
color=(0.9,0.81,0.45), mask=5))


O.bodies.erase(340)   # delete wall under ring: id: 340

# block z translation and block x, y, z rotations
for b in O.bodies:
if b.mask is 3:
b.state.blockedDOFs='zXY'
for b in O.bodies:
if b.mask is 5:
b.state.blockedDOFs='zXY'

# function for calming particles
def calm():
for c in O.bodies:
c.state.vel=Vector3(0,0,0)
c.state.angVel=Vector3(0,0,0)

# returns a value that can be useful for evaluating the stability of the 
packing. It is defined as (mean force on particles)/(mean contact force), so 
that it tends to 0 in a stable packing.
def checkUnbalanced():   
print "iter %d , unbalanced forces %f"%(O.iter, utils.unbalancedForce())  # 
%[(keyname)][flags][width][.precision]typecode : String Formatting  
iter00=O.iter

Unbalanced=open("Unbalanced iter Unbalanced forces.txt","a")
Unbalanced.write(repr(iter00)+' '+repr(utils.unbalancedForce())+'   
'+"\n")
Unbalanced.close()

# Engines:

#os.mkdir(O.tags['id'])   # Created separate directory and put all files
of VTK in it, till external files be seperate because of large
simulation.


O.engines=[
   ForceResetter(),
   InsertionSortCollider([Bo1_Polyhedra_Aabb(),]), # We can set collider's 
verletDist to a fraction of the polyhedra minimum size, since it determines how 
much is each body enlarged to avoid collision detection at every step.
   InteractionLoop(
  [Ig2_Polyhedra_Polyhedra_PolyhedraGeom(),], 
  [Ip2_PolyhedraMat_PolyhedraMat_PolyhedraPhys()], # collision "physics"
  [Law2_PolyhedraGeom_PolyhedraPhys_Volumetric()]   # contact law -- apply 
forces
   ),
   NewtonIntegrator(gravity=(0,-9.81,0),damping=0.2),
]

utils.calm()

# the model has to calm, because there are some overlaps in particles. 
O.engines=O.engines+[PyRunner(iterPe

[Yade-users] [Question #686970]: run yade in parallel

2019-12-12 Thread Mahdeyeh
New question #686970 on Yade:
https://answers.launchpad.net/yade/+question/686970

Hi everyone 
I want to run polyhedra particles in this computer:

CPU (Cores):16
2.3 Hz
Hard disc (HDD): 80 GB
Ram: 32 GB
ubuntu : 16.04
yade 1.20.0

number of bodies : 1511

for increasing speed in iterations per seconds and anything else, how many 
number of cores on the machine is better to use ? -j8   or -j12 or -j14 or -j16?

Thanks,
Mahdeyeh

-- 
You received this question notification because your team yade-users is
an answer contact for Yade.

___
Mailing list: https://launchpad.net/~yade-users
Post to : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


Re: [Yade-users] [Question #686446]: saving image of polyhedrals in paraview format

2019-12-12 Thread Mahdeyeh
Question #686446 on Yade changed:
https://answers.launchpad.net/yade/+question/686446

Status: Needs information => Solved

Mahdeyeh confirmed that the question is solved:
Thanks all , it solved

-- 
You received this question notification because your team yade-users is
an answer contact for Yade.

___
Mailing list: https://launchpad.net/~yade-users
Post to : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


Re: [Yade-users] [Question #686446]: saving image of polyhedrals in paraview format

2019-12-01 Thread Mahdeyeh
Question #686446 on Yade changed:
https://answers.launchpad.net/yade/+question/686446

Mahdeyeh gave more information on the question:
content of ri.txt:

*LWPOLYLINE
4.34559213436763,4.19563889421937
4.31042320818271,4.19563889421937
4.31042320818271,4.05445713776717
4.33341560779634,4.09083399031995
4.34559213436763,4.19563889421937
*LWPOLYLINE
4.03286380514289,4.43515523404666
4.17241407759840,4.43515523404666
4.22754503815440,4.36456304177393
4.03458661095554,4.31635372702571
3.96113997193621,4.31635372702571
4.03286380514289,4.43515523404666
*LWPOLYLINE
3.41971278690444,4.44366348237027
3.46320431378560,4.54994505088534
3.51343273075365,4.54994505088534
3.49728561797354,4.44366348237027
3.41971278690444,4.44366348237027
*LWPOLYLINE
4.25338987548479,9.19037679709093
4.25530578302851,9.26087198721953
4.29473955139678,9.29716228619832
4.45949178466789,9.29348909994814
4.45949178466789,9.27716014638961
4.42052364456134,9.19927290554726
4.25338987548479,9.19037679709093
*LWPOLYLINE
3.69430516443352,4.73783273957938
3.69430516443352,4.93182238931670
3.75625576954475,5.05564563793556
3.89787386380568,5.05564563793556
3.88841683538887,4.96484181584951
3.78929567430250,4.73783273957938
3.69430516443352,4.73783273957938


content of wa.txt:

*LWPOLYLINE
3.88376464353553,1.33800969242003
3.83751523200053,1.44820764004128
3.58728936915612,1.50080199767633
3.46538550372381,1.33429481921918
3.41389145499828,1.03535559574160
3.73344705537207,1.11568049675982
3.84774706442400,1.21264488864129
3.88376464353553,1.33800969242003
*LWPOLYLINE
3.23345566297171,0.52192032713330
3.27958743353576,0.74458543448110
3.44401021214259,0.78324840940373
3.23345566297171,0.52192032713330
*LWPOLYLINE
3.27937272637005,0.74453494745106
3.15506808053324,0.71530549733790
2.98498203374232,0.38894887153548
3.15154241501946,0.32440546898789
3.23317773197976,0.52156467644088
3.27937272637005,0.74453494745106
*LWPOLYLINE
3.34888179054002,0.32417690959650
3.15161168322698,0.32417690959650
2.92220949434164,0.25736425612108
2.93389111001614,0.05224953101619
3.00549399142725,0.000100
3.34888179054002,0.000100
3.34888179054002,0.32417690959650
*LWPOLYLINE
3.57679473408223,1.01790146152510
3.57679473408223,0.83456485024469
3.44421172347698,0.78360397581583
3.15527423779965,0.71566215621148
3.19601496840083,0.87852086403109
3.41369711466930,1.03487992070231
3.57679473408223,1.01790146152510
*LWPOLYLINE
3.86738813143966,0.58337060642318
3.83746323753791,0.84595222640707
3.73344146483806,1.11520040778873
3.57719473408223,1.01797061697598
3.57719473408223,0.83445564194878
3.66221469097450,0.53877534257427
3.86738813143966,0.58337060642318
*LWPOLYLINE
3.66196325599892,0.53856416977056
3.56332020100036,0.42298764735279
3.34895989235118,0.32437690959650
3.15174705630338,0.32437690959650
3.23336062877583,0.52148360146984
3.44433175430850,0.78332871413536
3.57692877684050,0.83429497432244
3.66196325599892,0.53856416977056
*LWPOLYLINE
3.66200050292966,0.42280599391862
3.56340387919622,0.42280599391862
3.34908179054002,0.32421283824984
3.34908179054002,0.000100
3.70621554064660,0.000100
3.70621554064660,0.28004870859782
3.66200050292966,0.42280599391862
*LWPOLYLINE
3.99847226107518,0.35938967395906
3.99847226107518,0.49250250795166
3.98265338055999,0.58366165149205
3.86761829926308,0.58311362967768
3.66217421731288,0.53845954082487
3.66217421731288,0.42292112543294
3.70638892102347,0.28016491851989
3.86623728143229,0.28249100841280
3.99847226107518,0.35938967395906
*LWPOLYLINE
4.02515441091265,0.28460352599531
4.02515441091265,0.000100
3.70641554064660,0.000100
3.70641554064660,0.27996528471022
4.02515441091265,0.28460352599531
*LWPOLYLINE
4.30413367924914,0.18964871156068
4.14673174306678,0.47513307236743
3.99869071915651,0.35929786155562
4.02534269858442,0.28475508939912
4.15266467969082,0.13013810552518
4.30413367924914,0.18964871156068
*LWPOLYLINE
4.54630602367677,0.33860146403383
4.30434112014817,0.18951980072554
4.25121355577861,0.12998034442008
4.25121355577861,0.000100
4.57188101771511,0.000100
4.54630602367677,0.33860146403383
*LWPOLYLINE
4.23893702920732,0.02521356962770
4.23600764623852,0.00
4.02525441091265,0.00
4.02525441091265,0.28470499176791
4.23893702920732,0.02521356962770
*LWPOLYLINE
4.54722317565999,0.34173497470129
4.18612100505811,0.54485821136444
4.14687710961946,0.47528364443020
4.30431312790843,0.18973746793899
4.54722317565999,0.34173497470129
*LWPOLYLINE
4.61136751993339,0.51437853423804
4.57329885211446,0.61220404001163
4.46750289343816,0.75785372203540
4.28885151333754,0.78952977027159
4.23675325130835,0.78952977027159
4.15620489702067,0.69246006924729
4.15657936559847,0.57364946371320
4.54849417296813,0.34276745307863
4.61136751993339,0.51437853423804
*LWPOLYLINE
4.23688450979664,0.78962942909311
4.28894388072864,0.78955511764699
4.31514645593306,0.93474249500317
4.23688450979664,0.78962942909311
*LWPOLYLINE
4.23661738714208,0.79009572683008

Re: [Yade-users] [Question #686446]: saving image of polyhedrals in paraview format

2019-12-01 Thread Mahdeyeh
Question #686446 on Yade changed:
https://answers.launchpad.net/yade/+question/686446

Status: Needs information => Open

Mahdeyeh gave more information on the question:
Here is my code:


from yade import export,polyhedra_utils
import os
from yade import plot
import math
from yade import utils
import pylab
import matplotlib; matplotlib.rc('axes',grid=True)
from matplotlib import pyplot
import numpy as np
from numpy import *



RawVer=np.genfromtxt('ri.txt',names=True,dtype=None)
# ListVer is list of all the vertices of ring`s polygons
Ver=()
ListVer=[]
for b in RawVer:
if b[0]=='*LWPOLYLINE':
ListVer.append(Ver)
Ver=()
continue
Cordn=b[0]
Cordn=np.fromstring(Cordn, sep=',')
Cordn=tuple(Cordn.tolist())
Cordn1=Cordn+(0.1,)   # add z vertex to coordinates 
Cordn2=Cordn+(0.2,)   # add z vertex to coordinates
if not Cordn1 in Ver:
Ver=Ver+(Cordn1,Cordn2)
ListVer.append(Ver)

RawVer1=np.genfromtxt('boundary.txt',names=True,dtype=None)
# ListVer is list of all the vertices of boundary`s polygons
Ver1=()
ListVer1=[]
for b in RawVer1:
if b[0]=='*LWPOLYLINE':
ListVer1.append(Ver1)
Ver1=()
continue
Cordn=b[0]
Cordn=np.fromstring(Cordn, sep=',')
Cordn=tuple(Cordn.tolist())
Cordn1=Cordn+(-2,)   # add z vertex to coordinates 
Cordn2=Cordn+(2,)   # add z vertex to coordinates
if not Cordn1 in Ver1:
Ver1=Ver1+(Cordn1,Cordn2)
ListVer1.append(Ver1)

RawVer2=np.genfromtxt('wa.txt',names=True,dtype=None)
# ListVer is list of all the vertices of caved waste rock`s polygons
Ver2=()
ListVer2=[]
for b in RawVer2:
if b[0]=='*LWPOLYLINE':
ListVer2.append(Ver2)
Ver2=()
continue
Cordn=b[0]
Cordn=np.fromstring(Cordn, sep=',')
Cordn=tuple(Cordn.tolist())
Cordn1=Cordn+(0.1,)   # add z vertex to coordinates 
Cordn2=Cordn+(0.2,)   # add z vertex to coordinates
if not Cordn1 in Ver2:
Ver2=Ver2+(Cordn1,Cordn2)
ListVer2.append(Ver2)


Dolomite = PolyhedraMat()
Dolomite.density = 2870 #kg/m^3 
Dolomite.young = 24.36e9 #Pa 
Dolomite.poisson = 0.2
Dolomite.frictionAngle = radians(55.12) #rad

Shale = PolyhedraMat()
Shale.density = 2750 #kg/m^3 
Shale.young = 6e9 #Pa 
Shale.poisson = 0.23
Shale.frictionAngle = radians(42) #rad

for ii in ListVer:
O.bodies.append(polyhedra_utils.polyhedra(Dolomite,v=ii,fixed=False, 
color=(0.1,0.5,0.2), mask=3))

for iii in ListVer1:
O.bodies.append(polyhedra_utils.polyhedra(Dolomite,v=iii,fixed=True, 
color=(1,0,1), mask=4))

for  in ListVer2:
O.bodies.append(polyhedra_utils.polyhedra(Shale,v=,fixed=False, 
color=(0.9,0.81,0.45), mask=5))



O.bodies.erase(12)   


 

def checkUnbalanced():   
print "iter %d , unbalanced forces %f"%(O.iter, utils.unbalancedForce())  # 
%[(keyname)][flags][width][.precision]typecode : String Formatting

O.engines=[
   ForceResetter(),
   InsertionSortCollider([Bo1_Polyhedra_Aabb(),]), # We can set collider's 
verletDist to a fraction of the polyhedra minimum size, since it determines how 
much is each body enlarged to avoid collision detection at every step.
   InteractionLoop(
  [Ig2_Polyhedra_Polyhedra_PolyhedraGeom(),], 
  [Ip2_PolyhedraMat_PolyhedraMat_PolyhedraPhys()], # collision "physics"
  [Law2_PolyhedraGeom_PolyhedraPhys_Volumetric()]   # contact law -- apply 
forces
   ),
   NewtonIntegrator(gravity=(0,-9.81,0),damping=0.2),
]

O.engines=O.engines+[PyRunner(iterPeriod=20,command='calm()',label="calmRunner")]
  #  because we need to calm only on the first few steps in our model.
O.engines=O.engines+[PyRunner(command='checkUnbalanced()',iterPeriod=1000,label="checker")]
  # call our function defined above 1000 cycles


polyhedra_utils.SizeRatio()# save sizes of polyhedra into file

export.textPolyhedra('poly.txt')   # Save polyhedra into a text file,
id, number of vertices and number of surfaces, particleVelocity and ...
.


clrOre=[0.1,0.5,0.2]
clrWaste=[0.9,0.81,0.45]


def positions():
for b in O.bodies:
if b.shape.color==clrOre:
print "%.9f  , %.9f , %.9f 
"%(b.state.pos[0],b.state.pos[1],b.state.pos[2])
time1=O.time

Positions=open("Positions time x y z.txt","a")
Positions.write(repr(time1)+'   '+repr(b.state.pos[0])+'
'+repr(b.state.pos[1])+''+repr(b.state.pos[2])+''"\n")
Positions.close() 


O.engines=O.engines+[PyRunner(command='positions()',realPeriod=0.5,label="flow")]
# call our function defined above every 60 seconds


O.dt=10e-6


iii=0
while iii<50:
O.run(1000,True)
iii+=1


O.save('test1.bz2')
O.saveTmp('test1')

-- 
You received this question notification because your team yade-users is
an answer contact for Yade.

___
Mailing list: https://launchpad.net/~yade-users
P

[Yade-users] [Question #686446]: saving image of polyhedrals in paraview format

2019-12-01 Thread Mahdeyeh
New question #686446 on Yade:
https://answers.launchpad.net/yade/+question/686446

Hi guys

I have some polyhedra particles, I want to save images of simulation in vtk and 
paraview format.
How I can do this ? 

Another my problem is, when I use vtkExporter :
"
 vtkExporter = export.VTKExporter('//home/mahdeyeh/test/vtkExporter') 
vtkExporter.exportPolyhedra('pos','b.state.pos') 
"

It shows this error:
"NameError: global name 'exportPolyhedra' is not defined "

why? I write "from yade import export,polyhedra_utils" at the beginning of code.

Thanks for your time


Yade 2018.02b 


-- 
You received this question notification because your team yade-users is
an answer contact for Yade.

___
Mailing list: https://launchpad.net/~yade-users
Post to : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


Re: [Yade-users] [Question #685405]: Error in running code in YADE 2019.01a-2

2019-10-25 Thread Mahdeyeh
Question #685405 on Yade changed:
https://answers.launchpad.net/yade/+question/685405

Mahdeyeh posted a new comment:
Dear Jan
With disabled GUI (yade -n script.py), runnig code has not error.

Now what should I do?

Best regards,
Mahdeyeh

-- 
You received this question notification because your team yade-users is
an answer contact for Yade.

___
Mailing list: https://launchpad.net/~yade-users
Post to : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


Re: [Yade-users] [Question #685405]: Error in running code in YADE 2019.01a-2

2019-10-25 Thread Mahdeyeh
Question #685405 on Yade changed:
https://answers.launchpad.net/yade/+question/685405

Mahdeyeh posted a new comment:
Hi Jan

 It is:

Linux version 5.0.0-32-generic (buildd@lgw01-amd64-034) (gcc version
8.3.0 (Ubuntu 8.3.0-6ubuntu1)) #34-Ubuntu SMP Wed Oct 2 02:06:48 UTC
2019

Linux 5.0.0-32-generic x86_64
Distributor ID: Ubuntu
Description:Ubuntu 19.04
Release:19.04
Codename:   disco
VERSION="19.04 (Disco Dingo)"

-- 
You received this question notification because your team yade-users is
an answer contact for Yade.

___
Mailing list: https://launchpad.net/~yade-users
Post to : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


[Yade-users] [Question #685405]: Error in running code in YADE 2019.01a-2

2019-10-25 Thread Mahdeyeh
New question #685405 on Yade:
https://answers.launchpad.net/yade/+question/685405

Hello guys,

I recently I have installed YADE 2019.01a-2. So I put my previous codes to run 
them. The codes run correctly in YADE 2018.02b But I see the following error 
when running them in YADE 2019.01a-2:

Welcome to Yade 2019.01a 
TCP python prompt on localhost:9000, auth cookie `usdska'
XMLRPC info provider on http://localhost:21000
Running script poly4.py
Traceback (most recent call last):
  File "/usr/bin/yade", line 241, in runScript
execfile(script,globals())
  File "poly4.py", line 4, in 
RawVer=np.genfromtxt('ring.txt',names=True,dtype=None)
  File "/usr/lib/python2.7/dist-packages/numpy/lib/npyio.py", line 1798, in 
genfromtxt
names = validate_names(names)
  File "/usr/lib/python2.7/dist-packages/numpy/lib/_iotools.py", line 425, in 
__call__
return self.validate(names, defaultfmt=defaultfmt, nbfields=nbfields)
  File "/usr/lib/python2.7/dist-packages/numpy/lib/_iotools.py", line 402, in 
validate
for item in names:
TypeError: 'QCborSimpleType' object is not iterable
[[ ^L clears screen, ^U kills line. F12 controller, F11 3d view (use h-key for 
showing help), F10 both, F9 generator, F8 plot. ]]


Why is this happening? please help

My codes are here:
https://answers.launchpad.net/yade/+question/685203

Best regards,
Mahdeyeh 

-- 
You received this question notification because your team yade-users is
an answer contact for Yade.

___
Mailing list: https://launchpad.net/~yade-users
Post to : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


Re: [Yade-users] [Question #685203]: problem in moving particles and existence of weight force on each particle

2019-10-16 Thread Mahdeyeh
Question #685203 on Yade changed:
https://answers.launchpad.net/yade/+question/685203

Status: Answered => Solved

Mahdeyeh confirmed that the question is solved:
Thanks Jan Stránský, that solved my question.

-- 
You received this question notification because your team yade-users is
an answer contact for Yade.

___
Mailing list: https://launchpad.net/~yade-users
Post to : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


Re: [Yade-users] [Question #685203]: problem in moving particles and existence of weight force on each particle

2019-10-16 Thread Mahdeyeh
Question #685203 on Yade changed:
https://answers.launchpad.net/yade/+question/685203

Mahdeyeh posted a new comment:
Dear Jan and Bruno

Same as all the time, you guys are the best.
Thank you very much.

Best regards,
Mahdeyeh

-- 
You received this question notification because your team yade-users is
an answer contact for Yade.

___
Mailing list: https://launchpad.net/~yade-users
Post to : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


Re: [Yade-users] [Question #685203]: problem in moving particles and existence of weight force on each particle

2019-10-16 Thread Mahdeyeh
Question #685203 on Yade changed:
https://answers.launchpad.net/yade/+question/685203

Mahdeyeh posted a new comment:
Thank you all for reply.

Dear Jan

> no need to sorry, thanks for following our instructions [1] :-)
I try my best but for following your instructins, but you know sometimes does 
not work! believe this! ;-)

> How do you know that "no force is applied on them"?
I check forces on bodies in simulation inspect window. before touching the 
ground, non of particles do not have force.

> it is a free fall. Do you want them to behave differently? Why? How?
why a particle (for example) which is on a side and is completely free, does 
not fall freely? apart of the others? 

>  - time step of the simulation is low
If I increase time step, model will explode. (I checked! Particles do not have 
overlap.)

>  Better idea is to increase time step for the phase with no collisions.
I do not understand your mean about the phase with no collisions (I am an 
amateur) ! When should increase time step? 

I really appreciate your kindness Jan.

Best regards,
Mahdeyeh

-- 
You received this question notification because your team yade-users is
an answer contact for Yade.

___
Mailing list: https://launchpad.net/~yade-users
Post to : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


Re: [Yade-users] [Question #685203]: problem in moving particles and existence of weight force on each particle

2019-10-15 Thread Mahdeyeh
Question #685203 on Yade changed:
https://answers.launchpad.net/yade/+question/685203

Description changed to:
Hello everyone
I have modeled some polyhedrons in space that have to move downwards due to 
gravity and then hit the floor and stop and place like a pile on ground.

I have some problem:
1- When the polyhedrons are coming down, no force is applied on them! why? Must 
be weight force on all the particles.
2- All the particles move down same as a block, non of them act lonely, even 
those particles that are on the sides and are completely free to fall down.
3- Particles move down very very very slow! Why? For saving time, when the 
particles are moving down, I increase the gravity to 10 (with simulation 
inspect window) for fast movement and when they are near the ground, I set real 
gravity. But when the  lower particles reach the ground  the whole particles 
stop moving and nothing happens! they have to place in form of a pile.

Thanks for your patient

Best regards,
Mahdeyeh

'ring.txt' is in first comment.  I really sorry for putting all of the 
coordinates! it is necessary.
My YADE version: 2018.02b

Here is the codes:

import numpy as np
from numpy import *

RawVer=np.genfromtxt('ring.txt',names=True,dtype=None)
# ListVer is list of all the vertices of ring`s polygons
Ver=()
ListVer=[]
for b in RawVer:
if b[0]=='*LWPOLYLINE':
ListVer.append(Ver)
Ver=()
continue
Cordn=b[0]
Cordn=np.fromstring(Cordn, sep=',')
Cordn=tuple(Cordn.tolist())
Cordn1=Cordn+(0.1,)   # add z vertex to coordinates 
Cordn2=Cordn+(0.2,)   # add z vertex to coordinates
if not Cordn1 in Ver:
Ver=Ver+(Cordn1,Cordn2)
ListVer.append(Ver)

RawVer1=np.genfromtxt('boundary.txt',names=True,dtype=None)
Ver1=()
ListVer1=[]
for b in RawVer1:
if b[0]=='*LWPOLYLINE':
ListVer1.append(Ver1)
Ver1=()
continue
Cordn=b[0]
Cordn=np.fromstring(Cordn, sep=',')
Cordn=tuple(Cordn.tolist())
Cordn1=Cordn+(-2,)   # add z vertex to coordinates 
Cordn2=Cordn+(2,)   # add z vertex to coordinates
if not Cordn1 in Ver1:
Ver1=Ver1+(Cordn1,Cordn2)
ListVer1.append(Ver1)

from yade import plot, polyhedra_utils


Dolomite = PolyhedraMat()
Dolomite.density = 2870 #kg/m^3 
Dolomite.young = 24.36e9 #Pa 
Dolomite.poisson = 0.2
Dolomite.frictionAngle = radians(55.12) #rad


for ii in ListVer:
O.bodies.append(polyhedra_utils.polyhedra(Dolomite,v=ii,fixed=False, 
color=(0.1,0.5,0.2), mask=3))

for iii in ListVer1:
O.bodies.append(polyhedra_utils.polyhedra(Dolomite,v=iii,fixed=True, 
color=(1,1,1), mask=4))

O.bodies.erase(341)   # delete wall under ring: id: 341
 
def checkUnbalancedI():   
print "iter %d , unbalanced forces %f"%(O.iter, utils.unbalancedForce())  # 
%[(keyname)][flags][width][.precision]typecode : String Formatting  

O.engines=[
   ForceResetter(),
   InsertionSortCollider([Bo1_Polyhedra_Aabb(),]), # We can set collider's 
verletDist to a fraction of the polyhedra minimum size, since it determines how 
much is each body enlarged to avoid collision detection at every step.
   InteractionLoop(
  [Ig2_Polyhedra_Polyhedra_PolyhedraGeom(),], 
  [Ip2_PolyhedraMat_PolyhedraMat_PolyhedraPhys()], # collision "physics"
  [Law2_PolyhedraGeom_PolyhedraPhys_Volumetric()]   # contact law -- apply 
forces
   ),
   NewtonIntegrator(gravity=(0,-9.81,0),damping=0.2),
   
PyRunner(command='checkUnbalancedI()',iterPeriod=1000,realPeriod=3600,label='checker')
 # call our function defined above every 3600 second or 500 cycles
]

O.engines=O.engines+[PyRunner(iterPeriod=20,command='calm()',label="calmRunner")]
#  because we need to calm only on the first few steps in our model.

O.dt=10e-6

iii=0
while iii<50:
O.run(1000,True)
for b in O.bodies:
x,y,z=b.state.pos[0],b.state.pos[1],b.state.pos[2]
print x,y,z
iii+=1


here is the boundary.txt:

*LWPOLYLINE
4.08255289437355,10.09276250439400
4.08255289437355,10.09267857306840
1.10586584671010,10.07329237103019
1.10586584671010,10.09157421969086
4.08255289437355,10.09276250439400
*LWPOLYLINE
2.8810347806,4.0313063418
2.9580536406,4.0313063418
4.08257892143658,10.09266327552933
4.08255971098529,10.09266327552933
2.8810347806,4.0313063418
*LWPOLYLINE
2.9775296742,4.0184118644
2.9775296742,3.9621450540
0.1072960445,3.9621450540
0.1072960445,4.0143090761
2.9775296742,4.0184118644
*LWPOLYLINE
0.1072960445,-0.00101851609184
0.1072960445,-0.00102332221523
6.73102849650382,-0.00102332221523
6.73102672595532,-0.00101804720175
0.1072960445,-0.00101851609184
*LWPOLYLINE
6.73102610626334,-0.00101628886392
6.73103044410717,-0.00101628886392
6.74417862583885,3.9123254822
6.74373784778834,3.9123254822
6.73102610626334,-0.00101628886392
*LWPOLYLINE
6.74054678821628,3.01646737237143
6.74054678821628,3.01622648008920
4.57127199826347,-

Re: [Yade-users] [Question #685203]: problem in moving particles and existence of weight force on each particle

2019-10-15 Thread Mahdeyeh
Question #685203 on Yade changed:
https://answers.launchpad.net/yade/+question/685203

Mahdeyeh posted a new comment:
*LWPOLYLINE
4.34559213436763,4.19563889421937
4.31042320818271,4.19563889421937
4.31042320818271,4.05445713776717
4.33341560779634,4.09083399031995
4.34559213436763,4.19563889421937
*LWPOLYLINE
4.03286380514289,4.43515523404666
4.17241407759840,4.43515523404666
4.22754503815440,4.36456304177393
4.03458661095554,4.31635372702571
3.96113997193621,4.31635372702571
4.03286380514289,4.43515523404666
*LWPOLYLINE
3.41971278690444,4.44366348237027
3.46320431378560,4.54994505088534
3.51343273075365,4.54994505088534
3.49728561797354,4.44366348237027
3.41971278690444,4.44366348237027
*LWPOLYLINE
4.25338987548479,9.19037679709093
4.25530578302851,9.26087198721953
4.29473955139678,9.29716228619832
4.45949178466789,9.29348909994814
4.45949178466789,9.27716014638961
4.42052364456134,9.19927290554726
4.25338987548479,9.19037679709093
*LWPOLYLINE
3.69430516443352,4.73783273957938
3.69430516443352,4.93182238931670
3.75625576954475,5.05564563793556
3.89787386380568,5.05564563793556
3.88841683538887,4.96484181584951
3.78929567430250,4.73783273957938
3.69430516443352,4.73783273957938
*LWPOLYLINE
5.5339642790,15.49527006744998
5.5339642790,15.68925971718730
5.59591488411124,15.81308296580616
5.67025551379046,15.81308296580616
5.62895478886898,15.49527006744998
5.5339642790,15.49527006744998
*LWPOLYLINE
3.20299113285824,4.55255886035707
3.20299113285824,4.93021944934796
3.34547762106828,5.14690997478260
3.48796338587174,5.14690997478260
3.48796338587174,4.97355774601286
3.39503820161146,4.70114675869974
3.20299113285824,4.55255886035707
*LWPOLYLINE
4.40033164375299,11.47918173746368
4.40033164375299,11.77016621206965
4.49325755141984,11.95590108499795
4.60476849593868,11.95590108499795
4.69149915018601,11.81969535186886
4.54281740855645,11.47918173746368
4.40033164375299,11.47918173746368
*LWPOLYLINE
4.92835616942645,14.39892740389717
4.92835616942645,14.68991187850315
5.02745009112680,14.87564675143145
5.21952367585947,14.73944101830236
5.07084193422991,14.39892740389717
4.92835616942645,14.39892740389717
*LWPOLYLINE
4.76583929759431,12.17259161043259
4.93810928058494,12.21481160990587
4.93810928058494,12.49134998562354
4.76583929759431,12.37070864857438
4.76583929759431,12.17259161043259
*LWPOLYLINE
4.76583929759431,12.37070864857438
4.93810928058494,12.49134998562354
4.76583929759431,12.56707237574099
4.76583929759431,12.37070864857438
*LWPOLYLINE
5.05140345699413,13.55539214235956
5.19530151763249,13.54741637776422
5.19530151763249,13.35342672802690
4.98403958777313,13.35342672802690
5.05140345699413,13.55539214235956
*LWPOLYLINE
5.17688563744608,15.18217349138459
5.41992349477189,15.09903599116629
5.43897328685997,15.35080971716022
5.31312497422737,15.41980884297518
5.22597011377383,15.41980884297518
5.17688563744608,15.18217349138459
*LWPOLYLINE
5.33812779458054,16.06433022160302
5.59591488411124,15.96167054485207
5.59591488411124,15.81308296580616
5.28623172820394,15.81308296580616
5.33812779458054,16.06433022160302
*LWPOLYLINE
3.06673351232743,4.22418949519609
3.00013404299333,4.000100
3.16572105915418,4.000100
3.16572105915418,4.06961939379889
3.06673351232743,4.22418949519609
*LWPOLYLINE
3.35770133484718,4.29249050036819
3.17824277381659,4.36670256960470
3.06682236486762,4.22442160490961
3.16583289976637,4.06981560739483
3.35770133484718,4.29249050036819
*LWPOLYLINE
3.43011808355378,4.06593223135340
3.39084723934804,4.07699751859220
3.38071884232678,4.00643552972899
3.41542145425865,4.00011560382660
3.43011808355378,4.06593223135340
*LWPOLYLINE
3.38051913835552,4.00645187280320
3.40430821630287,4.17218438207034
3.25430323997346,4.17218438207034
3.16592105915418,4.06961152975933
3.16592105915418,4.00010300224751
3.38051913835552,4.00645187280320
*LWPOLYLINE
3.41574768786674,4.000200
3.57524253047781,4.000200
3.57433683722952,4.01959574635174
3.50834393332176,4.12264436383462
3.45514758592311,4.12264436383462
3.43042731558429,4.06594048853765
3.41574768786674,4.000200
*LWPOLYLINE
3.45501659733433,4.12294436383463
3.45201954297334,4.20837990029655
3.47675055671419,4.26501931536194
3.58263633031453,4.21773629486176
3.50840464554390,4.12294436383463
3.45501659733433,4.12294436383463
*LWPOLYLINE
3.47679327806629,4.26521927291669
3.47267017425437,4.30848453800663
3.48916262901855,4.38957344721923
3.59920508210586,4.34153717137189
3.58271255521886,4.21792129149123
3.47679327806629,4.26521927291669
*LWPOLYLINE
3.57565297112033,4.000100
3.79991550127291,4.000100
3.82399339809358,4.14237807307012
3.70260647263054,4.16813509299964
3.57565297112033,4.000100
*LWPOLYLINE
3.80011834497802,4.000100
3.94090229521068,4.000100
3.96562654968141,4.04610500259990
3.89326360520934,4.14235598124846
3.82419250317199,4.14235598124846
3.80011834497802,4.000100
*LWPOLYLINE
3.8934542942,4.14243516156663

Re: [Yade-users] [Question #685203]: problem in moving particles and existence of weight force on each particle

2019-10-15 Thread Mahdeyeh
Question #685203 on Yade changed:
https://answers.launchpad.net/yade/+question/685203

Description changed to:
Hello everyone
I have modeled some polyhedrons in space that have to move downwards due to 
gravity and then hit the floor and stop and place like a pile on ground.

I have some problem:
1- When the polyhedrons are coming down, no force is applied on them! why? Must 
be weight force on all the particles.
2- All the particles move down same as a block, non of them act lonely, even 
those particles that are on the sides and are completely free to fall down.
3- Particles move down very very very slow! Why? For saving time, when the 
particles are moving down, I increase the gravity to 10 (with simulation 
inspect window) for fast movement and when they are near the ground, I set real 
gravity. But when the  lower particles reach the ground  the whole particles 
stop moving and nothing happens! they have to place in form of a pile.

Thanks for your patient

Best regards,
Mahdeyeh

'ring.txt' is in first comment. 
My YADE version: 2018.02b

Here is the codes:

import numpy as np
from numpy import *

RawVer=np.genfromtxt('ring.txt',names=True,dtype=None)
# ListVer is list of all the vertices of ring`s polygons
Ver=()
ListVer=[]
for b in RawVer:
if b[0]=='*LWPOLYLINE':
ListVer.append(Ver)
Ver=()
continue
Cordn=b[0]
Cordn=np.fromstring(Cordn, sep=',')
Cordn=tuple(Cordn.tolist())
Cordn1=Cordn+(0.1,)   # add z vertex to coordinates 
Cordn2=Cordn+(0.2,)   # add z vertex to coordinates
if not Cordn1 in Ver:
Ver=Ver+(Cordn1,Cordn2)
ListVer.append(Ver)

RawVer1=np.genfromtxt('boundary.txt',names=True,dtype=None)
Ver1=()
ListVer1=[]
for b in RawVer1:
if b[0]=='*LWPOLYLINE':
ListVer1.append(Ver1)
Ver1=()
continue
Cordn=b[0]
Cordn=np.fromstring(Cordn, sep=',')
Cordn=tuple(Cordn.tolist())
Cordn1=Cordn+(-2,)   # add z vertex to coordinates 
Cordn2=Cordn+(2,)   # add z vertex to coordinates
if not Cordn1 in Ver1:
Ver1=Ver1+(Cordn1,Cordn2)
ListVer1.append(Ver1)

from yade import plot, polyhedra_utils


Dolomite = PolyhedraMat()
Dolomite.density = 2870 #kg/m^3 
Dolomite.young = 24.36e9 #Pa 
Dolomite.poisson = 0.2
Dolomite.frictionAngle = radians(55.12) #rad


for ii in ListVer:
O.bodies.append(polyhedra_utils.polyhedra(Dolomite,v=ii,fixed=False, 
color=(0.1,0.5,0.2), mask=3))

for iii in ListVer1:
O.bodies.append(polyhedra_utils.polyhedra(Dolomite,v=iii,fixed=True, 
color=(1,1,1), mask=4))

O.bodies.erase(341)   # delete wall under ring: id: 341
 
def checkUnbalancedI():   
print "iter %d , unbalanced forces %f"%(O.iter, utils.unbalancedForce())  # 
%[(keyname)][flags][width][.precision]typecode : String Formatting  

O.engines=[
   ForceResetter(),
   InsertionSortCollider([Bo1_Polyhedra_Aabb(),]), # We can set collider's 
verletDist to a fraction of the polyhedra minimum size, since it determines how 
much is each body enlarged to avoid collision detection at every step.
   InteractionLoop(
  [Ig2_Polyhedra_Polyhedra_PolyhedraGeom(),], 
  [Ip2_PolyhedraMat_PolyhedraMat_PolyhedraPhys()], # collision "physics"
  [Law2_PolyhedraGeom_PolyhedraPhys_Volumetric()]   # contact law -- apply 
forces
   ),
   NewtonIntegrator(gravity=(0,-9.81,0),damping=0.2),
   
PyRunner(command='checkUnbalancedI()',iterPeriod=1000,realPeriod=3600,label='checker')
 # call our function defined above every 3600 second or 500 cycles
]

O.engines=O.engines+[PyRunner(iterPeriod=20,command='calm()',label="calmRunner")]
#  because we need to calm only on the first few steps in our model.

O.dt=10e-6

iii=0
while iii<50:
O.run(1000,True)
for b in O.bodies:
x,y,z=b.state.pos[0],b.state.pos[1],b.state.pos[2]
print x,y,z
iii+=1


here is the boundary.txt:

*LWPOLYLINE
4.08255289437355,10.09276250439400
4.08255289437355,10.09267857306840
1.10586584671010,10.07329237103019
1.10586584671010,10.09157421969086
4.08255289437355,10.09276250439400
*LWPOLYLINE
2.8810347806,4.0313063418
2.9580536406,4.0313063418
4.08257892143658,10.09266327552933
4.08255971098529,10.09266327552933
2.8810347806,4.0313063418
*LWPOLYLINE
2.9775296742,4.0184118644
2.9775296742,3.9621450540
0.1072960445,3.9621450540
0.1072960445,4.0143090761
2.9775296742,4.0184118644
*LWPOLYLINE
0.1072960445,-0.00101851609184
0.1072960445,-0.00102332221523
6.73102849650382,-0.00102332221523
6.73102672595532,-0.00101804720175
0.1072960445,-0.00101851609184
*LWPOLYLINE
6.73102610626334,-0.00101628886392
6.73103044410717,-0.00101628886392
6.74417862583885,3.9123254822
6.74373784778834,3.9123254822
6.73102610626334,-0.00101628886392
*LWPOLYLINE
6.74054678821628,3.01646737237143
6.74054678821628,3.01622648008920
4.57127199826347,-0.00101605441888
4.57126509312429,-0.00101605441888
6.7405467882

Re: [Yade-users] [Question #685203]: problem in moving particles and existence of weight force on each particle

2019-10-15 Thread Mahdeyeh
Question #685203 on Yade changed:
https://answers.launchpad.net/yade/+question/685203

Description changed to:
Hello everyone
I have modeled some polyhedrons in space that have to move downwards due to 
gravity and then hit the floor and stop and place like a pile on ground.

I have some problem:
1- When the polyhedrons are coming down, no force is applied on them! why? Must 
be weight force on all the particles.
2- All the particles move down same as a block, non of them act lonely, even 
those particles that are on the sides and are completely free to fall down.
3- Particles move down very very very slow! Why? For saving time, when the 
particles are moving down, I increase the gravity to 10 (with simulation 
inspect window) for fast movement and when they are near the ground, I set real 
gravity. But when the  lower particles reach the ground  the whole particles 
stop moving and nothing happens! they have to place in form of a pile.

Thanks for your patient

Best regards,
Mahdeyeh

'ring.txt' is in first comment. 
My YADE version: 2018.02b

Here is the codes:

import numpy as np
from numpy import *

RawVer=np.genfromtxt('ring.txt',names=True,dtype=None)
# ListVer is list of all the vertices of ring`s polygons
Ver=()
ListVer=[]
for b in RawVer:
if b[0]=='*LWPOLYLINE':
ListVer.append(Ver)
Ver=()
continue
Cordn=b[0]
Cordn=np.fromstring(Cordn, sep=',')
Cordn=tuple(Cordn.tolist())
Cordn1=Cordn+(0.1,)   # add z vertex to coordinates 
Cordn2=Cordn+(0.2,)   # add z vertex to coordinates
if not Cordn1 in Ver:
Ver=Ver+(Cordn1,Cordn2)
ListVer.append(Ver)

RawVer1=np.genfromtxt('boundary.txt',names=True,dtype=None)
Ver1=()
ListVer1=[]
for b in RawVer1:
if b[0]=='*LWPOLYLINE':
ListVer1.append(Ver1)
Ver1=()
continue
Cordn=b[0]
Cordn=np.fromstring(Cordn, sep=',')
Cordn=tuple(Cordn.tolist())
Cordn1=Cordn+(-2,)   # add z vertex to coordinates 
Cordn2=Cordn+(2,)   # add z vertex to coordinates
if not Cordn1 in Ver1:
Ver1=Ver1+(Cordn1,Cordn2)
ListVer1.append(Ver1)

from yade import plot, polyhedra_utils


Dolomite = PolyhedraMat()
Dolomite.density = 2870 #kg/m^3 
Dolomite.young = 24.36e9 #Pa 
Dolomite.poisson = 0.2
Dolomite.frictionAngle = radians(55.12) #rad


for ii in ListVer:
O.bodies.append(polyhedra_utils.polyhedra(Dolomite,v=ii,fixed=False, 
color=(0.1,0.5,0.2), mask=3))

for iii in ListVer1:
O.bodies.append(polyhedra_utils.polyhedra(Dolomite,v=iii,fixed=True, 
color=(1,1,1), mask=4))

O.bodies.erase(341)   # delete wall under ring: id: 341
 
def checkUnbalancedI():   
print "iter %d , unbalanced forces %f"%(O.iter, utils.unbalancedForce())  # 
%[(keyname)][flags][width][.precision]typecode : String Formatting  

O.engines=[
   ForceResetter(),
   InsertionSortCollider([Bo1_Polyhedra_Aabb(),]), # We can set collider's 
verletDist to a fraction of the polyhedra minimum size, since it determines how 
much is each body enlarged to avoid collision detection at every step.
   InteractionLoop(
  [Ig2_Polyhedra_Polyhedra_PolyhedraGeom(),], 
  [Ip2_PolyhedraMat_PolyhedraMat_PolyhedraPhys()], # collision "physics"
  [Law2_PolyhedraGeom_PolyhedraPhys_Volumetric()]   # contact law -- apply 
forces
   ),
   NewtonIntegrator(gravity=(0,-9.81,0),damping=0.2),
   
PyRunner(command='checkUnbalancedI()',iterPeriod=1000,realPeriod=3600,label='checker')
 # call our function defined above every 3600 second or 500 cycles
]

O.engines=O.engines+[PyRunner(iterPeriod=20,command='calm()',label="calmRunner")]
#  because we need to calm only on the first few steps in our model.

O.dt=10e-6

iii=0
while iii<50:
O.run(1000,True)
for b in O.bodies:
x,y,z=b.state.pos[0],b.state.pos[1],b.state.pos[2]
print x,y,z
iii+=1


here is the boundary.txt:

*LWPOLYLINE
4.08255289437355,10.09276250439400
4.08255289437355,10.09267857306840
1.10586584671010,10.07329237103019
1.10586584671010,10.09157421969086
4.08255289437355,10.09276250439400
*LWPOLYLINE
2.8810347806,4.0313063418
2.9580536406,4.0313063418
4.08257892143658,10.09266327552933
4.08255971098529,10.09266327552933
2.8810347806,4.0313063418
*LWPOLYLINE
2.9775296742,4.0184118644
2.9775296742,3.9621450540
0.1072960445,3.9621450540
0.1072960445,4.0143090761
2.9775296742,4.0184118644
*LWPOLYLINE
0.1072960445,-0.00101851609184
0.1072960445,-0.00102332221523
6.73102849650382,-0.00102332221523
6.73102672595532,-0.00101804720175
0.1072960445,-0.00101851609184
*LWPOLYLINE
6.73102610626334,-0.00101628886392
6.73103044410717,-0.00101628886392
6.74417862583885,3.9123254822
6.74373784778834,3.9123254822
6.73102610626334,-0.00101628886392
*LWPOLYLINE
6.74054678821628,3.01646737237143
6.74054678821628,3.01622648008920
4.57127199826347,-0.00101605441888
4.57126509312429,-0.00101605441888
6.7405467882

[Yade-users] [Question #685203]: problem in moving particles and existence of weight force on each particle

2019-10-15 Thread Mahdeyeh
New question #685203 on Yade:
https://answers.launchpad.net/yade/+question/685203

Hello everyone
I have modeled some polyhedrons in space that have to move downwards due to 
gravity and then hit the floor and stop and place like a pile on ground.

I have some problem:
1- When the polyhedrons are coming down, no force is applied on them! why? Must 
be weight force on all the particles.
2- All the particles move down same as a block, non of them act lonely, even 
those particles that are on the sides and are completely free to fall down.
3- Particles move down very very very slow! Why? For saving time, when the 
particles are moving down, I increase the gravity to 10 (with simulation 
inspect window) for fast movement and when they are near the ground, I set real 
gravity. But when the  lower particles reach the ground  the whole particles 
stop moving and nothing happens! they have to place in form of a pile.

Thanks for your patient

Best regards,
Mahdeyeh

'ring.txt' is in first comment. 

Here is the codes:

import numpy as np
from numpy import *

RawVer=np.genfromtxt('ring.txt',names=True,dtype=None)
# ListVer is list of all the vertices of ring`s polygons
Ver=()
ListVer=[]
for b in RawVer:
if b[0]=='*LWPOLYLINE':
ListVer.append(Ver)
Ver=()
continue
Cordn=b[0]
Cordn=np.fromstring(Cordn, sep=',')
Cordn=tuple(Cordn.tolist())
Cordn1=Cordn+(0.1,)   # add z vertex to coordinates 
Cordn2=Cordn+(0.2,)   # add z vertex to coordinates
if not Cordn1 in Ver:
Ver=Ver+(Cordn1,Cordn2)
ListVer.append(Ver)

RawVer1=np.genfromtxt('boundary.txt',names=True,dtype=None)
# ListVer is list of all the vertices of boundary`s polygons
Ver1=()
ListVer1=[]
for b in RawVer1:
if b[0]=='*LWPOLYLINE':
ListVer1.append(Ver1)
Ver1=()
continue
Cordn=b[0]
Cordn=np.fromstring(Cordn, sep=',')
Cordn=tuple(Cordn.tolist())
Cordn1=Cordn+(-2,)   # add z vertex to coordinates 
Cordn2=Cordn+(2,)   # add z vertex to coordinates
if not Cordn1 in Ver1:
Ver1=Ver1+(Cordn1,Cordn2)
ListVer1.append(Ver1)

from yade import plot, polyhedra_utils


Dolomite = PolyhedraMat()
Dolomite.density = 2870 #kg/m^3 
Dolomite.young = 24.36e9 #Pa 
Dolomite.poisson = 0.2
Dolomite.frictionAngle = radians(55.12) #rad



for ii in ListVer:
O.bodies.append(polyhedra_utils.polyhedra(Dolomite,v=ii,fixed=False, 
color=(0.1,0.5,0.2), mask=3))

for iii in ListVer1:
O.bodies.append(polyhedra_utils.polyhedra(Dolomite,v=iii,fixed=True, 
color=(1,1,1), mask=4))

O.bodies.erase(341)   # delete wall under ring: id: 341
   
# returns a value that can be useful for evaluating the stability of the 
packing. It is defined as (mean force on particles)/(mean contact force), so 
that it tends to 0 in a stable packing.
def checkUnbalancedI():   
print "iter %d , unbalanced forces %f"%(O.iter, utils.unbalancedForce())  # 
%[(keyname)][flags][width][.precision]typecode : String Formatting  

O.engines=[
   ForceResetter(),
   InsertionSortCollider([Bo1_Polyhedra_Aabb(),]), # We can set collider's 
verletDist to a fraction of the polyhedra minimum size, since it determines how 
much is each body enlarged to avoid collision detection at every step.
   InteractionLoop(
  [Ig2_Polyhedra_Polyhedra_PolyhedraGeom(),], 
  [Ip2_PolyhedraMat_PolyhedraMat_PolyhedraPhys()], # collision "physics"
  [Law2_PolyhedraGeom_PolyhedraPhys_Volumetric()]   # contact law -- apply 
forces
   ),
   NewtonIntegrator(gravity=(0,-9.81,0),damping=0.2),
   
PyRunner(command='checkUnbalancedI()',iterPeriod=1000,realPeriod=3600,label='checker')
 # call our function defined above every 3600 second or 500 cycles
]

# the model has to calm, because there are some overlaps in particles. 
O.engines=O.engines+[PyRunner(iterPeriod=20,command='calm()',label="calmRunner")]
  #  because we need to calm only on the first few steps in our model.

O.dt=10e-6

iii=0
while iii<50:
O.run(1000,True)
for b in O.bodies:
x,y,z=b.state.pos[0],b.state.pos[1],b.state.pos[2]
print x,y,z
iii+=1



here is the boundary.txt:

*LWPOLYLINE
4.08255289437355,10.09276250439400
4.08255289437355,10.09267857306840
1.10586584671010,10.07329237103019
1.10586584671010,10.09157421969086
4.08255289437355,10.09276250439400
*LWPOLYLINE
2.8810347806,4.0313063418
2.9580536406,4.0313063418
4.08257892143658,10.09266327552933
4.08255971098529,10.09266327552933
2.8810347806,4.0313063418
*LWPOLYLINE
2.9775296742,4.0184118644
2.9775296742,3.9621450540
0.1072960445,3.9621450540
0.1072960445,4.0143090761
2.9775296742,4.0184118644
*LWPOLYLINE
0.1072960445,-0.00101851609184
0.1072960445,-0.00102332221523
6.73102849650382,-0.00102332221523
6.73102672595532,-0.00101804720175
0.1072960445,-0.00101851609184
*LWPOLYLINE
6.73102610626334,-0.00101628886392
6.73103044410717,-0.00101628886392

Re: [Yade-users] [Question #685203]: problem in moving particles and existence of weight force on each particle

2019-10-15 Thread Mahdeyeh
Question #685203 on Yade changed:
https://answers.launchpad.net/yade/+question/685203

Description changed to:
Hello everyone
I have modeled some polyhedrons in space that have to move downwards due to 
gravity and then hit the floor and stop and place like a pile on ground.

I have some problem:
1- When the polyhedrons are coming down, no force is applied on them! why? Must 
be weight force on all the particles.
2- All the particles move down same as a block, non of them act lonely, even 
those particles that are on the sides and are completely free to fall down.
3- Particles move down very very very slow! Why? For saving time, when the 
particles are moving down, I increase the gravity to 10 (with simulation 
inspect window) for fast movement and when they are near the ground, I set real 
gravity. But when the  lower particles reach the ground  the whole particles 
stop moving and nothing happens! they have to place in form of a pile.

Thanks for your patient

Best regards,
Mahdeyeh

'ring.txt' is in first comment. 
My YADE version: 2018.02b

Here is the codes:

import numpy as np
from numpy import *

RawVer=np.genfromtxt('ring.txt',names=True,dtype=None)
# ListVer is list of all the vertices of ring`s polygons
Ver=()
ListVer=[]
for b in RawVer:
if b[0]=='*LWPOLYLINE':
ListVer.append(Ver)
Ver=()
continue
Cordn=b[0]
Cordn=np.fromstring(Cordn, sep=',')
Cordn=tuple(Cordn.tolist())
Cordn1=Cordn+(0.1,)   # add z vertex to coordinates 
Cordn2=Cordn+(0.2,)   # add z vertex to coordinates
if not Cordn1 in Ver:
Ver=Ver+(Cordn1,Cordn2)
ListVer.append(Ver)

RawVer1=np.genfromtxt('boundary.txt',names=True,dtype=None)
Ver1=()
ListVer1=[]
for b in RawVer1:
if b[0]=='*LWPOLYLINE':
ListVer1.append(Ver1)
Ver1=()
continue
Cordn=b[0]
Cordn=np.fromstring(Cordn, sep=',')
Cordn=tuple(Cordn.tolist())
Cordn1=Cordn+(-2,)   # add z vertex to coordinates 
Cordn2=Cordn+(2,)   # add z vertex to coordinates
if not Cordn1 in Ver1:
Ver1=Ver1+(Cordn1,Cordn2)
ListVer1.append(Ver1)

from yade import plot, polyhedra_utils


Dolomite = PolyhedraMat()
Dolomite.density = 2870 #kg/m^3 
Dolomite.young = 24.36e9 #Pa 
Dolomite.poisson = 0.2
Dolomite.frictionAngle = radians(55.12) #rad


for ii in ListVer:
O.bodies.append(polyhedra_utils.polyhedra(Dolomite,v=ii,fixed=False, 
color=(0.1,0.5,0.2), mask=3))

for iii in ListVer1:
O.bodies.append(polyhedra_utils.polyhedra(Dolomite,v=iii,fixed=True, 
color=(1,1,1), mask=4))

O.bodies.erase(341)   # delete wall under ring: id: 341
 
def checkUnbalancedI():   
print "iter %d , unbalanced forces %f"%(O.iter, utils.unbalancedForce())  # 
%[(keyname)][flags][width][.precision]typecode : String Formatting  

O.engines=[
   ForceResetter(),
   InsertionSortCollider([Bo1_Polyhedra_Aabb(),]), # We can set collider's 
verletDist to a fraction of the polyhedra minimum size, since it determines how 
much is each body enlarged to avoid collision detection at every step.
   InteractionLoop(
  [Ig2_Polyhedra_Polyhedra_PolyhedraGeom(),], 
  [Ip2_PolyhedraMat_PolyhedraMat_PolyhedraPhys()], # collision "physics"
  [Law2_PolyhedraGeom_PolyhedraPhys_Volumetric()]   # contact law -- apply 
forces
   ),
   NewtonIntegrator(gravity=(0,-9.81,0),damping=0.2),
   
PyRunner(command='checkUnbalancedI()',iterPeriod=1000,realPeriod=3600,label='checker')
 # call our function defined above every 3600 second or 500 cycles
]

O.engines=O.engines+[PyRunner(iterPeriod=20,command='calm()',label="calmRunner")]
#  because we need to calm only on the first few steps in our model.

O.dt=10e-6

iii=0
while iii<50:
O.run(1000,True)
for b in O.bodies:
x,y,z=b.state.pos[0],b.state.pos[1],b.state.pos[2]
print x,y,z
iii+=1


here is the boundary.txt:

*LWPOLYLINE
4.08255289437355,10.09276250439400
4.08255289437355,10.09267857306840
1.10586584671010,10.07329237103019
1.10586584671010,10.09157421969086
4.08255289437355,10.09276250439400
*LWPOLYLINE
2.8810347806,4.0313063418
2.9580536406,4.0313063418
4.08257892143658,10.09266327552933
4.08255971098529,10.09266327552933
2.8810347806,4.0313063418
*LWPOLYLINE
2.9775296742,4.0184118644
2.9775296742,3.9621450540
0.1072960445,3.9621450540
0.1072960445,4.0143090761
2.9775296742,4.0184118644
*LWPOLYLINE
0.1072960445,-0.00101851609184
0.1072960445,-0.00102332221523
6.73102849650382,-0.00102332221523
6.73102672595532,-0.00101804720175
0.1072960445,-0.00101851609184
*LWPOLYLINE
6.73102610626334,-0.00101628886392
6.73103044410717,-0.00101628886392
6.74417862583885,3.9123254822
6.74373784778834,3.9123254822
6.73102610626334,-0.00101628886392
*LWPOLYLINE
6.74054678821628,3.01646737237143
6.74054678821628,3.01622648008920
4.57127199826347,-0.00101605441888
4.57126509312429,-0.00101605441888
6.7405467882

Re: [Yade-users] [Question #684770]: warning when runnig model: error in linear solver

2019-10-15 Thread Mahdeyeh
Question #684770 on Yade changed:
https://answers.launchpad.net/yade/+question/684770

Status: Answered => Solved

Mahdeyeh confirmed that the question is solved:
Thanks Jan Stránský, that solved my question.

-- 
You received this question notification because your team yade-users is
an answer contact for Yade.

___
Mailing list: https://launchpad.net/~yade-users
Post to : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


Re: [Yade-users] [Question #684770]: warning when runnig model: error in linear solver

2019-10-10 Thread Mahdeyeh
Question #684770 on Yade changed:
https://answers.launchpad.net/yade/+question/684770

Mahdeyeh posted a new comment:
Thank you Jan and Robert.

I added my codes.

I think both of your reply are my answer and will solve my problem, but
unfortunately I don`t understand what is explained in your links, maybe
because I am really an amateur at YADE. So please let me read a bit
about determinant, 3x3 system of linear equation and intersection and
then close this question.

Best regards,
Mahdeyeh

-- 
You received this question notification because your team yade-users is
an answer contact for Yade.

___
Mailing list: https://launchpad.net/~yade-users
Post to : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


Re: [Yade-users] [Question #684770]: warning when runnig model: error in linear solver

2019-10-10 Thread Mahdeyeh
Question #684770 on Yade changed:
https://answers.launchpad.net/yade/+question/684770

Description changed to:
Hi everyone
I am running a model with polyhedra particles. The following line is displayed 
continuously with running:


WARN  /build/yade-fDuCoe/yade-2018.02b/pkg/dem/Polyhedra_support.cpp:370 
SolveLinSys3x3: error in linear solver

The running will not stop and continue, but the warning will still be displayed.
what is this? and why it is displayed in each line?

Thanks a lot

this is my script:

import numpy as np
from numpy import *

RawVer=np.genfromtxt('polyline.txt',names=True,dtype=None)
# ListVer is list of all the vertices of all the polygons
Ver=()
ListVer=[]
for b in RawVer:
if b[0]=='*LWPOLYLINE':
ListVer.append(Ver)
Ver=()
continue
Cordn=b[0]
Cordn=np.fromstring(Cordn, sep=',')
Cordn=tuple(Cordn.tolist())
Cordn1=Cordn+(0.1,)   # add z vertex to coordinates 
Cordn2=Cordn+(0.2,)   # add z vertex to coordinates
if not Cordn1 in Ver:
Ver=Ver+(Cordn1,Cordn2)
ListVer.append(Ver)


from yade import plot, polyhedra_utils


Dolomite = PolyhedraMat()
Dolomite.density = 2870 #kg/m^3 
Dolomite.young = 24.36e9 #Pa 
Dolomite.poisson = 0.2
Dolomite.frictionAngle = radians(55.12) #rad


for ii in ListVer:
O.bodies.append(polyhedra_utils.polyhedra(Dolomite,v=ii,fixed=True, 
color=(1,0.5,1), mask=3))


# block z translation and block x, y, z rotations
for b in O.bodies:
b.state.blockedDOFs='zXYZ'

# returns a value that can be useful for evaluating the stability of the 
packing. It is defined as (mean force on particles)/(mean contact force), so 
that it tends to 0 in a stable packing.
def checkUnbalancedI():   
print "iter %d, time elapsed %f,  time step %.6e, unbalanced forces = 
%.5f"%(O.iter, O.realtime, O.dt, utils.unbalancedForce())   # 
%[(keyname)][flags][width][.precision]typecode : String Formatting  

O.engines=[
   ForceResetter(),
   InsertionSortCollider([Bo1_Polyhedra_Aabb(),]),
   InteractionLoop(
  [Ig2_Polyhedra_Polyhedra_PolyhedraGeom(),], 
  [Ip2_PolyhedraMat_PolyhedraMat_PolyhedraPhys()], # collision "physics"
  [Law2_PolyhedraGeom_PolyhedraPhys_Volumetric()]   # contact law -- apply 
forces
   ),
   NewtonIntegrator(damping=0.2,gravity=(0,-9.81,0)),
   PyRunner(command='checkUnbalancedI()',realPeriod=5,label='checker') # call 
our function defined above every 5 second
]


O.engines=O.engines+[PyRunner(iterPeriod=20,command='calm()',label="calmRunner")]
  #  because we need to calm only on the first few steps in our model.

O.dt=10e-6


# With this command, model runs until 5 cycles also together the running we 
can see bodies position
iii=0
while iii<50:
O.run(1000,True)
for b in O.bodies:
x,y,z=b.state.pos[0],b.state.pos[1],b.state.pos[2]
print x,y,z
iii+=1



And this is part of my polyline.txt file:

*LWPOLYLINE
5.65925646218601,4.55181270691314
5.73126722138072,4.58605245783479
5.77867987874417,4.54814659932002
5.72613545317617,4.45313786655761
5.67735927237957,4.46914368762000
5.65925646218601,4.55181270691314
*LWPOLYLINE
5.77867987874417,4.54814659932002
5.85335478175727,4.48555609218365
5.85260679568780,4.56828407216204
5.77867987874417,4.54814659932002
*LWPOLYLINE
5.73126722138072,4.58605245783479
5.77867987874417,4.54814659932002
5.81450882721560,4.55780853991437
5.79764491294791,4.62869652636552
5.73126722138072,4.58605245783479
*LWPOLYLINE
5.58764749445495,4.58500232889874
5.62217282697479,4.53418014134792
5.73126722138072,4.58605245783479
5.73126722138072,4.63745946951823
5.68912951908611,4.66403774981748
5.62824026119494,4.66403774981748
5.58834735363834,4.61927433599938
5.58764749445495,4.58500232889874
*LWPOLYLINE
5.95173608530622,4.82137216180112
5.97070111950995,4.74674500619493
6.02759629397529,4.78820451330232
6.0418201016,4.87704637031124
6.01692847121745,4.90429121169332
5.96477451937599,4.89363019456064
5.95173608530622,4.82137216180112
5.97070111950995,4.74674500619493
*LWPOLYLINE
6.22515191067526,4.78844429158166
6.26883211191276,4.86556328135477
6.31760829270935,4.84955746029238
6.35032945839741,4.77159311041367
6.27619963174108,4.67665041426685
6.22515191067526,4.78844429158166
*LWPOLYLINE
6.40808285853895,4.80123465328169
6.42234644235425,4.77280528615367
6.47683116141809,4.77280528615367
6.51713191299161,4.82137216180112
6.37015271827735,4.94456619305478
6.40808285853895,4.80123465328169
*LWPOLYLINE
6.37015271827735,4.94456619305478
6.44482762129045,4.88197568591842
6.44482762129045,4.96470366589681
6.37015271827735,4.94456619305478
*LWPOLYLINE
6.32274006091390,4.98247205156955
6.37015271827735,4.94456619305478
6.40598166674878,4.95422813364914
6.38911775248110,5.02511612010029
6.32274006091390,4.98247205156955
*LWPOLYLINE
6.38911775248110,5.02511612010029
6.40598166674878,4.95422813364914
6.44482762129045,4.96470366589681
6.42012466819553,5.05252790576424
6.38911775248110,5.02511612010029
*LWPOLYLINE

[Yade-users] [Question #684770]: warning when runnig model: error in linear solver

2019-10-07 Thread Mahdeyeh
New question #684770 on Yade:
https://answers.launchpad.net/yade/+question/684770

Hi everyone
I am running a model with polyhedra particles. The following line is displayed 
continuously with running:


WARN  /build/yade-fDuCoe/yade-2018.02b/pkg/dem/Polyhedra_support.cpp:370 
SolveLinSys3x3: error in linear solver

The running will not stop and continue, but the warning will still be displayed.
what is this? and why it is displayed in each line?

Thanks a lot

-- 
You received this question notification because your team yade-users is
an answer contact for Yade.

___
Mailing list: https://launchpad.net/~yade-users
Post to : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


Re: [Yade-users] [Question #684492]: Model particles (polyhedra) have moved far from each other from the first

2019-10-02 Thread Mahdeyeh
Question #684492 on Yade changed:
https://answers.launchpad.net/yade/+question/684492

Status: Answered => Solved

Mahdeyeh confirmed that the question is solved:
Thanks Jan Stránský, that solved my question.

-- 
You received this question notification because your team yade-users is
an answer contact for Yade.

___
Mailing list: https://launchpad.net/~yade-users
Post to : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


Re: [Yade-users] [Question #684492]: Model particles (polyhedra) have moved far from each other from the first

2019-10-02 Thread Mahdeyeh
Question #684492 on Yade changed:
https://answers.launchpad.net/yade/+question/684492

Mahdeyeh posted a new comment:
Dear Jan Stránský

> the saved data has only 3 decimal digits (probably it it not the problem, but 
> try with more precise values)
> polyhedrons in Yade are convex. Dos your geometry contains only convex shapes?

They were two important points that solved my problem, some of particles
were in concave shape. you are so great and wonderful.

Best regards,
Mahdeyeh

-- 
You received this question notification because your team yade-users is
an answer contact for Yade.

___
Mailing list: https://launchpad.net/~yade-users
Post to : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


Re: [Yade-users] [Question #684492]: Model particles (polyhedra) have moved far from each other from the first

2019-10-02 Thread Mahdeyeh
Question #684492 on Yade changed:
https://answers.launchpad.net/yade/+question/684492

Status: Answered => Open

Mahdeyeh is still having a problem:
Thanks a lot Jan Stránský for your time and reply.

>Try before O.run():
>###
>O.step()
>for i in O.interactions:
 >  print(i.geom.penetrationVolume)
I did it and I Saw they had very small penetrationVolume, I really 
confused;when I check the geometry in AutoCad the particles are quite seperate 
from each other. Between the edge of neighbour polygons is distance, of course 
their distance is very very small but it exists. But when I load model in YADE 
without running, unbelievably I see visually some particles overlap!!!
1- Is that possible this overlap is because of very small distance between 
particles?


2- Is there any solution for this problem instead of changing their
geometry?

-- 
You received this question notification because your team yade-users is
an answer contact for Yade.

___
Mailing list: https://launchpad.net/~yade-users
Post to : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


Re: [Yade-users] [Question #684492]: Model particles (polyhedra) have moved far from each other from the first

2019-09-30 Thread Mahdeyeh
Question #684492 on Yade changed:
https://answers.launchpad.net/yade/+question/684492

Mahdeyeh gave more information on the question:
 Dear Jan Stránský

> Please also investigate the situation BEFORE running the script, just after 
> loading the polyhedrons (or after one iteration to be able to investigate 
> interactions - if there are some, what are the overlaps etc.).
Are they loaded correctly?

The situation of particles before running the script are correct and
they are loaded quite correctly. they are near each other.

-- 
You received this question notification because your team yade-users is
an answer contact for Yade.

___
Mailing list: https://launchpad.net/~yade-users
Post to : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


  1   2   >