Skip to content
Open
Show file tree
Hide file tree
Changes from 9 commits
Commits
Show all changes
26 commits
Select commit Hold shift + click to select a range
e0c7256
WIP
streeve Nov 6, 2025
9cf55c7
Add initial infrastructure for anisotropic materials
streeve Nov 6, 2025
f4b4ec6
fixup: simplify anisotropic model
streeve Nov 6, 2025
40f3d3c
FIXME: this is where the physics is needed
streeve Nov 6, 2025
e937323
Add cubic anisotropy for PMB
streeve Nov 7, 2025
42260fb
fixup: device markup
streeve Nov 11, 2025
412f2f7
fixup: tag naming
streeve Nov 11, 2025
8e8cb2b
fixup: cubic compile
streeve Dec 9, 2025
f92f749
DO NOT MERGE: change elastic wave to anisotropic
streeve Dec 9, 2025
16db62f
Revised cubic model
pabloseleson Dec 10, 2025
fc0db66
Incorporated back unintended deletion of operator
pabloseleson Dec 10, 2025
cd6d481
fixup: simplify constructor
streeve Dec 10, 2025
2605b06
fixup: remove r in aniso
streeve Dec 10, 2025
e483ab3
fixup: separate isotropic/cubic base models
streeve Dec 10, 2025
fe31311
Added transversely isotropic model
pabloseleson Dec 10, 2025
e2753ab
fixup: compile transverse iso
streeve Dec 10, 2025
a91146b
fixup: delegating constructor
streeve Dec 11, 2025
3a78460
Initial EPP with TransverseIso
streeve Dec 11, 2025
2faa78e
DO NOT MERGE: use tensile test as starting point for anisotropic plas…
streeve Dec 11, 2025
59790e2
Implemented initial orientation-dependent yield stretch
pabloseleson Dec 11, 2025
fe45761
fixup: compile
streeve Dec 12, 2025
b7c4034
First draft anisotropic bond breaking
streeve Dec 12, 2025
837b87c
fixup: wrong s0 for aniso
streeve Dec 16, 2025
9f531bb
fixup: actually pass two values for aniso dogbone
streeve Feb 19, 2026
4189a94
Fix incorrect transvse isotropic bond breaking criterion
streeve Mar 16, 2026
3c1467c
Fixed an anisotropic elastic constant and bond breaking
pabloseleson Mar 16, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions examples/mechanics/elastic_wave.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -36,8 +36,8 @@ void elasticWaveExample( const std::string filename )
// Material parameters
// ====================================================
double rho0 = inputs["density"];
auto K = inputs["bulk_modulus"];
double G = inputs["shear_modulus"];
double C11 = inputs["C11"];
double C12 = inputs["C12"];
double delta = inputs["horizon"];
delta += 1e-10;

Expand All @@ -54,9 +54,9 @@ void elasticWaveExample( const std::string filename )
// ====================================================
// Force model
// ====================================================
using model_type = CabanaPD::LinearLPS;
using model_type = CabanaPD::LinearPMB;
CabanaPD::ForceModel force_model( model_type{}, CabanaPD::NoFracture{},
delta, K, G );
CabanaPD::Cubic{}, delta, C11, C12 );

// ====================================================
// Particle generation
Expand Down
2 changes: 1 addition & 1 deletion src/CabanaPD_ForceModels.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -261,7 +261,7 @@ struct BaseDynamicTemperatureModel
};

template <typename PeridynamicsModelType, typename MechanicsModelType = Elastic,
typename DamageType = Fracture,
typename AnisotropyType = Isotropic, typename DamageType = Fracture,

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why we use here "AnisotropyType = Isotropic"?

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The default anisotropy is "no anisotropy"

typename ThermalType = TemperatureIndependent, typename... DataTypes>
struct ForceModel;

Expand Down
8 changes: 8 additions & 0 deletions src/CabanaPD_Types.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,14 @@ struct ElasticPerfectlyPlastic
{
using base_type = Plastic;
};
//! Fully isotropic.
struct Isotropic
{
};
//! Cubic anisotropy.
struct Cubic
{
};

// Model category tags.
struct Pair
Expand Down
26 changes: 17 additions & 9 deletions src/force/CabanaPD_PMB.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -113,11 +113,13 @@ class Force<MemorySpace, ModelType, PMB, NoFracture>

