Re: [Yade-users] [Question #268697]: installation of YADE with suse distribution

2015-06-30 Thread Anton Gladky
Question #268697 on Yade changed:
https://answers.launchpad.net/yade/+question/268697

Anton Gladky proposed the following answer:
There is no move to qt5 yet. Those new files are disabled, if you
do not put -DUSE_QT5=1 option explicitly.

Anton


2015-06-30 19:01 GMT+02:00 Luc OGER :
> Question #268697 on Yade changed:
> https://answers.launchpad.net/yade/+question/268697
>
> Luc OGER posted a new comment:
> I am using for a long time the yade distribution with OPENSUSE 13.2
> x86_64 without any problem up to now!
>
> But this new update series of packages such the move from qt4 to qt5
> generates also for me the same kind of warnings:
>
> I guess that some changes of the qt4/GLviewer to qt5/glviewer in some paths 
> is needed?
>  gui/qt4/GLViewer.cpp  |5 
> +-
>  gui/qt4/GLViewer.hpp  |4 
> +
>  gui/qt4/GLViewerDisplay.cpp   |8 
> +
>  gui/qt4/build |4 
> -
>  gui/qt5/GLViewer.cpp  |  488 
> ++
>  gui/qt5/GLViewer.hpp  |  163 
> ++
>  gui/qt5/GLViewerDisplay.cpp
>
> why both are in the distribution?
>
> --
> You received this question notification because you are a member of
> yade-users, which 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

-- 
You received this question notification because you are a member of
yade-users, which 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 #268697]: installation of YADE with suse distribution

2015-06-30 Thread Luc OGER
Question #268697 on Yade changed:
https://answers.launchpad.net/yade/+question/268697

Luc OGER posted a new comment:
I am using for a long time the yade distribution with OPENSUSE 13.2
x86_64 without any problem up to now!

But this new update series of packages such the move from qt4 to qt5
generates also for me the same kind of warnings:

I guess that some changes of the qt4/GLviewer to qt5/glviewer in some paths is 
needed?
 gui/qt4/GLViewer.cpp  |5 +-
 gui/qt4/GLViewer.hpp  |4 +
 gui/qt4/GLViewerDisplay.cpp   |8 +
 gui/qt4/build |4 -
 gui/qt5/GLViewer.cpp  |  488 
++
 gui/qt5/GLViewer.hpp  |  163 
++
 gui/qt5/GLViewerDisplay.cpp

why both are in the distribution?

-- 
You received this question notification because you are a member of
yade-users, which 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 #268697]: installation of YADE with suse distribution

2015-06-30 Thread Anton Gladky
Question #268697 on Yade changed:
https://answers.launchpad.net/yade/+question/268697

Status: Open => Answered

Anton Gladky proposed the following answer:
Try to replace the line in lib/base/Math.hpp:8

-using Real = double
+typedef double Real;

if it will work, your compiler does not support C++11 completely.

Cheers

Anton


2015-06-30 14:36 GMT+02:00 feddyadong :
> New question #268697 on Yade:
> https://answers.launchpad.net/yade/+question/268697
>
> Hello,
> I try to intall YADE in the suse server distribution:
> SUSE Linux Enterprise Server 11 SP1  (x86_64) - Kernel \r (\l)
>
> I downloaded and compiled all the library needed for the YADE installation 
> and I modified some files to
> specify the location of the files .h and .so associate at each library.
>
> After some modifications the cmake command work well and i obtain this 
> message:
>
> -- Yade configured with following features: Odeint VTK OpenMP GTS GUI CGAL 
> PFVFLOW GL2PS LBMFLOW
> -- Disabled features: LINSOLV SPH LIQMIGRATION MASK_ARBITRARY PROFILING
> -- Optimized build
> -- ===
> -- Configuring done
> -- Build files have been written to: /home2/caparmor/fadong/YADE/myYADE/build
>
> but the make command send this error message:
>
> -- Generating doneservice7>66% make
> [  1%] Generating qt4/moc_OpenGLManager.cxx
> [  2%] Generating qt4/moc_GLViewer.cxx
> Scanning dependencies of target _GLViewer
> [  2%] Building CXX object gui/CMakeFiles/_GLViewer.dir/qt4/GLViewer.cpp.o
> In file included from 
> /home2/caparmor/fadong/YADE/myYADE/trunk/core/Omega.hpp:20,
>  from 
> /home2/caparmor/fadong/YADE/myYADE/trunk/gui/qt4/GLViewer.hpp:6,
>  from 
> /home2/caparmor/fadong/YADE/myYADE/trunk/gui/qt4/GLViewer.cpp:11:
> /home2/caparmor/fadong/YADE/myYADE/trunk/lib/base/Math.hpp:8: error: expected 
> nested-name-specifier before 'Real'
> /home2/caparmor/fadong/YADE/myYADE/trunk/lib/base/Math.hpp:8: error: 'Real' 
> has not been declared
> /home2/caparmor/fadong/YADE/myYADE/trunk/lib/base/Math.hpp:8: error: expected 
> `;' before '=' token
> /home2/caparmor/fadong/YADE/myYADE/trunk/lib/base/Math.hpp:8: error: expected 
> unqualified-id before '=' token
> ^Cmake[2]: *** [gui/CMakeFiles/_GLViewer.dir/qt4/GLViewer.cpp.o] Interrupt
>
> I tried to change the version of gcc (4.9.2, 4.8.2, 4.2.2) but without succes.
>
>
>
> You received this question notification because you are a member of
> yade-users, which 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

-- 
You received this question notification because you are a member of
yade-users, which 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 #268697]: installation of YADE with suse distribution

2015-06-30 Thread Anton Gladky
Try to replace the line in lib/base/Math.hpp:8

-using Real = double
+typedef double Real;

if it will work, your compiler does not support C++11 completely.

Cheers

Anton


2015-06-30 14:36 GMT+02:00 feddyadong :
> New question #268697 on Yade:
> https://answers.launchpad.net/yade/+question/268697
>
> Hello,
> I try to intall YADE in the suse server distribution:
> SUSE Linux Enterprise Server 11 SP1  (x86_64) - Kernel \r (\l)
>
> I downloaded and compiled all the library needed for the YADE installation 
> and I modified some files to
> specify the location of the files .h and .so associate at each library.
>
> After some modifications the cmake command work well and i obtain this 
> message:
>
> -- Yade configured with following features: Odeint VTK OpenMP GTS GUI CGAL 
> PFVFLOW GL2PS LBMFLOW
> -- Disabled features: LINSOLV SPH LIQMIGRATION MASK_ARBITRARY PROFILING
> -- Optimized build
> -- ===
> -- Configuring done
> -- Build files have been written to: /home2/caparmor/fadong/YADE/myYADE/build
>
> but the make command send this error message:
>
> -- Generating doneservice7>66% make
> [  1%] Generating qt4/moc_OpenGLManager.cxx
> [  2%] Generating qt4/moc_GLViewer.cxx
> Scanning dependencies of target _GLViewer
> [  2%] Building CXX object gui/CMakeFiles/_GLViewer.dir/qt4/GLViewer.cpp.o
> In file included from 
> /home2/caparmor/fadong/YADE/myYADE/trunk/core/Omega.hpp:20,
>  from 
> /home2/caparmor/fadong/YADE/myYADE/trunk/gui/qt4/GLViewer.hpp:6,
>  from 
> /home2/caparmor/fadong/YADE/myYADE/trunk/gui/qt4/GLViewer.cpp:11:
> /home2/caparmor/fadong/YADE/myYADE/trunk/lib/base/Math.hpp:8: error: expected 
> nested-name-specifier before 'Real'
> /home2/caparmor/fadong/YADE/myYADE/trunk/lib/base/Math.hpp:8: error: 'Real' 
> has not been declared
> /home2/caparmor/fadong/YADE/myYADE/trunk/lib/base/Math.hpp:8: error: expected 
> `;' before '=' token
> /home2/caparmor/fadong/YADE/myYADE/trunk/lib/base/Math.hpp:8: error: expected 
> unqualified-id before '=' token
> ^Cmake[2]: *** [gui/CMakeFiles/_GLViewer.dir/qt4/GLViewer.cpp.o] Interrupt
>
> I tried to change the version of gcc (4.9.2, 4.8.2, 4.2.2) but without succes.
>
>
>
> You received this question notification because you are a member of
> yade-users, which 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

___
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 #268691]: Apply force only once

2015-06-30 Thread Jan Stránský
Question #268691 on Yade changed:
https://answers.launchpad.net/yade/+question/268691

Jan Stránský posted a new comment:
Hi Laura

I mean something like this:

#
O.load('/path/spheresurface.yade')

MatBal=O.materials.append(FrictMat(...))


### green sphere
greenSphere = 
sphere((0.108,0.2289647116,0.7175),0.0199647116,color=(0,1,0),material='mat1')
# no need of utils.sphere
greenSphereId = O.bodies.append(greenSphere)



def guardar():
...

O.engines=[
ForceResetter(),
InsertionSortCollider(
[Bo1_Sphere_Aabb(),
Bo1_Facet_Aabb(),
Bo1_Box_Aabb(),
Bo1_Wall_Aabb()]),
InteractionLoop(
[Ig2_Sphere_Sphere_ScGeom(),
Ig2_Facet_Sphere_ScGeom(),
Ig2_Wall_Sphere_ScGeom(),
Ig2_Box_Sphere_ScGeom()],
[Ip2_FrictMat_FrictMat_FrictPhys()],
[Law2_ScGeom_FrictPhys_CundallStrack()]
),
# PyRunner(command='force()',
#iterPeriod=1,initRun=True,label='checker'), # this
PyRunner will not be used
PyRunner(command='guardar()',
iterPeriod=1,initRun=True,label='checker'),
NewtonIntegrator(damping=0.5,gravity=(0,-9.81,0),label='newton'),
yade.qt.SnapshotEngine(fileBase='3d-',iterPeriod=
1000,label='snapshot')
]
O.dt=utils.PWaveTimeStep()

greenSphere.state.vel = (1,0,0) # this :-)
#3

cheers
Jan


2015-06-30 15:31 GMT+02:00 rayolau
:

> Question #268691 on Yade changed:
> https://answers.launchpad.net/yade/+question/268691
>
> rayolau posted a new comment:
> Hi Jan, thanks again!
>
> I don't understand what do you say about put the b.state.vel at the
> begin of the simulation without use PyRunner.  What type of function
> should I write in the script for identify the green sphere and then
> apply the vector velocity in this sphere? Sorry for question, could be a
> own mistake in my way of do the script.
>
> cheers,
>
> Laura
>
> --
> You received this question notification because you are a member of
> yade-users, which 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
>

-- 
You received this question notification because you are a member of
yade-users, which 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 #268691]: Apply force only once

2015-06-30 Thread rayolau
Question #268691 on Yade changed:
https://answers.launchpad.net/yade/+question/268691

Status: Answered => Solved

rayolau confirmed that the question is solved:
Hi Jan,

Solved!!
 I made the identification of waiting in the terminal , apply the rate in the 
field , and then start the simulation , which saves the position and speed of 
the stone with the PyRunner for storing data.

Thanks for the help. Regards =)

