Skip to content

Commit dbd1712

Browse files
committed
Merged with release-2.5
2 parents c1fc45b + c2f97a1 commit dbd1712

178 files changed

Lines changed: 6442 additions & 4116 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

Documentation/FEBioStudioReleaseNotes.txt

Lines changed: 54 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,60 @@
44

55
*****************************************************************
66

7+
===========================================================================
8+
9+
R E L E A S E 2.5 1/16/2024
10+
11+
===========================================================================
12+
13+
New Features:
14+
* Added "physics" color mode option, which colors each surface depending on how it is used in the model's loads and boundary conditions.
15+
* Added support for file extension dyn (will read lsdyna input file).
16+
* Added support for exporting 3D image data to several formats.
17+
* Added support for reading and writing quadratic beam elements to febio4 format.
18+
19+
Improvements:
20+
* Inverted faces but not elements in NetGen mesher, to produce correct mesh output upon conversion to editable mesh.
21+
* Added ability to merge multiple STEP objects into single STEP object upon import, allowing conforming meshing with Netgen
22+
* Added Fluent mesh exporting capability
23+
* Added a log message when attempting to export wrong Mesh type to Fluent. Made export distinguish mixed face types versus uniform face types
24+
* Updated copyright statement on splash and about box.
25+
* Added febio format 4.0 export for post docs.
26+
* Added nodal fluid flux plot variable to FSI analyses
27+
* Deletion of multiple parts will now process much faster.
28+
* All new documents are now added to the recent files list.
29+
* Added icons to model search panel, and a column for the type. Filter now also searches type strings.
30+
* Implemented more efficient way of tracking output when running febio in a thread.
31+
* Modified mesh building algorithm in post lsdyna importer to speed it up.
32+
* In the Project panel, added support to load fs2 files via folder import, and fixed bug when moving files to a folder.
33+
* Added options to set caps when rendering smooth paths and cylinders. Beam ends are now rendered as flat. Fixed issue with rendering colormaps on solid beams.
34+
35+
Bug Fixes:
36+
* Fixed issue with FSModel::GetEnumValues for getting dof_list.
37+
* Fixed some issues with reading feb3 files.
38+
* Added checks when rendering objects to make sure a valid render mesh exists.
39+
* Timeline panel is now updated when states are deleted.
40+
* Fixed issue with saving the correct model file name when saving fsps files.
41+
* Fixed issue with reading surfaces of febio files that uses node numbering that does not start at one.
42+
* Fixed issue with rendering images with correct orientation in slice view. Also fixed bug in rendering z-slice.
43+
* Updated ImageMap tool and WarpImageFilter to work with rotated images. Fixed bug caused by missing cases in 3DImage::Value
44+
* Fixed bug in loading models with DICOM images
45+
* Fixed issue with volume rendering images with orientation.
46+
* Image models are now rendered with correct orientation.
47+
* Fixed issue in kinemat build tool.
48+
* Fixed problem with input of numbers in a property form.
49+
* Fixed issue where shell IDs were not copied from lsdyna file.
50+
* Fixed issue with rare case where elements have duplicate IDs.
51+
* Fixed string overflow in FEBio import.
52+
* Fixed issue with importing nodesets from old feb files.
53+
* Fixed issue with volume rendering of signed int image data.
54+
* Made some fixes to old febio and nike3d file readers.
55+
* Fixed bug in rendering of general springs.
56+
* Fixed problem with reading discrete element sets from LSDYNA file.
57+
* Fixed bug in curve-projection tool that did not take transform of curves into account.
58+
* Fixed issue with rendering half-spheres in special case.
59+
60+
761
===========================================================================
862

963
R E L E A S E 2.4 11/15/2023

Documentation/FEBioStudio_User_Manual.lyx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -124,13 +124,13 @@ status open
124124
User's Manual
125125
\series default
126126
\emph on
127-
Version 2.4
127+
Version 2.5
128128
\end_layout
129129

130130
\begin_layout Date
131131

132132
\series bold
133-
Last Updated: November 15, 2023
133+
Last Updated: January 16, 2024
134134
\end_layout
135135

136136
\begin_layout Standard
1.93 KB
Binary file not shown.

Documentation/Figures/graph.png

35.5 KB
Loading

FEBio/FEBioException.h

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,9 +25,7 @@ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
2525
SOFTWARE.*/
2626

2727
#pragma once
28-
#include <string>
2928
#include <FSCore/FSObject.h>
30-
3129
#include <string>
3230

3331
using std::string;

FEBio/FEBioExport25.cpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2634,6 +2634,7 @@ const char* ElementTypeString(int ntype)
26342634
case FE_PENTA15: sztype = "penta15"; break;
26352635
case FE_PYRA13 : sztype = "pyra13"; break;
26362636
case FE_BEAM2 : sztype = "line2"; break;
2637+
case FE_BEAM3 : sztype = "line3"; break;
26372638
default:
26382639
assert(false);
26392640
}

FEBio/FEBioFormat.cpp

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -522,6 +522,13 @@ bool FEBioFormat::ParseControlSection(XMLTag& tag)
522522
FEBioInputModel& febio = GetFEBioModel();
523523
FSModel& fem = GetFSModel();
524524

525+
if (m_nAnalysis == -1)
526+
{
527+
int moduleId = FEBio::GetModuleId("solid");
528+
if (moduleId < 0) { throw XMLReader::InvalidAttributeValue(tag, "type", "solid"); }
529+
FileReader()->GetProject().SetModule(moduleId, false);
530+
}
531+
525532
// create a new analysis step from these control settings
526533
if (m_pstep == 0) m_pstep = NewStep(fem, m_nAnalysis);
527534
FSAnalysisStep* pstep = dynamic_cast<FSAnalysisStep*>(m_pstep);
@@ -1118,6 +1125,9 @@ FSMaterial* FEBioFormat::ParseMaterial(XMLTag& tag, const char* szmat, int propT
11181125
// HACK: a little hack to read in the "EFD neo-Hookean2" materials of the old datamap plugin.
11191126
if (strcmp(szmat, "EFD neo-Hookean2") == 0) pm = FEMaterialFactory::Create(fem, "EFD neo-Hookean");
11201127

1128+
// HACK: "St.Venant-Kirchhoff" was renamed to "isotropic elastic"
1129+
if (strcmp(szmat, "St.Venant-Kirchhoff") == 0) pm = FEMaterialFactory::Create(fem, "isotropic elastic", propType);
1130+
11211131
// FBS1 never supported these materials, so we'll just use the FEBio classes.
11221132
if ((strcmp(szmat, "remodeling solid" ) == 0) ||
11231133
(strcmp(szmat, "hyperelastic" ) == 0) ||

FEBio/FEBioFormat3.cpp

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,6 @@ SOFTWARE.*/
2727
#include "stdafx.h"
2828
#include "FEBioFormat3.h"
2929
#include <FEMLib/FERigidConstraint.h>
30-
#include <GeomLib/FSGroup.h>
3130
#include <GeomLib/GMeshObject.h>
3231
#include <FEMLib/FEInitialCondition.h>
3332
#include <FEMLib/FEBodyLoad.h>
@@ -1010,7 +1009,7 @@ void FEBioFormat3::ParseGeometrySurface(FEBioInputModel::Part* part, XMLTag& tag
10101009

10111010
// make zero-based
10121011
vector<int> node(N);
1013-
for (int j = 0; j < N; ++j) node[j] = nf[j] - 1;
1012+
for (int j = 0; j < N; ++j) node[j] = nf[j];// -1;
10141013
s.m_face.push_back(node);
10151014

10161015
++tag;
@@ -1312,6 +1311,13 @@ bool FEBioFormat3::ParseSurfaceDataSection(XMLTag& tag)
13121311
}
13131312
else dataType = FEMeshData::DATA_TYPE::DATA_SCALAR;
13141313

1314+
const char* szgen = tag.AttributeValue("generator", true);
1315+
if (szgen)
1316+
{
1317+
tag.skip();
1318+
return true;
1319+
}
1320+
13151321
FSSurface* feSurf = feb.FindNamedSurface(surf->cvalue());
13161322
FSMesh* feMesh = feSurf->GetMesh();
13171323

FEBio/FEBioFormat4.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,6 @@ SOFTWARE.*/
2626

2727
#include "stdafx.h"
2828
#include "FEBioFormat4.h"
29-
#include <GeomLib/FSGroup.h>
3029
#include <GeomLib/GMeshObject.h>
3130
#include <FEMLib/FEInitialCondition.h>
3231
#include <FEMLib/FEBodyLoad.h>
@@ -671,6 +670,7 @@ void FEBioFormat4::ParseGeometryElements(FEBioInputModel::Part* part, XMLTag& ta
671670
else if (strcmp(sztype, "TRI6G14" ) == 0) ntype = FE_TRI6;
672671
else if (strcmp(sztype, "TRI6G21" ) == 0) ntype = FE_TRI6;
673672
else if (strcmp(sztype, "line2" ) == 0) ntype = FE_BEAM2;
673+
else if (strcmp(sztype, "line3" ) == 0) ntype = FE_BEAM3;
674674
else throw XMLReader::InvalidTag(tag);
675675

676676
// get the optional material attribute
@@ -902,9 +902,9 @@ void FEBioFormat4::ParseGeometrySurface(FEBioInputModel::Part* part, XMLTag& tag
902902
// read the node numbers
903903
tag.value(nf, N);
904904

905-
// make zero-based
905+
// copy to vector
906906
vector<int> node(N);
907-
for (int j = 0; j < N; ++j) node[j] = nf[j] - 1;
907+
for (int j = 0; j < N; ++j) node[j] = nf[j];
908908
s.m_face.push_back(node);
909909

910910
++tag;

FEBio/FEBioFormatOld.cpp

Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -103,6 +103,12 @@ bool FEBioFormatOld::ParseModuleSection(XMLTag &tag)
103103
assert(false);
104104
}
105105
*/
106+
107+
const char* sztype = atype.cvalue();
108+
int moduleId = FEBio::GetModuleId(sztype);
109+
if (moduleId < 0) { throw XMLReader::InvalidAttributeValue(tag, "type", sztype); }
110+
FileReader()->GetProject().SetModule(moduleId, false);
111+
106112
return (m_nAnalysis != -1);}
107113

108114
//=============================================================================
@@ -484,6 +490,7 @@ void FEBioFormatOld::ParseBCFixed(FSStep* pstep, XMLTag &tag)
484490

485491
// create a nodeset of this BC
486492
FSNodeSet* pg = new FSNodeSet(po);
493+
po->AddFENodeSet(pg);
487494

488495
// assign the nodes to this group
489496
for (int i = 0; i<N; ++i) if (BC[i] & ntype) { pg->add(i); BC[i] &= (~ntype); }
@@ -494,6 +501,7 @@ void FEBioFormatOld::ParseBCFixed(FSStep* pstep, XMLTag &tag)
494501
FSFixedDisplacement* pbc = new FSFixedDisplacement(&fem, pg, ntype, pstep->GetID());
495502
sprintf(szname, "FixedDisplacement%02d", CountBCs<FSFixedDisplacement>(fem)+1);
496503
pbc->SetName(szname);
504+
pg->SetName(szname);
497505
pstep->AddComponent(pbc);
498506
}
499507
else if (ntype < 64)
@@ -502,20 +510,23 @@ void FEBioFormatOld::ParseBCFixed(FSStep* pstep, XMLTag &tag)
502510
FSFixedRotation* pbc = new FSFixedRotation(&fem, pg, ntype, pstep->GetID());
503511
sprintf(szname, "FixedRotation%02d", CountBCs<FSFixedRotation>(fem)+1);
504512
pbc->SetName(szname);
513+
pg->SetName(szname);
505514
pstep->AddComponent(pbc);
506515
}
507516
else if (ntype == 64)
508517
{
509518
FSFixedTemperature* pbc = new FSFixedTemperature(&fem, pg, 1, pstep->GetID());
510519
sprintf(szname, "FixedTemperature%02d", CountBCs<FSFixedTemperature>(fem)+1);
511520
pbc->SetName(szname);
521+
pg->SetName(szname);
512522
pstep->AddComponent(pbc);
513523
}
514524
else if (ntype == 128)
515525
{
516526
FSFixedFluidPressure* pbc = new FSFixedFluidPressure(&fem, pg, 1, pstep->GetID());
517527
sprintf(szname, "FixedFluidPressure%02d", CountBCs<FSFixedFluidPressure>(fem)+1);
518528
pbc->SetName(szname);
529+
pg->SetName(szname);
519530
pstep->AddComponent(pbc);
520531
}
521532
else
@@ -526,6 +537,7 @@ void FEBioFormatOld::ParseBCFixed(FSStep* pstep, XMLTag &tag)
526537
FSFixedConcentration* pbc = new FSFixedConcentration(&fem, pg, ntype, pstep->GetID());
527538
sprintf(szname, "FixedConcentration%02d", CountBCs<FSFixedConcentration>(fem)+1);
528539
pbc->SetName(szname);
540+
pg->SetName(szname);
529541
pstep->AddComponent(pbc);
530542
}
531543
}
@@ -612,6 +624,7 @@ void FEBioFormatOld::ParseBCPrescribed(FSStep* pstep, XMLTag& tag)
612624
}
613625

