Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Interpolation for vector fields #258

Merged
merged 18 commits into from
Feb 15, 2025
Merged

Conversation

greole
Copy link
Contributor

@greole greole commented Feb 8, 2025

This PR adds interpolation kernels for Field<Vector> for upwind and linear interpolations. Currently, overloading of interpolate(src, dst) is used to implement the functionality on the operator. The reason is that template functions seems to not work well with the runTimeSelection mechanism and the static create functions and the virtual interpolate members.

This PR is required for #256.

Additional changes:

  • the implementation of the interpolation tests are improved and benchmarks are added.
  • renamed volField, surfaceField to src and dst. To make the purpose clearer.

Copy link

github-actions bot commented Feb 8, 2025

Deployed test documentation to https://exasim-project.com/NeoFOAM/Build_PR_258

@greole greole changed the base branch from main to stack/vectorFields February 9, 2025 10:37
@greole greole force-pushed the enh/vector_interpolation branch from b0892b2 to 9c6e27c Compare February 9, 2025 10:38
@greole greole changed the title wip interpolation functions for vector fields Interpolation for vector fields Feb 9, 2025
@greole greole added the full-ci a label that triggers the full ci pipeline label Feb 11, 2025
@greole greole added the ready-for-review Set this label to indicate that the PR is ready for review label Feb 11, 2025
@@ -33,15 +33,19 @@ class Linear : public SurfaceInterpolationFactory::Register<Linear>

static std::string schema() { return "none"; }

void interpolate(const VolumeField<scalar>& volField, SurfaceField<scalar>& surfaceField)
const override;
void interpolate(const VolumeField<scalar>& src, SurfaceField<scalar>& dst) const override;
Copy link
Collaborator

Choose a reason for hiding this comment

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

im not source if src and dst are the best names:

more intuitive would be define a variable like phi and phif and make it consistent with the documentation

@greole greole merged commit d52a4a4 into stack/vectorFields Feb 15, 2025
18 of 20 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
full-ci a label that triggers the full ci pipeline ready-for-review Set this label to indicate that the PR is ready for review
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants