guidance and control of ocean vehicles-thor i fossen

494

Click here to load reader

Post on 16-Nov-2014

478 views

Category:

Documents


69 download

DESCRIPTION

ocean engineering

TRANSCRIPT

";/"-GuidanceandControlof ceanVehiclesThor I. FossenUniversity of TrondheimNorwayJOHN WILEY & SONSChichester' New Y6'rk . Brisbane . Toronto . Singapore

Copyright 1994byJohnWiley&Sons LtdBaffinsLane, ChichesterWestSussexP019lUD, EnglandNational Chichester (0243) 779777International (+ 14) 213779777ReprintedDecember 1995ReprintedMay1998Hcpdntcd March 1999All rightsreservedNopartof thispublicationmaybereproducedbyanymeans, OItransmitted I or translatedintoa machinelanguage without thewrittenpermissionof thepublisher.OtherWHeyEditorial OfficesJohnWiley&Sons, Inc, 605ThirdAvenue,NewYork, NY10158-0012, USAJacarandaWileyLtd, 33Park Road, Milton,Queensland4064, AustraliaJohnWiley&Sons(Canada) Ltd, 22Worcester Road,Rexdale, OntarioM9WlL1, CanadaJohnWiley&Sons(SEA) PteLtd, 37JalanPamimpin#05-01,BlockB, UnionIndustrial Building,2057Britisll Library CataloguinginPublicationDataA cataloguerecordforthisbookisavailablefromtheBritishLibraIYISBN0171941131Producedfromcamera-readycopysuppliedbytheauthor usingLaTeX,Printed andboundinGreatBritainbyAntony Rowe Ltd, Chippenham. Wiltshire"I",,:!\iIIlI'IThisbook isdedicatedtoHeidi andSindreContentsPreface xiii1 Introduction 12 Modelingof MarineVehicles 52.1 Kinematics . 62.1.1 EulerAngles .. 72.. 1.2 Euler Parameters . 122.1.3 Euler-Rodrigues Parameters 172.1.4 Comments onParameter Alternatives. 172.2 NewtonianandLagrangianMechanics 182.2.1 Newton-Euler Formulation. . . . 182.22 Lagrangian Formulation . . . . . 192.23 Kirchhoff'sEquations of Motion .. 202.3 Rigid-Body Dynamics ... 212.3.1 6 DOF Rigid-Body Equations of Motion 2524 HydrodynamicForces andMoments .. 30241 AddedMassand Inertia . . 32242 HydrodynamicDampi]fg 4224.3 Restoring ForcesandMoments 462.5 Equations of Motion . 482.5.1 Vector Representations . 482.5.2 UsefulProperties of theNonlinearEquationsof Motion. 492.53 TheLagrangian VersustheNewtonianApproach 522 6 Conclusions 5427 Exercises.... 553 Environmental Disturbances 573.1 ThePrinciple of Superposition .. 573.2 Wind-Generated Waves. . . 6032.1 Standard Wave Spectra .. 623.2.2 Linear Approximationstothe Wave Spectra 693.2.3 Frequency of Encounter 72324 Wave-InducedForces andMoments 733.3 Wind. "'" 7' 76331 Standard Wind Spectra . 76viii CONTENTS332 WindForcesandMoments.773.4 OceanCunents843,41 CurrentVelocity843.4.2 Current-Induced ForcesandMoments853.5 Conclusions 9036 Exercises914 Stability andControl of UnderwaterVehicles9341 ROVEquations of Motion944.11 ThrusterModel94412 Nonlinear ROVEquations of Motion994.13 LinearROVEquations of Motion 994.2 Stability of Underwater Vehicles. 102421 Open-Loop Stability 1024.2.2 Closed-Loop Tracking Control 1044.3 Conventional AutopilotDesign. . 105431 Joy-StickControl SystemsDesign 1054.3.2 Multivariable PID-ControlDesign forNonlinear Systems 105433 PID Set-Point Regulation in Terms of Lyapunov Stability. 1074.3.4 Linear QuadraticOptimal Control 112,I4.4 DecoupledControl Design 114I,4.4.1 Forward SpeedControl . 1154,42 Automatic Steering. 1174.4.3 Combined Pitch andDepthControl . 11945 AdvancedAutopilotDesign forROVs . 1254.51 Sliding ModeControl . 1254.5.2 State Feedback Linearization. . 137;I4.53 AdaptiveFeedback Linearization 14345.4 Nonlinear Tracking(TheSlotine andLi Algorithm) 1464.5.5 Nonlinear Tracking(TheSadegh andHorowitzAlgorithm) 1514.5.6 CascadedAdaptiveControl (ROVandActuatorDynamics) 1524.57 UnifiedPassive AdaptiveControlDesign 15545.8 Parameter Drift duetoBoundedDisturbances 1594.6 Conclusions 16147 Exercises. 1625 Dynarp.icsandStability of Ships 1675.1 Rigid-Body Ship Dynamics .. 1685.2 The Speed Equation 1695.21 Nonlinear Speed Equation 169522 Linear Speed Equation 1705.3 TheLinear Ship Steering Equations . 1715.3.1 TheModelof Davidson andSchiff (1946) . 17153.2 TheModelsof Nomoto(1957) 172I,iI ,CONTENTS IX533 Non-Dimensional Ship Steering Equationsof Motion 1775 3A Determination of HydrodynamicDerivatives 17954 The Steering Machine 18155 Stability of Ships . . . . . . . . . 18555.1 Basic Stability Definitions 185552 Metacentric Stability 1905.53 Criteria forDynamic Stability in Straight-Line Motion 193554 Dynamic Stability on Course. 19756 Nonlinear Ship Steering Equations . 198561 TheNonlinear Modelof Abkowitz(1964) 1985.62 TheNonlinear Modelof Norrbin(1970) . 1995.6.3 TheNonlinear Model of Blanke(1981) . . 2015.7 CoupledEquationsforSteering andRolling 2025.7.1 TheModel of VanAmerongenandVanCappelle(1981). 20257.2 TheModel of Son andNomoto(1981) 2035.7.3 TheModelof ChristensenandBlanke(1986). 2045 8 Steering Maneuvering Characteristics . . . . 20658.1 Full-Scale Maneuvering Trials 20758.2 TheNorrbinMeasureof Maneuverability 2165 9 Conclusions 218510Exercises 2186 AutomaticControl of Ships 2216.1 Filtering of First-Order Wave Disturbances. 2226L1 Dead-Band Techniques 22361.2 Conventional FilterDesign. 2246.1.3 Observer-BasedWaveFilter Design. 22861.4 Kalman Filter Based WaveFilter Design 2376.1.5 WaveFrequency Tr'acker . . . 24262 ForwardSpeedControl . . . . 2466.2.1 Propellers asThrustDevices. 246622 Control of Ship Speed 254623 Speed Control for Cruising. 2576.3 Course-Keeping Autopilots. . . . 2596.3.1 Autopilots of PlD-Type 2596.3.2 Compensation of ForwardSpeed Effects 2636.3.3 LinearQuadraticOptimal Autopilot: 2656.3.4 AdaptiveLinearQuadratic Optimal Control 2716.4 Turning Controllers. 2736.4.1 PlD-Control. 2766.4.2 CombinedOptimal and Feedforward TurningController 2776.4.3 Nonlinear Autopilot Design .... 2786.4.4 AdaptiveFeedbackLinearization . 2816.4 5 ModelReferenceAdaptiveControl 283CONTENTSxiB3B21 Euler'sMethod ..B2.2 Adams-Bashforth's2nd-OrderMethodB2.3 Runge-Kutta2nd-OrderMethod(Heun'sMethod)B 24 Runge--Kutta 4th-OrderMethodNumerical Differentiation.406408409409410:::1.C Stability TheoryC 1 Lyapunov Stability Theory.C.l.1 LyapunovStability forAutonomous SystemsC.l.2 LyapunovStability forNon-Autonomous SystemsC.2 Input-OutputStability.C2.1 Some Basic DefinitionsC.22 Lp-StabilityC.2.3 Feedback StabilityC.3 Passivity TheoryC.3.1 Passivity Interpretation of Mechanical Systems.C.3.2 Feedback Stability intheSenseof PassivityC.3.3 Passivity in Linear SystemsC.3A Positive RealSystemsD LinearQuadraticOptimalControlD.1 Solution of theLQTrackerProblem.,TIl.l Linear Time-Varying SystemsD.L2 Approximate Solution forLinear Time-Invariant SystemsD.2 Linear Quadratic Regulator411411411412414414416417418418421421423425425426427429E Ship andROVModels 431El Ship Models. 431E.l.1 Mariner Class Vessel 431E12 TheESSO190000 dwt Tanker. 435EL3 Container Ship . . . 440E2 UnderwaterVehicleModels . 447E2.1 Linear Model of a Deep Submergence Rescue Vehicle (DSRV)447E22 LinearModelof aSwimmer Delivery Vehicle(SDV) 448E2.3 NonlinearModel of theNavalPostgraduateSchool AUVII 448F Conversion FactorsBibliographyIndex453455475PrefaceMyfirst interest for offshoretechnologyandmarinevehiclesstartedduringmy"siviJingeni0r"(MSc) study at the Department of Marine Systems Design at TheNorwegian Institute of Technology(NIT). This interestwas my main motivationfor a doctoral study in Engineering Cybernetics at theFaculty of Electrical Engi-neeringandComputer Sciences(NIT) andmygraduate studies inflight controlat theDepartment of AeronauticsandAstronautics, Universityof Washington,Seattle. Consequently, muchofthematerial andinspirationfor the bookhasevolvedfromthis period. Writingthis book, is anattempt todrawthe disci-plines of engineering cyberneticsand marine engineering together.Systems forGuidanceandControl have been taught by the author since 1991for MSc students in Engineering Cybernetics at the Faculty of Electrical Engineer-ing andComputer Science(NIT) Thebook isintendedasatextbook for seniorand graduate students with some background in control engineering and calculus.Some basic knowledgeof linear and nonlinear control theory, vectoranalysis anddifferential equationsisrequired. Theobjectiveof thebookis topresent andapply advancedcontrol theory to marine vehicles like remotely operated vehicles(ROVs), surfaceships, highspeedcrafts andfloatingoffshorestructures Thereasonfor applyingmoresophisticatedautopilotsforsteeringanddynamicpo-sitioning of marinevehicles ismainlyduetofuel economy, improvedreliabilityandperformanceenhancement, Since1973, therapidincreaseinoil priceshascontributedtothistrend. This justifiestheuseof moreadvancedmathematicalmodelsandcontrol theoryinguidance andcontrol applications,Ass. ProfessorThor1. FossenUniversity of TrondheimTheNorwegian Institute of TechnologyDepartmentof EngineeringCyberneticsN-7034 Trondheim, NorwayAcknowledgmentsIt is impossible to mention everyone whohas contributedwith ideas, suggestionsand examples, but I owe you all my deepestthanks I am particularly grateful toDr SveinL Sagatun(ABBIndustry, Oslo) andDr. Asgeir S0rensen(ABBCor-porateResearch, Oslo) for theircommentsanduseful suggestions. Dr. S0rensenshould also be thanked for his sincere help in writing Section 7.1 on surface effectships, ,/xiv PREFACEI acknowledge the helpof Professor Mogens Blanke (Department of Con-trol Engineering, AalborgUniversity) for hishelpinwriting Section6,2onshippropulsionandspeedcontrol whileDr EdingLunde (consultant for DynamicaAS, Trondheim) andMLWilliamC O'Neill (consultant for AdvancedMarineVehicles, 852GoshenRoad, NewtownSquare, PA19073) shouldbethankedfortheir sincere help in writing Section 7,2 on foilborne catamarans, I am also grate-fultoProfessor Olav Egeland(Department of Engineering Cybernetics, NIT)forhis valuable commentsto Sections2,1to2,3 and toProfessorAnthonyJ, Healey(Mechanical Engineering Department,Naval Postgraduate School, Monterey)forcontributing withlecturenotesandtheunderwatervehiclemodelsinAppendixB-2,Iwant toexpressmygratitudetoABBIndustry(Oslo), RobertsonTritechAjS(Egersund), theNorwegianDefenceResearchEstablishment (Kjeller) andtheUlsteinGroup(Ulsteinvik) forcontributingwithfull scaleexperimental re-sults"Furthermore, MLStewartClark, Senior Consultant(NIT) anddoctoral stu-dentsAlf GBringaker andErling Johannessen(Department of Engineering Cy-bernetics, NIT)shouldbethankedfor their careful proofl'eading andcommentsto the finalmanuscript,Theauthor is alsograteful tohis doctoral student Ola-ErikFjellstadandAstridEgeland fortheir usefulcommentsand suggestions, MortenBrekke, GeirEdvin Hovland, TrygveLauvdal andKjetil Ri1Je shouldbethankedfortheir helpwithillustrations, examplesandcomputersimulations, Thebookalsogreatlybenefits fromstudents who took thecourse in guidance andcontrol atNITfrom1991to1993, Theyhaveall helpedmetoreducethenumber of typographicalerrors toanacceptablelevel.. Finally, I want tothank Ms, LauraDennyandML Stuart Gale (John Wiley & Sons Ltd,) who have provided me withtechnicalandeditorial commentstothe finalmanuscript.'l'horLFossenJanuary1994,IIIChapter1IntroductionThe subject of this textbook isguidanceandcontrol of ocean vehicles. Thistitlecovers control systems designfor all types ofmarinevehicles likesubmarines,torpedoes, unmannedandmannedunderwatervehicles, conventional ships, highspeed craftsand semi-submersibles. Examplesof such systemsare:o control systems for forward speed controlo autopilots for course-keeping and divingo turning controllerso track-keeping systemso dynamic positioning (DP)o rudder-roll stabilization (RES) fin control systemso wave-induced vibration dampingFor practical purposes the discussion will concentrate on three vehicle categories:small unmannedunderwater vehicles, surface shipsandhigh speedcraft.Guidance andControlThe termsguidance andcontrol can be defined sothat:GUIDANCEistheactionof determiningthecourse, attitudeandspeedof thevehicle, relative to some reference frame(usually the earth), tobe followedby thevehicle.CONTROL is the development andapplication to a vehicle of appropriate forcesandmomentsforoperating pointcontrol, trackingand stabilization. Thisinvolvesdesigning the feedforwardand feedbackcontrollaws.2 Introduction, :,Example1.1 (Automatic Weather Routing) ),Thedesignof anautomaticweatheT'r'outingsystemfaT' a shipTequiT'es insightinbothadvanced modelingand optimalcontmltheory. M weneedanaccu-ratemodel of theshipandtheenvironmentalfOT'ces (wind, waves andcurTents)to describe the speedloss of the ship in badweatheT'. Basedonthe speedlosscomputations wecancomputea fuel optimal route. Finally, we havetodesignanoptimal track-keepingcontroller(autopilot) to enSUT'e that thismuteisfollowedbytheship.--1Feedforward Iu: Actuators :'CIcontrol systemII Dynamicsh IKinematics hFeedbackVehicler---control system .-motionsensorTld1;I Reference I I Guidance II Kinematic f-t-I generlltor I Isensors IItransfonnationItweatherdatawind,waves andt Figure1.1: Guidance and control system forautomatic weather routing of ships.AguidanceandcontT'ol system forautomaticweather routingof a shipisshowninFiguT'e 1.1. This systemuses weatherdatameasurementstocompute a fueloptimal mutefaT' theshipwhichisfedforwardtothe contT'ol systemthrough ablock denotedas the "feedforwaT'd contml system". Inaddition tothis, feedback isprovided inanoptimalmanner fromvelocityv andposition/attitude17 thmughtheblock "feedbackcontrol system". The contr-ol force andmoment vectorT ispmvidedbytheactuatoT'viathecontm.l variable u, whichmaybeinterpretedasthesumof the feedforwardand feedbackcontrol action.Wealsonotice that the1'efeT'ence gener'atoT'17dmay useweather datat; (windspeed, winddirection, waveheight etc.J togetherwiththeshipstates(v, 17) tocompute the optimal route. This is usually done by includingconstraints forfuel consumption, actuatorsaturation, fOT'waT'd speed, restrictedareas for shipmaneuveringetc.oIntroductionAnOverviewof theBook, ,).3Thisbook dealsmainly with modeling andcontrolof unmanneduntetheredun-derwater vehicles(remotely operated vehiclesandautohomousunderwatervehi-cles), surface ships(cargo ships, tankersetc,) and high speed craft(surface effectships and foilbomecatamarans).Thedesign of modern marine vehicleguidanceandcontrol systemsrequiresknowledgeofabroadfieldof disciplines. Someofthesearevectorial kinemat-ics anddynamics, hydrodynamics, navigationsystems andcontrol theory. Tobeabletodesignahighperformancecontrol systemit is evident that agoodmathematical modelof thevehicle isrequiredforsimulation andverificationofthe design. As a result of this, the book contains a large number of mathematicalmodels intended forthis purpose. The clifferenttopics inthe book are organizedaccording to:MODELING: marinevehiclekinematicsanddynamicsin6 degrees of freedom(Chapter 2) andenvironmental clisturbancesintermsof wind, waves andcurrents(Chapter3)UNDERWATERVEHICLES: stabilityand control systemdesignfor small UD-manned underwater vehicles(Chapter 4).SURFACESHIPS: shipdynamics, stabilityandmaneuvering(Chapter 5) andship control systemdesign(Chapter 6),HIGHSPEEDCRAFT: control systemdesign forsurfaceeffect ships(SES) andfoilcats(Chapter 7) ..Itisrecommendedthat oneshouldreadChapter 2beforeChapters 3-7sincethesechapters use basic results from vectoIial kinematicsanddynamics.Chapter2Modeling of MarineVehiclesModeling of marine vehicles involves the study of statics anddynamics. Statics isconcerned with the equilibrium of bodies at rest or moving with constant velocity,whereas dynamics is concerned with bodies having accelerated motion. Statics isthe oldest of the engineering sciences. In fact, important contributions were madeover2000yearsagobyArchimedes (287-212BC) whoderivedthebasiclawofhydrostaticbuoyancy. Thisresult isthefoundationforstaticstabilityanalysesof marine vessels.Thestudyofdynamicsstartedmuchlatersinceaccuratemeasurements oftime are necessary to performdynamic experiments. One of the first time-measuringinstruments, a "water clock", was designed byLeonardo daVinci(1452-1519) This simple instrument exploited the fact that the interval betweenthe falling drops of water could be considered constant. The scientific basis of dy-namics was provided by Newton's laws published in 1687. It is common to dividethe studyof dynamics into twoparts: kinematics, which treatsonly geometricalaspectsof motion, andkinetics, whichistheanalysisoftheforces causingthemotion.Table2.1: Notationused formarine vehicles.forces and linear and positions andDOF moments angular vel. Euler angles1 motions in the x-direction (surge) X u x2 motions in the y-direction (sway) Y u y3 motionsin the z-direction (heave) Z w z4 rotation aboutthe x-axis(roll) K p . x0.Consequently, the rotation sequencefromatob can bewrittenas:b=Ca(2.3)(2.4)whereC canbeinterpretedas a rotation matrixwhichsimplyis anoperatortaking a fixed vector0.and rotating it to a new vector Co., From(2.3)we obtainthe following expression forC:IC=cos {3 I + (1 - cos (3...\T - sin{3 S(>.U (2.5)whereI isthe3 x3 identitymatrix andS(..\) isaskew-symmetricmatrix(seeDefinition 2.2)defined such that>. x0. Cl S(..\)a, that is:(2.6)Definition2.2 (Skew-Symmetry of aMatrix)Amatrix S issaid tobe skew-symmetrical if:S=-STThis implies that the off-diagonal matrixelements of S satisfy Sij - -Sji fori '" j while thematrix diagonal consistsof zeroelements.oThe setof all3 x3 skew-symmetric matricesisdenotedby88(3)whilethesetof all 3 x3 rotation matrices is usually referredto by the symbol 80(3)1'SpecialOrthogonal group of order 3.2.1Kinematics9Another useful interpretation of 0 E50(3) is as a matrix giving theorientationof atransformedcoordinateframewith respect toafixed(inertial) coordinateframe This isparticularlyuseful inguidance andcontrol applications whereweare concerned with motion variablesin the inertial and body-fixedreference frames.Expanding (2.5)yields the following expressions forthe matrix elements Ci{CIl - (1 - cos (3) ),i +cos (3C22- (1 - cos (3)+cos (3C33- (1 - cos (3)+cos (3C12 -(1 - cos (3) ),1),2 +)'3 sin (3C21- (1 - cos (3) ),2),1- ),3 sin (3 (2.7)C23 - (1 - cos (3)),2),3 +),1 sin (3C32- (1 - cos (3),\3A2- Al sin (3C31 - (1- COS(3),3),1 + A2sin(3C13- (1- cos (3)Al),3- ),2 sin (3Principal RotationsTheprincipalrotationmatricescanbeobtainedbysetting,\ = [1,0, of, ,\ =[0,1, of and>. =[0,0, If, respectively, in the general formula for C. This yieldsthe following transformation matrices:-SB]1 0o cB[cBOy,O = 0sB[1 0 0 ]Ox, =c0isa good approximation>Remark 2: It should be noted that for surface ships movin9 with a speed U 0 inwaves, Salvesen, Tuckand Faltinsen(1970) haveshownbyapplyingstriptheorythat MA(U)=f M';;(U). However, for' underwater vehicles(ROVs) and foilbornecatamarans opemting outside the wave-affectedzone, symmetry andfrequencyindependence havebeenshowntobereasonableassumptions. Thisis alsoa goodappmximation forpositioned ships(U~ 0).oConsider a symmetrical added inertia matrix (without loss of generality) hav-ing21distincthydrodynamicderivatives. Theaddedmassforcesandmomentscan be derived by applying potential theory. The method is based on the assump-tions of inviscid fluid, no circulation and that the body is completely submerged inan unbounded fluid. The last assumption is violated at the seabed, near underwa-ter installations and at the surface. However, this is not a practical problem sincedouble-body theory can be applied (Faltinsen 1990). Expanding (2.119) under theassumption that MA=M';;, yields:2TA- -Xuu2- Yvv2- Z,;,w2- 2Y,;,vw - 2X,;,wu - 2Xiluv_Kpp2- Mqq2- Nrr2- 2Mrqr - 2Krrp - 2Kqpq-2p(Xpu +Ypv +Zpw)-2q(Xqu +Yqv +Zqw)-2r(X;.u+Y;.v + Zrw) (2122)AddedMassForcesandMomentsBasedonthekineticenergyTAofthefluidit is straightforwardtoderivetheadded mass forces and moments. Thisusually done by application of Kirchhofl'sequations (Kirchhoff 1869), which simply relates the fluid energy to the forces andmoments acting on the vehicle. Consider Kirchhoff's equations in component form(seeMilne-Thomson 1968):d8TA=dt 8ud8TA--- =dt 8vd8TA--- =dt 8w2.4 HydrodynamicForcesandMoments35daTA---dt fJpdaTA---dt fJqdaTA---dt fJraTAaTA aTA aTA= w--- v-- +T--- q--- KAfJv fJw fJq fJTaTAaTA aTA aTA= u-- - w-- +p-- -T--- MAfJw fJu fJr fJpaTA aTA aTA aTA= v---u--+q---P---NAfJu fJv fJp fJq(2.123)Substituting (2.122)into(2.123)gives the following expressions for the addedmassterms(Imlay1961):XA = X"u+ X,;,(W +uq) + Xqq + Z,;,wq + Zqq2+Xvv +XftP+XfT- YvVT- YftTP- YrT2-XvUT- Y,;,WT+Y,;,vq + Zppq - (Yq - Zf)qTYA = Xvu+Y,;,w+Yqq+Yvv +YftP+ YrT + Xvur - Y,;,up + XfT2+ (Xp - Zf)Tp- Zftp2-Xw(up -WT) +X"ur- Z,;,wp-Zqpq + XqqTZA = X,;,(v. - wq) + Z,;,w + Zqq- X"uq- X qq2+Y,;,v +ZftP+ ZiT + Yvvp +Yfrp + Ypp2+Xvup+ Y,;,wp-Xvvq- (Xp - Yq)pq- XfqrK A= Xpu + Zpw + Kqq- Xvwu +Xfuq- Y,;,w2- (Yq - Zi)wq + Mfq 2+Ypv +Kpp +KfT + Y,;,v2- (Yq - Zf)VT + Zftvp - MfT2- KqTP+X,;,uv - (Yv - Z,;,)vw- (Yf + Zq)wr- Yftwp- XqUT'+(Yf + Zq)vq +Kipq - (Mq- Ni)qTMA = Xq(v. + wq) + Zq(w- uq) + Mqq- X,;,(u2- w2) - (Z,;, - X")wu+Yqv + Kqp +MfT + Ypvr - Yrvp- Kf(p2- r2) + (Kft - Nf)Tp-Y,;,uu + Xvuw - (Xf + Zp)(up - WT) + (Xp - Zi)(Wp + ur)-Mfpq +KqqTNA = XfU + ZiW + Mfq + X vu2+ Y,;,wu - (Xp - Yq)uq- Zpwq- K qq2+Yfv +KiP + NiT- X vu2- Xivr- (Xp - Yq)up + MfTp + K qp2-(X"- Yv)uv- X';'VW + (Xq+ Yp)up +YfUT + ZIiWP-(Xq+Yp)vq- (Kp - Mq)pq- KfqT (2.124)Imlay(1961) arrangedtheequationsinfour lineswithlongitudinal compo-nentsonthefirstlineandlateral components onthe second line Thethirdlineconsistsof mixedtermsinvolvinguor wasonefactor. If oneor bothofthesevelocities are largeenough -tobe treatedas aconstant the thirdline maybetreatedasanadditiomi.!termtothelateral equation of motion Thefourthline36 Modelingof MarineVehiclescontains mixedterms that usuallycanbeneglectedas secondorder terms Itshouldbenotedthat the off-diagonal elements of]'vIAwill be small comparedtothe diagonal elements for most practical applications. A more detailed discussiononthedifferent addedmass derivatives isfoundinHumphreys andWatkinson(1978)Property2.5 (CA)For arigid-bodymovingthrough an ideal fluid the hydrodynamic Coriolis andcentripetalmatrix CA(V) canalways be parameterizedsuchthat CA(V) isskew-symmetrical, thatis:bydefining.'[Oaxa -S(AIIVI + AI2V2) ]CA(V) =-S(AIIVI + A I2V2) -S(A21VI + A 22V2whereA ij(i, j =1,2) aredefined in(2.120).Proof: Substituting:into(2.93)inTheorem2.2directlyproves(2.125).oFormula(2.. 125)canbe written in component formaccordingto:(2.125)(2.126)0 0 0 0 -U3 U20 0 0 U3 0 -UjCA(v) =0 0 0 -u, Uj 0(2127)0 -U3U2 0 -b3b2U3 0 -Uj b30 -bj-u, Uj 0 -b2bj 0whereUI = X"u +XiJV +Xww + XpP +Xqq +XrrU2 = XiJU +YiJV +Yww +Ypp +Yqq +Yfrua = Xwu +Ywv +Zww + ZpP + Zqq + ZfTbl= Xpu +Ypv + Zpw + Kpp + Kqq +KfTb2= Xqu +Yqv + Zqw + Kqp +Mqq +MfTba Xru +Yfv +Zrw +Kfp + Mfq +Nrr(2.128)2.4 HydrodynamicForcesandMoments37SurfaceShipsFor surfaceships like tankers, cargoships, cruise-liners etc it is common todecouplethesurgemode fromthesteering dynamics. Similarly, theheave, pitchandroll modes areneglectedunder theassumptionthat thesemotionvariablesare smalLThis implies that the contribution fromthe added mass derivatives ona surface shipmoving withforwardspeedU 0 andthusNI Aof is:00]["] [ 0YvYr v+ 0Nil Ni' r Yitv +YrtN" i-Yvv - ] [ U ].x:uu vo TFor shippositioningwehavethat U 0andthereforeMA=Hence,we canreplaceNuwithYr intheaboveexpressionwhichyields:00]["] [0 0Y;Yrv+ 0 0Y". N;, r YiJv + YrT -Xuu-(YvV+YrT) ] [ U]XiJu Vo rUnderwaterVehiclesIngeneral, themotion of anunderwatervehiclemoving in6 DOF at high speedwill behighlynonlinearandcoupled. However, inmanyROVapplications thevehiclewillonlybeallowedtomoveat lowspeed. If thevehiclealsohas threeplanesof symmetry, this suggeststhat wecanneglectthecontribution fromtheelements in theadded mass matrix NI A Hence,the following simpleexpressions forMAandCAare obtained:MA = -diag{Xi" 2,-L/240 Modeling of MarineVehicles(2140)Two-dimensionaladdedmasscoefficients AgD) andasfunctionof thecircular frequencyof oscillation ,wfor acircularcylinderisshowninFigure24Noticethat the(ilinderapproximationintheshipexampleisbasedontheas-sumptionthatj(pA) inFigure24isequal toone This isonlytruefor alimited frequencyintervaL(::l'D} .....:4" (w)AAOB06,'\\ :"\'!.": \,\' __,,1('D)(W)?4 ,aA .. 02......: ".":'::- -- _. - -I 5;:----:----:'''=5-----,2;,----::'2,5w2R9Figure 2.4: Two-dimensional added massinheave andswayfor acircularcylinder(infinite waterdepth) as a function of wave circular frequency Inthe figureA =0511" R2whereRisthecylinder radius.AddedMassDerivativesfor aProlateEllipsoidFortunately, manyofthe addedmass derivatives containedin the general ex-pressionsforaddedmassareeitherzeroor mutuallyrelatedwhenthebodyhasvarious symmetries, Consider an ellipsoidtotally submerged andwiththeoriginat thecenter of theellipsoid, describedas:(2.141). i! 'Herea, bandc arethesemi-axes, seeFigure 2,5, Aprolate spheroidis obtainedbylettingb =c anda >b, Imlay,(1961) givesthefollowingexpressions 1'01 the2.4 HydrodynamicForcesandMomentsyzFigure2.5: Ellipsoid with semi-axesa, bandc,x41diagonaladdedmassderivatives (cross-coupling termswill bezeroduetobodysymmetryaboutthreeplanes):x" -aom2 - ao(2142)Kp- 01Nr - Mq =-5Yv- Zw=(30m2 - (30(2,143)(2.144)(2145)where themass of theprolate spheroid is:4m =-rrpab23Introducetheeccentricitye definedas:e=1-(b/a)2Hence, theconstantsaoand(30can becalculated as:(30 -(2147)(2,149)An alternative representation of these mass derivatives is presented by Lamb(1932) whodefinesLamb'sk-factorsas:ao2 - ao(2.150)42f302- f30Modelingof MarineVehicles(2.151)k' (2.152)(2.156)Hence, thedefinition of the added mass derivatives simplifiesto:Xv. --k1 m (2.153)Yli - Z,;, = -k2 m (2.154)Ni-Mq =-k'Iy(2.155)wherethemoment of inertia of the prolate spheroidis:4 2( 2 2Iy=Iz=-51rpab a +b)1 .A more general discussion onadded mass derivativesforbodies with varioussymmetries is found in Imlay(1961). Other useful referencesdiscussing methodsfor computationof theaddedmass derivatives areHumphreys andWatkinson(1978) and Triantafyllou andAmzallag (1984).2.4.2 Hydrodynamic DampingiAsmentioned in theprevioussectionhydrodynamicdamping forocean vehiclesis mainly caused by:D p(v) =radiation-induced potential damping dueto forcedbody oscillationsDs(v)=linear skin frictiondueto laminar boundarylayers and quadratic skinfriction duetoturbulent boundarylayers.Dw(v)=wave driftdamping.D M(V) =damping due tovortex shedding(Morison'sequation).Consequently, thetotal hydrodynamicdamping matrix can bewrittenasa sumof thesecomponents, that is:D(v) t;. Dp(v) + Ds(v) + Dw(v) + DM(V)where D(v)satisfies that following property:(2.157)Property2.6 (D)FaT a rigid-body movingthTOUghanideal fluidthehydmdynamicdamping matrixwillbereal, non-symmetricaland strictlypositive(seeAppendix A). Hence:D(v) > 0 'if v E1R62.4 Hydrodynamic ForcesandMoments43Proof: Thepropertyistrivial sincehydrodynamicdampingforces qreknowntobedissipative. Therefore, thequadraticform:vTD(v) v > 0 V v -# 0 '.oIn practical implementations it is difficult to determine higher order termsas wellastheoff-diagonal termsinthegeneralexpressionfor D (v). Thissuggeststhefollowing approximation of D(v):Surface ShipsForlowspeedslendershipswecandecouplethesurgemodeflOm. thesteeringmodes(swayand yawl. Hence, thelinearized damping forcesandmoments(ne-glecting heave, roll and pitch) can be written:Notice that1'; -# N ~ .[XuD(v) =- ~(2.158)Underwater VehiclesIn general, the damping of an underJater vehicle moving in 6 DOF at high speedwill behighlynonlinear andcoupled.. Nevertheless, one roughapproximationcould be to assume that the vehicle is performing a non-coupled motion, has threeplanes of symmetry and that terms higher than second order are negligible.. Thissuggestsadiagonalstructureof D(v) withonlylinearandquadraticdampingterms onthe diagonaLMoreover,D(v)=-diag{Xu, Yv, Zw, Kp, Mq, Ne }-diag{Xulul lul, Yvlvl lvi, Zwlwl Iwl, Kplpl Ip!, Mqlql Iq!, Nrlrl Irl } (2.159)Potential DampingWe recall from the beginning of Section 2.4 that forces on the body when the bodyis forced to oscillate with the wave excitation frequencyand there are no incidentwaves will result in addedmass, dampingand restoringforces andmoments.The radiation-induced damping term is usually referred toaspotential damping.However, thecontribution fromthe potential damping terms compared tootherdissipative terms like viscous damping terms are negligible for underwater vehiclesoperating at great depths. However, forsurfacevehiclesthepotentialdampingeffect maybesignificant. Forships linear theorysuggeststhat theradiation-induced forcesand moments can be writtenaccording to(seeEquation 2.112):44Modeling of MarineVehiclesTR =-A(w)1] - B(w) r,- Cry (2.160)where A = -MAis the addedinertiamatrix, B = - D p represents linearpotential damping, Crepresents the linearized restoring forcesand moments andw is the wavecircular frequency,The frequencydependenc;y for the2D damping coefficients in sway and heavefor a floating cylinder is illustrated in Figure 2.6. 3D linear damping coefficientsin sway and yaw for a slender ship with length Lcan thusbe estimated by usingthevalue for BgD) according to:1 lL/ 2(2D)- -Yv = -2 B22(y,z) dx-L/21 lL/ 2(?D)- -Nr =-2 x2B22(y,z)dx-L/22 ,(2,161)(2.162),1,8 \,Hi \,1,4 \' ' ~ " ..12 ,.... \ .. " ~,,,,,0..8060402.~ , . , . ,",.;, . " " ' . ~ , , . , .. ,.,.'---,.. ""'''1''. " , , - , . , . ~,.. " .. ,'" ~ ,. ,.------0:"----:0'::S---:--2R--:-1'::.S---2:-----::2S"'-9Figure 2.6: Two-dimensional linear dampinginheave andsway as afunctionofwavecircularfrequencyfor acircular cylinder (infinitewater depth), InthefigureA = 0,5 7rR2where Ris the cylinder radius..It shouldbe notedthatmostshipcontrol systemsarebasedontheassumptionthat A(w) andB(w) are frequency-independent (w=0) because the controlsystem is only designedtocounteractforlow-frequency motioncomponents.Skin FrictionLinear skinfriction due tolaminar boundarylayer theoryis important whenconsideringthelow-frequencymotionofthevehicle. Hence, this effect should2.4HydrodynamicForcesandMoments45be considered when designingthe control system. In addition t9 linear skinfrictiontherewill beahigh-frequencycontributionduetoturbulent boundarylayer theory. This is usually referred toasaquadratic o ~ nonlinear skinfriction.Wave Drift DampingWavedrift dampingcanbeinterpretedas addedresistancefor surface vesselsadvancing in waves. This type of damping is derived from 2nd-order wave theoryWavedrift dampingisthemost important dampingcontributiontosurgeforhigher sea states. This is due to the fact that the wave drift forces are proportionalto the square of the significant wave height. Wave drift damping in sway and yawissmall relativetoeddymakingdamping(vortexshedding). Aruleof thumbisthat 2nd-orderwavedrift forcesare lessthan1% of the1st-orderwaveforceswhenthesignificantwaveheight isequal to1 mand10%whenthesignificantwave height is equal to10 m.Damping Due toVortexSheddingD'Alambert'sparadox states thatnohydrodynamicforcesactonasolidmovingcompletely submerged with constant velocity in a non-viscous fluid. In a viscousfluid, frictional forces arepresent suchthat thesystemisnot conservativewithrespect toenergy. Theviscous dampingforce due tovortexsheddingcanbemodeled as:1f(U)= -2PGD(Rn)A IUI U(2.163)whereUis thevelocityof thevehicle, Aistheprojectedcross-sectional area,GD(Rn) is thedrag-coefficient basedon therepresentativeareaandP isthewa-ter density. This expression is recognizedasone of the terms inMorison'sequa-tion(seeFaltinsen 1990). The drag coefficientGD(Rn)dependson theReynoldsnumber (seeFigure2.7):Rn=UDv(2.164)where Dis the characteristic length of the body andvisthe kinematic viscositycoefficient (v =1.56.10-6for salt water at 5 C with salinity 3.5%), see AppendixF. Quadratic drag in 6 DOF isconvenientlyexpressedas:IvlT Dj VIvIT DzvIvlT D3vIvlT D4VIvlT D5 VIvlT D6V(2.165)46 Modeling of MarineVehiclesHereD i(i =L.6)is6 x 6 matrices depending onp, CDandA Notice thatCDand Awillbe differentfor the different matrix elements.0.8B0.60.4:': ;; ,,;.. ..: kiD = 9008.;s, ,. . ..., .;. :. : :..:... "....... . . . . . .....k l Q = j 1 9 ~ ~.. .. ., ...RnFigure 2.7: Dragcoefficient CDversus Reynolds number Rnfor aroughcircularcylinder in steady incident flow. Three different surface roughness curves k/ D wherekis the average height of the surface roughness andDis the cylinder diameter are shown(Faltinsen 1990).2.4.3 Restoring ForcesandMomentsIn the hydrodynamic terminology, the gravitational and buoyant forces are calledrestoring forces. Thegr'avitational forcefGwillact throughthecenterof grav-ityrG=[xG' YG, zG]Tof thevehicle. SiInilarly, thebuoyant forcefBwill actthwughthe center of buoyancy rB= [XB, YB, ZBJT. The restoring forceswill havecomponentsalongtherespectivebody axes.Underwater VehiclesLet mbethemassof thevehicleincludingwaterinfreefloatingspaces, V' thevolumeof fluiddisplacedbythevehicle, 9theaccelerationof gravity(positivedownwards) andpthefluiddensity. AccordingtotheSNAME(1950) notation,thesubmergedweight of thebodyisdefinedas: W=mg, whilethebuoyancyforceisdefinedas: B= pgV'. ByapplyingtheresultsfwmSection2.. 1.1, theweightandbuoyancy forcecan be transformedtothebody-fixed coordinate sys-tem with:(2.166)where J 1(TI2) is the Euler angle coordinate transformationmatrixdefined inSection 2.1.1. According to(2.118), the sign of the restoring forcesand momentsg(7J) must be changed since this term is included on the left-hand side of Newton's2nd law. Consequently, therestoring forceandmoment vectorin thebody-fixedcoordinate system is:2.4 HydrodynamicForcesandMoments47(2.167)Notice that the z-a.xis is taken to be positive downwards.. Expanding this expres-sion yields:(W - B) se(W - B) cesr/>(W - B)cecr/>(yaW - yBB) cecr/> +(zaW - zBB) se +(xaW- xBB) cesr/>(zaW- zBB) cesr/>(xaW - xBB) cecr/>(YaW - yBB) se(2168)Equation(2.168)istheEuleranglerepresentationof thehydrostaticforcesandmoments. Analternativerepresentationcanbefoundbyapplying quaternions.ThenE1(e) replaces J1(7J2) in(2.166), seeSection 212 Aneutrallybuoyantunderwater vehicle will satisfy:W=B (2..169)Let thedistancebetweenthecenter of gravityCGandthecenterofbuoyancyCBbe defined by thevector: IHence, (2.168)simplifies to:(2.170)SurfaceShipsooo-BGyWcecr/> + BGzWcesr/>BGzW se + BG"Wcecr/>-BG"Wcesr/> - BGyW se(2..171)Thegeneral expression (2.168) shouldonlybe usedfor completelysubmergedvehicles. For surface vessels, the restoring forces will depend on the vessel's meta-centricheight, thelocationof thecenter of gravityandthecenterof buoyancy.Metacentric stability and restoring forcesfor surface shipsare treated separatelyin Section 5.5.2.48 Modelingof MarineVehicles2.5 Equations of MotionIn this section we will'discuss different representations. and properties of themarine vehicleequationsof motion. Moreover, wewill showhowvariousbody-symmetries can be usedto simplify theequations of motion.2.5.1 Vector RepresentationsTheequationsof motioncanberepresentedinboththebody-fixedandearth-fixedreference frames. Wewill discussboth theserepresentations.Body-Fixed Vector RepresentationInSection2.3we havealready shownthat thenonlinear equationsof motion inthe body-fixed framecan be written as:whereIM 1/ + C(v) v +g(TJ)= rl!i7=J(TJ)v!(2.172)(2.173)M= MRB + l'vIA(2.. 174)\D(v)=Dp(v) + Ds'(v) + Dw(v) + DM(v)(2.175)Earth-fixedVectorRepresentationTheearth-fixedrepresentationisobtainedbyapplyingthefollowingkinematictransformations(assuming that J (TJ) is non-singular):i7 = J(TJ) v - 0Vv E lR6, TJ E lR6if M=M'T>0and M= O. Theproofs areleft as anexercise. ItshouldbenotedthatTJ) will not beskew-symmetrical althoughO(v) isskew-symmetrical.SimplicityConsiderationsof the Inertia MatrixThe general expression for the inertia matrix Mcan be considerably simplified byexploiting different body sy=etries. It is straightforward to verify the followingcases(notice that mij =mji):L(i) xy-plane of symmetry(bottqm/top symmetry)[ m"mI::! 0 0 0m" ]m21 m22 0 0 0 m,.M- 00m"m:Hm"0, "- 00m43 mol4 m,t5 00 0mOJ mMm"0mal m6'0 0 0 moa'.

