Actuator sector moving refinement and sampling - #2011
Conversation
|
@ndevelder , here is the latest version of the actuator sector code. |
8e6567f to
8e73c40
Compare
d2dd8f2 to
394ff8d
Compare
|
This PR is ready for review. |
|
I made a PR to your branch to help with the conflicts. Let me know if anything is unclear. |
Fixing actuator sector refinement conflicts
|
Thanks @mbkuhn , I merged the PR and it is now included in the repo. |
|
@mbkuhn , this is in working order. |
There was a problem hiding this comment.
Pull request overview
Adds actuator-following AMR refinement and sampling for moving actuator sectors and drones.
Changes:
- Exposes actuator geometry and rigid reference frames.
- Adds moving plane/volume samplers and particle rebuilding after regridding.
- Adds refinement criteria, documentation, unit tests, and a regression test.
Reviewed changes
Copilot reviewed 28 out of 28 changed files in this pull request and generated 3 comments.
Show a summary per file
| File | Description |
|---|---|
unit_tests/wind_energy/actuator/test_drone.cpp |
Tests moving drone sampling and regridding. |
unit_tests/wind_energy/actuator/test_actuator_sector.cpp |
Tests sector geometry and refinement. |
test/test_files/act_drone_refinement/act_drone_refinement.inp |
Adds drone refinement regression case. |
test/CMakeLists.txt |
Registers the regression test. |
src/wind_energy/actuator/sector/actuator_sector_ops.H |
Declares sector geometry/frame operations. |
src/wind_energy/actuator/sector/actuator_sector_ops.cpp |
Implements sector geometry/frame operations. |
src/wind_energy/actuator/motion/RigidTransform.H |
Defines rigid coordinate transforms. |
src/wind_energy/actuator/motion/RigidBodyMotion.H |
Exposes rigid-body poses. |
src/wind_energy/actuator/motion/RigidBodyMotion.cpp |
Implements pose generation. |
src/wind_energy/actuator/drone/drone_ops.H |
Declares drone geometry/frame operations. |
src/wind_energy/actuator/drone/drone_ops.cpp |
Implements drone geometry/frame operations. |
src/wind_energy/actuator/ActuatorModel.H |
Extends the actuator model interface. |
src/wind_energy/actuator/actuator_types.H |
Defines refinement geometry data. |
src/wind_energy/actuator/actuator_ops.H |
Adds default geometry/frame operations. |
src/utilities/tagging/CMakeLists.txt |
Builds actuator refinement support. |
src/utilities/tagging/ActuatorRefinement.H |
Declares actuator-following refinement. |
src/utilities/tagging/ActuatorRefinement.cpp |
Implements cylindrical rotor tagging. |
src/utilities/sampling/VolumeSampler.H |
Exposes volume geometry to subclasses. |
src/utilities/sampling/Sampling.H |
Tracks pending particle rebuilding. |
src/utilities/sampling/Sampling.cpp |
Rebuilds sampling particles after movement/regridding. |
src/utilities/sampling/PlaneSampler.H |
Exposes plane geometry to subclasses. |
src/utilities/sampling/MovingVolumeSampler.H |
Declares actuator-attached volume sampling. |
src/utilities/sampling/MovingVolumeSampler.cpp |
Implements moving volume sampling. |
src/utilities/sampling/MovingPlaneSampler.H |
Declares actuator-attached plane sampling. |
src/utilities/sampling/MovingPlaneSampler.cpp |
Implements moving plane sampling. |
src/utilities/sampling/CMakeLists.txt |
Builds the moving samplers. |
docs/sphinx/user/inputs_tagging.rst |
Documents actuator refinement inputs. |
docs/sphinx/user/inputs_Sampling.rst |
Documents moving sampler inputs. |
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
| if (axial <= forward && axial >= -backward && | ||
| radial_sq <= radius_sq) { | ||
| tag(i, j, k) = amrex::TagBox::SET; |
There was a problem hiding this comment.
I can handle this one in this PR or with a follow-on; don't worry about it
| m_axis1 = std::move(axis1); | ||
| m_axis2 = std::move(axis2); | ||
| m_offset_vector = std::move(offset_vector); | ||
| PlaneSampler::check_bounds(); |
|
|
||
| .. input_param:: sampling.MovingPlaneSampler.actuator_label | ||
|
|
||
| **type:** String, optional |
|
It seems like the copilot review did not turn up much insight. Can you tell whether the volume sampling issue has to do with the ghost cells or not? You could try running on a single processor and a box size that takes up the whole domain. You could also see if the problem happens on any field or only on derived fields. |
Summary
This capability allows a refinement box and/or sampling planes to move and track an actuator sector or drone.
Pull request type
Please check the type of change introduced:
Checklist
The following is included:
This PR was tested by running:
Additional background
This PR builds on #2001
Issue Number: