For me I haven’t encountered such issue. What does the error message “the matrix is not invertibleDeff_tim” mean? The stiffness matrix is not invertible?
there are clearly something wrong with your mesh, look at the nodes for that element for dehomogenization run, we find out 72566=72650, 72562=72582. Those are identical nodes. I will debug later why homogenization do not report this mistake.
72566 1.500000060000e-01 2.960129870000e-03 -9.799511170000e-03
72562 1.500000060000e-01 4.159276370000e-03 -9.664834480000e-03
72582 1.500000060000e-01 4.159276370000e-03 -9.66834480000e-03
72650 1.500000060000e-01 2.960129870000e-03 -9.79511170000e-03
80000 1.490000040000e-01 3.189816140000e-03 -9.599932470000e-03
79996 1.490000040000e-01 4.139665050000e-03 -9.299265220000e-03
80016 1.490000040000e-01 4.398901950000e-03 -1.007749890000e-02
80084 1.490000040000e-01 3.490134140000e-03 -1.018460560000e-02
I find a version which can reproduce the error message.
I wrote a script to identify nodes with identical coordinates, turned out there are some nodes with the same coordinates (highlighted in the screenshot below). I am not sure why Abaqus creates identical nodes. I will look into it.
After some debugging I realized the cause of distorted elements shown in dehomongezation process is not caused by different nodes having identical coordinates, as they do not form bad elements, but because some elements have bad qualities. And such bad elements are not highlighted by abaqus (it seems abaqus’s built-in mesh quality check is not very reliable on checking mesh quality and there might be hidden bad elements that abaqus miss). I wrote a script to automatically highlight elements that swiftcomp complains about and moved the nodes to form better elements. After these fixes I have obtained the results for dehomogenization.
Also I wrote a script to merge the nodes that share the same coordinates, so there is no duplicate nodes in the sc file.
It is interesting that Swiftcomp has a stricter check on the element quality by calculating the jacobian during the dehomogenization process but not the homogenization process.
This is a bug, and will be fixed later in the next release.
I am trying to visualize displacement/stress distribution using the outputs from dehomogenization, but the script I wrote wasn’t working for me. Could you share an example for how visualization works for 3D SG?
The input file for dehomogenization:
wing3dSG_adjusted.sc
wing3dSG_adjusted.sc.glb
The output files from dehomogenization:
wing3dSG_adjusted.sc.u
wing3dSG_adjusted.sc.sg
wing3dSG_adjusted.sc.sn
wing3dSG_adjusted.sc.snm
wing3dSG_adjusted.sc.sgm
I have update sgio to read swiftcomp dehomogenization output and write it to gmsh data for visualization.
Please update the sgio to the latest version (v0.2.12)
pip install -U sgio
Attached is an example script showing how to use the function test.py.txt (1.1 KB)
Note: You need to use
swiftcomp input.sc 1D LG
to generate the output in the gmsh format. The native output format (without G
) does not work.
Thank you so much for the update @su.tian.22
The example script you showed is working for my outputs, but this is what I saw in gmsh.
The contour plot for stress doesn’t seem ideal and the mesh is interfering with the contour plot. I would wish to cut the geometry in half and disable mesh (no elements or nodes) for better visualization, but it seems difficult on gmsh. I am wondering if I could find a tool to convert to odb file for visualization on Abaqus which gives me more control for how I visualize the output. If no such tool exists, I may need to make a tool of my own to visualize on Abaqus.
You can try the following in gmsh:
- Double right click → Mesh visibility → Turn off all edges
- Menu → Tools → Clipping: You can create plane cuts to see internal elements.
@su.tian.22 thanks for your help on this!
I encountered this error when running swiftcomp for a finer mesh using quadratic 3d elements to see if the results have truly converged.
Command:
swiftcomp wing3dSG_adjusted.sc 1D H
Message:
SwiftComp begins at 203344.680
Inputs echoed in file wing3dSG_adjusted.sc.ech!
Constitutive modeling for a 1D (beam) model!
Homogenization will be carried out!
You are running SwiftComp with full integration!
Finished reading/processing model file!
Effective properties can be found in file wing3dSG_adjusted.sc.k!
error from factor and solve of sparse solver with info%flag= -12
I am not sure what the error error from factor and solve of sparse solver with info%flag= -12
means.
Most likely, you had some unsuccessful run. Please delete all temporary files before re-run it.
Based on some of my tests I figured out the following:
- For the same mesh, swiftcomp works for linear elements (8 node solid element) and the homogenization results are correct, but when I convert the elements to quadratic (20 node solid element), swiftcomp does not work for the error message
error from factor and solve of sparse solver with info%flag= -12
. - Starting with a clean sc file does not seem to address the issue of
error from factor and solve of sparse solver with info%flag= -12
- I encountered two scenarios of failure using the same sc file with quadratic elements, one is
error from factor and solve of sparse solver with info%flag= -12
and another one is Swiftcomp exiting before completing calculation without any warning/error.
Command:
swiftcomp wing3dSG_quadratic.sc 1D H
Swiftcomp stops running afterEffective properties can be found in file wing3dSG_quadratic.sc.k!
is printed out. Swiftcomp exited 1-2 seconds after running, but in fact it needs at least 1 min to finish calculation as the sc file is very large (has over 700k nodes). The k file and opt file are empty except for the ech file which contains complete data.
I also attempted to use group server with the same sc file using quadratic elements. It looks like swiftcomp also stopped working after running.
How many elements/nodes you have. If it is close to be one millions nodes, it might have some difficulty for normal computers.
From the query:
Total number of nodes: 701449
Total number of elements: 152478
58077 quadratic hexahedral elements of type C3D20R
94401 quadratic wedge elements of type C3D15
can you share the input file with me for me to take a look?
The sc file I used is wing3dSG_quadratic.sc