double xi, r, s;
double rx, ry, rz;
getDistance( x, u, i, j, xi, r, s, rx, ry, rz );
double xi_x, xi_y, xi_z;
getDistance( x, u, i, j, xi, r, s, rx, ry, rz, xi_x, xi_y, xi_z );

s = model( ThermalStretchTag{}, i, j, s );

const double coeff = model( ForceCoeffTag{}, i, j, s, vol( j ) );
const double coeff = model( ForceCoeffTag{}, i, j, s, vol( j ), r,
xi, xi_x, xi_y, xi_z );
fx_i = coeff * rx / r;
fy_i = coeff * ry / r;
fz_i = coeff * rz / r;
Expand Down Expand Up @@ -188,7 +190,8 @@ class Force<MemorySpace, ModelType, PMB, NoFracture>
s = model( ThermalStretchTag{}, i, j, s );

const double coeff =
0.5 * model( ForceCoeffTag{}, i, j, s, vol( j ) );
0.5 * model( ForceCoeffTag{}, i, j, s, vol( j ), r, xi, xi_x,
xi_y, xi_z );
const double fx_i = coeff * rx / r;
const double fy_i = coeff * ry / r;
const double fz_i = coeff * rz / r;
Expand Down Expand Up @@ -273,7 +276,9 @@ class Force<MemorySpace, ModelType, PMB, Fracture>
// Get the reference positions and displacements.
double xi, r, s;
double rx, ry, rz;
getDistance( x, u, i, j, xi, r, s, rx, ry, rz );
double xi_x, xi_y, xi_z;
getDistance( x, u, i, j, xi, r, s, rx, ry, rz, xi_x, xi_y,
xi_z );

s = model( ThermalStretchTag{}, i, j, s );

Expand All @@ -287,7 +292,8 @@ class Force<MemorySpace, ModelType, PMB, Fracture>
else if ( mu( i, n ) > 0 )
{
const double coeff =
model( ForceCoeffTag{}, i, j, s, vol( j ), n );
model( ForceCoeffTag{}, i, j, s, vol( j ), r, xi, xi_x,
xi_y, xi_z, n );

double muij = mu( i, n );
fx_i = muij * coeff * rx / r;
Expand Down Expand Up @@ -394,7 +400,8 @@ class Force<MemorySpace, ModelType, PMB, Fracture>
s = model( ThermalStretchTag{}, i, j, s );

const double coeff =
0.5 * model( ForceCoeffTag{}, i, j, s, vol( j ), n );
0.5 * model( ForceCoeffTag{}, i, j, s, vol( j ), r, xi,
xi_x, xi_y, xi_z, n );
const double muij = mu( i, n );
const double fx_i = muij * coeff * rx / r;
const double fy_i = muij * coeff * ry / r;
Expand Down Expand Up @@ -471,8 +478,8 @@ class Force<MemorySpace, ModelType, LinearPMB, NoFracture>

linear_s = model( ThermalStretchTag{}, i, j, linear_s );

const double coeff =
model( ForceCoeffTag{}, i, j, linear_s, vol( j ) );
const double coeff = model( ForceCoeffTag{}, i, j, linear_s,
vol( j ), xi, xi, xi_x, xi_y, xi_z );
Comment thread
streeve marked this conversation as resolved.
Outdated
fx_i = coeff * xi_x / xi;
fy_i = coeff * xi_y / xi;
fz_i = coeff * xi_z / xi;
Expand Down Expand Up @@ -540,7 +547,8 @@ class Force<MemorySpace, ModelType, LinearPMB, NoFracture>
linear_s = model( ThermalStretchTag{}, i, j, linear_s );

const double coeff =
0.5 * model( ForceCoeffTag{}, i, j, linear_s, vol( j ) );
0.5 * model( ForceCoeffTag{}, i, j, linear_s, vol( j ), xi, xi,
xi_x, xi_y, xi_z );
const double fx_i = coeff * xi_x / xi;
const double fy_i = coeff * xi_y / xi;
const double fz_i = coeff * xi_z / xi;
Expand Down
52 changes: 30 additions & 22 deletions src/force_models/CabanaPD_LPS.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -20,11 +20,11 @@

namespace CabanaPD
{
template <typename MechanicsModelType>
template <typename MechanicsModelType, typename AnisotropyType>
struct BaseForceModelLPS;
Comment thread
streeve marked this conversation as resolved.

template <>
struct BaseForceModelLPS<Elastic> : public BaseForceModel
struct BaseForceModelLPS<Elastic, Isotropic> : public BaseForceModel
{
using base_type = BaseForceModel;
using model_type = LPS;
Expand Down Expand Up @@ -200,14 +200,15 @@ struct BaseForceModelLPS<Elastic> : public BaseForceModel
#pragma GCC diagnostic pop
};

template <>
struct ForceModel<LPS, Elastic, NoFracture, TemperatureIndependent>
: public BaseForceModelLPS<Elastic>,
template <typename AnisotropyType>
struct ForceModel<LPS, Elastic, AnisotropyType, NoFracture,
TemperatureIndependent>
: public BaseForceModelLPS<Elastic, AnisotropyType>,
BaseNoFractureModel,
BaseTemperatureModel<TemperatureIndependent>

{
using base_type = BaseForceModelLPS<Elastic>;
using base_type = BaseForceModelLPS<Elastic, AnisotropyType>;
using base_fracture_type = BaseNoFractureModel;
using base_temperature_type = BaseTemperatureModel<TemperatureIndependent>;
using fracture_type = NoFracture;
Expand All @@ -221,13 +222,14 @@ struct ForceModel<LPS, Elastic, NoFracture, TemperatureIndependent>
using base_type::influence_type;
};

template <>
struct ForceModel<LPS, Elastic, Fracture, TemperatureIndependent>
: public BaseForceModelLPS<Elastic>,
template <typename AnisotropyType>
struct ForceModel<LPS, Elastic, AnisotropyType, Fracture,
TemperatureIndependent>
: public BaseForceModelLPS<Elastic, AnisotropyType>,
BaseFractureModel,
BaseTemperatureModel<TemperatureIndependent>
{
using base_type = BaseForceModelLPS<Elastic>;
using base_type = BaseForceModelLPS<Elastic, AnisotropyType>;
using base_fracture_type = BaseFractureModel;
using base_temperature_type = BaseTemperatureModel<TemperatureIndependent>;

Expand Down Expand Up @@ -301,12 +303,15 @@ struct ForceModel<LPS, Elastic, Fracture, TemperatureIndependent>
}
};

template <>
struct ForceModel<LinearLPS, Elastic, NoFracture, TemperatureIndependent>
: public ForceModel<LPS, Elastic, NoFracture, TemperatureIndependent>
template <typename AnisotropyType>
struct ForceModel<LinearLPS, Elastic, AnisotropyType, NoFracture,
TemperatureIndependent>
: public ForceModel<LPS, Elastic, AnisotropyType, NoFracture,
TemperatureIndependent>
{
using base_type =
ForceModel<LPS, Elastic, NoFracture, TemperatureIndependent>;
using base_type = ForceModel<LPS, Elastic, AnisotropyType, NoFracture,
TemperatureIndependent>;
using typename base_type::base_model;
using model_type = LinearLPS;

template <typename... Args>
Expand All @@ -319,12 +324,15 @@ struct ForceModel<LinearLPS, Elastic, NoFracture, TemperatureIndependent>
using base_type::operator();
};

template <>
struct ForceModel<LinearLPS, Elastic, Fracture, TemperatureIndependent>
: public ForceModel<LPS, Elastic, Fracture, TemperatureIndependent>
template <typename AnisotropyType>
struct ForceModel<LinearLPS, Elastic, AnisotropyType, Fracture,
TemperatureIndependent>
: public ForceModel<LPS, Elastic, AnisotropyType, Fracture,
TemperatureIndependent>
{
using base_type =
ForceModel<LPS, Elastic, Fracture, TemperatureIndependent>;
using base_type = ForceModel<LPS, Elastic, AnisotropyType, Fracture,
TemperatureIndependent>;
using typename base_type::base_model;

using model_type = LinearLPS;

Expand All @@ -341,12 +349,12 @@ struct ForceModel<LinearLPS, Elastic, Fracture, TemperatureIndependent>
template <typename ModelType>
ForceModel( ModelType, Elastic, NoFracture, const double delta, const double K,
const double G, const int influence = 0 )
-> ForceModel<ModelType, Elastic, NoFracture>;
-> ForceModel<ModelType, Elastic, Isotropic, NoFracture>;

template <typename ModelType>
ForceModel( ModelType, NoFracture, const double delta, const double K,
const double G, const int influence = 0 )
-> ForceModel<ModelType, Elastic, NoFracture>;
-> ForceModel<ModelType, Elastic, Isotropic, NoFracture>;

template <typename ModelType>
ForceModel( ModelType, Elastic, const double delta, const double K,
Expand Down
Loading