2.5Equations of Motion(ii) xz-planeof symmetry (port/starboard symmetry)_mu 0 mlJ 0 ml5+]0ffi'2::! 0 m2i0"!vI =m'l0m"0m"0m"0 mH 0m'6m"0m"0m"00 me:! 0m"0 m66(iii) yz-plane of sy=etry(fore/aft symmetry)_51[mU 0 0 0o m22 m23 m:a-t!vI= 0 m32 m:J3 ma4o m4:! rn.i3 muffi1'il 0 0 0m6l 0 0 0m15 m16]o 0o 0o 0m55 mG6IDes mes(iv) xz-andyz-planes of symmetry(port/starboardand fore/aft sy=etries)_[ m;'0 0 0 ml5.1]m22 0 m24 0!vI = 00m"0 00 m42 0m"0m'l0 0 0m"0 0 0 0 0(v)Moregenerally, theresultinginertiamatrixfor abodywith ij- andj k-planes of sy=etryis formedby theintersection !vIij njk = !vIij n IvJik\xz-, yz- and xy-planes of symmetry (port/starboard, fore/aft and bot-tom/top symmetries).SimplicityConsiderationsof theDamping MatrixFor the linear time-invariant system:!vIv+Dv=r(2_181)the sy=etrypropertiesof thedamping matrixDwill be equaltothoseof theinertia matrix IvI.Example2.1 (Horizontal Motion of aDynamically Positioned Ship)The horizontal motionof adynamicallypositionedship(U= 0) is usuallyde-scribedbythemotioncomponents insurge, swayandyaw_ Therefore, wechoosev = tu, 11, rjTand1] = [x, y, 'l/JjT_ Thisimpliesthat thedynamics associatedwiththemotion in heave, roll and pitchare neglected, that is w =p =q -:- 0_ Further-more, weassumethat theshiphashomogeneousmassdistributionandxz-planesymmetry_ Hence,(2182)Let thecoordinateoriginbeset inthecenter lineof theshipsuchthat: YG= 0.Under thepreviouslystatedassumptions, matrices(2.91) and(2.102) associatedwiththerigid-bodydynamicsreduceto: '.52 Modeling of MarineVehiclesommxaoo-mu-m(xar +v) ]muo(2183)Thismotivatesthefollowingreductionof (2.120) and(2.127).'[-X. 0 0]l'vIA= 0U _Y, -Yio -Yf -Ni-o Y,v + Yi' ]o -Xuu"'Yuu 0(2.184)Hence, M= M Tand C(v) = -CT(v), thatis:[m-X.M= 0oo 0]m-Yit mxc -Yfmxc -f J; - Nf(2.. 185)(2.186)-(m - Y,)v- (mxa- Yi)r ](m - Xu)uo[0C(v) = 0(m - Y,)v +(mxa- Yi)'oo-(m - Xu)u\For' simplicity, weassumelineardamping' and thatsurgeisdecoupled fromswayandyaw. Thisimpliesthat:D= [ - ~ O U - ~ " - ~ , ] (2.187)-Nu -NrAmodel that iswellsuited forshippositioningisthenobtainedby writing:Mv+C(v)v+Dv=Bu (2.188)whereB isthecontrol matrixdescribingthethrusterconfigurationand u is thecontrol vector. Duringstationkeeping, u, v and r areall small whichsuggeststhat a furthersimplificationcouldbetoneglecttheterm C(v)v.o2.5.3 TheLagrangian Versus the NewtonianApproachOneadvantagewiththeLagrangian approach is thatweonly havetodeal withthetwoscalar energyfunctionsT andV. TheNewtonianapproachisvector-oriented sinceeverything isderivedfromNewton'ssecond law. Thisoften leadstoa morecumbersomederivationof theequationsof motion. We will illustratethis by applying the Lagrange equations of motion to derive the earth-fixed vectorrepresentation.2.5Equations of MotionLagrangianDerivationof theEarth-FixedVectorRepresentationRecall that:!!.- (8L) _oL 8Pd_ .dt oil 017 +8i1 - TryHerewe have includedanadditional term:53(2.189)(2.190)to describe the dissipative forces. Pd can be interpreted as a power function. TheLagrangian for thevehicle-ambient water system isgivenby:(2..191)where TRBis the rigid-body kinetic energy, TAisthefluidkineticenergyand Visthepotential energy defined implicit by:8V07] =9ry(17)Hence, the total kinetic energycan beexpressedas:\T =TRB +TA =~ i1TJ-T(MRB + MA)r1iI =~ i1TMry(17) iIFurthermore,we can compute:The next step involvescomputing:8L= 8T_8V= ~ i1T8Mry(17) i1- 9 (17)817 817 817 2 817 ryUsing these results together with:M ( ) _ 'T8Mry(17)ry17-17817implies that (2.189)can be written:(2.192)(2.193)(2.194)(2.195)(2.196)(20197)(20198)54 Modeling of MarineVehiclesFromthis expression, the definition of the Coriolis and centripetal matrixisrecognizedas:!l 1 .2 whichhasits analogous definition inthe skew-symmetricproperty:xT-x =0 'if xHence, wehaveshownthat:,(2.199)(2200)ij + iJ + iJ += (2201)by applyingthe Lagmnge equations with 1] = [x, y, z, rP, e, 1/'Vas generalizedcoordinates. A similar derivationcanbedone inthebody-fi,'CedreferenceframewithLJ =[u,v,w,p,q,rjTbyapplying theQuasi-Lagrangian approachdescribedinSection2.2.3. Amore detaileddiscussiononLagrangiandynamics anditsapplications tomarine vehicles is foundin Sagatun(1992).2.6 ConclusionsIn this chapter, we have used a general framework in terms of the Newtonian andLagrangian formalismtoderivethenonlineardynamicequationsof motionin6DOF. Thekinematicequationsof moti6naremainlydiscussedintermsof thequatemion and Euler angle representation. Emphasis is placed on expressing themultivariable nonlinear equations of motion such that well known properties frommechanical systemtheorycanbeextendedtothemultivariablecase.. Themainmotivationfor this is that certainnonlinear systemproperties canbe usedtosimplify thecontrol systemsdesign. Inother words, a systematicrepresentationof a complex model is necessary for a good exploitation of the physics anda prioriinformationof thesystem. Itshouldbenotedthat theresulting mathematicalmodel doesnot includethecontributionof theenvironmental disturbanceswind, wavesand currents. However, environmental modeling will be discussed inthenext chapteLForthe interested reader the developmentof thekinematic equationsof mo-tionarefoundinKane, LikinsandLevinson (1983) andHughes (1986). Boththesereferences usespacecraft systems for illustration. Analtemativederiva-tionof the Euleranglerepresentation inthecontextof shipsteering is given byAbkowitz (1964) Ananalogy torobot manipulatorsis givenbyCraig(1989}-AdetaileddiscussiononkinematicsisfoundinGoldstein(1980) whileaman:recentlydiscussion of quatemionsis foundinChou(1992).The nonlinear model structure presentedat the end of this chapter is mainl,rintended for control systems design in combination with system identification a.ml.parameterestimation. Hence, theextensive literatureonbasichydrodynamicsshould be consulted to obtain numerical values forthe hydrodynamic derivatives2.7Exercises55which are necessary for accurate prediction andcomputer simulations. SomestandardreferencesinhydrodynamicsareFaltinsen(1990), Newman(1977) andSarpkaya(1981). AdetaileddiscussiononLagrangian,!-ndNewtoniandynam-ics canbe found in Goldstein (1980), Hughes (1986), Kane et aL (1983) andMeirovitch(1990), forinstance.2.7 Exercises2.1 A marinevehicleis moving in the x-direction with aspeed u(t) =2 (m/s) and inthey-directionwitha speed vet)=asin(t) (m/s). Theheadingangleis'/J(t) (rad) ..Assumethat the heave, roll andpitchmodes canbeneglected. Calculateboththebody-fixed and earth-fixedaccelerationin thex-andy-directions.2.2 Calculatetheinertiamoment withrespect to checenter ofgravityfor aspherewith radiusr andmass densityp. Showthatthe sphere'sproducts of inertia are zero.2.3 Usetheparallel axestheoremtoproveExpressions(2.109) and(2.110).2.4 Givena rigid-bodywitha coordinate frame XcYcZc locatedin the center ofgravity. The body'sinertia tensoris:(a)Rotate the given coordinate system XcYcZcsuch thatthe axesof thenew coor-dinate system XcY,jZccoincides with theprincipalaxesof inertia.(b)Instead of rotating the coordinate system XcYcZcfind the distance between thecoordinatesystemXcYcZcandanewcoordinatesystemXoYoZolocatedat apoint 0such thattheinertia tensor 10becomesdiagonal.2.5 Find acontinuous linearapproximation tothe quadraticdamping force:J(t)= -Xululu(t)lu(t)1whereXulul < 0 and-Uo:::; u(t) :::;uo.2.6 Derivetheequationsof motionforanunderwater vehiclein surge, sway, lollandyaw by applying the bodycfixed vector representation.. Assume linear damping and thatall termsincludingCoriolisandcentripetalforcescan beneglected. Writetheexpres-sions for M, D,gand Jaccording to the SNAME notation for hydrodynamic deriva-tives. The controlforceand momentvectorare assumedtobeT = [71' TZ, 73, T4jT2.7 Computetheadded inertia matrix foraprolatespheroid withmassmandsemi-axesa =2randb = c =r.56Modeling of MarineVehicles2.8 Given the Euler angles 0 'r/ v E]R6, TJ E]R62.11 Compute Yu, Nr, YuandN, forasurfaceship with maindimensionsD=8(m)and L = 100(m)ata wave circular frequenj;y w = LO(rad/s)by applying strip theory.2.12 Derive(2.98) and(2.99)from(2.72) and(2.87) byusing the formulas:ax(bx c) - S(a)S(b)c(axb) x c - S(S(a)b)cwhereS(a)S(b)=I S(S(a)b). Anotheruseful formulaistheJacobi identity:ax(b x c) +b x(c x a) + c x(a xb)=0which can be expressed in terms of the skew-symmetric operator S(-)E 88(3) accordingto:S(a)S(b)c +S(b)S(c)a +S(c)S(a)b =0Fina]]y show that (2.100) and(2.101) can bederivedfrom(2.98) and(2.99).2.13 Derive the nonlinear body-fixed vector representation for a marine vehicle movingin6 DOFby applying theQuasi-Lagrangianapproach. Allterms should beexpressedbymatricesand vectors.--------_..---- -- - -----Chapter3Environmental DisturbancesIn the previous chapter a general model structure for marine vehicles was derived.In this chapter we will look further into details on the modeling aspects in terms ofenvironmental disturbance models. Moreover, the following type of environmentaldisturbances will be considered:e Waves(wind generated) Wind Ocean currentsIngeneral these disturbances Will] be bothadditive andmultiplicative tothedynamicequationsof motion. However, in this chapterwewill assumethattheprincipleof superposition canbeapplied. Formostmarinecontrol applicationsthis isa good approximation.3.1 The Principle of SuperpositionThe previous chapterhas shown that the nonlinear dynamic equations of motioncould be written:Intheanalysisbelow it isconvenient towritethedampingmatrixasasumoftheradiation-inducedpotentialdamping matrix Dp(v) andaviscousdampingmatrix Dy(v) =Ds(v) + Dw(v) + DM(v)containingtheremaining dampingterms" Hencewecan write:D(v) =Dp(v) + Dy(v) (3.2)Basedonthismodel wewill applytheprincipleof superpositiontoderivethelinear and llOnlinear equations of motion in terms of environmental disturbances.58LinearEquationsof MotionEnvironmental DisturbancesLinearization of theCoriolis and centripetal forcesC RB(V)VandC A(V)Vaboutzeroangularvelocity(p = q = T = 0) impliesthat theCoriolisandcentripetalterms can be removed from the above expressions, that is C RB(V)V = C A(V)V =0. If wealsolinearize D(v)vabout zeroangularvelocity, andu=uo, v =voandw=wo, we canwrite(3.1)as:[MRB +MA]v+ [Np +N v]V+G1] =TE +TwhereNp, Nvand Garethreeconstant matrices givenby:(33)LinearEquationsof MotionIncluding theEnvironmental DisturbancesFurthermore, theprinciple of superposition suggests thattheenvironmental dis-turbancescan be added to the right-hand sideof (3.3)to yield:lYIRB v + Nvv +lYI Av + Np v + G1] = T wave + Twind + Tcurrent +T (3.5)~ --..". '.... ... Iradiation-induced forces environmental forcesIIn the previous chapter the mdiation-inducedforces were referred to as sub-problem one, Section 2.4. In this chaptersub-problem two is considered. Moreover,wewant tofindtheforcesonthebodywhenthebodyisrestrainedfromoscil-lating, andthereareincidentregularwaves. Theseforces arerecognizedastheFmude-KTiloff anddiffmctionforces. Generally, theforces of sub-problemtwoare computed by integrating thepressure induced by the undisturbed wavesandthe pressure created by the vehicle when the wavesare reflected from the vehicleoverthewet bodysurface(Faltinsen1990). Sincethisprocedureismathemat-icallyinvolvedandnot towell suitedtocontrolsystemsdesign, wewillrestrictourtreatment tothefollowingapproximatesolutionfor theFroude-Kriloff anddiffraction forces.Np = 8[Dp(v)v]8vv=vo8[Dv(v)v]N v = 8vG=8g(1])81](3.4),:1I1Approximate Solution fortheFroude-Kriloff andDiffractionForcesIf the body is totally submerged, has asmall volume andthe whole body surfaceis wetted, a special solution to sub-problem two exists. By small volume we meanthat a characteristic cross-sectional dimension of the body is small relative to thewavelengthA. Foravertical cylinder small volumemeans that A >5D, whereDisthecylinderdiameter. ROVs areusuallywithinthis limit. Let thefluidvelocityvectorbedefinedbyVc = tuc, vc, Wc, 0, 0, ojTwherethelast threefluidmotion components are zero(assuming irrotational fluid) we can write (Faltinsen1990):3.1ThePrinciple of Superposition59Tcurrent = MFKVC + MA lic+ Np 1/c+ .Nv1/c(3.6)'---..----'.... ". .---.........--.Froude-Kriloff diffraction forces viscousforceswhere MFK maybeinterpretedas the Froude-Kriloff inertia matrix, that istheinertiamatrixof thedisplacedfluid. Moreover, let 'Vbethevolumeof thedisplacedfluidandp thefluiddensity, hencethe massof thedisplaced fluidcanbewritten:m=p'VThemomentsandproductsof the inertia of thedisplaced fluidare:(3.7)Ix=Jv(y2 + z2)pd'V l xy=Jvxypd'Vl y =Jv (x2+ z2)pd'V Ix:=Ivxzpd'V (3.8)I.=J"(x2+ y2)pd'V ly =J" yzpd'VWe can nowestablishthe concept of displacedfluidinertiafor a completelysubmerged body by defining the FK-inertia matrix MFK=> 0 similar toMRB(see Section2.3.1). Moreover,[ .0 0 0 mZB-rn" ] ]0 m 0 -ffiZB 0 mXEMFJ(=[ mI3x30 0 ffi mYB-ffiXB 0mS(rB) 10-0 -mZBmYB I. -I:r:v -7=:ffizB0 -ffiXB -7:r:", Iv -I!J;J:.-mYB ffiXB 0 -I=, -7'1::'I,(3,9)where rB= [XB, YB, zB]Tisthe center of buoyancy.LinearEquations of RelativeMotionIf weassumethat MFK= MRB, that isthevehicleisneutrallybuoyant andthemassis homogeneouslydistributed, thelinear equations of motioncanbecombined togive:[MRB + MAl V, + [Np + N v] 1/, +G1] = T wave + Twind + T... .. . "--'-..,...-----'M N(3.10)where1/, =1/ - 1/c can be interpreted as the relative velocity vector In this case1/c should contain the contribution fromthecurrents.NonlinearEquations of RelativeMotionForunderwater vehicles, anextensiontothenonlinear casecouldbe towrite(Fossen 1991):JIII V, +C(1/,.)1/, +D(v,)1/, +g(1]) =Twave +Twind + T(3.11)60Environmental DisturbancesOften this approximation is also used for ships due to its intuitive and simpleway of treating slowly-varying CUITents in terms of relative velocity, In the nextsections we will discuss mathematical models for vc, 'T and 'Twind.3.2 Wind-Generated WavesThe process of wave generation due to wind starts with small wavelets appearingon the water surface. This increases the drag force which in turn allows shortwaves to grow. These short waves continue to grow until they finally break andtheir energy is dissipated. It is observed that a developing sea or storm starts withhigh frequencies creating a spectrum with peak at a relative high frequency. Astorm which has been blowing for a long time is said to create a fully developed sea.After the wind has stopped blowing, low frequency decaying sea or swell is beingformed. These long waves form a wave spectrum with a low peak frequencyl. Ifthe swell from one storm interacts with the waves from another storm, a wavespectrum with two peak frequencies may be observed. For simplicity we will onlyconsider wave spectra with one peak frequency, see Figure 3L Wind-generatedwaves are usually represented as a sum of a large number of wave components.The wave amplitude Ai of wave component i is related to the wave spectraldensity furlction S(Wi) as (Newman 1977):,Af = '2S(Wi) /::,w(3,12)where Wi is the wave frequency of wave component i and /::,w is a constant differ-ence between successive frequencies,5(0)), IFigure 3.1: Figure showing wave spectrum with one peak Wi is chosen as a randomfrequency in the frequency interval Aw.,Let the wave numbeT of one single wave component be denoted by ki. Hence,lThe peak frequency of the wave spectrum is often referred to as the modalk, = 271", )",(3.13)3.2Wind-GeneratedWaves 61whereAi is the wave lengtp,see Figure 3.2. The waveelevation ((x, t)of a long-crestedinegularseapropagatingalongthepositivex-a.xis canbewrittenas asum of wavecomponents(Newman 1977): '.1; (x,t)1; (X,t)HHTt 11;, .xFigure3.2: Characteristicsof a wavetraveling withspeedc =AfT = w/k. Inthefigure A=wave length, H=wave height, A =waveamplitude, T=wave period and( = wave elevation.N((x, t) - :LA; cos (Wit - kix + 0shouldbemodifiedtoincorporatethefrequency of encounter.For instance, wecanrewrite(3.47) as:h( ) Kw s ( ). s =S2 + 2 ( te', S +w; 3 64However, it shouldbenotedthat the wave frequency of adynamicpositionedship canbeperfectly describedbyuJe =te'osinceUiscloseto or equal to zeroBeam seaQuartering seap= 30.Following seaBow scnHead seaFigure3.7: Definition of ship's heading (encounter) angle(Reid et at 1984).3.2.4 Wave-InducedForces andMomentsInorder tosimulatethemotionofoceanvehicles,in the presenceofirregularwaveswewill considertheeffect of Ist-and2nd-orderwavedisturbances.SuperpositioninTermsof Ist-and2nd-OrderWaveDisturbancesThe responsesof anoceanvehicle ina seawayareusually computedby applyingtheprincipleofsuperpQsiiion.. Assumethat the1st-order wavedisturbancescan74 Environmental DisturbancesIbedescribedbythedampedoscillator (3.. 54)-(357) .. Alternatively, YH canbecomputedbyusingthespectral densit.yfunctionS(w). Furthermore, weassumet.hat 2nd-order wavedrift forcesin theX-, y-andz-directions can be modelled byt.hreeslowly-varying parameters: d =[dJ, d2, d3jT' Hence,1st-orderwavedisturbances XH - A HXH + EH wH(oscillatoricmotion)YH- CHXH(3.65)2nd-orderwavedrift d- WdHereWdisavect.orof zeromeanGaussianwhitenoiseprocesses.. Moreover, theprinciple of superposition suggest.s that. thevehicledynamicsandthe2nd-orderwavedisturbancescanbecombinedt.oyield:Mv + C(v)v + D(v)v +9(TI) = d + Tij =J(TJ) v(3.. 66)(3.67)The measurement equation is modified to include the 1st-order wave inducedmotion, that is:Y=YL+YH(3.68)IIwherethelow-frequencypositionandattitudecomponentsusuallyaregivenbyY L = TJ Noticethat we have included1the wave drift forces inthe dynamicequationof motion(processnoise) whiletheoscillatoricmotionisaddedtothemodel output (coloredmeasurement noise). Inmanypractical operations likeship steering andpositioning this simple model issufficientAmoreintuitiveandphysical approachwouldbe tomodel 1st-order waveforces andmomentsasprocessnoiseas well Thiscanbedonebyapplyingthefollowing modeldescription1st-Order WaveForcesandMoment onaBlock-ShapedShipConsidertheexpression(i(X, t) in(3.14) for thewaveelevation ThewaveslopeSi forwavecomponent i isdefinedas:,JJI"ii1,Ij( )d(i(x, t). 2)Si X, t = dx = Ai kism(wit - kix + rpi) + O(Ai(3.. 69)Thewaveelevation andwaveslopecan beexpressedintermsof We foramovingship. For simplicity, weassumethat x=0andthat higherorder termscanbeneglected. Hence,(i(t)=(i(O, t) := Ai COS(Weit +Wc> 0, 0, Or is a vectorof irrotational body-fixed current veloc-ities----86Method1:Environmental DisturbancesSection 2.L I has alreadyshown that the earth-fixed linear velocity could betransformed to body-fixedlinear velocities by applying the principal rotationmatrices. Lettheear th-fixedcurrentvelocity vectorbe denotedby Hence, wecan compute thebody-fixed componentsas:(3.107)(3.108)where[c1{;cll -s1{;cq, +c1psllsq, s1{;sq, + c1{;cq,sll ]J 1( r/J, e, 1{;) = s1{;clI C1PCq, +Sq,SIlS1P -C1pSq, +SIIS1PCq,-sll clIs,p cllcq,Let us assumethat body-fixedCUIrent velocityis constant or at least slowly-varying such that the following holds:Hence, the nonlinear relativeequations of motion(3.11) taketheform:IMv +C(vT ) V r+D(v,)VT +9('1])=T I\iJ = J(1]) vi(3109)(3.110)(3.111)Noticethat thismodel representationisbasedonthestatevariables (v, vc, 1])withv,. =v- VcMethod2:An alternative representation of the nonlinear equations of motion is obtained bydefining(vr ,1]) asthe statevariables. Moreover, from(3.11) we havethat:IMvT +C(v,) VT +D(vr) v, +9(1])= T IFurthermore, we canwrite:i] = J(1])v = J(1])(vr+vc)Werecallthat:where =Hence,(3.112)(3.113)(3.114)Using the resultsfromSection2.1.1, wecan write:87(3.. 119)(3.. 120)(3.121)(3.116)(3.117)(3.. 115)EVc cosCl< cos f3 Uc-EVc sin f3 Vc -wE-VcsinCl< cos f3c[ ]= Cy,a ] (3.. 118)whereCi,j isthetransformationmatrixdefinedin(2.8) andVc is theaveragecurrent velocityintheearth-fixedreferenceframe. Expandingthis expressionyields:Figure3.12: Orientationofaveragecurrent velocitywithearth-fixedX, Y, andZaxes,3.4OceanCurrents1 foTVc = - Vz(z)dzT.owhere Tis the hull draft. The earth-fixed fluid velocity components v!;, canberelatedtoVc bydefiningtwoangles Cl< (angleofattack) andf3 (sideslipangle)describing theorientationofVcaboutthey-andz-axis, respectively(seeFigure3.12).Next, thekinematicequationscan bemodified toincludethenew statevariable1/, anda vectordescribing theearth-fixedcurrentvelocity, thatis:Three-Dimensional CurrentModel (SubmergedBody)If the vertical velocity profile Vz(z) is lmown,the average current velocityVcoverthe draftof the vehiclecanbecomputedas:88 Environmental DisturbancesTwo-DimensionalCurrentModel (Sur'faceVessel)For the2-Dcase, theearth-fixedcunent componentscanbedescribedbytwoparameters only, that is average current speed Vc and directionofcunent 13.Consequently, the above3-D expressionsreduceto:- Vc cos13VcsinfJ(3.122)(3123)Since we ale considering the horizontal motion of the vehicle, we can assume thatbothif;and earezerowhichimplies that (uc, vc) canbecomputedflom(3.107)as:[ ~ : ] =[ - ~ ~ ~ ~ ~ ~ ~ ~ ] [ ~ ~ ]Substituting theexpressionsfor u;; and v;;into(3.124)finallyyields3,UcVc cos(fJ - 1ft)Vc - Vcsin(fJ - 1ft)(3.124)(3.125)(3.126)x' - - - - - - - - - - ~ yFigure 3.13: Definition of averagevelocityVc anddirectionf3 oftheCUlTent for asurface vesseL'Herewehaveusedthetrigonometric formulas: (1)costa - b) =cosacosb+ sinasinb and(2) sin(a - b) =sinacosb - cosasin b.3.4OceanCurrentsGenerationof OceanCurrents89For computer simulations theaverage CUIIentvelocitycan be generatedby usinga1st-order Gauss-MarkovProcess For instanceVe(t) canbedescribedbythefollowingdifferential equation:V;,(t) + Itov;,(t) = wet) (3.127)(3..128)where wet) is a zero mean Gaussian white noise sequence and Ito ~ 0 is a constant.Inmanycasesitissufficient tochooseIto = 0whichsimplycorresponds toarandomwalk, that is timeintegrationof white noise. For details onGaussianprocesses seeGelb, Kasper, Jr., Nash, Jr,Price andSutherland, JL(1988).This processmust be limited such that Vmin:s; Ve(t) :s; Vma: Vma.,) aT (Ve(k +1) IIII I1 1Q(Nm) - - -- - - --: IIIIIIUa(voltage):ij,

,.

,!,111IIFigure4.4: Propeller transfer functionsDue to physical limitations of the DC motor, hard nonlinearities like actuatorsaturation, Coulomb friction,dead-zones and hysteresis should also be included inthe complete model. Neglecting these effects, implies that we can apply Laplace'stransformation to(4.13) and(4.14). Moreover,n(s)= h".(s) ua(s) - hQ(s) Q(s)wheresistheLaplace variable and:(4.15)KrK2(1 +T3s)h".(s)= (1 +Trs)(l +T2s); hQ(s) = (l +Trs)(l +T2s) (4.16)Here Ki(i = 1,2) aretwogainconstants andTi(i = 1,2,3) are three timeconstantsdepending onthe parameters in(4.13) and(4.14)98 Stability andControl of UnderwaterVehiclesIII(4,17)whichcan beminimized subject to:Optimal Distribution of PropulsionandControlForcesForunderwater vehicleswhere thecontrol matrixB isnon-square andP2: n,that is there are equal or more control inputs than controllable DOF, it is possibletofindan "optimal" distributionof control energy, for eachDOF(FossenandSagatun1991a), Consider thequadraticenergycost function:J=~ u T W u2r - Bu =0 (418)Here W is a positivedefinite matrix, usuallydiagonal, weighting the controlenergy, For underwater vehicleswhichhavebothcontrol surfacesandthrusters,the elements in Wshould be selected such that using the control surfaces is muchmoreinexpensivethanusingthethrusters, that isprovidingameansof savingbatteryenergy" DefinetheLagrangian:IL(u, A)= ~ U T W U + AT(r - Bu) (419)whereA denotesthe Lagrange multipliers Hence,differentiating theLagrangianLwithrespect touyields:8L T-=Wu-BA=O8uFromthisexpressionwe obtain:(4,20)ii\\I(4,21)By usingthe fact that:u=Bt" r (4,,25)In the case when all inputs are equality weighted, that is W=I, (4,24) simplifiesto:r =Bu = BW-1BTA (4,22)andassuming that BW-1B Tisnon-singular, wefindthefollowing optimalso-lution fortheLagrangemultiplicators:A =(BW-1BT)-lrSubstituting thisresult into(4,21) yieldsthegenemlized inverse:IBt" =W-1BT(BW-1BT)-l Iwhich suggests that ucan be computedas:(4,23)(4,24),;.",',. :, ~~ ,,H,:~ ,4.1ROVEquationsof Motion99(426)This simplified resultis known as theMoore-Penrosepseudoinverse" Notice thatforthesquare case(p = n), Btis simply equalto B-14.1.2 Nonlinear ROV Equationsof MotionThe nonlinear ROY equations of motion can be represented both in the hody-fixedand the earth-fixed reference frames. This has already been shown in Section 25"Thebody-fixedandearth-fixedvector representationsareasfollows:Body-FixedVectorRepresentationIM v+ C(v) v +D(v) v +g(ry) = rlEarth-Fixed Vector Representation(4.27)(4" 28)Iij + 1))r, + 1))r, += rT(1)) r I (4,"29)The state vectors are v = tu, v, w, p, q, r]T and 1) = [x, y, z, if, 0, 1p]T The differentmatricesandtheir propertiesare discussedmore closely in Section 2 5"4.1.3 Linear ROV Equations of MotionThe linear equations of motion are obtained by linearization of the general expres-sions (4.27) and (4.28) about a time-varying reference trajectory or an equilibriumpoint, for instance:vo(t) - [uo(t), vo(t), wo(t),Po(t), qo(t), To(tW (4,.30)1)o(t) - [xo(t), yo(t), zo(t), ifo(t), Oo(t), 1/Jo(tW (4",31)6 DOF PerturbedEquationsof MotionLet the perturbations fromthe reference trajectory lIo(t) and ryo(t) be describedbythedifferentials:.6.lI(t) =vet) - vo(t); .6.ry(t) =1)(t) -1)o(t); M(t)=r(t) - TO(t) (4.32)Introducing the following vector notation:f Av) =C(v) v;(4"33)100Stability andControlof UnderwaterVehiclesimplies that(4,27)canbelinearized according to:Mb.v + 8tc(v) I b.v +8td(V) I b.v +8g(TJ) I b.TJ =b.T (4,34)8v v 8v v 8TJ TJo 0 0Perturbating (4.28)yields:ryo + b.ry =J(TJo +b.TJ)[vo +b.v) (4.. 35)Substitutingryo=J (TJo) Vointothisexpressionimpliesthat:b.ry =J(TJo +b.TJ) b.v + [J(TJo +b.7/) - J(TJo)]Vo (4.. 36)Linear theory implies that 2nd-order terms (b.1/i b.Vj "'" 0) can be neglected,Hence,Ib.ry =J(TJo) b.v +J*(vo,TJo) b.TJ I (4.37)Herewehaverearrangedthelastterm in(4.36) according to:[J(TJo +b.TJ) - J(TJo)]Vo J*(vo,TJo) b.TJ (4.38)Thefollowingtwo special casesof (4.. 37)are particularlyuseful:(1) Vo=0 -->(2) Vo =TJo =0 -->b.ry = J(TJo) b.vb.ry = b.vLinear Time-Varying ROV Equationsof MotionDefiningXl = b.v andX2=b.TJ, yieldsthefollowing lineartime-varying model:whereM Xl +C(t) Xl + D(t)Xl +G(t)X2 = TX2= J(t)Xl + J*(t)X2(4,39)(440)G(t) = 8g(TJ) I J(t)=J(TJo(t))8TJ TJo(t)r(t) =J*(vo(t), TJo(t)) (441)C(t)= 8tc(v)18v Vo(t)D(t)= 8td(V) I8v Vo(t)DefiningX= [xi, x[]Tand u = T, weobtainthefollowing state-spacemodel:-M-IG(t)] [ Xl] [ M-I]J*(t) X2 + 0 u(442).I-'"4.1ROVEquationsof Motionwhichcan be writteninabbreviated formas::i; = A(t) x + B(t)uLinear Time-InvariantROVEquationsof Motion101(4.43)In many ROY applications it is reasonable to assume thatthe ROY is moving inthe longitudinal plane with non-zero velocity componentsUo andWoin the x-andz-directions, respectively. Furthermore, let us assume that the steady-state linearand angular velocity components: Vo =Po =qo =TO =0 and that the equilibriumpointisdefinedbythezeroroll andpitchangles, that is: ,po= eo= O. Hence,thetime-varying matrices in(4.42)simplifyto thefollowing constantmatrices:[m-X.-xvM- -Xw- -XpmZa- Xq-mYG -Xf.-xvm-YiJ-Yw-mza-Yp-Yojm::z::c -Yf-xw-Ywm-ZwmYG- Zp-mXa - Zq-Zf-Xp-m=c - YpmYG- Zp1= - K.-1;:;v- 1!'o -sin>!,o 0]J1 = sinwo cos1/Jo 0o 0 1thelineartime-invariantmodel canbewritten(4.46)(4.47)102 Stability andControl of UnderwaterVehicles(4.49)whereAandBareconstant matrices. Noticethat Cwillbezeroif werequirethat Uo =Wo = 0 inadditiontoVo= o.4.2 Stability of UnderwaterVehiclesStabilityof anunderwater vehiclecanbedefinedastheabilityof returningtoanequilibrium state of motion after a disturbance without anycorrective action,such asuse of thruster power or control surfaces. Hence, maneuverability canbedefinedasthecapabilityof thevehicletocarryoutspecificmaneuvers. Exces-sivestability implies that thecontrol effort willbeexcessivewhileamarginallystablevehicle iseasytocontrol. Thus, acompromise betweenstabilityandma-neuverability must be made. Furthermore, it makes senseto distinguish betweencontrols-fixed andcontrols-freestability. Theessential difference betweenthesetermsisthat:o Controls-fixed stability implies investigating the vehicle's stability whenthecontrol surfacesare fixedandwhenthethrusthorn allthethrustersisconstant.o Controls-free stability referstothecasewhen both thecontrol surfacesand the thruster power are allowed to vary. This implies that the dynamicsof thecontrol system must also be considered inthe stability analysis.Thesetermswillbe describedmore closely in the nextsections.4.2.1 Open-LoopStabilityOpen-loop (controls-fixed) stability analysis of marine vehicles concerns the prob-lem of finding static stability criteria based on the hydrodynamic derivatives Forlinear modelsthisisquitesimplethankstothewell knowntechniquesof RouthandHurwitz. Thissectionshowsthat analternativeapproachbasedonLya-punov'sdirect method can be applied in thenonlinear case. Formarine vehiclesthe Lyapunov function Vcan be chosen to represent the system's total mechanicalenergy. ConsidertheLyapunovfunctioncandidateV(1],il)= ~ ilTMry(1])il + f g ~ ( z ) dz (4.48)whereMryandgry aredefinedinChapter 2. HereVcanbeinterpretedasthesum of the kineticand potential energy of the vehicle. Hence, zeroenergycorre-spondstotheequilibrium point 1] =0andil =O. Instabilitycorrespondstoagrowthinmechanical energywhileasymptotic stability ensurestheconvergenceof mechanical energytozero. Differentiating Vwithrespect totime(assumingMry= M ~ > 0)yields:11 =ilT[Mry(1])ij + g,,(1])J +~ ilTMry il:.t;,4.2Stability of UnderwaterVehiclesHencetheexpression for Vcan be rewrittenas:103Applying the skew-symmetricproperty: iJT- iJ =0ViJ, yields11 =iJT +rJ)iJ +g,/(1J)] (451)In controls-fixed stability analyses, the dynamics of the control inputs is neglectedHence, we simply consider the system:M,/(1J)ij + 1J)iJ + 1J)iJ += 0Applying thisequationtotheexpressionfor 11, finallyyields:(4.52)Theorem4.1 (Controls-FixedStability)Accordingto Lyapunovstab,i[itytheory, AppendixCl, sufficient conditionsforcontrols-fixed stabilityare:(1) V> 0 forall iJ, 1JE JRnwhereasiJ #0and1J # 0.. Hence:if andonly if theinertiamatrix:M>O(4.54)(4.55)Noticethat J-l(1J) is definedfor all1J EJRn whileJ(1J) is undefinedfor0= 90(ii) V< 0 forall v E IRnif andonly if thedampingmatrix:D(v) >0 V v EIR.n(iii) V->coas 1I1J1I ->coand lIiJlI ->co. Thisissatisfied for(4.48).o(4.56)Thefirstcondition simply states thattheinertia including hydrodynamic addedmassmustbe strictly positive. Forunderwater vehicleswecanassumeconstantadded mass(independentof the wave frequency) which implies that !VI = 0andM = MT>O. Thesecondconditionsimplystates that thesystemmust be104 Stability andControlof UnderwaterVehiclesdissipativewhichisalsotruefor anuncontrolledundisturbedROVMoreover,energy shouldnotbegeneratedbythe systemitself.Theuncontrolledsystemaboveissaidtobe autonomoussinceit doesnotexplicitlydepend on timet. Hence, we can apply Lyapunov's direct methodtoprovestability(seeAppendixC.1.1), If trackingof atime-varyingreferencetrajectory is of interest, the new dynamics associatedwith the tracking errorwillbenon-autonomous. By non-autonomous we mean a systemwith state equation::i: = j(x, t) (4.57)where the nonlinearfunctionj(x, t) explicitly depends on time. In order to proveconvergenceor stability of this systemnon-autonomoustheorymust be applied.4.2.2 Closed-LoopTrackingControlInthissection, it will beshownhowBarbiilat'slemmacanbeusedtoderiveanon-autonomous tracking control law" The design methodology is best illustratedbyconsidering a simple example.Example4.1 (Velocity TrackingControl)Assumethat wewant to contml thevehicle's linear andangularvelocities. Lettheerrordynamics bedenotedby v(t)= v(t)- Vd(t) whereVd(t) is thedesiredstatevector. For' marinevehicles aswell as mechanicalsystemsingeneral, wecandefinea Lyapunov functioncandidate,;(4,58)whichcanbeinterpretedasthe ''pseudo-kinetic'' energyof thevehicle. Differen-tiating Vwithrespecttotime(assuming M= M Tand M= 0) yields:V= vTMDSubstituting(4.27)intotheexpression for Vyields:(4.59)V=vT[r - MVd- C(V)Vd - D(V)Vd - g(1])]- vTD(v)v (4.60)Herewe have used theskew-symmetric p1'Operty: vTC(v)v =0 'if v E]Rn Thissuggeststhat thecontrollawcouldbebeselectedas!,:(4.61)whereK d isa positiver'egulator gainmatTix of appmpriatedimension, Hence:'(4.62)type of control action isusually referred to as the Slotine and Li algorithm inrobotics(SlotineandLi 1987). However, inthiscasethespecial structureoftheunderwater vehicledynamics is exploitedinthedesign.4.3Conventional Autopilot Design 105Notice that V ::; 0implies that Vet) ::; V(O) V t ::::: 0, andtherefore that vi.sbounded. This in-turnimpliesthat if is bounded. Hence, If must be uniformlycontinuous Finally, applicationof Barbalat'slemma(see Appendix Cl) showsthat V..... 0whichimpliesthat v ..... 0ast ..... (Xlo4.3 Conventional AutopilotDesignThissectionstartswithabrief reviewof PID-control designbefore wediscussextensionsto nonlinear controltheory.4.3.1 Joy-StickControl SystemsDesignIt iscommontoclassifycontrolsystemsintotwofUndamental types, open-loopandclosed-loop(feedback) control systems. Figure 45showsanopen-loopROYautopilot systemwherethe commandedfeedforward force andmoment vectorreis generatedbytheRaYpiloL Theoutput fromthejoy-sticksystemu iscomputedbyapplyingthegeneralizedinverseBtvoftheinput matrix. Open-loop systems work satisfactory if the environmental disturbances are not too largeandif the numerical expression for Bisknownwith sufficient accuracy.Improvedrobustnessandperformanceinthepresenceof environmental dis-turbancescanbeobtainedbyapplyingaclosed-loop control systemof PID-type(proportional, derivativeandintegral) instead, seeFigure 45 Inthiscase, thepilot joy-stickisusedtogeneratethecommandedpositionandattitude'TIc (oralternativelylinear andangularvelocity). Closed-loop controlrequiresthatsen,sor/navigation data areavailable forfeedback.In Figure 4.5 a reference pre-filter is includedto smooth outthecommandedinput. This is done to avoicl saturation in the actuator as a result of large trackingerrorscausedby steps inthecommandedinput. Fora second-order system, thereferencepre-filter isusually chosenas:(4.63)-where TJd EJR6 isthedesiredoutput fromthepre-filter, 'TIc EJR6 is thecom-manded input, A =diag{(I> .,., (6} is the desired damping ratios and n =diag{wr, ... , W6} isthedesired natural frequencies. Thedesign of thePID-controllaw for tracking of thedesired state'TIdis thetopic for thenextsection.4.3.2 Multivariable PID-Control Designfor NonlinearSystemsMost existing RaY-systems use a series of single-input single-output (SISO)con-trollers of PID-type where each controller is designed for the control of one DOF.This implies that thecontrol matricesKp , KdandKiin thePID-controllaw:106 Stability andControlof UnderwaterVehiclesenvironmentaldisturbancesi'',,,',,,,

I--JI r, .. g(.) , t; ; feedforward ;: ROY d . !; ..1,ji " frompilotAOpenloop (feedforward) force/moment controlenvironmentaldisturbancessensornoisefrompilotBClosedloop (feedback) position/attitude controlFigure4.5: Open-loop and closed-loop ROV control systems design.r ..'"TPID = Kp e(t) + Kd e(t) + Kit e(-r)d-r (4.64)shouldbechosenpositiveanddiagonaL Heree= TJd- TJ isthetrackingerror..However, most ROVsystems for offshoreapplications use onlysimpleP- andPI-controllers for automaticheadinganddepthcontrol since it is difficult tomeasure(estimate) the velocity vector v. A standardPID-control design canbeimprovedbyusingthevehiclekinematics together withgravitycompensation..Moreover, we will show that perfect set-point regulation can be achieved in termsof Lyapunov stability theoryif TpIDistransformedaccording to:(4.65)In addition,we will assume that the control input vector is related to the thruster.' 4.3Conventional AutopilotDesignforcesand momentsaccording to(4.l0)c Hence, theinversemapping:107u= BtvT (4.66)where Btvis the generalized inverse(see Section 4.Ll), can be usedtocalculatethedesiredcontrolsuInthenext sectionwewill also showthat excellent performancecanbeob-tained for the whole flight envelope by including the vehicle kinematics and restor-ing forcesinthePID-controldesignc Moreover, it isnotnecessarytoperformagain-scheduling technique to counteract the time-varying behavior of the dynam-ics and kinematicsc However, precautions against saturation and integral wind-upshould be made. This is illustrated in Figure 4c6 where the PID-controllaw of theEAVE-EASTvehicle attheUniversityof New-Hampshireis shown. Thisdesignisperformedundertheassumptions (without lossof generality) 'TJd =constant,J('TJ) = I andg('TJ) = o."::' ResetfunctionVehicleDynamics11Figure4.6: TheEAVE-EASTProportional Integral DerivativeController (Venkat-achalam etal. 1985)4.3.3 PIDSet-Point Regulation inTerms of LyapunovStabilityInthissection, wewillinvestigatetheclosed-loopdynamicsof thecontrol law(464)and(4.65)undertheassumption thatthedesired state vector:'TJ d=constant (4.67)Thiscontrol problemwill be referredtoasregulation asthe opposite of trackingcontrol whichinvolves the designof afeedback andfeedforward controller fortracking of atime-varying smoothreferencetrajectory'TJAt). ConsideranaffineROV-model:108Stability andControl of UnderwaterVehiclesMv +C(v)v + D(v)v +9(17) = B'U(4.68)where17 E JRn,V E JRnand'UE JRT Let usassume that the inputmatrix Bandgravitational forces9(17) areknown whereasM', Cand Dareunknown. Hence,thefollowingconsiderationsmay be done:PD-Control of NonlinearSquare System(r =n)Assume that Bis invertible and let the control law be chosen as a PD-controllawwherethe term g(17) is included to compensate for gravity and buoyancy, that is:'u = B-1[J7(17)Kp e- K dv +9(17)] I (4.. 69)Noticethat (4.. 64) and(4.65) areequivalentto(4.69) if K d=JTKdJ> 0andKi=O. Thiscontrol lawismotivatedfromtimedifferentiationof aLyapunovfunctioncandidate:(4.70)whichyields11 =v7[Mv - J7(17) Kp e] (4.. 71)Herewehaveusedthefact that e= -7] = -J(17) v. Substituting(4.68) intothisexpression for 11, yields:11 = v7[Bu- D(v) v- 9(17)- JI(17) Kpe] (472)Notice that vI C(v) v= 0 for all vE JRn .. From this it is seen that the proposedPD-controllawwithappropriate cboicesof Kp =K ~ > 0andK d>0ensuresthat:.1(4.73)This means that the poweris dissipated passively bythe damping matrix Dandactively bythe virtual damping matrix K dWe now only havetocbeck thatthesystem cannot get "stuck" at 11equal tozero, whenever e #0.. From(4.. 73) weseethat 11 =0 implies that v=O. Hence, (4.68)with(4.69) yields:'/(4.74)Consequently v will ben o n ~ z e r o if e #0and11 = 0 only if e =O. Thereforethesystem cannot get "stuck" and the system state vector17 will alwaysconvergeto17d inviewof V--t O.This result was first proven by Tagegaki and Arimoto (1981)who applied theresult torobot manipulatorcontroL However, nonlinearcontrol ofunderwater,1,4.3ConventionalAutopilot Design 109vehicles in terms of Euler angle feedback was first discussed by Fossen and Sagatun(1991b)0 Laterthis work has been extendedtoquaternion feedbackregulation intermsof vectorquatemion, Eulerrotation andRodriguesparameter feedbackbyFjellstadandFossen(1994b)0PID-Controlof Nonlinear Square System(r = n)ArimotoandMiyazaki (1984)haveshown thattheresultsabovecanbe general-izedtoinclude integral action, Let:(475)denote the generalized momentum of the vehicle, Hence, it can be shown bytimedifferentiation of a Lyapunovfunctioncandidate:[M-I1 ~V(x)=-xTaI2 0whereais small positive constant anda la]KpKiXKia Ki(4,76)x= rp, 17, l err) drf(4,77)that V.:;0 and that 17 convergesto17d =constant. Thisis based ontheassump-tionthat thePID-control law istakento be:(4,78)whereKp , KiandKdarematrices satisfying:Kd > M ~Ki >0Kp2>Kd+-Kia(4079)(4.80)(4.81)(40.82)whereaisa small positive constant chosen so smallthat:1 a 6 8 1 \ ! I ~-(1- a)Kd - aM~ + - 2::;(T)i - T)id)--> 02 2i=1 8T)iIt shouldbenotedthat thissolutiononly guaranteeslocal stabilityinalimitedregion about the origin, For details on the proof see Arimoto and Miyazaki (1984).110Stability andControlof UnderwaterVehiclesOverdeterminedSystem(r > n)If wehave more controlinputsthan statesto be controlled, we showedthat B-1couldbe replaced bythegeneralized inverseBtvdefinedin Section 4 1.1. Hence,itisstraightforwardtoshowthat theaboveresultsarevalidfor thenon-squarecaseT>n,Non-AffineSystems(r > n)For theregulationproblemit isstraightforwardtoextendtheaboveresults tonon-affine systemswherethecontrol inputis givenby(see(4.8)):r=Bl u-B2(u)vInfact thenonlinear controllaw:tu= Bt [JT(7]) Kp e- K'd v+ 9(7])] Iappliedto(4.68)implies that V canbewritten:(4,83)(4.84)(4.. 85)where K'd > 0 must be chosen such that this e..xpression becomes negative. Noticethat the additional coupling term B2 ( u)v only contributes to the system dampingif B2(u)>O. If B 2(u)< 0we mustchooseK'd > -B2(u) toensure stabilityPerfect Collocation(r =m)In somecases, wecandesignanoutputfeedbackcontrollawthatovercomestheproblem that all states must be measured. This design is based on the assumptionthat thenumber of inputsuE lH"areequal tothenumber of measured outputsyElRm. To dothis, wewill apply passivitytheory;see AppendixC.3for details.Thissuggest that theplant andcontrol systemcanbedescribedbytwoblodO. Hencev= PA)x + xTpBuLet usassume that the sensors andactuatorscan be located suchthat:y=GxwhereGisa constant lmownmatrix defined by:andPsatisfiestheLyapunovequation:withQ=QT2: o. Hence:(4.90)(4.91)(4.92)(4.93). 1V=yTu--xTQX (4.. 94)2This is referred toasperfect collocation betweenthe sensorsand actuators Thisresult is also known as the Kalman- Yakubovichlemma (see Appendix C.3)whichisusedtocheckif asystemispositive real. For linear causal systems positiverealnessisequivalent withpassivity.We now turn attention to the last block representing the output feedbackcontrol law. AccordingtoAppendix0.3a systemis strictlypassiveif andonlyif thereexistsa scalar Cl< > 0 andsome constant f3such that:(4.95)112 Stability andControl of UnderwaterVehiclesFor alinearoutput feedbackcontrol law:(4.96)where H(s) = diag{hi(sn(i = L.T)tobestrictly passive thetransfer functionshi ( s)mustsatisfy:forsomeu> 0 and:Re{hi(s - un~ 0 'r/ w~ 0Lhi(jW) < 90 'r/ w~ 0(4.97)(4.98)This is satisfied, for instance, if hi(s)is chosenas aPID-controllaw withlimitedderivativeandintegral action, thatis:h(s)-Kf3 I+Tis I+Tds (4.99), - p 1 + f3 Tis 1 +Cl< TdsHere Kp>0, Ti>Td, Cl< < 1and f3 >1. Finally, DefinitionG8 ensuresthat y ELT. Itshouldbenotedthatit isstraightforwardtogeneralizetheseresults toanonlinear ROVmodel byusingthegeneral frameworkof passivity.Arelatedworkoncollocation isfoundin S!ilrensen(1993) whohasappliedthisdesign methodologyto control high-speed surfaceeffect ships(see Section 7.1).4.3.4 Linear QuadraticOptimal ControlLinear quadratic(LQ)optimal control design is based on minimization of a linearquadratic performanceindexrepresentingthe control objective. Consider thelinear state-space model::i:: - Ax+Bu+Ewy - ex(4.100)(4101)wherex is thestatevector, u istheinput vector, wis thedisturbancevectorandy isusedtodescribethecontrol objective. Let J beaperformanceindexweighting thetracking error vectoragainst thecontrolpower, thatis:min J=~ (T(fJTQfJ +uTpu)dr (4102)2 laHereP> 0 and Q2: 0 are the weighting matrices andfJ =y - Yd is the trackingerror vector. Thecommanded input vectorisdenotedYd' Anapproximateopti-mal solutiontothetracking problem(4.102)for0 T0Differentiating Vwith respectto time(assuming m=0)yieldsv= m!; 8= -d Ixl82+ 8(T - mx, -d Ixlx,)127(4.159)(4.160)(4.. 161)Ih-xSXr- Xd - Ai:TI ""+dIT I:i: :i:,..Imx xX=TIxr' = Id - .Aix.L,.--s =X- xrmdl:i:1KdI K sgn()IFigure4.17: 8180 sliding control applied to underwater vehiclesTaking thecontrollaw to be:IT=mx, +dlxlx, - Kds - Ksgn(s)! (4.162)where mand daretheestimatesof mandd, respectively, and:yields:sgn(s)= { ~-1if s>0if s = 0otherwise(4.163)v= -(Kd +d Ixl ) 82+( fix, +dlXIX, ) s - KIsl (4.164)Here fi = m- mand d= d- d Conditionsonthe switching gainKarefoundbyrequiring that V :::; O. The particular choice:128 Stability andControl of UnderwaterVehicles(4165)with1] > 0 impliesthat:(4.166)Thisisduetothefact that ( Kd +d lxl ) ;,0 Vx. Noticethat, 11 So 0 impliesthat V(t) So V(O), andthereforethat s is bounded. This inturnimpliesthatV isbounded. Hence 11must beuniformlycontinuous, Finally, applicationofBarbiilat's lemma thenshowsthat s -;. 0 andthus x-;. 0 ast -;. 00ChatteringItiswell known that theswitchingtermKsgn(s) can leadtochattering. Chat-teringmust beeliminatedfor the controllertoperformproperly SlotineandLi (1991)suggest smoothing outthecontrol law discontinuity inside aboundarylayer byreplacingthesgn(.)functioninthecontrol lawwith:sat(sjcp) = {sgn(s)s/if;if Is/if;1>1otherwise(4.. 167)The boundary layerthicknesscan alsobe madetime-varying to exploitthema..'{-imum control bandwidth available. See Slotine and Li (1991) for a closer descrip-tion ontime-varying boundarylayers.whererP should be interpreted as the boundary layer thickness. This substitutionwill in factassign a low-pass filter structure to the dynamics of the sliding surfaces inside the boundary layer (see below). Moreover, replacing the Ksgn(s)term in(4.162) withIf. sat(sjcp) yieldsthefollowingexpressionsforthes-dynamicsandV.(4170)(4.169)(4.171)(4.168)v~ -( Kd + d Ixl +~ ) 82K -m s+ ( K d +d Ixl +~ ) s =mXr+d lxix,m s+ (Kd +d Ixl ) s + Ksgn(s) = mXr +dlxix,Outside theboundarylayer:Inside theboundarylayer:4.5AdvancedAutopilotDesignfor RaVsExample4.5 (Sliding ModeControl Applied to RaVs)Considerthesimplified model of anunderwater vehicleinsurge:129m x+d Ixlx = T (4..172)with m = 200 kgand d =50 kg/m. TheSISOslidingcontroller canbecomplLiedas"Ir = mx, +d lxix, - Kd s - Ksat(slifJ) IwhereKd~ O. The followingtwocaseswerestudied(1)PD-Controller:(4.173)m=Od=OKd=500K=ONoticethatthissimplycorrespondstothePDcontrollaw:T = -KdS = -Kd j; - .\ Kd x(2) Sliding ModeController:m =0.. 6m m ~ 0.5md =1.5 d d ~ 0.5dK = I(m x, + dIxl x,)1+0.1K d= 200(4.174)Inthesimulationstudytheclosed-loopbandwidthwas chosenas.\ = 1for bothcontrollers. The boundary layer thickness was chosen as ,-02'!-OA.0 10 20 30time (s]40-40401110 20 30time (s]SI mQ contra er-

0-\],I-(N]200100o-100-200-300olOO\"-100-200-3000 10 20 30 40time (s]Figure 4.18: Performance study of the sliding controller (solid)andthe PD-controller(dotted)(N]200 .--__0.2slidin controllerOA r======t==:;:;:===l -OA C==::::==:::==:===:::Jo 10 20 30 40time (s]-0.240 30 20time (s]POcontroller10-s.. .... \Tf\..0.2oOA-OAo-0.2Figure 4.19: Control input andmeasureoftrackingfot thePD-controller andthesliding controller.4.5Advanced AutopilotDesignfor R.OVs 131where x =x- Xdisthestatetrackingerrorandh EJRHisavector of knowncoefficients tobeinterpretedlater. It is important that theslidingsurfaceisdefinedsuchthat convergence of er( x) -+ 0implies convergence of the statetr acking error x -+O.Assume that we can write the dynamic and kinematic model as a SIMS linearmodel:x=Ax+bu+f(x) (4176)wherex EJRHanduEJR f (x) shouldbeinterpretedasanonlinearfunctiondescribing thedeviationfromlinearity in termsof distur bancesandunmodelleddynamics.. The experiments of Healey and co-authors show that this model can beusedtodescribealarge numberof ROVflight conditions Thefeedbackcontrollawiscomposed of twoparts:u=u+uwherethe nominal part ischosenas:(4.177)(4.178)Herek isthefeedbackgainvector Substituting theseexpressionsinto(4,176)yieldstheclosed-loop dynamics:x=Acx+bu+f(x); (4.179)Hence, the feedbackgain vector kcan be computed by meansof pole-placementby first specifying the closed-loop state matrix Ac. In order to determine the non-linear part of the feedbackcontrol law wefirst pre-multiply(4.179)withhT andthen subtracthTXdfromboth sides, Hencethe followingexpressionisobtained:&(x)=hTAcx+hTbu+hTf(x)-hTxdChoosing u (assuming that hTb #0)as:(4.180)70(4.181)wherej(x)isanestimate of f(x), yieldsthe er-dynamics:O'(x) =hTAc x- 1]sgn(er(x)) + hT6.f(x) (4.182)where 6.f(x) = f(x)- j(x), We now turn tothe choice of h A nonzerovectormE JRn that s a t i s f i ~ s :Am=).m (4183)where ,\ E.'\(A) is an eigenvalueofA issaidtobe a right eigenvectorof Afor ,\, Hence, if oneoftheeigenvalues ofAcis specifiedtobezero, the term132 Stability andControl of UnderwaterVehiclesFigure4.20: Single-input multiple-states(SIMS)sliding mode control lawhTA c x=h)T xin(4.182)can be madeequal to zeroby choosing hastheTight eigenvector' offor,\ =0, thatis:h = 0h isa right eigenvector of for,\ = 0Withthischoice of h, the(T-dynamics reducesto:&(5:) = -r] sgn((T(5:)) + hT6.f(x)(4.184)(4.185)which can be madeglobal\::lf\t , by selectingr] as:(4.. 186)This iseasily seen byapplying theLyapunov functioncandidate:1Veal='20'2Differentiation of Vwith respecttotime yields:v=a &=-r] a sgn(a) + a hT6.f(x)=-r] lal + (T hT6.f(x)(4.187)(4.188)Choosingr] accordingto(4.186) ensuresthat V:::; O. Hence, byapplicationofBarbiilat'slemma(T converges tozeroinfinitetimeifryischosenlargeenoughtoovercomethedestabilizingeffectsoftheunmodelleddynamics 6. f (x).. Thechoice ofr] will bea trade-off betweenrobustnessandperformance.4.5AdvancedAutopilotDesignforROVsImplementationConsiderations133Inpractical implementations, chattering shouldberemovedbyreplacing sgn(u)withsat(u/rP) in (4.181) where the design parameter rP is the slidingsurfaceboundary layer thickness. Alternatively, the discontinuous function sat(u1rP)couldbereplacedbythecontinuousfunctiontanh(u/rP); seetheupper plot ofFigure 4.21.tanh(al.p )o -3 -2 -1 0 2 3 crer 32o_L3crFigure 4.21: Diagram showing tanh(u!rP) and (j tanh(u!rP)as a function of the bound-ary layerthicknessrP E {D.I, 0.5, l.D}.This suggeststhemodified control laws:u - -ex + (hTb)-l[hTxd - h T)(x) -1]sat(u/rP)]u _kTx + (hTb)-l[hTXd - hT)(x) -1]tanh(u/rP)]These substitutions imply that:(4189)(4.190)if lu/rP1 >1otherwisewhere the product u tanh(u/ rP) is shown in the lower plot of Figure 4.21. It shouldbe noted that the proposed feedbackcontrol with a predescribed1] usually yieldsaconservativeestimateof thenecessarycontrol actionrequiredtostabilizetheplant, This suggests that 1] shouldbetreatedasatunable parameter.where m- X"isthemass of thevehicleincluding hydrodynamicadded mass, P isthewaterdensity, CDisthedragcoefficient, Aistheprojectedarea, Xlnlnisthepropeller for'cecoefficientandf (u, n) r'epresentstheunmodelleddynamics. Sincethespeeddynamicsisof first orderand completelydecoupled fromtheother statevariables, wecanselect h=1 sothat.:Stability andControl of UnderwaterVehicles 134Example4.6 (ForwardSpeedControl)Againconsider thespeedequation(4.110) intheform.'(m -X,,)u+~ P C D A lulu = X1n1n Inln+ f(u,n)a =U =u -Ud(4191)(4,192)Thedesired a-dynamicsisobtained for' thefollowingfeedbackcontrollaw.'InIn =_1_[(m - X,,)Ud +~ P CD A lulu - (m - X,,)1) tanh(o'/11h 11 . 11 -[an, a12, WVc11= 0.1251Thesimulationresults forthissystemwithreferencemodel.[,pd] _ [0 1] [..pd ] + [ 0]id - - w ~ -2(wnrd u l ~ 1pc(4.201)(4.202)(4.203)(4.204)(4.205)(4.206)-where( =08andWn=0.1 are shown inFigure 4.22. All simulations wereperformed witha samplingtimeoJ 0.1(s) andboundarylayerthickness1J =01136 Stability andControlof Underwater Vehicles0.51 (deg/s), ,:,->' '.......,,oFigure 4.22: Step response'l/Jc= 20 (deg) with sinusoidal disturbance Vc Dotted linesdenote'l/Jdandrd

o 50 100time(sec)100 50time(sec)-060 100-0.. 5100 50 0 50time(sec) time(sec)251/J (deg)58(deg)20

015Fromthis figureit is seen that the sinusoidal disturbancedoesnotaffect thetmck-ing performanceor thestabilityof thecontrollaw Thiswillnot bethecase if asimplePID-controllawisappliedtothissystem.oExample4.8 (Combined Pitch/Depth Control)Consider thesimplifieddivingequationsof motion inthe form..a =hI(w - Wd) + h2(q - qd) + h3(0 - Od) + h.t (z - Zd) (4.208)where hi for (i=1...4) are the components of h. As inthe previous examplek = [kl, k2, k3, k4JT must be solvedfromthe specifiedclosed-loop dynamics via[: ] [:] [ ]iJ = 0 1 0 0 0 + 0 8si 1 0 -uo 0 z 0Wenowdefinetheslidingsurfaceas:(4.207).,,...-4.5AdvancedAutopilotDesignfor ROVs 137eigenvaluespecifications_ Sincethereis one pureintegrationinthepitchchannelthismodecanber-emoved fromA cbyselectingk3= O. Hence, wecancompute hbysolving_' A(Ac) = A(A - be) suchthat A ~ h = 0for A3 = 0whichissimplyaSrd-order pole-placement problem, Finally,(4_209)andOs=-k1w-kzq-k4z+ ;0 [hI wd+h2Qd+h3ed+h4zd-71tanh(u!0and R'd >O. Hencewecan expressthe error dynamicsaccOIdingto:Mry(77) [ry + Kd i] +KpryJ =rT(77) P(av , v, 77) BWriting thisexpression in state-space form, yields:x = Ax +B J-T(77) P(av , v, 77) Bwherex = [ij, i]jTand(4.261)(4.262)(4.263)4,5 Advanced Autopilot Design for RaVsConvergence of ij to zero can be proven by defining:145p = pT > 0(4.264)Differentiating V with respect to time and substituting the error dynamics intothe expression for V, yields:11 = xT(P + PA + ATp)x + 2 (xTPBrTp + ({r-I)8 (4.265)where r = rT> 0 is a positive definite weighting matrix of appropriate dimen-sion This suggests the parameter update law (assuming iJ = 0):18= -rpT(av,II,T)) rl(T)) ylwhere we have introduced a new signal vector y defined as(4.266)y=Cx(4.267)In order to prove that V ::; 0 we can choose:(4,268)where Co > 0 and Cl > 0 are two positive scalars to be interpreted later, further-more we choose:PA+ATp = -Q;(4,269)where P and Q are defined according to Asare and Wilson (1986):P = [ col\lIryKd + clMryKp Col\lIry]coMryclMry(4.270)(4.271)If in addition, we use the fact that ;z.T !VIryZ is bounded, we can establish: ('" EO- R3)xTPx::;axTx ==:> xTpx:Sf3xT[ ~ r y ~ " 1 x (4.272)where a > 0 and f3 > 0 are two positive constants Hence, we can choose Co > 0,Cl > 0 and:xTQx > f3xT[ ~ " ~ J xsuch that P = pT > 0 and:V = xT(P - Q)x ::; 0(4.273)(4.274)146 Stability andControl of UnderwaterVehiclesbyrequiring:(1) (cOKd + clKp) Cl > c51(2) 2coKp > (31(3) 2(c1Kd- col)>(31Here(3 usually is taken to be a small positive constant while Kp > 0 andKd > 0canbechosenasdiagonal matrices. Consequently, convergenceof ij tozeroisguaranteedbyapplyingBarbiilat'slemma.. We alsonoticethat theparametervector iJ will bebounded. Hence, PEisnot requiredtoguaranteethetrackingerrortoconvergetozero. Robustnessduetoactuatordynamicsand saturationarediscussedbyFjellstad, Fossen andEgeland(1992).4.5.4 NonlinearTracking(TheSlotine andLi Algorithm)Anadaptive control law exploiting the skew-symmetric property of robot manip-ulatorswasfirst derivedby Slotine andLi (1987). Later, extensions of this workwas made to the 3 DOF spacecraft attitude control problem in terms of Rodriguespammeters by Slotine and Benedetto (1990)together with Fossen (1993a). Theseresults have been