Difference between revisions of "Examples/2D/souto etal 2012 standingwave"

From AQUAgpusph
Jump to: navigation, search
m (Added categories)
m
Line 59: Line 59:
 
We are using a number of AQUAgpusph presets:
 
We are using a number of AQUAgpusph presets:
  
* [[Presets/cfd|cfd.xml]]: It is a fluid dynamics problem
+
* [[Presets/cfd.xml|cfd.xml]]: It is a fluid dynamics problem
* [[Presets/domain|domain.xml]]: Probably it is not mandatory to set a computational domain, but it is ever a good option to prevent program failures.
+
* [[Presets/domain.xml|domain.xml]]: Probably it is not mandatory to set a computational domain, but it is ever a good option to prevent program failures.
* [[Presets/energy|energy.xml]] and [[Presets/energy_report|energy.report.xml]]: The main result of this example is the kinetic energy.
+
* [[Presets/energy.xml|energy.xml]] and [[Presets/energy_report.xml|energy.report.xml]]: The main result of this example is the kinetic energy.
* [[Presets/timing_report|timing.report.xml]] and [[Presets/performance_report|performance.report.xml]]: Useful to profile the execution.
+
* [[Presets/timing_report.xml|timing.report.xml]] and [[Presets/performance_report.xml|performance.report.xml]]: Useful to profile the execution.
  
 
To load all these presets we can create a file called '''Presets.xml''', with the following content:
 
To load all these presets we can create a file called '''Presets.xml''', with the following content:

Revision as of 13:48, 18 March 2015

Introduction

In this examples we are reproducing the simulation of the standing wave carried out by Souto et all (2012) [1].

The standing wave is defined on top of an infinite periodic fluid domain composed by rectangular subdomains of dimensions , with . In such domain a wave with length (i.e. the wave number is ) and amplitude is imposed. Denoting the ratio by the following velocity potential can be considered:

valid for small values of . In previous equations is the angular frequency given by the dispersion relation of gravity waves: , and corresponds to the flat free surface (In Fig. 13 of Souto et all (2012)[1] it is wrong described)

Therefore the velocity field can be computed as . It should be noticed that for a flat free surface is obtained.

With such velocity potential, for a viscous fluid, it is possible to get an analytical solution for the kinetic energy decay[2]:

where the kinematic viscosity can be computed from the Reynolds number:

In our simulation , , , and , where is the initial distance between the particles.

Setting up the simulation

In AQUAgpusph the examples are generated on top of template archives, which are read and modified by the Python Script Create.py, such that they can be ran from an arbitrary folder, and modified just touching such Create.py script.

You can run the prebuilt version of the example right after compiling AQUAgpusph:

cd examples/2D/souto_etal_2012_standingwave
./run.sh --run

Also you can plot the result in real time opening a new terminal (in the same place) and typing:

./run.sh --plot e

Souto etal 2012 standingwave-Ekin.png

Resulting kinetic energy compared with the analytically computed.

However we are interested into setup the case from scratch, assuming that we are running it in the same folder we are creating the input files.

Presets

We are using a number of AQUAgpusph presets:

To load all these presets we can create a file called Presets.xml, with the following content:

<?xml version="1.0" ?>
<sphInput>
    <Include file="/usr/share/aquagpusph/resources/Presets/cfd.xml" />
    <Include file="/usr/share/aquagpusph/resources/Presets/domain.xml" />
    <Include file="/usr/share/aquagpusph/resources/Presets/energy.xml" />
    <Include file="/usr/share/aquagpusph/resources/Presets/timing.report.xml" />
    <Include file="/usr/share/aquagpusph/resources/Presets/performance.report.xml" />
    <Include file="/usr/share/aquagpusph/resources/Presets/energy.report.xml" />
</sphInput>

Replace /usr/share/aquagpusph by the AQUAgpusph folder.

References

  1. 1.0 1.1 Antonio Souto-Iglesias, Fabricio Macià, Leo M. González, Jose L. Cercos-Pita. On the consistency of MPS. Computer Physics Communications, 2012
  2. J. Lighthill. Waves in Fluids. Cambridge University Press, 2001