# Help needed: Replicating PFC 2D example in PFC3D

**URL:** <https://forum.itascainternational.com/t/help-needed-replicating-pfc-2d-example-in-pfc3d/1540>\
**Category:** PFC\
**Tags:** tips, suggestions\
**Created:** [June 19, 2024, 10:14pm UTC](https://forum.itascainternational.com/t/help-needed-replicating-pfc-2d-example-in-pfc3d/1540 "2024-06-19T22:14:41Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![paudyalp11](https://avatars.discourse-cdn.com/v4/letter/p/9fc348/32.png) [@paudyalp11](https://forum.itascainternational.com/u/paudyalp11)\
**Post date:** [June 19, 2024, 10:14pm UTC](https://forum.itascainternational.com/t/help-needed-replicating-pfc-2d-example-in-pfc3d/1540/1 "2024-06-19T22:14:41Z")

</div>

Hi everyone,

I was trying to replicate the direct shear box example given in [this](https://docs.itascacg.com/pfc600/pfc/pfcmodule/doc/manual/wall_manual/wall_commands/cmd_wall_servo.html#wall.servo) in PFC3D. According to the manual, the example is for PFC2D, but the same procedure would work in PFC3D. While I was able to recreate the general mechanism of the direct shear test in PFC3D, I am having some trouble applying the normal load on the top of the specimen before shearing. The specimen tends to dilate, and the balls appear to spill over when I apply the servo load to the top wall, just like in the 2D example (screenshot attached).

 ![screenshot1](https://canada1.discourse-cdn.com/flex031/uploads/itasca/original/2X/3/31e2d8a1b0e1b28b3bf59a5703f26fbf9f94123b.jpeg)

I thought the most likely issue was the low porosity value of 0.17 in the 2D example, which caused it to generate a close packing with significant overlaps. I increased the porosity to 0.35, and while the spillover is not as apparent, there still seems to be an increase in volume.

 ![screenshot2](https://canada1.discourse-cdn.com/flex031/uploads/itasca/original/2X/9/9431f42fbb2c05eb4d9d01bce00eb675a1ffa771.png)

I also tried to increase the loading magnitude, which caused the walls to disappear. I therefore want some suggestions/tips on how to solve this issue. Here is my data file:  
[dss\_attempt2.dat](https://forum.itascainternational.com/uploads/short-url/sCpZ74KwGw6xJiTe1x5VY1iTe7s.dat) (2.8 KB)

Thank you,  
Prabhat

---

<div class="post-metadata">

**Author:** ![dblanksma](https://avatars.discourse-cdn.com/v4/letter/d/858c86/32.png) [@dblanksma](https://forum.itascainternational.com/u/dblanksma)\
**Post date:** [June 27, 2024, 2:34pm UTC](https://forum.itascainternational.com/t/help-needed-replicating-pfc-2d-example-in-pfc3d/1540/2 "2024-06-27T14:34:53Z")

</div>

Hello @paudyalp11  
You will most likely need to change the `gain-factor`, `gain-update` or `velocity-max` in the wall servo command in order to maintain a constant force on the wall. The initial packing of the balls will determine if the sample dilates or contract. My guess is that you have a very tight initial packing and thus the sample dilates upon shearing.

---

<div class="post-metadata">

**Author:** ![paudyalp11](https://avatars.discourse-cdn.com/v4/letter/p/9fc348/32.png) [@paudyalp11](https://forum.itascainternational.com/u/paudyalp11)\
**Post date:** [June 27, 2024, 10:21pm UTC](https://forum.itascainternational.com/t/help-needed-replicating-pfc-2d-example-in-pfc3d/1540/3 "2024-06-27T22:21:21Z")

</div>

Hi, @dblanksma, I was able to solve this issue by relaxing the physics of the balls a bit by reducing their elastic modulus. Still, I will look into changing the parameters that you mentioned. Thanks for the help.

---

<div class="post-metadata">

**Author:** ![Djameldjaafri1986](https://avatars.discourse-cdn.com/v4/letter/d/ce73a5/32.png) [@Djameldjaafri1986](https://forum.itascainternational.com/u/Djameldjaafri1986)\
**Post date:** [October 26, 2024, 7:21pm UTC](https://forum.itascainternational.com/t/help-needed-replicating-pfc-2d-example-in-pfc3d/1540/4 "2024-10-26T19:21:42Z")

</div>

Hello,

I have established a 3D direct shear test using PFC3d and it worked very well. However, i got the Peak shear test After a large displacement. While in experimental test the whole displacement test is 8 mm and the Peak reached quickly. I doubt in consolidation time. Could any one help me with this issue.

Djaafri Djamel
