Re: [Yade-users] [Question #623658]: how to set the shape of a rigid boundary as a rectangle

2017-04-19 Thread ting
Question #623658 on Yade changed:
https://answers.launchpad.net/yade/+question/623658

Status: Answered => Solved

ting 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 #623658]: how to set the shape of a rigid boundary as a rectangle

2017-04-19 Thread Jérôme Duriez
Question #623658 on Yade changed:
https://answers.launchpad.net/yade/+question/623658

Status: Open => Answered

Jérôme Duriez proposed the following answer:
Hi,

This "facet" function creates a body with a "Facet" shape which is
necessarily a triangle [1]. You may however define a second adjacent
"facet" so that you would eventually have a rectangle (made of two YADE
bodies).

Or, maybe more simply, you may use other shapes, such as (infinite) Walls [2], 
or Boxes [3].
Bodies with such shape can also be easily created with built-in functions [4,5]

[1] https://yade-dem.org/doc/yade.wrapper.html#yade.wrapper.Facet
[2] https://yade-dem.org/doc/yade.wrapper.html#yade.wrapper.Wall
[3] https://yade-dem.org/doc/yade.wrapper.html#yade.wrapper.Box
[4] https://yade-dem.org/doc/yade.utils.html#yade.utils.wall
[5] https://yade-dem.org/doc/yade.utils.html#yade.utils.box

-- 
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 #623658]: how to set the shape of a rigid boundary as a rectangle

2017-04-19 Thread ting
New question #623658 on Yade:
https://answers.launchpad.net/yade/+question/623658

Hi everyone:

I am new to Yade and python and I am trying to simulate a rigid rectangle plate 
and moving it as a blade. I found I can simulate a rigid boundary as a triangle 
as following:
O.bodies.append(facet([(0,0,0),(2,0,1),(0,0,1)]))
But I found it cannot form a rectangle by adding one more point.
Can someone tell me how to modify it or using other approach?
Thank you so much and wish have a good day!

Regards,
Ting

-- 
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 #620981]: record deformed shape in cohesive triaxil test

2017-04-19 Thread Seti
Question #620981 on Yade changed:
https://answers.launchpad.net/yade/+question/620981

Status: Answered => Solved

Seti confirmed that the question is solved:
Hi Robert,


Thanks for your time and recommendation.


Hi Hien,

thanks for recommendation. I meant force network.



Cheers,
Seti

-- 
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 #443228]: segmentation fault using two kinds of cohefricmats under cohesive triaxial test

2017-04-19 Thread Seti
Question #443228 on Yade changed:
https://answers.launchpad.net/yade/+question/443228

Seti posted a new comment:
awesome, it is working. Thanks Jan :)

-- 
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 #620981]: record deformed shape in cohesive triaxil test

2017-04-19 Thread Hien N.G. NGUYEN
Question #620981 on Yade changed:
https://answers.launchpad.net/yade/+question/620981

Hien N.G. NGUYEN proposed the following answer:
Do you mean the force network instead? (force network: serie of lines
presenting all interactions, and lines' thickness represent force's
magnitude?) Be careful to use the terminology 'force-chain'.

If so, you can do it outside of YADE, try saving interactions info data and 
plot it with matplotlib or mayavi.
Or you can do it the simple way: save YADE model (yade.gz for example) and you 
can access this every via YADE UI.
Load the saved model, then in the UI window, do this:
Display Tab -> OpenGLRenderer -> tick 'intrPhys'
You can also hide spheres by unticking 'shape'

Good luck
Hien

-- 
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 #443228]: segmentation fault using two kinds of cohefricmats under cohesive triaxial test

2017-04-19 Thread Jan Stránský
Question #443228 on Yade changed:
https://answers.launchpad.net/yade/+question/443228

Jan Stránský proposed the following answer:
Ok, I have found the problem.

> Apart from the wall using the frictmat

the problem is that FrictMat is actually not used:

>for b in O.bodies:
> if random.random() < 0.5:
>  b.mat = mat1
> else:
>  b.mat = mat2

here you set materials of all bodies to CohFrictMat. Than between Box an
Sphere, ScGeom is created, but Ip2_CohFrictMat when setCohesionNow is
set consideres ScGeom6D, caousing the segmentation fault.

preserve FrictMat on boxes like following
###
for b in O.bodies:
  if not isinstance(b.shape,Sphere): # change material only on spheres
continue
  if random.random() < 0.5:
...
###
and the code should work (works for me)
cheers
Jan

-- 
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 #443228]: segmentation fault using two kinds of cohefricmats under cohesive triaxial test

2017-04-19 Thread Jan Stránský
Question #443228 on Yade changed:
https://answers.launchpad.net/yade/+question/443228

Jan Stránský posted a new comment:
Strange, I tried it now and also got segmentation fault, too..

below see valgrind output in case it help for somebody. The error occurs
at the beginning of the last O.run command

cheers
Jan

#
==7339== Thread 8:
==7339== Invalid write of size 8
==7339==at 0x8E295F0: ScGeom6D::initRotations(State const&, State const&) 
(in /home/honzik/lib/x86_64-linux-gnu/yade-2017.01a/libyade.so)
==7339==by 0x9064E4C: 
Ip2_CohFrictMat_CohFrictMat_CohFrictPhys::go(boost::shared_ptr 
const&, boost::shared_ptr const&, boost::shared_ptr 
const&) (in /home/honzik/lib/x86_64-linux-gnu/yade-2017.01a/libyade.so)
==7339==by 0x927C77B: InteractionLoop::action() [clone ._omp_fn.0] (in 
/home/honzik/lib/x86_64-linux-gnu/yade-2017.01a/libyade.so)
==7339==by 0xDD81CBE: GOMP_parallel (in 
/usr/lib/x86_64-linux-gnu/libgomp.so.1.0.0)
==7339==by 0x927D3BA: InteractionLoop::action() (in 
/home/honzik/lib/x86_64-linux-gnu/yade-2017.01a/libyade.so)
==7339==by 0x8B97BC1: Scene::moveToNextTimeStep() (in 
/home/honzik/lib/x86_64-linux-gnu/yade-2017.01a/libyade.so)
==7339==by 0x8B9B2C2: SimulationFlow::singleAction() (in 
/home/honzik/lib/x86_64-linux-gnu/yade-2017.01a/libyade.so)
==7339==by 0x8A85645: ThreadWorker::callSingleAction() (in 
/home/honzik/lib/x86_64-linux-gnu/yade-2017.01a/libyade.so)
==7339==by 0x8B93B90: ThreadRunner::call() (in 
/home/honzik/lib/x86_64-linux-gnu/yade-2017.01a/libyade.so)
==7339==by 0x8B93E77: ThreadRunner::run() (in 
/home/honzik/lib/x86_64-linux-gnu/yade-2017.01a/libyade.so)
==7339==by 0x8B95A71: boost::detail::thread_data::run() (in /home/honzik/lib/x86_64-linux-gnu/yade-2017.01a/libyade.so)
==7339==by 0xAF0E5D4: ??? (in 
/usr/lib/x86_64-linux-gnu/libboost_thread.so.1.58.0)
==7339==  Address 0x2f87db10 is 0 bytes after a block of size 176 alloc'd
==7339==at 0x4C2E0EF: operator new(unsigned long) (in 
/usr/lib/valgrind/vgpreload_memcheck-amd64-linux.so)
==7339==by 0x8C3698B: Ig2_Box_Sphere_ScGeom::go(boost::shared_ptr 
const&, boost::shared_ptr const&, State const&, State const&, 
Eigen::Matrix const&, bool const&, 
boost::shared_ptr const&) (in 
/home/honzik/lib/x86_64-linux-gnu/yade-2017.01a/libyade.so)
==7339==by 0x927C624: InteractionLoop::action() [clone ._omp_fn.0] (in 
/home/honzik/lib/x86_64-linux-gnu/yade-2017.01a/libyade.so)
==7339==by 0xDD81CBE: GOMP_parallel (in 
/usr/lib/x86_64-linux-gnu/libgomp.so.1.0.0)
==7339==by 0x927D3BA: InteractionLoop::action() (in 
/home/honzik/lib/x86_64-linux-gnu/yade-2017.01a/libyade.so)
==7339==by 0x8B97BC1: Scene::moveToNextTimeStep() (in 
/home/honzik/lib/x86_64-linux-gnu/yade-2017.01a/libyade.so)
==7339==by 0x8B9B2C2: SimulationFlow::singleAction() (in 
/home/honzik/lib/x86_64-linux-gnu/yade-2017.01a/libyade.so)
==7339==by 0x8A85645: ThreadWorker::callSingleAction() (in 
/home/honzik/lib/x86_64-linux-gnu/yade-2017.01a/libyade.so)
==7339==by 0x8B93B90: ThreadRunner::call() (in 
/home/honzik/lib/x86_64-linux-gnu/yade-2017.01a/libyade.so)
==7339==by 0x8B93E77: ThreadRunner::run() (in 
/home/honzik/lib/x86_64-linux-gnu/yade-2017.01a/libyade.so)
==7339==by 0x8B95A71: boost::detail::thread_data::run() (in /home/honzik/lib/x86_64-linux-gnu/yade-2017.01a/libyade.so)
==7339==by 0xAF0E5D4: ??? (in 
/usr/lib/x86_64-linux-gnu/libboost_thread.so.1.58.0)
==7339== 
==7339== Invalid write of size 8
==7339==at 0x8E295FD: ScGeom6D::initRotations(State const&, State const&) 
(in /home/honzik/lib/x86_64-linux-gnu/yade-2017.01a/libyade.so)
==7339==by 0x9064E4C: 
Ip2_CohFrictMat_CohFrictMat_CohFrictPhys::go(boost::shared_ptr 
const&, boost::shared_ptr const&, boost::shared_ptr 
const&) (in /home/honzik/lib/x86_64-linux-gnu/yade-2017.01a/libyade.so)
==7339==by 0x927C77B: InteractionLoop::action() [clone ._omp_fn.0] (in 
/home/honzik/lib/x86_64-linux-gnu/yade-2017.01a/libyade.so)
==7339==by 0xDD81CBE: GOMP_parallel (in 
/usr/lib/x86_64-linux-gnu/libgomp.so.1.0.0)
==7339==by 0x927D3BA: InteractionLoop::action() (in 
/home/honzik/lib/x86_64-linux-gnu/yade-2017.01a/libyade.so)
==7339==by 0x8B97BC1: Scene::moveToNextTimeStep() (in 
/home/honzik/lib/x86_64-linux-gnu/yade-2017.01a/libyade.so)
==7339==by 0x8B9B2C2: SimulationFlow::singleAction() (in 
/home/honzik/lib/x86_64-linux-gnu/yade-2017.01a/libyade.so)
==7339==by 0x8A85645: ThreadWorker::callSingleAction() (in 
/home/honzik/lib/x86_64-linux-gnu/yade-2017.01a/libyade.so)
==7339==by 0x8B93B90: ThreadRunner::call() (in 
/home/honzik/lib/x86_64-linux-gnu/yade-2017.01a/libyade.so)
==7339==by 0x8B93E77: ThreadRunner::run() (in 
/home/honzik/lib/x86_64-linux-gnu/yade-2017.01a/libyade.so)
==7339==by 0x8B95A71: boost::detail::thread_data::run() (in 

Re: [Yade-users] [Question #622071]: a problem about micro-stress computing

2017-04-19 Thread xjin
Question #622071 on Yade changed:
https://answers.launchpad.net/yade/+question/622071

Status: Open => Solved

xjin confirmed that the question is solved:
Thanks Jan Stránský!

-- 
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 #622071]: a problem about micro-stress computing

2017-04-19 Thread Jan Stránský
Question #622071 on Yade changed:
https://answers.launchpad.net/yade/+question/622071

Jan Stránský posted a new comment:
> Is the reason that the stress calculation is approximate calculation?

oppositely, the reason is exact calculation :-) in general, stress may
be non-symmetric because the particle assembly is not in static
equlibrium from moment point of view

in "classical" mechanics, t_xy=t_yx holds under assumption of zero
rotation, you assume strain=symgrad(displacement) and you don't care of
antisym part anymore. In DEM, rotation and moments are important (in
"classical" continuum, you have forces, but no moments)... just a veeery
brief intro, have a look e.g. at [1] (1st google result of "Cosserat
continuum", see especially slide 15) or other similar materials. In
case, open a new question

cheers
Jan

[1]
http://alertgeomaterials.eu/data/school/2010/03%20Papamichos%20E%20Cosserat%20theory.pdf

-- 
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 #622071]: a problem about micro-stress computing

2017-04-19 Thread xjin
Question #622071 on Yade changed:
https://answers.launchpad.net/yade/+question/622071

Status: Solved => Open

xjin is still having a problem:
Thanks Jan Stránský, the original problem have already been solved. 
Another confusion makes me want to ask you for help. 

As the explanation mentioned  before, stress = (s_x, t_xy, t_xz, t_yx, s_y, 
t_yz, t_zx, t_zy, s_z). 
And the example I obtain: 

Yade [19]:obtain stress
 -> [19]: 
Matrix3(-0.13752527190640026,0.03607936010975411,0.0008634995770584191, 
0.03445913198778846,-0.06373525199754092,0.006348443944983994, 
-0.0012487034856438542,0.014427579541476804,-0.11692017375785213)


Therefore,
-
  s_x=-0.13752527190640026
t_xy=0.03607936010975411
t_xz=0.0008634995770584191
t_yx=0.03445913198778846
  s_y=-0.06373525199754092
t_yz=0.006348443944983994
t_zx=-0.0012487034856438542
t_zy=0.014427579541476804
  s_z=-0.11692017375785213
-
for the values, I find t_xy does not equal to t_yx,t_xz does not equal to t_zx 
and t_yz does not equal to t_zy.
As the knowledge of Elasticity shows, the t_xy=t_yx and so on.
Is the reason that the stress calculation is approximate calculation?
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 #622864]: import gmsh force element

2017-04-19 Thread Jan Stránský
Question #622864 on Yade changed:
https://answers.launchpad.net/yade/+question/622864

Jan Stránský posted a new comment:
Hello,

> 2.) ...Can I import an .inp (tetrahedral) mesh file?

yes, but I don't know of any existing function, so you would need to
write your own import function. Alternatively you can save the mesh in
different format or use some converter from .inp to different format

cheers
Jan

-- 
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