-
Notifications
You must be signed in to change notification settings - Fork 87
Description
πͺͺ Title
Allow multiple lumped ports on the same boundary attribute (for co- and cross-polar analysis)
π Description
Currently, Palace does not allow assigning more than one LumpedPort to the same boundary attribute.
This limitation triggers the following verification error:
Verification failed: (!data.active || !port_marker[attr - 1]) is false:
--> Boundary attribute is assigned to more than one lumped port!
... in function: void palace::LumpedPortOperator::SetUpBoundaryProperties(const palace::IoData&, const palace::MaterialOperator&, const mfem::ParMesh&)
... in file: /tmp/krono/spack-stage/spack-stage-palace-develop-uv64y6xpn4v5w6kqisdxkgm7pzwxjeot/spack-src/palace/models/lumpedportoperator.cpp:343
This behavior prevents users from modeling configurations where two ports share the same physical surface but differ in excitation direction β for instance, when evaluating co-polar and cross-polar reflected components (only one port would be excited at a time).
π§© Minimal JSON Example
{
"Boundaries": {
"LumpedPort": [
{
"Index": 1,
"Attributes": [7],
"Direction": [0.0, 1.0, 0.0],
"Excitation": true,
"R": 50
},
{
"Index": 2,
"Attributes": [7],
"Direction": [-0.7071, 0.0, 0.7071],
"Excitation": false,
"R": 50
}
]
}
}βοΈ Expected Behavior
It should be possible to define multiple LumpedPort objects on the same boundary attribute, provided that:
- only one is active (
"Excitation": true), or - all are passive (for reciprocity or scattering analysis).
This would allow users to:
- define co- and cross-polar ports on the same surface,
- avoid duplicating geometry or mesh elements just to represent different port directions.
π‘ Proposed Enhancement
- Allow multiple lumped ports to share a boundary attribute if only one is active.
- Relax validation so it only fails when multiple excited ports are assigned to the same attribute.
- Optionally, support a compound port definition for multi-polarization setups.
π§ͺ Steps to Reproduce
- Define two lumped ports using the same attribute in the JSON input.
- Run
palace -i example.json. - The verification step fails with the error above.
ποΈ Environment
- Palace version:
developbranch - OS: Linux (Spack environment)
- Problem type: Driven (Lumped Port)
π Suggested Priority
Medium β this improvement would simplify polarization and scattering studies without geometry duplication.