Coder Social home page Coder Social logo

mre-code-hub / mwave Goto Github PK

View Code? Open in Web Editor NEW

This project forked from cmcnatt/mwave

0.0 0.0 0.0 384.67 MB

A water wave and wave energy converter computation package

License: GNU Lesser General Public License v3.0

MATLAB 93.71% HTML 1.09% Batchfile 0.11% Roff 5.09%

mwave's Introduction

#mwave mwave is a water wave and wave energy converter (WEC) computation package written for MATLAB. Copyright (C) 2014 Cameron McNatt contact: [email protected] repository: https://github.com/cmcnatt/mwave

README Last modified: 3 September, 2015

About

mwave can be used to compute (for example):

  • various linear wave fields
  • WEC motions and power
  • WEC array motions and power
  • WEC wave fields

At this point, it is essentially all linear wave theory. Most values are complex variables and assume an exp(iomegat) time dependence, where i is the imaginary 1, omega is the radial frequency and t is time.

It was initially written as a pre- and post-processor for WAMIT (www.wamit.com), but it has expanded a bit beyond that, for example to include:

  • the computation of analytical wave fields (heaving and surging point sources).
  • the hydrobody computation, which allows for analytical wave field to be computed from real geometries (albeit with WAMIT).
  • the interaction theory computation, which allows for arrays for floating bodies to be computed efficiently.

The documentation ('Documentation' folder and source files) is still a bit sparse, and this needs work. I would recommend checking out the references (References in Documentation folder) including the WAMIT theory manual for more info on the theory.

I'm sure there are bugs and better ways of doing things than I've implemented. And so, please contribute to the code! If you contribute to a given file, add your name to the header. If you create a new file, add the header, by either copying and pasting the header from the file mwaveHeader in the 'Header' folder, or by running addMwaveHeader on that file. Then submit a GitHub pull request.

##INSTALLATION:

  1. Put the mwave folder where ever you'd like it.

  2. Add it to your MATLAB path, by

    a) running in MATLAB: addpath(genpath(folderName),'-frozen') savepath b) adding to your startup.m file: addpath(genpath(folderName),'-frozen')

where folderName is the full path to the mwave folder. Because '-frozen' is used, MATLAB won't recognize when you add a new file, so be sure to explicitly add that file as well (or run addpath again).

  1. Add newmodes.dll, see NEWMODES below.

##NEWMODES: The Newmodes.dll is a library of user defined subroutines that WAMIT uses to compute generalized modes of motion. WAMIT comes with some prewritten subroutines, but I've added some custom ones as well.

The attenuator floating bodies ('FloatingAttenuator', 'FloatingSphereEndCyl', 'FloatingSphereEndCylHinge') use WAMIT generalized modes. Custom subroutines were written for the WAMIT Newmodes.dll.

At this point, the jury is still out on whether I can share my Newmodes.dll or Newmodes.f fortran source code, and so unfortunately, unless you write your own version of my subroutine, you cannot run the WAMIT runs with these geometries.

##GETTING STARTED: The best place to get started is with the examples in the 'Examples' folder. I tried to very explicit with my comment here. The UnitTest folder also has some good examples.

I would really like to make this code as useful to people as possible, so if you have any questions or need help, please contact me at [email protected]

mwave's People

Contributors

acotten1 avatar cmcnatt avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.