Laura

-- 
You received this question notification because you are a member of
yade-users, which 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 #268691]: Apply force only once

2015-06-30 Thread rayolau
Question #268691 on Yade changed:
https://answers.launchpad.net/yade/+question/268691

rayolau posted a new comment:
Hi Jan,

Solved!!
 I made the identification of waiting in the terminal , apply the rate in the 
field , and then start the simulation , which saves the position and speed of 
the stone with the PyRunner for storing data.

Thanks for the help. Regards =)

Laura

-- 
You received this question notification because you are a member of
yade-users, which 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 #268691]: Apply force only once

2015-06-30 Thread Jan Stránský
Hi Laura

I mean something like this:

#
O.load('/path/spheresurface.yade')

MatBal=O.materials.append(FrictMat(...))


### green sphere
greenSphere = 
sphere((0.108,0.2289647116,0.7175),0.0199647116,color=(0,1,0),material='mat1')
# no need of utils.sphere
greenSphereId = O.bodies.append(greenSphere)




def guardar():
...

O.engines=[
ForceResetter(),
InsertionSortCollider(
[Bo1_Sphere_Aabb(),
Bo1_Facet_Aabb(),
Bo1_Box_Aabb(),
Bo1_Wall_Aabb()]),
InteractionLoop(
[Ig2_Sphere_Sphere_ScGeom(),
Ig2_Facet_Sphere_ScGeom(),
Ig2_Wall_Sphere_ScGeom(),
Ig2_Box_Sphere_ScGeom()],
[Ip2_FrictMat_FrictMat_FrictPhys()],
[Law2_ScGeom_FrictPhys_CundallStrack()]
),
# PyRunner(command='force()',
#iterPeriod=1,initRun=True,label='checker'), # this
PyRunner will not be used
PyRunner(command='guardar()',
iterPeriod=1,initRun=True,label='checker'),
NewtonIntegrator(damping=0.5,gravity=(0,-9.81,0),label='newton'),
yade.qt.SnapshotEngine(fileBase='3d-',iterPeriod=
1000,label='snapshot')
]
O.dt=utils.PWaveTimeStep()

greenSphere.state.vel = (1,0,0) # this :-)
#3

cheers
Jan



2015-06-30 15:31 GMT+02:00 rayolau :

> Question #268691 on Yade changed:
> https://answers.launchpad.net/yade/+question/268691
>
> rayolau posted a new comment:
> Hi Jan, thanks again!
>
> I don't understand what do you say about put the b.state.vel at the
> begin of the simulation without use PyRunner.  What type of function
> should I write in the script for identify the green sphere and then
> apply the vector velocity in this sphere? Sorry for question, could be a
> own mistake in my way of do the script.
>
> cheers,
>
> Laura
>
> --
> You received this question notification because you are a member of
> yade-users, which 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
>
___
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 #268691]: Apply force only once

2015-06-30 Thread rayolau
Question #268691 on Yade changed:
https://answers.launchpad.net/yade/+question/268691

rayolau posted a new comment:
Hi Jan, thanks again!

I don't understand what do you say about put the b.state.vel at the
begin of the simulation without use PyRunner.  What type of function
should I write in the script for identify the green sphere and then
apply the vector velocity in this sphere? Sorry for question, could be a
own mistake in my way of do the script.

cheers,

Laura

-- 
You received this question notification because you are a member of
yade-users, which 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 #268697]: installation of YADE with suse distribution

2015-06-30 Thread feddyadong
New question #268697 on Yade:
https://answers.launchpad.net/yade/+question/268697

Hello,
I try to intall YADE in the suse server distribution:
SUSE Linux Enterprise Server 11 SP1  (x86_64) - Kernel \r (\l)

I downloaded and compiled all the library needed for the YADE installation and 
I modified some files to
specify the location of the files .h and .so associate at each library.

After some modifications the cmake command work well and i obtain this message:

-- Yade configured with following features: Odeint VTK OpenMP GTS GUI CGAL 
PFVFLOW GL2PS LBMFLOW
-- Disabled features: LINSOLV SPH LIQMIGRATION MASK_ARBITRARY PROFILING
-- Optimized build
-- ===
-- Configuring done
-- Build files have been written to: /home2/caparmor/fadong/YADE/myYADE/build

but the make command send this error message:

-- Generating doneservice7>66% make
[  1%] Generating qt4/moc_OpenGLManager.cxx
[  2%] Generating qt4/moc_GLViewer.cxx
Scanning dependencies of target _GLViewer
[  2%] Building CXX object gui/CMakeFiles/_GLViewer.dir/qt4/GLViewer.cpp.o
In file included from 
/home2/caparmor/fadong/YADE/myYADE/trunk/core/Omega.hpp:20,
 from 
/home2/caparmor/fadong/YADE/myYADE/trunk/gui/qt4/GLViewer.hpp:6,
 from 
