Skip to content
Snippets Groups Projects
Closed Directional waves from multi boundaries (src/../waveModel.C)
  • View options
  • Directional waves from multi boundaries (src/../waveModel.C)

  • View options
  • Closed Issue created

    When you have two wave generation lines (e.g., one line parallel to the x-axis, and the other one parallel to the y-axis), the simulation crashes even with regular waves. After trying different cases and digging up every single line in the wave codes and my model setup, I noticed that something is wrong when I wanted to generate waves perpendicular/directional to the y-axis although everything was fine when it was perpendicular/directional to the x-axis. The piece of information on my log file (e.g. Transformation from local to the global system: (-0 1 -0 -1 -0 -0 -0 -0 1)) gave me the idea that my model was generating waves going in the opposite direction (i.e. going outwards instead of coming inside the domain). This issue, I believe, relies on a typo in the waveModel.C code (src/waveModels/waveModel/waveModel.C, lines 67:69). These three lines are:

    // Rotation from global<->local about global origin Rlg_ = tensor(x, y, z); Rgl_ = Rlg_.T();

    Which should be changed to below in order to fix the problem.

    // Rotation from global<->local about global origin Rgl_ = tensor(x, y, z); Rlg_ = Rgl_.T();

    I have attached an example with two generation lines for the propagation of a directional wave (i.e. 30 deg) which does not work (crashes) with the original code but workes perfectly with the suggested modification. Please note that I have already tested this example with other configurations of incoming waves from different boundaries and it works correctly (i.e. this modification is not limited to this example).

    DirectionalWave_Example.zip

    Linked items ... 0

  • Activity

    • All activity
    • Comments only
    • History only
    • Newest first
    • Oldest first
    Loading Loading Loading Loading Loading Loading Loading Loading Loading Loading