LIGGGHTS w bonds 3.8.0 fix

Submitted by tjleps on Thu, 05/10/2018 - 21:26

modifying LIGGGHTS with bonds to work with 3.8.0 by changing the seed argument to type char

in fix_bond_create_gran.h:

69: delete "seed" from int declarations
add "const char *seed"
add "bool proc_shift = 1;"

in fix_bond_create_gran.cpp:

90:delete line
112: get rid of atoi so seed is still the string
129:change to "random = new RanMars(lmp,seed,proc_shift,1);"

It should now compile just fine and has the same functionality as the original for random bond creation.

bakyym | Wed, 08/01/2018 - 10:06

Hi tjleps
I have tried your way to make the bonds model work for liggghts 3.8.0. But it failed. it still can't compile in 3.8.0. After I typed 'make auto' in src file, it just showed 'Makefile:1389: recipe for target 'fix_bond_create_gran.o' failed'. Do you have any ideas to fix this?It really bothers me .
Regards

tjleps | Wed, 01/30/2019 - 20:18

Sorry for the very late reply, but you must also delete line 90:"int seed = 12345;" in fix_bond_create_gran.cpp. I have edited the original post to reflect this.

tjleps | Fri, 09/14/2018 - 20:06

Sorry, I haven't been on the forums in a while. I'm not sure exactly what's going wrong, but I can check my code to see if I missed something in this post.

lumblab227 | Sun, 11/10/2019 - 14:00

(1) I have successfully compiled the 3.8.0 with bonds.
(2) When I use the fix create bonds, it showed INTERNAL ERROR: ERROR: Internal error: NULL seed_char (../random.cpp:58)

Could you please clarify if this issue happened in your situation? Thanks!

lumblab227 | Sun, 11/10/2019 - 17:53

I have called the fix create bonds just as I did with v.3.7.0, which is also provided in your examples. Shall I change some parsing or input parameters on the command lines?

lumblab227 | Sun, 11/10/2019 - 17:58

fix bondcr all bond/create/gran 1 1 1 ${bond_skin} 1 6
run 1
fix_modify bondcr every 0

those lines are working nicely with v3.7.0.

As far as i could see, one issue is v.3.8.0 has changed the way of random seed generation, which you could clearly see the difference between create_atom.cpp(v3.7.0) and create_atom.cpp(v.3.8.0).

mschramm | Wed, 11/13/2019 - 19:03

Hello,
With the deletion of line 90, either a new default seed char will need to be given in the code or you will need to add the "prob" flag to the call
fix bondcr all bond/create/gran 1 1 1 ${bond_skin} 1 6 prob 1.0 123457
prob 1.0 123457 sets the seed and says that there is a 100% chance that if a bond could form, it will form.

The null error is coming from the variable seed being declared in the header but never assigned a value.

I have not tested this but from looking at the code, this should be what is needed.

lumblab227 | Sun, 11/24/2019 - 18:00

Thanks and congrats to your success in research.
I have just tested a simple case. However, the kinetic energy is zero, which would also lead to 0 stress in all three directions. Again, the script is the same, I have not changed anything.

And, do you think it is possible to use superquadric particles along with bonded spherical particles?

tjleps | Wed, 11/13/2019 - 19:20

Sorry, I always call the command with a probability, though often have it set to 1, so I never encountered that problem, and completely forgot to initialize it because of that.
Thanks mschramm.

mschramm | Sun, 11/24/2019 - 21:11

Hello,
I have started to port things over and have bonds working on 3.8. I have gone through my examples and everything looks to be in order.
I went through the thread again and I didn't see a input file. Could you either post the script here or email it to me? mschramm@iastate.edu

As far as using superquadratics and bonds, I would recommend not doing so. The bond calculations will need to be redone to accurately describe the bond shape.
This would not stop anyone from just using the bond blindly. This probably would not effect simulations using bond as a cohesion style bond while for simulations
to describe straw stalks could be greatly effected by this. You would also need to worry about how contacts effect things. Currently, both bonds and contacts are calculated,
so if 2 spheres are bonded together and are in compression, then both the force normal in the contact model and the force normal in the bond model will be calculated
and added together.
FYI, LIGGGHTS_FLEXIBLE_FIBERS and LIGGGHTS-WITH-BONDS are in BETA and should be used with CAUTION...
Maybe in LIGGGHTS 4.0 (if it gets released...) will include their implementation of the bond model...

lumblab227 | Sat, 11/30/2019 - 15:57

Thanks, Mschramm. I have just sent a simple script to your email address. I have attached the script and log file. The issue is about the calculation of kinetic energy (always 0) and stress tensor (always 0) no matter what. Would you mind taking a moment to look at it?

Kind regards,
Lumb

lumblab227 | Sat, 11/30/2019 - 16:39

And I just test the cantilever beam case with v.3.8.0 w/ bond as you might have done. It shows: Signal: Segmentation fault (11)

Would you mind sharing your log file with this script running?

lcraul | Sat, 01/18/2020 - 12:55

Dear mschramm,
I'm a new user of LIGGGHTS and CFDEM. I want to do a simulation on the fluid flow through a particle packing between two rock type plates. The spicial issue is that both the rock plate and the particle are expected to be consisted of small particles and broken into small particles under a critical stress condition. So, I plan to use the LIGGGHTS_Flexible_Fibers you developed. It is a great work which I think is very suitable for my case. However, I have a few question on how to use it.
(1) Is it a full release as LIGGGHTS@public? Does it need to be built tha same way as the LIGGGHTS@public?
(2) Can the LIGGGHTS_Flexible_Fibers be coupled with CDEDM?
(3) How can I build the LIGGGHTS_Flexible_Fibers alone or based on the LIGGGHTS@public? How to compile it into the CFDEM?
Your response is really important to me. Looking forward to your reply.
Best,
regards

lcraul

mschramm | Sat, 01/18/2020 - 19:50

Hello,
1) All functionality of the public version should be available in the flexible fibers version and can be built by simply typing make auto.
2) I have yet to try this but I see no additional problems from using the flexible fibers code. There is a issue with multisphere particles in general.
The way the drag forces work, drag is applied to each particle in a multisphere equally. This is accounted for in the private version of LIGGGHTS.
3) I do not fully understand this question. All files are included in the src directory. Once you have downloaded the src files, you should only need
to type make auto to build LIGGGHTS_Flexible_Fibers. There should be no extra steps when coupling with CFDEM.

zhbkro | Mon, 11/29/2021 - 08:51

Hey guys,
now I am trying to compile LIGGGHTS_Flexible_Fibers, i did all steps which were shown in DOCS folder, but when I tried to run an example in BondPackage folder, i got an error which says :Invalid Atom style (it also shows that version liggghts 3.3.1 compiled by Kloss) , could you please help me to compile the examples to run in a proper way? Actually I am using 3.8 version. Thank you in advance, hope for your help.

mschramm | Mon, 11/29/2021 - 20:44

Hello,
How did you call the command? Did you simply type "liggghts -in in.liggghts" ?
Did you also install liggghts via a package manager (apt, yum, pacman)?

If you compiled successfully, you can try running the test_case python script as that calls the lmp_auto executable itself.
If this works, then you need to check how you created the symbolic links.