-
Notifications
You must be signed in to change notification settings - Fork 337
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
port the old BoxLib faverage tool to AMReX #3293
Conversation
this can compute the lateral average (optionally density weighted) of a variable from a plotfile. It assumes that the vertical direction is the last dimension.
Could add an item here: https://amrex-codes.github.io/amrex/docs_html/Post_Processing.html |
added the docs |
@@ -0,0 +1,285 @@ | |||
// | |||
// Laterally average a variable with optional density weighting (Favre average) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What does Favre average
mean?
{ | ||
|
||
amrex::Initialize(argc, argv, false); | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Let's put everything between amrex::Initialize
and amrex::Finalize
inside {}
so that things like PlotFileData
are destroyed before amrex::Finalize
.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
done
Favre averaged means density weighted
…On Wed, May 3, 2023 at 4:33 PM Weiqun Zhang ***@***.***> wrote:
***@***.**** requested changes on this pull request.
------------------------------
In Tools/Plotfile/faverage.cpp
<#3293 (comment)>:
> @@ -0,0 +1,285 @@
+//
+// Laterally average a variable with optional density weighting (Favre average)
What does Favre average mean?
------------------------------
In Tools/Plotfile/faverage.cpp
<#3293 (comment)>:
> +#include <AMReX_PlotFileUtil.H>
+#include <AMReX_MultiFabUtil.H>
+#include <AMReX_ParallelDescriptor.H>
+
+using namespace amrex;
+
+std::string inputs_name = "";
+
+void PrintHelp ();
+
+
+int main(int argc, char* argv[])
+{
+
+ amrex::Initialize(argc, argv, false);
+
Let's put everything between amrex::Initialize and amrex::Finalize inside
{} so that things like PlotFileData are destroyed before amrex::Finalize.
—
Reply to this email directly, view it on GitHub
<#3293 (review)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/ADA5MXZC2RDO6NFRIFL52TDXELTN3ANCNFSM6AAAAAAXU3UOCE>
.
You are receiving this because you are subscribed to this thread.Message
ID: ***@***.***>
--
John Bell
CCSE, MS 50A-3111, LBNL
1 Cyclotron Rd., Berkeley, CA 94720
Phone: 510 486-5391 Cell: 510 604-7437
Fax: 510 486-6900
|
Is there a version of this tool that will make a 2D projection to a plane? |
I think we could easily write one, so long as it projects along a coordinate axis. |
this can compute the lateral average (optionally density weighted) of a variable from a plotfile. It assumes that the vertical direction is the last dimension.
this can compute the lateral average (optionally density weighted) of a variable from a plotfile. It assumes that the vertical direction is the last dimension.
Summary
Additional background
Checklist
The proposed changes: