Added an example of two interconnecting tubes to the repo:
fcFEM - FEA from start to finish
Moderator: bernd
Forum rules
and Helpful information for the FEM forum
and Helpful information for the FEM forum
Re: fcFEM - FEA from start to finish
These are the most thorough instructions I found for getting scikit-sparse installed on Windows and no I haven't done it myself: https://github.com/EmJay276/scikit-spar ... stallationgbParametric wrote: ↑Mon Aug 29, 2022 12:16 pm I would be interested in testing this on Windows as well, if someone manages to get this working, any tips will be apriciated.
Re: fcFEM - FEA from start to finish
I have reinstated the Drucker-Prager material model. This means that analyses with frictional materials are possible with the current version.
Here an example of an embankment (dike) with ditch. A very common sight in the Dutch landscape.
In a first analysis the material is assumed fully cohesive with a very low shear strength of 5kPa, representing undrained behavior of very soft clay.
By incrementing the self-weight it is possible to judge stability of the embankment.
The load-deflection curve indicates failure at a load factor of 0.5, implying the embankment is not stable.
The deformation shows a circular slip surface extending into the ditch.
If the embankment is built up slowly and water is allowed to drain from the soil skeleton, we can take account of some friction. Assuming this is a modest 10 degrees, the stability of the embankment becomes much better.
The load factor at failure now exceeds one, meaning the full weight can be applied.
Finally, the failure mechanism shows a smaller slip surface.
Here an example of an embankment (dike) with ditch. A very common sight in the Dutch landscape.
In a first analysis the material is assumed fully cohesive with a very low shear strength of 5kPa, representing undrained behavior of very soft clay.
By incrementing the self-weight it is possible to judge stability of the embankment.
The load-deflection curve indicates failure at a load factor of 0.5, implying the embankment is not stable.
The deformation shows a circular slip surface extending into the ditch.
If the embankment is built up slowly and water is allowed to drain from the soil skeleton, we can take account of some friction. Assuming this is a modest 10 degrees, the stability of the embankment becomes much better.
The load factor at failure now exceeds one, meaning the full weight can be applied.
Finally, the failure mechanism shows a smaller slip surface.
Re: fcFEM - FEA from start to finish
I have implemented the Mohr Coulomb model. Although the Drucker Prager model runs about twice as fast, it has the drawback that it only approximates the frictional behavior of soils and therefore usually over-predicts collapse loads.
I used the following smooth strip footing problem to validate the implementation of the Mohr Coulomb model:
and modeled this with the following coarse mesh:
By taking account of symmetry, only half the problem needs to be modeled.
For the chosen material parameters, the Prandtl solution predicts a collapse pressure of 14.835 times the cohesion. For the footing dimensions chosen in FreeCAD (0.5x0.25m) this yields a 909 kN collapse load. The fcFEM analysis predicts a collapse load of 928 kN or 2% above the theoretical solution.
Although the Prandtl solution (like most theoretical solutions for collapse loads) is only valid for material with PHI = PSI, it is used in practical engineering regardless of this limitation. To judge the validity of this approach, I repeated the analysis for PHI = 20 degrees and PSI = 0 degrees.
As can be seen from the load-deflection curve, now the collapse load reduces to 880 kN (3% below the Prandtl solution). So the assumption that the dilation angle PSI doesn't matter is incorrect.
The sensitivity to PSI can be explained as follows. When the soil dilates at failure and is restricted to do so due to physical or modelling constraints, the pressure will go up and increase the frictional strength. In the current analysis the combination of a high Poission's ratio and limited mesh size makes the analysis extra sensitive to the choice of dilation angle.
I used the following smooth strip footing problem to validate the implementation of the Mohr Coulomb model:
and modeled this with the following coarse mesh:
By taking account of symmetry, only half the problem needs to be modeled.
For the chosen material parameters, the Prandtl solution predicts a collapse pressure of 14.835 times the cohesion. For the footing dimensions chosen in FreeCAD (0.5x0.25m) this yields a 909 kN collapse load. The fcFEM analysis predicts a collapse load of 928 kN or 2% above the theoretical solution.
Although the Prandtl solution (like most theoretical solutions for collapse loads) is only valid for material with PHI = PSI, it is used in practical engineering regardless of this limitation. To judge the validity of this approach, I repeated the analysis for PHI = 20 degrees and PSI = 0 degrees.
As can be seen from the load-deflection curve, now the collapse load reduces to 880 kN (3% below the Prandtl solution). So the assumption that the dilation angle PSI doesn't matter is incorrect.
The sensitivity to PSI can be explained as follows. When the soil dilates at failure and is restricted to do so due to physical or modelling constraints, the pressure will go up and increase the frictional strength. In the current analysis the combination of a high Poission's ratio and limited mesh size makes the analysis extra sensitive to the choice of dilation angle.
Re: fcFEM - FEA from start to finish
A better demonstration of the effect of dilation is the so-called trapdoor problem. It represents a trapdoor under a layer of soil that is raised to measure the resistance. The latter case is representative of a flat anchor pulled from the soil.
In the first analysis I take friction angle PHI=30 degrees and dilation angle PSI=0 degrees to represent a realistic non-dilatent soil. The cohesion is kept at 10 kPa in all analyses. The first picture shows that the deformation at failure is restricted to a rather narrow region above the trapdoor.
This is even better visible if we project the velocity arrows at failure:
However, if we increase the dilation angle to PSI=30 degrees, the deformation spreads out over the width of the model
and the velocity arrows show a conical slip surface
Due to the longer slip surface, the collapse load in the second analysis is also much higher than in the first analysis
So, this example conclusively demonstrates the importance of dilation for collapse analyses
In the first analysis I take friction angle PHI=30 degrees and dilation angle PSI=0 degrees to represent a realistic non-dilatent soil. The cohesion is kept at 10 kPa in all analyses. The first picture shows that the deformation at failure is restricted to a rather narrow region above the trapdoor.
This is even better visible if we project the velocity arrows at failure:
However, if we increase the dilation angle to PSI=30 degrees, the deformation spreads out over the width of the model
and the velocity arrows show a conical slip surface
Due to the longer slip surface, the collapse load in the second analysis is also much higher than in the first analysis
So, this example conclusively demonstrates the importance of dilation for collapse analyses
Re: fcFEM - FEA from start to finish
Great, especially since CalculiX doesn't support this material model and the Drucker-Prager model is also unavailable there normally (but at least it can be found as an example of UMAT subroutine in the documentation).
Re: fcFEM - FEA from start to finish
The README on the GitHub repo for Scikit-Sparse was updated late last year with a section on Windows installation: https://github.com/scikit-sparse/scikit ... /README.md. I don't have a Windows machine so cannot test it myself.Syres wrote: ↑Wed Aug 31, 2022 4:27 pmThese are the most thorough instructions I found for getting scikit-sparse installed on Windows and no I haven't done it myself: https://github.com/EmJay276/scikit-spar ... stallationgbParametric wrote: ↑Mon Aug 29, 2022 12:16 pm I would be interested in testing this on Windows as well, if someone manages to get this working, any tips will be apriciated.
Re: fcFEM - FEA from start to finish
The following should work:
1) download Miniforge3: https://github.com/conda-forge/miniforg ... x86_64.exe
2) run the installer: Miniforge3-Windows-x86_64.exe
3) find and run Miniforge Prompt on your system - this opens a Miniforge Prompt: (base) C:\"path">
4) create a new virtual environment: (base) C:\"path"> mamba create --name fcFEM (or any other name of your choice)
5) change into the new environment: (base) C:\"path"> mamba activate fcFEM (or the other name you chose)
6) install freeCAD and dependencies: (fcFEM) C:\"path"> mamba install freecad scipy numba matplotlib scikit-sparse (with spaces and no commas)
7) check with python if the dependencies can be imported: (fcFEM) C:\"path"> python
8) >>> import scipy.sparse
9) >>> import sksparse.cholmod
10) if no problems quit python and start freecad: (fcFEM) C:\"path"> freecad
The details of where to install fcFEM itself can be found in the README file: https://github.com/HarryvL/fcFEM-basic#readme
Could somebody with a Windows machine please test this and let us know?
1) download Miniforge3: https://github.com/conda-forge/miniforg ... x86_64.exe
2) run the installer: Miniforge3-Windows-x86_64.exe
3) find and run Miniforge Prompt on your system - this opens a Miniforge Prompt: (base) C:\"path">
4) create a new virtual environment: (base) C:\"path"> mamba create --name fcFEM (or any other name of your choice)
5) change into the new environment: (base) C:\"path"> mamba activate fcFEM (or the other name you chose)
6) install freeCAD and dependencies: (fcFEM) C:\"path"> mamba install freecad scipy numba matplotlib scikit-sparse (with spaces and no commas)
7) check with python if the dependencies can be imported: (fcFEM) C:\"path"> python
8) >>> import scipy.sparse
9) >>> import sksparse.cholmod
10) if no problems quit python and start freecad: (fcFEM) C:\"path"> freecad
The details of where to install fcFEM itself can be found in the README file: https://github.com/HarryvL/fcFEM-basic#readme
Could somebody with a Windows machine please test this and let us know?
Last edited by HarryvL on Mon Oct 02, 2023 3:40 pm, edited 2 times in total.
Re: fcFEM - FEA from start to finish
I tried this on my friendly neighbour's Windows machine and it works.
PS: I did hit this problem: viewtopic.php?t=36087&start=40#p710705 and solved it with the workaround here: viewtopic.php?t=36087&start=40#p679070
PS: I did hit this problem: viewtopic.php?t=36087&start=40#p710705 and solved it with the workaround here: viewtopic.php?t=36087&start=40#p679070