diff options
author | sotech117 <michael_foiani@brown.edu> | 2024-05-10 09:14:45 -0400 |
---|---|---|
committer | sotech117 <michael_foiani@brown.edu> | 2024-05-10 13:18:13 -0400 |
commit | 9a9bb1a85de1eddb993efa635a59c693c37ec32f (patch) | |
tree | f3e809a4cb28369f60815ee3f28d314a6a06a9fe /src | |
parent | ed9d441ea39800a6c239a60d4587768411cb5ff7 (diff) |
demo day
Diffstat (limited to 'src')
-rwxr-xr-x | src/glwidget.cpp | 2 | ||||
-rw-r--r-- | src/ocean/ocean_alt.cpp | 2 | ||||
-rw-r--r-- | src/ocean/ocean_alt.h | 14 |
3 files changed, 9 insertions, 9 deletions
diff --git a/src/glwidget.cpp b/src/glwidget.cpp index 57df286..49189fc 100755 --- a/src/glwidget.cpp +++ b/src/glwidget.cpp @@ -176,7 +176,7 @@ void GLWidget::initializeGL() float extentLength = (coeffMax - coeffMin).norm(); // Screen-space size of vertex points - m_vSize = 0.005 * extentLength; + m_vSize = 10; // Scale all movement by this amount m_movementScaling = extentLength * 0.5; diff --git a/src/ocean/ocean_alt.cpp b/src/ocean/ocean_alt.cpp index 503cd4c..7825e37 100644 --- a/src/ocean/ocean_alt.cpp +++ b/src/ocean/ocean_alt.cpp @@ -438,7 +438,7 @@ std::vector<Eigen::Vector3f> ocean_alt::get_vertices(){ { for (int k = 0; k < N; k++) { - double c = Lx - 2 / (num_rows / Lx); + double c = Lx - 2 / (num_rows / Lx); // FIXME: when I am not perfect Eigen::Vector3f vertex = m_vertices[k] + Eigen::Vector3f(-i*(c), 0.0, (j)*(c)); vertices.push_back(vertex); diff --git a/src/ocean/ocean_alt.h b/src/ocean/ocean_alt.h index 333d2ca..5df1eb5 100644 --- a/src/ocean/ocean_alt.h +++ b/src/ocean/ocean_alt.h @@ -73,23 +73,23 @@ private: std::map<int, WaveIndexConstant> m_waveIndexConstants; // stores constants that only need to be calculate once for each grid constant - const double Lx = 512.0; - const double Lz = 512.0; + const double Lx = pow(2, 14); + const double Lz = pow(2, 14); const int num_rows = 256; const int num_cols = 256; - const int num_tiles_x = 1; - const int num_tiles_z = 1; + const int num_tiles_x = 2; + const int num_tiles_z = 2; const double vertex_displacement = Lx / 2; const int N = num_rows*num_cols; // total number of grid points - const double lambda = .75; // how much displacement matters + const double lambda =0.0; // how much displacement matters const double spacing = 1.0; // spacing between grid points - const double A = 10000; // numeric constant for the Phillips spectrum - const double V = 700; // wind speed + const double A = 6.5; // numeric constant for the Phillips spectrum + const double V = 500; // wind speed const double gravity = 9.81; const double L = V*V/gravity; const Eigen::Vector2d omega_wind = Eigen::Vector2d(1.0, 0.0); // wind direction, used in Phillips equation |