614626
// create the prescribed BC
627+
FEBioInputModel& feb = GetFEBioModel();
615628
FSModel& fem = GetFSModel();
616629
char szname[256];
617630
vector<FSPrescribedDOF*> pBC(nns);
@@ -628,6 +641,7 @@ void FEBioFormatOld::ParseBCPrescribed(FSStep* pstep, XMLTag& tag)
628641
FSNodeSet* pg = new FSNodeSet(po);
629642
sprintf(szname, "Nodeset%02d", i + 1);
630643
pg->SetName(szname);
644+
po->AddFENodeSet(pg);
631645

632646
// make a new boundary condition
633647
FSPrescribedDOF* pbc = 0;
@@ -706,12 +720,17 @@ void FEBioFormatOld::ParseBCPrescribed(FSStep* pstep, XMLTag& tag)
706720
FSPrescribedDOF* pbc = pBC[ng];
707721
// pbc->GetLoadCurve()->SetID(lc);
708722
pbc->SetScaleFactor(DC[i].s);
723+
if (DC[i].lc >= 0)
724+
{
725+
feb.AddParamCurve(pbc->GetParam("scale"), DC[i].lc);
726+
}
709727
}
710728
}
711729

712730
//-----------------------------------------------------------------------------
713731
void FEBioFormatOld::ParseForceLoad(FSStep *pstep, XMLTag &tag)
714732
{
733+
FEBioInputModel& feb = GetFEBioModel();
715734
FSModel& fem = GetFSModel();
716735

717736
// count how many prescibed nodes there are
@@ -790,6 +809,7 @@ void FEBioFormatOld::ParseForceLoad(FSStep *pstep, XMLTag &tag)
790809
if (cc[j][i] >= 0)
791810
{
792811
FSNodeSet* pg = new FSNodeSet(po);
812+
po->AddFENodeSet(pg);
793813
sprintf(szname, "ForceNodeset%02d", i + 1);
794814
pg->SetName(szname);
795815

@@ -799,6 +819,11 @@ void FEBioFormatOld::ParseForceLoad(FSStep *pstep, XMLTag &tag)
799819
pFC[cc[j][i]] = pbc;
800820
pNS[cc[j][i]] = pg;
801821
pstep->AddComponent(pbc);
822+
823+
if (FC[i].lc >= 0)
824+
{
825+
feb.AddParamCurve(pbc->GetParam("scale"), FC[i].lc);
826+
}
802827
}
803828
}
804829

@@ -1532,6 +1557,7 @@ bool FEBioFormatOld::ParseInitialSection(XMLTag& tag)
15321557
FSNodalVelocities* pbc = new FSNodalVelocities(&fem, pg, v, m_pBCStep->GetID());
15331558
char szname[64] = { 0 };
15341559
sprintf(szname, "InitialVelocity%02d", CountBCs<FSNodalVelocities>(fem) + 1);
1560+
if (pg) { pg->SetName(szname); po->AddFENodeSet(pg); }
15351561
pbc->SetName(szname);
15361562
m_pBCStep->AddComponent(pbc);
15371563
}
@@ -1571,6 +1597,7 @@ bool FEBioFormatOld::ParseInitialSection(XMLTag& tag)
15711597
FSInitConcentration* pbc = new FSInitConcentration(&fem, pg, bc, c, m_pBCStep->GetID());
15721598
char szname[64] = { 0 };
15731599
sprintf(szname, "InitialConcentration%02d", CountBCs<FSInitConcentration>(fem) + 1);
1600+
if (pg) { pg->SetName(szname); po->AddFENodeSet(pg); }
15741601
pbc->SetName(szname);
15751602
m_pBCStep->AddComponent(pbc);
15761603
}
@@ -1603,6 +1630,7 @@ bool FEBioFormatOld::ParseInitialSection(XMLTag& tag)
16031630
char szname[64] = { 0 };
16041631
sprintf(szname, "InitialFluidPressure%02d", CountBCs<FSInitFluidPressure>(fem) + 1);
16051632
pbc->SetName(szname);
1633+
if (pg) { pg->SetName(szname); po->AddFENodeSet(pg); }
16061634
m_pBCStep->AddComponent(pbc);
16071635
}
16081636
else if (tag == "temperature") // initial temperature
@@ -1634,6 +1662,7 @@ bool FEBioFormatOld::ParseInitialSection(XMLTag& tag)
16341662
char szname[64] = { 0 };
16351663
sprintf(szname, "InitialTemperature%02d", CountBCs<FSInitTemperature>(fem) + 1);
16361664
pbc->SetName(szname);
1665+
if (pg) { pg->SetName(szname); po->AddFENodeSet(pg); }
16371666
m_pBCStep->AddComponent(pbc);
16381667
}
16391668
else ParseUnknownTag(tag);
@@ -1764,16 +1793,25 @@ void FEBioFormatOld::ParseContactSliding(FSStep* pstep, XMLTag& tag)
17641793

17651794
// create a new surface
17661795
FSSurface* ps = new FSSurface(po);
1796+
po->AddFESurface(ps);
17671797
if (ntype == 1)
17681798
{
17691799
pms = ps;
17701800
if (szn) ps->SetName(szn);
1801+
else {
1802+
sprintf(szbuf, "SecondarySurface%02d", CountInterfaces<FSSlidingWithGapsInterface>(fem) + 1);
1803+
ps->SetName(szbuf);
1804+
}
17711805
pi->SetSecondarySurface(ps);
17721806
}
17731807
else
17741808
{
17751809
pss = ps;
17761810
if (szn) ps->SetName(szn);
1811+
else {
1812+
sprintf(szbuf, "PrimarySurface%02d", CountInterfaces<FSSlidingWithGapsInterface>(fem) + 1);
1813+
ps->SetName(szbuf);
1814+
}
17771815
pi->SetPrimarySurface(ps);
17781816
}
17791817

@@ -2381,6 +2419,7 @@ void FEBioFormatOld::ParseRigidWall(FSStep* pstep, XMLTag& tag)
23812419
FSSurface* ps = new FSSurface(po);
23822420
pci->SetItemList(ps);
23832421
if (szn) ps->SetName(szn);
2422+
po->AddFESurface(ps);
23842423

23852424
// read the surface
23862425
ParseContactSurface(ps, tag);
@@ -2455,6 +2494,8 @@ void FEBioFormatOld::ParseContactRigid(FSStep *pstep, XMLTag &tag)
24552494
if (sz) sprintf(szbuf, "%s", szname);
24562495
else sprintf(szbuf, "RigidInterface%02d", i + 1);
24572496
pi->SetName(szbuf);
2497+
pn->SetName(szbuf);
2498+
po->AddFENodeSet(pn);
24582499
pstep->AddComponent(pi);
24592500
}
24602501
}

0 commit comments

Comments
 (0)