← Back to team overview

yade-users team mailing list archive

Re: [Question #679154]: run FEMxDEM examples

 

Question #679154 on Yade changed:
https://answers.launchpad.net/yade/+question/679154

    Status: Open => Answered

Janek Kozicki proposed the following answer:
Hi,

I did spend some time trying to get FEMxDEM examples to work. I am
not 100% satisfied, perhaps if you are determined enough we can both
improve the documentation for this in https://yade-dev.gitlab.io/trunk/FEMxDEM.html

However perhaps we will need some help from FEMxDEM original author,
hence I am sending this email also to Ning Guo. Bruno mentioned that Ning has 
successors in HK, I am not sure who are they, but maybe they can help
too, if Ning is not available. We just need to find them ;)

Regarding your present error:

https://gitlab.com/yade-
dev/trunk/blob/master/examples/FEMxDEM/biaxialSmooth.py#L10

your command 5. is too short, the first argument is the position of
your yade executable. I have written it as '/path/to/yade'

If you are not sure where is your yade executabe, you can type command:

  which yade

And then use it in place of '/path/to/yade' in command:

ln -s /path/to/yade ../../py/FEMxDEM/yadeimport.py

It is because yade must be imported inside a FEMxDEM python script.
So this command creates a symbolic link 'ln -s' pointing to original
yade exectuable, and this symlink is called yadeimport.py and is
placed inside py/FEMxDEM directory (not the examples dir!) So that
the FEMxDEM scripts can find it.

Regarding yade version, I would suggest the recently released 2019.01a
version. But it is very likely that 2018.02b will work too.

best regards
Janek

PS: I will be able to have a closer look on weekend at that.

jamespaul said:     (by the date of Wed, 13 Mar 2019 07:03:26 -0000)

> Question #679154 on Yade changed:
> https://answers.launchpad.net/yade/+question/679154
> 
> Summary changed to:
> run FEMxDEM examples
> 
> Description changed to:
> Hi,
> 
> I want to run a FEMxDEM code,
> 
> Learning from 'examples/FEMxDEM/biaxialSmooth.py',i entered the
> following 6 commands in the terminal:
> 
> 1 sudo apt install python-escript
> 2 cd /usr/share/doc/yade/examples
> 3 export PYTHONPATH="/usr/lib/x86_64-linux-gnu/yade/py/yade/FEMxDEM"
> 4 export LD_LIBRARY_PATH=/usr/lib/python-escript/lib
> 5 ln -s /usr/share/doc/yade/examples/FEMxDEM/prepareRVE.py
> 
> error:ln: invalid option -- '/'
> Try 'ln --help' for more information.
> 
> 6 ln -s/usr/share/doc/yade/examples/FEMxDEM/prepareRVE.py
> /usr/share/doc/yade/examples/FEMxDEM/biaxialSmooth.py
> 
> error:ln: invalid option -- '/'
> Try 'ln --help' for more information.
> 
> >I think the 5th step is wrong,because i haven't 'ln yade-versionNo  
> yadeimport.py'.How do I generate this file and connect with
> biaxialSmooth.py? Via prepareRVE.py?
> 
> >The version of YADE should be at least rev3682 in which Bruno added the stringToScene function.  
> My Yade version: 2018.02b.Is rev3682 a version of yadedaily?
> 
> Thanks in advance,
> 
> James
> 
> -- 
> 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@xxxxxxxxxxxxxxxxxxx
> Unsubscribe : https://launchpad.net/~yade-users
> More help   : https://help.launchpad.net/ListHelp


-- 
Janek Kozicki                               http://janek.kozicki.pl/  |

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