1PIDcontrollerFromWikipedia,thefreeencyclopediaAproportional–integral–derivativecontroller(PIDcontroller)isageneric.controlloopfeedbackmechanismwidelyusedinindustrialcontrolsystems.APIDcontrollerattemptstocorrecttheerrorbetweenameasuredprocessvariableandadesiredsetpointbycalculatingandthenoutputtingacorrectiveactionthatcanadjusttheprocessaccordingly.ThePIDcontrollercalculation(algorithm)involvesthreeseparateparameters;theProportional,theIntegralandDerivativevalues.TheProportionalvaluedeterminesthereactiontothecurrenterror,theIntegraldeterminesthereactionbasedonthesumofrecenterrorsandtheDerivativedeterminesthereactiontotherateatwhichtheerrorhasbeenchanging.Theweightedsumofthesethreeactionsisusedtoadjusttheprocessviaacontrolelementsuchasthepositionofacontrolvalveorthepowersupplyofaheatingelement.By"tuning"thethreeconstantsinthePIDcontrolleralgorithmthePIDcanprovidecontrolactiondesignedforspecificprocessrequirements.Theresponseofthecontrollercanbedescribedintermsoftheresponsivenessofthecontrollertoanerror,thedegreetowhichthecontrollerovershootsthesetpointandthedegreeofsystemoscillation.NotethattheuseofthePIDalgorithmforcontroldoesnotguaranteeoptimalcontrolofthesystemorsystemstability.Someapplicationsmayrequireusingonlyoneortwomodestoprovidetheappropriatesystemcontrol.Thisisachievedbysettingthegainofundesiredcontroloutputstozero.APIDcontrollerwillbecalledaPI,PD,PorIcontrollerintheabsenceoftherespectivecontrolactions.PIcontrollersareparticularlycommon,sincederivativeactionisverysensitivetomeasurementnoise,andtheabsenceofanintegralvaluemaypreventthesystemfromreachingitstargetvalueduetothecontrolaction.2AblockdiagramofaPIDcontrollerNote:Duetothediversityofthefieldofcontroltheoryandapplication,manynamingconventionsfortherelevantvariablesareincommonuse.1.ControlloopbasicsAfamiliarexampleofacontrolloopistheactiontakentokeepone'sshowerwaterattheidealtemperature,whichtypicallyinvolvesthemixingoftwoprocessstreams,coldandhotwater.Thepersonfeelsthewatertoestimateitstemperature.Basedonthismeasurementtheyperformacontrolaction:usethecoldwatertaptoadjusttheprocess.Thepersonwouldrepeatthisinput-outputcontrolloop,adjustingthehotwaterflowuntiltheprocesstemperaturestabilizedatthedesiredvalue.Feelingthewatertemperatureistakingameasurementoftheprocessvalueorprocessvariable(PV).Thedesiredtemperatureiscalledthesetpoint(SP).Theoutputfromthecontrollerandinputtotheprocess(thetapposition)iscalledthemanipulatedvariable(MV).Thedifferencebetweenthemeasurementandthesetpointistheerror(e),toohotortoocoldandbyhowmuch.Asacontroller,onedecidesroughlyhowmuchtochangethetapposition(MV)afteronedeterminesthetemperature(PV),andthereforetheerror.ThisfirstestimateistheequivalentoftheproportionalactionofaPIDcontroller.TheintegralactionofaPIDcontrollercanbethoughtofasgraduallyadjustingthetemperaturewhenitisalmostright.Derivativeactioncanbethoughtofasnoticingthewatertemperatureisgettinghotterorcolder,andhowfast,andtakingthatintoaccountwhendecidinghowtoadjustthetap.Makingachangethatistoolargewhentheerrorissmallisequivalenttoahighgaincontrollerandwillleadtoovershoot.Ifthecontrollerweretorepeatedlymakechangesthatweretoolargeandrepeatedlyovershootthetarget,thiscontrolloop3wouldbetermedunstableandtheoutputwouldoscillatearoundthesetpointineitheraconstant,growing,ordecayingsinusoid.Ahumanwouldnotdothisbecauseweareadaptivecon...