Skip to content
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

Renamed bins to levels #68

Closed
wants to merge 100 commits into from
Closed

Renamed bins to levels #68

wants to merge 100 commits into from

Conversation

Leynse
Copy link
Contributor

@Leynse Leynse commented Feb 14, 2024

No description provided.

… multiple parameters user changeable (snapwave_gammaig, snapwave_Tinc2ig, snapwave_shinc2ig,snapwave_finc2ig) as in HurryWave. Added factor to control offshore estimate of IG energy: snapwave_eeinc2ig
- Change default depth of snapwave from 0.01 to 0.001m for more flexibility and accuracy in specifying snapwave_hmin
- Make possible to change the baldock_ratio (default = 0.2 as before)
…waves to his-output as 'dw'and 'df' if storefw = 1

- TODO; still check better whether integrated calculation is correct
- Add Battjes-Janssen 1978 breaking dissipation model for IG waves with 2 options to apply breaking everywhere or where H>gamma*depth, controlled by snapwave_battjesjanssen_opt=1 (default) or 2
- add snapwave_ig_opt to swith between Baldock for IG waves =1 (default) of BattjesJanssen
…previous timestep as in Baldocks formulation and write to sfincs netcdf output

- Calculate directionally averaged normalised bed slope betan and write to sfincs netcdf output
- Calculate directionally averaged shoaling factor fsh and write to sfincs netcdf output
- Make fsh be dependent on one minus the percentage of breaking waves Qb instead of assuming Qb=1 as in Hurrywave implementation
- Make coefficients in fsh user changeable and have a minimum value as in Hurrywave implementation -> snapwave_fshfac=1, snapwave_fshexp=15, snapwave_fshalphamin=0.1
- Add a coefficient that controls how much of the incident energy sink ends up as IG wave source -> snapwave_shpercig=0.25 -> meaning that not all dissipated energy goes to the IG frequencies
- Bugfix so Hmx_ig is actually controlled by gamma_ig instead of gamma of incident waves
- Some intermediate attempts at different options inside Baldock breaker formulation
- add user parameter snapwave_depthforcerelease controlling below what water depth, there will be no inc2ig energy transfer anymore
…gy source is given anymore to IG waves, should become more generalised later
…_snapwave_ig

# Conflicts:
#	source/src/sfincs_lib.f90
#	source/third_party_open/netcdf/netcdf4.vcxproj
… monochromatic

- Propose tp = snapwave_tpmean*snapwave_Tinc2ig instead of fixed value of 6
- Was needed to read in snapwave_Tinc2ig again because snapwave_data is not available in SFINCS itself
- Add 'srcsh' variable of energy sink incident waves/energy source ig waves to his output, is directionally averaged
- Therefore, in snapwave/snapwave_solver.f90 change srcsh into srcsh_local
…o between Tp,inc and Tp,ig: snapwave_Tinc2ig = 7 (default) instead of hardcoded ratio of 6.0

- add quadtree print statements as in main
…sh formula in subroutine 'estimate_shoaling_rate', still with regular Baldock wave dissipation

- Option of old fsh formula with BattjesJanssen IG dissiptation is ig_opt = 3
- Reset defaults of shinc2ig and shpercig
- Still have problem at boundaries
- Still need to calcullate steepnes, reldepth, depthforcerelease based on weighted nearest offshore wave data
- Use now downwind IG wave height from previous timestep, to evaluate choice still
- if (Sxxprev(itheta)<=0.0) then is enough
…d values of 8

- Not sure whether all real*8 were needed in the end...
- Still to be reviewed whether method works good like this with all in rms instead of Hm0
… to limit 'inverse' shadow zone for IG waves, induced by the srcsh component
Leynse and others added 28 commits January 11, 2024 18:55
…ctions in a separate module and file!

- Also added to Makefile
…eterisation versions

- Added option whether one wants to use the herbers determined Hm0ig&Tp for boundary conditions (snapwave_use_herbers = 1, default)
- Added option then for choosing Tpig type method based on computed spectrum (snapwave_tpig_opt = 1, default). Options are: 1=Tm01 (default), 2=Tpsmooth, 3=Tp, 4=Tm-1,0

Other notes - SFINCS changes:
Changed: references of betan are now beta in SFINCS netcdf output
Removed: option that SFINCS wavemaker directly uses the snapwave_tpmean * snapwave_Tinc2ig > now let it come from Snapwave,
where snapwave_tpigmean comes from (still there the option to user define snapwave_Tinc2ig, using snapwave_tpigopt=XX)

Other notes - SnapWave changes:
Removed: option in find_boundary_indices() that would find the nearest grid active point (kcs=1), that was used before in case of IG waves
Removed: old vars like H_rep, steepnes_bc, depthforcerelease etc.
Removed now unused variables: snapwave_shpercig, snapwave_fshalphamin, snapwave_fshfac, snapwave_fshexp
Kept: baldock_opt > discuss later whether we want to keep this with SnapWave team
- Add all snapwave vars also to attribute list for netcdf output, not all possible because of same name as in sfincs_data. Can see whether/how to add those later
- renamed iig to igwaves_opt, and put in snapwave_data
- Removed write statement, tpinc and tpig values are available in sfincs_his.nc now by default
…v_ig' in sfincs_snapwave.f90 after call update_boundary_conditions & compute_wave_field so values at first timestep are not 0!

- Also added check on incoming Tpig in sfincs_snapwave, that is used in SFINCS' wavemaker routine.

- Add check and warning on water depth in snapwave_infragravity - determine_ig_bc, because if you have snapwave.bnd points in shallow water (e.g. <10m), and expecially with low directional spreading, the computed Hm0ig can be large (>2m)
- Consider calculating a mean deptht_bwv to use for herbers if deptht_bwv(ib) is very low, or set back to 10 m minimum. For now it's only a warning
-  zsm also used in sfincs_continuity if 'snapwave=true' > todo: check if needed, or only for wavemaker
- remove reduction of IG wave height at boundary in case of high values in Herbers - for now
fixed issue where combined uv indices were not set properly (issue only occurred icm snapwave)
added advection_mask (set to 0 next to boundaries and wave makers)
added check on time series for wave makers and snap wave not covering entire simulation time span
…l tstop (plus a little bit with dt), max output was called twice,

while only (correctly) allocated for 1 timestep
- Solved by not adding 'dtmaxout' in sfincs_lib.f90 if t>t1
- to be discussed whether this is the optimal solution
…which sometimes went wrong

- solved by adding parantheses
…cdf library (causing in weird error message for user), but do a more clear check on the extension being '.nc' or not.

- Therefore error message is adapted
…sing netcdf library (causing in weird error message for user), but do a more clear check on the extension being '.nc' or not."

This reverts commit 9bcea17.
@Leynse Leynse closed this Mar 1, 2024
@Leynse Leynse deleted the renamed_bins_to_levels branch March 1, 2024 09:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants