Vpp-simulator

Discussion in 'Hydrodynamics and Aerodynamics' started by SAMNAR, Jul 9, 2012.

  1. SAMNAR
    Joined: Jul 2012
    Posts: 3
    Likes: 0, Points: 0, Legacy Rep: 10
    Location: Sant Cugat del Vallès

    SAMNAR New Member

    Hello everyone,

    This is my first post here so I may introduce myself. My name is not samnar, I'm from Sant Cugat (near Barcelona in Spain) and nowadays I'm trying to finish my bachelor thesis. I haven't been studying english for a long time so I beg you forgive my mistakes.

    Our thesis is about a kind of unsteady VPP-track simulator. Our simplified boat model takes into account the common aero-hydro forces and the yaw moment (leaving roll for the time being). We are using two different RS, one fixed on the sailboat and the other on earth.

    The inputs that we consider are:

    • environmental: TWS,TWA,true current speed and true current angle.
    • status: boat speed, leeway angle,angle between reference systems and angular velocity between reference systems.
    • control: rudder angle and sailchord deviation angle (assuming just one sail).

    And the output has to be the status at (t0+Δt). We calculate it by means of an euler integrator solver.

    By now we have programmed both the model and the solver in C but we are having several problems with the calculus of the fluidynamic forces.

    Aero forces:

    In this part of the model we need the lift and drag coefficients related with the angle of attack of the sails (not the AWA).

    For the aerodynamic forces our professor suggested the use of the typical flat plate lift and drag coefficients. Do you know what relative error may the solution have using this approximation?:?:

    I've recently discovered XFOIL and I thought that another possibility to get that coefficients in a more precise way could be using XFOIL for a cambered flat profile. Do you think this approach will be better? What should be the ratio between the profile thickness and the mainchord to get accurate results?:?:

    I would like to hear other options for solving the aero forces, so pleas feel free to contribute.

    Hydro forces:

    Here we have some references that we have to explore like: "Aero-hydrodynamics and the perfo. of SY" (Fossati) and other papers found in internet. Pleas let me know any other reference.

    Finally we have some trouble in finding the inertia moment around "z" axis. The professor suggested the use of an empty semi-cylinder to model the bare hull and two plates to model both rudder and keel. I think that it would be better to use a revolution semi-paraboloid approximation for the hull, how do you see it? :?:Again I'll apreciate any help in this issue.

    I may refer to the "database" we are planning to use. We'll use the RI (or IR) form due to it's extended use in our coasts, examples of this forms can be found in:

    http://89.131.139.93/fmi/iwp/cgi?-db=RI2012&-loadframes

    Once in the site you have to click on the upper right box, selecting a boat model and clicking on "continuar" box.

    I hope you'll be interested in our work and I promise we'll publish our code once we fix all the remaining issues.

    Cheers!
     
  2. Tim B
    Joined: Jan 2003
    Posts: 1,438
    Likes: 59, Points: 0, Legacy Rep: 841
    Location: Southern England

    Tim B Senior Member

    For the Aero calcs have a look at Hazen's method. The basics are in "Principles of Yacht Design". The version quoted in principles doesn't include any sheeting angle, but it should give you an idea about the "coefficient-only" model. Your next option up in complexity is a Vortex-Lattice method. There are a few around on the net, so you might comment on thier application in your write-up, but I wouldn't try to incorporate it in your simulation, as you won't have time to code it and verify it. Up from that is a "full" 3D panel method, and then 3D CFD. I would do no more than comment that these methods could feed the coefficient model for known AWA and sheeting angles.

    For hydro forces you need to look at the work of Gerritsma and Keuning, done at Delft. The Delft series is a very good place to start for yacht-hull resistance and sideforce.

    In terms of inertia, I had a similar problem a little while ago. However, If you discretize the hull (and everything else) into triangles (easy with a CAD package), each of which is so small that it can be treated as a point mass, then the inertia of the whole boat is simply the sum of the inertias of all the point masses. This is obviously a simplification, but I don't think it's unreasonable. You can include major structure and known masses (anchor & chain for example) in the same way. That should give you the major terms of the mass matrix. The cross-coupling terms can be worked out from the major terms for each element.

    Have a look at the references on http://openDynamics.engineering.selfip.org they may be of some help. Given that openDynamics is a vessel dynamics code I'm developing, feel free to ask any questions, I may be able to help.

    Cheers,

    Tim B.
     
    1 person likes this.
  3. SAMNAR
    Joined: Jul 2012
    Posts: 3
    Likes: 0, Points: 0, Legacy Rep: 10
    Location: Sant Cugat del Vallès

    SAMNAR New Member

    Thanks Tim B,

    Your references and tips seem really interesting. I'll have, for sure, many questions to ask you when I finish exploring them.

    Cheers!

    SAMNAR
     
  4. tspeer
    Joined: Feb 2002
    Posts: 2,319
    Likes: 303, Points: 83, Legacy Rep: 1673
    Location: Port Gamble, Washington, USA

    tspeer Senior Member

    Here are some references you may find useful:

    Erik Jan de Ridder, Jan Alexander Keuning & Kees Jan Vermeulen, "A Mathematical Model for the Tacking Maneuver of a Sailing_Yacht," 18th HISWA Symposium, 2004, http://www.hiswasymposium.com/assets/files/pdf/2004/Keuning@hiswasymposium-2004.pdf.

    B. Verwerft and J.A. Keuning, "The application of a time dependent performance prediction model on the dynamic behaviour of a sailing yacht," 20th HISWA Symposium, 2008, http://www.hiswasymposium.com/assets/files/pdf/2009/Hiswa Symposium 2008 Bart Verwerft.pdf.

    Jan Alexander Keuning, "The influence of the shape of the keel on the forces on the rudder of a sailing yacht," 19th HISWA Symposium, 2006, http://www.hiswasymposium.com/assets/files/pdf/2006/Keuning@hiswasymposium-2006.pdf.

    J. A. Keuning and U. B. Sonnenberg, "Approximation of the Hydrodynamic Forces on a Sailing Yacht based on the 'Delft Systematic Hull Yacht Series'," 15th HISWA Symposium, 1998, http://www.hiswasymposium.com/assets/files/pdf/previous/15th - 1998/Keuning@hiswasymposium-1998.pdf

    When you program your VPP, you should make a clear distinction between states, parameters, controls, and outputs. States are variables that must be integrated in time. Each state will have an associated time derivative that is calculated at the present time based on the forces and moments at the present time. States also need to have initial conditions assigned to them. Parameters are constants that define the characteristics of various parts of your model, such as dimensions, mass properties, etc. The environmental quantities may also be considered to be parameters. Controls are inputs to the model that can be varied arbitrarily, such as rudder deflection, sail trim or crew position. Outputs are variables that can be calculated entirely from the values of the states, parameters and controls at a given time step.

    You will need a solver that can vary the controls and states so as to achieve a trimmed equlibrium (all state time derivatives equal zero) at a desired sailing condition (true wind angle, etc.). One way to do this is to set up a feedback control system between the outputs and the controls, and let the controller run to steady state. A faster way may be to use something like a conjugate gradient algorithm.

    The most useful way to organize the calculation of the forces and moments is to program generic equations into the VPP and have tables in external files that contain the particular coefficients, mass properties, etc., as a function of the other parameters, controls and outputs. This way you can change the tables to improve the model without having to rewrite code, and it is easy to move from one configuration to another by simply specifying a different set of tables.

    A simulation platform such as Matlab may make it easier to handle the numerical aspects of your model, allowing you to concentrate on the fidelity of the force and moment tables. Matlab will also be convenient when you start to do your dynamic analyses, as it can generate linear models (useful for understanding the dynamic modes and for control synthesis) and there are programs that use Matlab for estimating optimal trajectories, such as DIDO (http://www.elissarglobal.com/industry/products/software-3/).
     
    1 person likes this.
  5. tspeer
    Joined: Feb 2002
    Posts: 2,319
    Likes: 303, Points: 83, Legacy Rep: 1673
    Location: Port Gamble, Washington, USA

    tspeer Senior Member

    With regard to XFOIL, it will only handle two-dimensional section coefficients. If you have a headsail, XFOIL will not be able to handle the interaction between main and jib. You may find Javafoil more useful for section characteristics for this reason.

    To get the three-dimensional aerodynamics, you will need a program like AVL in addition to the section data.

    However, if you go with an empirical model like the Hazen model, you do not need these programs. Since the focus of your initial work should be on the dynamic modelling, an empirical model will allow you to focus on the most important aspects of the simulation. More fidelity can be added later.
     
  6. philSweet
    Joined: May 2008
    Posts: 2,697
    Likes: 460, Points: 83, Legacy Rep: 1082
    Location: Beaufort, SC and H'ville, NC

    philSweet Senior Member

    SAMNAR, one aspect of sailing that almost all craft have in common is the ability to reef and change the twist of the sails. If a sail template file contained five points in 3D that represented the leach of the sail (tack at 0,0,0), it could be though of as five strips of sail. Reef parameter could delete the bottom strip. Flat parameter could rotate a leechpoint about the z axis by an amount depending on the z coordinate. Aero forces would consist of Cl, Cd, Area, and Center of force of each strip after the template had been modified and positioned relative to the hull. Evaluate each strip and add a factor for the exposed mast if some reefing was done.

    You also need to bound the sail position as a function of AWA in some way for any given sail foil shape. This may be why your advisor recommended a flat plate model for the sail. The bounding parameters should be part of each template file (or if you decide to use separate templates for sail perimeter and foil shape- with the foil shape template). A flat triangle seems a reasonable first template. Make it easy on your advisor. Show him something he can check on manually with ease. In the real world, the ability to validate is crucial, so target some arangement for which you can validate the steady state status, then the dynamic data may be teased out with a bit more confidence.
     
  7. SAMNAR
    Joined: Jul 2012
    Posts: 3
    Likes: 0, Points: 0, Legacy Rep: 10
    Location: Sant Cugat del Vallès

    SAMNAR New Member

    Thanks for all your tips!

    Tim B., I'm trying to build and run your code but it seems I'm missing something. In command window when I use "make" command it says that "mingw32-make" can't be recognized. Do you know how could I fix this?

    Cheers, SAMNAR
     

  8. Tim B
    Joined: Jan 2003
    Posts: 1,438
    Likes: 59, Points: 0, Legacy Rep: 841
    Location: Southern England

    Tim B Senior Member

    Samnar,

    You need the QT Libraries and gfortran installed. Then run qmake, followed by make in the src directory, and everything should build ok (binaries will be placed in the "bin" directory)

    The code that is currently in the repository is only the pdStrip code and the windows front-end with some other conversion codes. I have not yet got the time-domain dynamics model to a commit-ready state, however, I am reasonably close, so I will work on it over the weekend.

    I am also thinking of changing to GIT for source-control, but I will update the wiki if I decide to do that.

    Cheers,

    Tim B.
     
Loading...
Forum posts represent the experience, opinion, and view of individual users. Boat Design Net does not necessarily endorse nor share the view of each individual post.
When making potentially dangerous or financial decisions, always employ and consult appropriate professionals. Your circumstances or experience may be different.