diff --git a/README.md b/README.md index 7a67857..38357a6 100644 --- a/README.md +++ b/README.md @@ -1,3 +1,16 @@ # Lockgate -Modules to calcualte the forces on lock gates. +Modules to calculate the forces on lock gates. +It consists of different modules to calcualte the force for different situations. +The following modules are identified: + +1. Lockgate1: +2. Lockgate2: +3. Lockgate3: +4. Lockgate4: +5. Lockgate5: +6. Lockgate6: +7. Lockgate7: +8. Lockgate8: + +More info can be found on read the docs \ No newline at end of file diff --git a/pyproject.toml b/pyproject.toml index a1e5722..642651f 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -4,7 +4,7 @@ dynamic = ["version"] authors = [ { name = "Sam van der Zwan", email = "sam.vanderzwan@deltares.nl" }, ] -description = "Modules to calcualte the forces on lock gates." +description = "Modules to calculate the forces on lock gates." readme = "README.md" classifiers = [ "Programming Language :: Python :: 3", @@ -19,7 +19,9 @@ classifiers = [ "Topic :: Scientific/Engineering :: Physics", ] -dependencies = ["coloredlogs~=15.0.1"] +dependencies = ["coloredlogs~=15.0.1", + "numpy~=1.21.2", +] [project.optional-dependencies] dev = [ diff --git a/src/lockgate/lockgate3/LGATE3.py b/src/lockgate/lockgate3/LGATE3.py index fe44338..92bb054 100644 --- a/src/lockgate/lockgate3/LGATE3.py +++ b/src/lockgate/lockgate3/LGATE3.py @@ -205,5 +205,5 @@ def gate7(fileName): fileout.close() if __name__ == "__main__": - filename = 'B001' + filename = r'.\test_data\lockgate3\B001' gate7(filename) diff --git a/src/lockgate/lockgate8/REFL2.py b/src/lockgate/lockgate8/REFL2.py index 3f38723..a0e455b 100644 --- a/src/lockgate/lockgate8/REFL2.py +++ b/src/lockgate/lockgate8/REFL2.py @@ -292,7 +292,9 @@ def refl(fileName, maxsteps): alfa = (hlm-hv)/na0 print(alfa) fileout.close() + + if __name__ == "__main__": maxsteps = 500 # Number of steps going over a period of wave between two sections - filename = 'R21' + filename = r'.\test_data\lockgate8\R21' refl(filename, maxsteps) diff --git a/test_data/lockgate3/B001.IN b/test_data/lockgate3/B001.IN new file mode 100644 index 0000000..5b7a66b --- /dev/null +++ b/test_data/lockgate3/B001.IN @@ -0,0 +1,7 @@ +-5.00 12.00 +-4.90 12.50 0.40 1.00 0.00 +13.00 1.50 + 0.90 0.70 0.90 0.70 + 0.00 +1000. 0.02 +-.01309 \ No newline at end of file diff --git a/test_data/lockgate8/R10.IN b/test_data/lockgate8/R10.IN new file mode 100644 index 0000000..792fdf6 --- /dev/null +++ b/test_data/lockgate8/R10.IN @@ -0,0 +1,15 @@ +** Hv Zk + 0.00 -4.00 +** LAB LCD LEF LGH LIJ LKL + 3.75 7.50 7.50 7.50 7.50 3.75 +** BAB BCD BEF BGH BIJ BKL +25.00 22.00 19.00 16.00 13.00 10.00 +** dt tinit tend + 0.05 0.00 240.00 +** NTM + 4 +** TM QM +-10.00 10.00 + 0.00 10.00 +100.00 10.00 +500.00 10.00 diff --git a/test_data/lockgate8/R20.IN b/test_data/lockgate8/R20.IN new file mode 100644 index 0000000..d0ede3f --- /dev/null +++ b/test_data/lockgate8/R20.IN @@ -0,0 +1,9 @@ + 0.00 -4.00 + 7.50 15.00 15.00 15.00 15.00 7.50 +40.00 34.00 28.00 22.00 16.00 10.00 + 0.1 0.00 240.00 + 4 +-10.00 10.00 + 0.00 10.00 +100.00 10.00 +500.00 10.00 diff --git a/test_data/lockgate8/R21.IN b/test_data/lockgate8/R21.IN new file mode 100644 index 0000000..f23721b --- /dev/null +++ b/test_data/lockgate8/R21.IN @@ -0,0 +1,9 @@ + 0.00 -4.00 + 7.50 15.00 15.00 15.00 15.00 7.50 +40.00 40.00 40.00 40.00 40.00 40.00 + 0.1 0.00 240.00 + 4 +-10.00 10.00 + 0.00 10.00 +100.00 10.00 +500.00 10.00