3.66667

3.7 | 3 ratings Rate this file 102 downloads (last 30 days) File Size: 3.01 KB File ID: #10557

wavelength

by alex sanchez

 

28 Mar 2006 (Updated 24 Apr 2006)

No BSD License  

solves the dispersion relation for ocean surface waves by using the Newton-Raphson method

Download Now | Watch this File

File Information
Description

Solves the dispersion relation for ocean surface waves

USAGE:
  [L,e,c] = wavelength(T,d,U,delta,alpha,tol)

DESCRIPTION:
  Simple program that solves the
  dispersion relation for ocean
  surface waves using the
  Newton-Raphson method
  It can also account for wave-current
  interaction by solving a modified form
  of the dispersion relation proposed be
  Jonsson (1970)

INPUT VARIABLES:
  T = Wave Period, (seconds)
  d = Water Depth, (m)
  U = Current Velocity, (m/s)
  delta = direction of current (rad) with
      respect to the cross-shore direction
  alpha = direction of waves (rad) with
      respect to the cross-shore direction
  tol = Maximum tolerance allowed for L
      the default is 1e-6 (Generally 3 iterations)

OUTPUT VARIABLES:
  L = Wave length, (m)
  e = Relative error of L
  c = Iteratios

NOTES:
  For deep water - L = g*T^2/2/pi
  For shallow water - L = T*sqrt(gd)

REFERENCES
Eckart, C. (1952) The Propagation of Gravity
  Waves From Deep to Shallow Water, Natl. Bur. Standards,
  Circular 521, Washington, DC, pp 165-173.

Jonsson, I.G., Skougaard, C., and Wang, J.D. (1970)
  Interaction between waves and currents, Preceedings
  of the 12th Coastal Engineering Conference,
  ASCE, 489-507

nargin==0 runs a demo

MATLAB release MATLAB 7 (R14)
Tags for This File  
Everyone's Tags
Tags I've Applied
Add New Tags Please login to tag files.
Comments and Ratings (4)
04 Apr 2006 Garner Izru

Good!

06 Apr 2006 Lez Zeppelin

Poor numerics & script.

31 Oct 2007 Luis Nevarez

i need the program

20 Dec 2008 James Franklin

I think that's a bit harsh Lez, the program works well AND quickly. i have checked it against the CARC wave calculator and it appears correct so far.

the sript is clear and the numerics are from Goda (2000) random sea and design of maritime structures....Goda isn't wrong!

Overall for a engineer or a student or a postgrad starting wave modelling this a good and useful *.m file.

Cheers!

Please login to add a comment or rating.
Updates
10 Apr 2006

major bug fix in while loop

24 Apr 2006

update

Tag Activity for this File
Tag Applied By Date/Time
wave length alex sanchez 22 Oct 2008 08:20:51
dispersion alex sanchez 22 Oct 2008 08:20:51
currentwave alex sanchez 22 Oct 2008 08:20:51
interaction alex sanchez 22 Oct 2008 08:20:51
ocean alex sanchez 22 Oct 2008 08:20:51
 

MATLAB Central Terms of Use

NOTICE: Any content you submit to MATLAB Central, including personal information, is not subject to the protections which may be afforded information collected under other sections of The MathWorks, Inc. Web site. You are entirely responsible for all content that you upload, post, e-mail, transmit or otherwise make available via MATLAB Central. The MathWorks does not control the content posted by visitors to MATLAB Central and, does not guarantee the accuracy, integrity, or quality of such content. Under no circumstances will The MathWorks be liable in any way for any content not authored by The MathWorks, or any loss or damage of any kind incurred as a result of the use of any content posted, e-mailed, transmitted or otherwise made available via MATLAB Central. Read the complete Terms prior to use.

Contact us at files@mathworks.com