/home2/caparmor/fadong/YADE/myYADE/trunk/gui/qt4/GLViewer.cpp:11:
/home2/caparmor/fadong/YADE/myYADE/trunk/lib/base/Math.hpp:8: error: expected 
nested-name-specifier before 'Real'
/home2/caparmor/fadong/YADE/myYADE/trunk/lib/base/Math.hpp:8: error: 'Real' has 
not been declared
/home2/caparmor/fadong/YADE/myYADE/trunk/lib/base/Math.hpp:8: error: expected 
`;' before '=' token
/home2/caparmor/fadong/YADE/myYADE/trunk/lib/base/Math.hpp:8: error: expected 
unqualified-id before '=' token
^Cmake[2]: *** [gui/CMakeFiles/_GLViewer.dir/qt4/GLViewer.cpp.o] Interrupt

I tried to change the version of gcc (4.9.2, 4.8.2, 4.2.2) but without succes.



You received this question notification because you are a member of
yade-users, which 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 #268691]: Apply force only once

2015-06-30 Thread Jan Stránský
Question #268691 on Yade changed:
https://answers.launchpad.net/yade/+question/268691

Jan Stránský proposed the following answer:
Hi Laura,


> I've changed the IterPeriod and the value of O.force, and works ok.
>

I believe it works, but I would not use it this way :-)

b.state.vel(id_ball,(1,0,0))
> Error: b.state.vel(id_ball, (10,0,0))
> TypeError: 'Vector3' object is not callable


the syntax should be:

b.state.vel = (1,0,0)

use this line only once in the beginning of the simulation (preferably do
not use PyRunner). Otherwise it would overwrite the vertical component of
the motion. (To test it, you can use PyRunner as you have it now with
initRun=True and iterPeriod=someVeryBigNumber)

cheers
Jan

-- 
You received this question notification because you are a member of
yade-users, which 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 #268691]: Apply force only once

2015-06-30 Thread Jan Stránský
Hi Laura,


> I've changed the IterPeriod and the value of O.force, and works ok.
>

I believe it works, but I would not use it this way :-)

b.state.vel(id_ball,(1,0,0))
> Error: b.state.vel(id_ball, (10,0,0))
> TypeError: 'Vector3' object is not callable


the syntax should be:

b.state.vel = (1,0,0)

use this line only once in the beginning of the simulation (preferably do
not use PyRunner). Otherwise it would overwrite the vertical component of
the motion. (To test it, you can use PyRunner as you have it now with
initRun=True and iterPeriod=someVeryBigNumber)

cheers
Jan
___
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 #268691]: Apply force only once

2015-06-30 Thread rayolau
Question #268691 on Yade changed:
https://answers.launchpad.net/yade/+question/268691

rayolau posted a new comment:
Hi Jan, thanks for your reply!

Respect "I think that the force was applied correctly. The only problem is that 
the
force was was applied for one time step (I assume very short time), so it
has almost no effect.." You were right . I've changed the IterPeriod and the 
value of O.force, and works ok. 

PyRunner(command='force()',
iterPeriod=100,initRun=True,label='checker'), 

def force():
piedraensayo=[]
for i in range(0,len(O.bodies)):
b=O.bodies[i]
if O.bodies[i].shape.color==(0,1,0):
piedraensayo.append([i])
id_ball=i   
fx=1
fy=0
fz=0
O.forces.addF(id_ball, (fx, fy, fz))

However, maybe I should apply a velocity in x direction. In this sense,
I tried this, and not working. The problem is I don't know how putting
the identity of the green sphere to apply the velocity vector only on
her.

def force():
piedraensayo=[]
for i in range(0,len(O.bodies)):
b=O.bodies[i]
if O.bodies[i].shape.color==(0,1,0):
piedraensayo.append([i])
id_ball=i   
b.state.vel(id_ball,(1,0,0))

Error: b.state.vel(id_ball, (10,0,0))
TypeError: 'Vector3' object is not callable


Thanks for your help , as always! =)

-- 
You received this question notification because you are a member of
yade-users, which 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 #268691]: Apply force only once

2015-06-30 Thread Jan Stránský
Question #268691 on Yade changed:
https://answers.launchpad.net/yade/+question/268691

Status: Open => Answered

Jan Stránský proposed the following answer:
Hi Laura


> My first choice was to put a high period (1 for example), but
> this way , the green sphere falls on the surface of spheres before the
> force was applied .


I think that the force was applied correctly. The only problem is that the
force was was applied for one time step (I assume very short time), so it
has almost no effect..


> What I need is to apply a force on green particle
> when it is "in the air " to describe a parabolic movement to fall on the
> surface and stop.
>

>From this sentence, I am not sure if applied force is really what you are
looking for.. Wouldn't setting initial velocity in x direction be OK? The
resulting trajectory would be parabola..

cheers
Jan

-- 
You received this question notification because you are a member of
yade-users, which 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 #268691]: Apply force only once

2015-06-30 Thread Jan Stránský
Hi Laura


> My first choice was to put a high period (1 for example), but
> this way , the green sphere falls on the surface of spheres before the
> force was applied .


I think that the force was applied correctly. The only problem is that the
force was was applied for one time step (I assume very short time), so it
has almost no effect..


> What I need is to apply a force on green particle
> when it is "in the air " to describe a parabolic movement to fall on the
> surface and stop.
>

>From this sentence, I am not sure if applied force is really what you are
looking for.. Wouldn't setting initial velocity in x direction be OK? The
resulting trajectory would be parabola..

cheers
Jan
___
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 #268691]: Apply force only once

2015-06-30 Thread rayolau
Question #268691 on Yade changed:
https://answers.launchpad.net/yade/+question/268691

Description changed to:
Hi guys!

I try to study the displacement of various spheres ( with different
weight ) when they apply the same force, on a surface which previously
has been created and is composed of other spheres.

My problem is the IterPeriod of the PyRunner function that I create for
apply the force on the sphere that I want, in this case, green spheres.

If I put the period = 1 , the force is constantly applied .How I can apply the 
force only once? PyRunner(command='force()',
¿?¿?¿?iterPeriod=¿?¿?¿,initRun=True,label='checker'),

My first choice was to put a high period (1 for example), but
this way , the green sphere falls on the surface of spheres before the
force was applied . What I need is to apply a force on green particle
when it is "in the air " to describe a parabolic movement to fall on the
surface and stop.

The second PyRunner is to store the position data ( x , y, z) and the
green particle velocity .

Thanks in advance =)

the code:

O.load('/path/spheresurface.yade')

#/
#// materials \\\
#/

MatBal=O.materials.append(FrictMat(
young=27e9,poisson=0.30,density=1000,
frictionAngle=0.7,label='mat1'))

#/
#// green sphere
#/

### green sphere

O.bodies.append(utils.sphere((0.108,0.2289647116,0.7175),0.0199647116,color=(0,1,0),material='mat1'))


#/
# force on green sphere
#/

def force():
piedraensayo=[]

###force on green sphere
for i in range(0,len(O.bodies)):
b=O.bodies[i]
if O.bodies[i].shape.color==(0,1,0):
piedraensayo.append([i])
id_ball=i   
fx=1
fy=0
fz=0
O.forces.addF(id_ball, (fx, fy, fz))


#/
#///save position and velocity \
#/
def guardar():
if O.iter==0:
global paso
matriz1=[]
for i in range(0,len(O.bodies)):
b=O.bodies[i]
if O.bodies[i].shape.color==(0,1,0):

matriz1.append([i,b.state.pos[1],b.state.pos[1],b.state.pos[2],b.state.vel.norm()])

np.savetxt('pruebaVERDE.out',matriz1,delimiter=',')

paso=1

if paso==1 and O.time>0.2:

matriz2=[]
for i in range(0,len(O.bodies)):
b=O.bodies[i]
if O.bodies[i].shape.color==(0,1,0):

matriz2.append([i,b.state.pos[0],b.state.pos[1],b.state.pos[2],b.state.vel.norm()])

np.savetxt('pruebaVERDE2.out',matriz2,delimiter=',')

paso=paso+1

if paso==2 and O.time>0.4:

matriz3=[]
for i in range(0,len(O.bodies)):
b=O.bodies[i]
if O.bodies[i].shape.color==(0,1,0):

matriz3.append([i,b.state.pos[0],b.state.pos[1],b.state.pos[2],b.state.vel.norm()])

np.savetxt('pruebaVERDE3.out',matriz3,delimiter=',')

paso=paso+1

#/
#/ engines \\\
#/

O.engines=[ 
ForceResetter(),
InsertionSortCollider(
[Bo1_Sphere_Aabb(),
Bo1_Facet_Aabb(),
Bo1_Box_Aabb(),
Bo1_Wall_Aabb()]),
InteractionLoop(
[Ig2_Sphere_Sphere_ScGeom(),
Ig2_Facet_Sphere_ScGeom(),
Ig2_Wall_Sphere_ScGeom(),
Ig2_Box_Sphere_ScGeom()],
[Ip2_FrictMat_FrictMat_FrictPhys()],
[Law2_ScGeom_FrictPhys_CundallStrack()]
),
PyRunner(command='force()',
iterPeriod=1,initRun=True,label='checker'),
PyRunner(command='guardar()',
iterPeriod=1,initRun=True,label='checker'),
NewtonIntegrator(damping=0.5,gravity=(0,-9.81,0),label='newton'),
yade.qt.SnapshotE

Re: [Yade-users] [Question #268691]: Apply force only once

2015-06-30 Thread rayolau
Question #268691 on Yade changed:
https://answers.launchpad.net/yade/+question/268691

Description changed to:
Hi guys!

I try to study the displacement of various spheres ( with different
weight ) when they apply the same force, on a surface which previously
has been created and is composed of other spheres.

My problem is the IterPeriod of the PyRunner function that I create for
apply the force on the sphere that I want, in this case, green spheres.

If I put the period = 1 , the force is constantly applied .How I can apply the 
force only once? PyRunner(command='force()',
¿?¿?¿?iterPeriod=¿?¿?¿,initRun=True,label='checker'),

My first choice was to put a high period (1 for example), but
this way , the green sphere falls on the surface of spheres before the
force is applied . What I need is to apply a force on green particle
when it is "in the air " to describe a parabolic movement to fall on the
surface and stop.

The second PyRunner is to store the position data ( x , y, z) and the
green particle velocity .

Thanks in advance =)

the code:

O.load('/path/spheresurface.yade')

#/
#// materials \\\
#/

MatBal=O.materials.append(FrictMat(
young=27e9,poisson=0.30,density=1000,
frictionAngle=0.7,label='mat1'))

#/
#// green sphere
#/

### green sphere

O.bodies.append(utils.sphere((0.108,0.2289647116,0.7175),0.0199647116,color=(0,1,0),material='mat1'))


#/
# force on green sphere
#/

def force():
piedraensayo=[]

###force on green sphere
for i in range(0,len(O.bodies)):
b=O.bodies[i]
if O.bodies[i].shape.color==(0,1,0):
piedraensayo.append([i])
id_ball=i   
fx=1
fy=0
fz=0
O.forces.addF(id_ball, (fx, fy, fz))


#/
#///save position and velocity \
#/
def guardar():
if O.iter==0:
global paso
matriz1=[]
for i in range(0,len(O.bodies)):
b=O.bodies[i]
if O.bodies[i].shape.color==(0,1,0):

matriz1.append([i,b.state.pos[1],b.state.pos[1],b.state.pos[2],b.state.vel.norm()])

np.savetxt('pruebaVERDE.out',matriz1,delimiter=',')

paso=1

if paso==1 and O.time>0.2:

matriz2=[]
for i in range(0,len(O.bodies)):
b=O.bodies[i]
if O.bodies[i].shape.color==(0,1,0):

matriz2.append([i,b.state.pos[0],b.state.pos[1],b.state.pos[2],b.state.vel.norm()])

np.savetxt('pruebaVERDE2.out',matriz2,delimiter=',')

paso=paso+1

if paso==2 and O.time>0.4:

matriz3=[]
for i in range(0,len(O.bodies)):
b=O.bodies[i]
if O.bodies[i].shape.color==(0,1,0):

matriz3.append([i,b.state.pos[0],b.state.pos[1],b.state.pos[2],b.state.vel.norm()])

np.savetxt('pruebaVERDE3.out',matriz3,delimiter=',')

paso=paso+1

#/
#/ engines \\\
#/

O.engines=[ 
ForceResetter(),
InsertionSortCollider(
[Bo1_Sphere_Aabb(),
Bo1_Facet_Aabb(),
Bo1_Box_Aabb(),
Bo1_Wall_Aabb()]),
InteractionLoop(
[Ig2_Sphere_Sphere_ScGeom(),
Ig2_Facet_Sphere_ScGeom(),
Ig2_Wall_Sphere_ScGeom(),
Ig2_Box_Sphere_ScGeom()],
[Ip2_FrictMat_FrictMat_FrictPhys()],
[Law2_ScGeom_FrictPhys_CundallStrack()]
),
PyRunner(command='force()',
iterPeriod=1,initRun=True,label='checker'),
PyRunner(command='guardar()',
iterPeriod=1,initRun=True,label='checker'),
NewtonIntegrator(damping=0.5,gravity=(0,-9.81,0),label='newton'),
yade.qt.SnapshotEn

Re: [Yade-users] [Question #268691]: Apply force only once

2015-06-30 Thread rayolau
Question #268691 on Yade changed:
https://answers.launchpad.net/yade/+question/268691

Summary changed to:
Apply force only once

Description changed to:
Hi guys!

I try to study the displacement of various spheres ( with different
weight ) when on they apply the same force, on a surface which
previously has been created and is composed of other spheres.

My problem is the IterPeriod of the PyRunner function that I create for
apply the force on the sphere that I want, in this case, green spheres.

If I put the period = 1 , the force is constantly applied .How I can apply the 
force only once? PyRunner(command='force()',
¿?¿?¿?iterPeriod=¿?¿?¿,initRun=True,label='checker'),

My first choice was to put a high period (1 for example), but
this way , the green sphere falls on the surface of spheres before the
force is applied . What I need is to apply a force on green particle
when it is "in the air " to describe a parabolic movement to fall on the
surface and stop.

The second PyRunner is to store the position data ( x , y, z) and the
green particle velocity .

Thanks in advance =)

the code:

O.load('/path/spheresurface.yade')

#/
#// materials \\\
#/

MatBal=O.materials.append(FrictMat(
young=27e9,poisson=0.30,density=1000,
frictionAngle=0.7,label='mat1'))

#/
#// green sphere
#/

### green sphere

O.bodies.append(utils.sphere((0.108,0.2289647116,0.7175),0.0199647116,color=(0,1,0),material='mat1'))


#/
# force on green sphere
#/

def force():
piedraensayo=[]

###force on green sphere
for i in range(0,len(O.bodies)):
b=O.bodies[i]
if O.bodies[i].shape.color==(0,1,0):
piedraensayo.append([i])
id_ball=i   
fx=1
fy=0
fz=0
O.forces.addF(id_ball, (fx, fy, fz))


#/
#///save position and velocity \
#/
def guardar():
if O.iter==0:
global paso
matriz1=[]
for i in range(0,len(O.bodies)):
b=O.bodies[i]
if O.bodies[i].shape.color==(0,1,0):

matriz1.append([i,b.state.pos[1],b.state.pos[1],b.state.pos[2],b.state.vel.norm()])

np.savetxt('pruebaVERDE.out',matriz1,delimiter=',')

paso=1

if paso==1 and O.time>0.2:

matriz2=[]
for i in range(0,len(O.bodies)):
b=O.bodies[i]
if O.bodies[i].shape.color==(0,1,0):

matriz2.append([i,b.state.pos[0],b.state.pos[1],b.state.pos[2],b.state.vel.norm()])

np.savetxt('pruebaVERDE2.out',matriz2,delimiter=',')

paso=paso+1

if paso==2 and O.time>0.4:

matriz3=[]
for i in range(0,len(O.bodies)):
b=O.bodies[i]
if O.bodies[i].shape.color==(0,1,0):

matriz3.append([i,b.state.pos[0],b.state.pos[1],b.state.pos[2],b.state.vel.norm()])

np.savetxt('pruebaVERDE3.out',matriz3,delimiter=',')

paso=paso+1

#/
#/ engines \\\
#/

O.engines=[ 
ForceResetter(),
InsertionSortCollider(
[Bo1_Sphere_Aabb(),
Bo1_Facet_Aabb(),
Bo1_Box_Aabb(),
Bo1_Wall_Aabb()]),
InteractionLoop(
[Ig2_Sphere_Sphere_ScGeom(),
Ig2_Facet_Sphere_ScGeom(),
Ig2_Wall_Sphere_ScGeom(),
Ig2_Box_Sphere_ScGeom()],
[Ip2_FrictMat_FrictMat_FrictPhys()],
[Law2_ScGeom_FrictPhys_CundallStrack()]
),
PyRunner(command='force()',
iterPeriod=1,initRun=True,label='checker'),
PyRunner(command='guardar()',
iterPeriod=1,initRun=True,label='checker'),
NewtonIntegrator(damping=0.5,gravity=(0,-9.81,

[Yade-users] [Question #268691]: Apply force one once time

2015-06-30 Thread rayolau
New question #268691 on Yade:
https://answers.launchpad.net/yade/+question/268691

Hi guys!

I try to study the displacement of various spheres ( with different weight ) 
when on they apply the same force, on a surface which previously has been 
created and is composed of other spheres.

My problem is the IterPeriod of the PyRunner function that I create for apply 
the force on the sphere that I want, in this case, green spheres.

If I put the period = 1 , the force is constantly applied .How I can apply the 
force one once time only? PyRunner(command='force()',
¿?¿?¿?iterPeriod=¿?¿?¿,initRun=True,label='checker'),

My first choice was to put a high period (1 for example), but this way 
, the green sphere falls on the surface of spheres before the force is applied 
. What I need is to apply a force on green particle when it is "in the air " to 
describe a parabolic movement to fall on the surface and stop.

The second PyRunner is to store the position data ( x , y, z) and the green 
particle velocity .

Thanks in advance =)

the code:

O.load('/path/spheresurface.yade')

#/
#// materials \\\
#/

MatBal=O.materials.append(FrictMat(
young=27e9,poisson=0.30,density=1000,
frictionAngle=0.7,label='mat1'))

#/
#// green sphere
#/

### green sphere

O.bodies.append(utils.sphere((0.108,0.2289647116,0.7175),0.0199647116,color=(0,1,0),material='mat1'))


#/
# force on green sphere
#/

def force():
piedraensayo=[]

###force on green sphere
for i in range(0,len(O.bodies)):
b=O.bodies[i]
if O.bodies[i].shape.color==(0,1,0):
piedraensayo.append([i])
id_ball=i   
fx=1
fy=0
fz=0
O.forces.addF(id_ball, (fx, fy, fz))


#/
#///save position and velocity \
#/
def guardar():
if O.iter==0:
global paso
matriz1=[]
for i in range(0,len(O.bodies)):
b=O.bodies[i]
if O.bodies[i].shape.color==(0,1,0):

matriz1.append([i,b.state.pos[1],b.state.pos[1],b.state.pos[2],b.state.vel.norm()])

np.savetxt('pruebaVERDE.out',matriz1,delimiter=',')

paso=1

if paso==1 and O.time>0.2:

matriz2=[]
for i in range(0,len(O.bodies)):
b=O.bodies[i]
if O.bodies[i].shape.color==(0,1,0):

matriz2.append([i,b.state.pos[0],b.state.pos[1],b.state.pos[2],b.state.vel.norm()])

np.savetxt('pruebaVERDE2.out',matriz2,delimiter=',')

paso=paso+1

if paso==2 and O.time>0.4:

matriz3=[]
for i in range(0,len(O.bodies)):
b=O.bodies[i]
if O.bodies[i].shape.color==(0,1,0):

matriz3.append([i,b.state.pos[0],b.state.pos[1],b.state.pos[2],b.state.vel.norm()])

np.savetxt('pruebaVERDE3.out',matriz3,delimiter=',')

paso=paso+1

#/
#/ engines \\\
#/

O.engines=[ 
ForceResetter(),
InsertionSortCollider(
[Bo1_Sphere_Aabb(),
Bo1_Facet_Aabb(),
Bo1_Box_Aabb(),
Bo1_Wall_Aabb()]),
InteractionLoop(
[Ig2_Sphere_Sphere_ScGeom(),
Ig2_Facet_Sphere_ScGeom(),
Ig2_Wall_Sphere_ScGeom(),
Ig2_Box_Sphere_ScGeom()],
[Ip2_FrictMat_FrictMat_FrictPhys()],
[Law2_ScGeom_FrictPhys_CundallStrack()]
),
PyRunner(command='force()',
iterPeriod=1,initRun=True,label='checker'),
PyRunner(command='guardar()',
iterPeriod=1,initRun=True,label='checker'),
NewtonIntegrator(damping=0.5,gravity=(0,-9.81,0),label='newton'),
yade.qt.SnapshotEngine(file

Re: [Yade-users] [Question #268688]: harmonic average of stiffness between sphere and wall

2015-06-30 Thread Alsidqi Hasan
Question #268688 on Yade changed:
https://answers.launchpad.net/yade/+question/268688

Alsidqi Hasan posted a new comment:
Thanks so much Bruno.

Al

-- 
You received this question notification because you are a member of
yade-users, which 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 #268688]: harmonic average of stiffness between sphere and wall

2015-06-30 Thread Alsidqi Hasan
Question #268688 on Yade changed:
https://answers.launchpad.net/yade/+question/268688

Status: Answered => Solved

Alsidqi Hasan confirmed that the question is solved:
Thanks Chareyre, that solved my question.

-- 
You received this question notification because you are a member of
yade-users, which 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 #268688]: harmonic average of stiffness between sphere and wall

2015-06-30 Thread Chareyre
Question #268688 on Yade changed:
https://answers.launchpad.net/yade/+question/268688

Status: Open => Answered

Chareyre proposed the following answer:
Hello Alsidqi,
The calculation is the same, and the radius used for the wall body is
the radius of the sphere body.
Bruno

-- 
You received this question notification because you are a member of
yade-users, which 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 #268688]: harmonic average of stiffness between sphere and wall

2015-06-30 Thread Alsidqi Hasan
New question #268688 on Yade:
https://answers.launchpad.net/yade/+question/268688

Dear Yade developers/users

How yade calculates harmonic average of stiffness between sphere and wall?  In 
yade documentation I read only formulation between sphere and sphere. Questions:
Is the same formulation used between sphere and wall? 
If yes, what is the value of r for wall in the formulation used by yade? 
If no, what is the formulation?

Thank you,
Best Regards,

Alsidqi

-- 
You received this question notification because you are a member of
yade-users, which 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