Skip to content

Clean up embeddedmesh implementation#1614

Open
eulovi wants to merge 1 commit into4C-multiphysics:mainfrom
eulovi:clean_embeddedmesh_implementation
Open

Clean up embeddedmesh implementation#1614
eulovi wants to merge 1 commit into4C-multiphysics:mainfrom
eulovi:clean_embeddedmesh_implementation

Conversation

@eulovi
Copy link
Contributor

@eulovi eulovi commented Dec 19, 2025

Description and Context

One problem that I noticed in the PR #1613 is that the current embeddedmesh implementation in constraint_framework is not flexible enough to add new coupling strategies. So far, only the Mortar method is implemented. Therefore, in this PR a base class SolidToSolidCouplingManager is introduced. This class can work as a base class for other methods and holds basic functionality needed for embedded mesh strategies. Also I tried to clean how parameters are obtained, so that no unnecessary parameters are called if the coupling strategy doesn't require them.

Related Issues and Pull Requests

Related to #1613

Copy link
Contributor

@maxfirmbach maxfirmbach left a comment

Choose a reason for hiding this comment

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

Overall looks nice 👍. I have left some comments 😃.

#include "4C_fem_discretization.hpp"

FOUR_C_NAMESPACE_OPEN
FOUR_C_NAMESPACE_OPEN namespace Core::IO { class VisualizationManager; }
Copy link
Contributor

Choose a reason for hiding this comment

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

This looks weird.

#include <memory>

// Forward declarations.
class Map;
Copy link
Contributor

Choose a reason for hiding this comment

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

I think we should not forward declare things outside of FOUR_C_NAMESPACE_OPEN.

{
class VisualizationManager;
}
namespace Solid
Copy link
Contributor

Choose a reason for hiding this comment

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

Some blank lines in between would be nice. Currently it looks a bit cramped.


namespace LinAlg
{
class SparseMatrix;
Copy link
Contributor

Choose a reason for hiding this comment

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

SparseMatrix is already declared a few lines above.

namespace Core::LinAlg
{
class SparseMatrix;
class FE_Vector;
Copy link
Contributor

Choose a reason for hiding this comment

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

I think FE_Vector does not exist. It should be FEVector I guess.

return is_cut_node;
}

MPI_Comm Constraints::EmbeddedMesh::SolidToSolidCouplingManager::get_my_comm()
Copy link
Contributor

Choose a reason for hiding this comment

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

Is this function really necessary?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants