diff --git a/examples/thermomechanics/thermal_deformation_heat_transfer.cpp b/examples/thermomechanics/thermal_deformation_heat_transfer.cpp index 021ac974..1b0fdedc 100644 --- a/examples/thermomechanics/thermal_deformation_heat_transfer.cpp +++ b/examples/thermomechanics/thermal_deformation_heat_transfer.cpp @@ -70,8 +70,7 @@ void thermalDeformationHeatTransferExample( const std::string filename ) // ==================================================== // Does not set displacements, velocities, etc. auto particles = - std::make_shared>( + CabanaPD::createParticles( exec_space(), low_corner, high_corner, num_cells, halo_width ); // ==================================================== diff --git a/src/CabanaPD_Particles.hpp b/src/CabanaPD_Particles.hpp index 4905e91a..02843e57 100644 --- a/src/CabanaPD_Particles.hpp +++ b/src/CabanaPD_Particles.hpp @@ -834,18 +834,15 @@ auto createParticles( const ExecSpace& exec_space, template -auto createParticles( const ExecSpace& exec_space, - std::array low_corner, - std::array high_corner, - const std::array num_cells, - const int max_halo_width, - typename std::enable_if< - (std::is_same_v || - std::is_same_v), - int>::type* = 0 ) +auto createParticles( + const ExecSpace& exec_space, std::array low_corner, + std::array high_corner, const std::array num_cells, + const int max_halo_width, + typename std::enable_if<( is_temperature_dependent::value ), + int>::type* = 0 ) { - return std::make_shared< - CabanaPD::Particles>( + return std::make_shared>( exec_space, low_corner, high_corner, num_cells, max_halo_width ); } diff --git a/src/CabanaPD_Types.hpp b/src/CabanaPD_Types.hpp index 2e47a9c9..58894e93 100644 --- a/src/CabanaPD_Types.hpp +++ b/src/CabanaPD_Types.hpp @@ -25,9 +25,11 @@ struct Fracture // Thermal types. struct TemperatureIndependent { + using base_type = TemperatureIndependent; }; struct TemperatureDependent { + using base_type = TemperatureDependent; }; struct DynamicTemperature : public TemperatureDependent {