Увод
Geneticprogrammingisaspecialmachinelearningtechnologythatusesevolutionaryalgorithms.Itstartsfromagroupof"crowds"composedofmillionsofrandomlygeneratedcomputerprograms,andthenDeterminethesuitabilityofaprogrambasedontheabilityofaprogramtocompleteagiventask.Darwin’snaturalselection(survivalofthefittest)isusedtodeterminethewinningprogram.Computerprogramsalsosimulategendercombination,mutation,geneduplication,genedeletion,etc.Evolvefromgenerationtogenerationuntilapredeterminedstoppingconditionisreached.Thebasicideaofgeneticprogrammingalsodrawsonthebiologicalevolutiontheoryandtheprincipleofheredityinnature,andisamethodofautomaticallyandrandomlygeneratingsearchprograms.Asanewglobaloptimizationsearchalgorithm,thisalgorithmissimple,versatile,robust,andshowsstrongabilitytosolvenonlinearcomplexproblems,soithasbeensuccessfullyappliedinmanydifferentfields,andInrecentyears,morein-depthresearchhasbeenobtained.
Распон примене и карактеристике
TheapplicationrangeofGPisverywide.Intheory,anyfunctionthatobtainsavaluebasedonmultipleinputvalues,suchas:forf(x1,x2,...,xn)SuchfunctionscanbegeneratedusingGP.Whentheprogramisrelativelysimpleinlogic,itcanbedirectlywrittenbyhand,andthereisnoneedtouseGPtogenerateit,butforsomelogicallycomplexprograms,itcanbeusedtoautomaticallyevolveandgenerateaprogram.
Forexample,itisverydifficulttogeneratecontrolprogramsforagentsthathavemorecontrolresponses.Theyoftengeneratecorrespondingdecisions(actions)basedonmultipleexternalstimuli.ThistypeofprogramcanbeusedGPtogenerate.
Inthespecificimplementation,ithasthefollowingcharacteristics:
(1)Шта ГП решава је програм (орални алгоритам) који описује проблем.
(2)GPisusuallyrepresentedbyatreestructure,andthedescriptionisrelativelycomplicated.
(3) Дужина (дубина) појединаца у свакој генерацији ГП-а је генерално различита, чак и дужина (дубина) између појединаца у истој генерацији је такође различита.
(4)TheresourcesconsumedbyGPareuncontrollable(uncontrollableheremeansthatitcannotbeaccuratelydescribed),itneedstoconsumealotofmemoryspace,sotheevolutionofeachgenerationisrelativelyslow.
Процес имплементације
Лангуагеселецтион
Geneticprogramminghasdifferentimplementationmethodsindifferentlanguages.Theprogramgeneratedbygeneticprogrammingcanberegardedasbothprogramanddata.Intheprocessofgeneticprogramming,itisdata,whichneedstoberandomlygenerated,crossed,mutated,andevaluated;aftergeneticprogramming,itisaprogramandneedstobeexecuted.Lisplanguageisverysuitableforgeneticprogramming,becauseLisplanguagecanoperateontheprogramitselfandthenexecuteit.
Програмрепресентатионметход
Programcanhavetworepresentationmethods:treestructurerepresentationandstringrepresentation.Thetreestructurerepresentationmethodhasaclearstructure.Itisrelativelysimpletoperformcrossoverandmutationoperations,butrequiresalargestoragespace.Sincegeneticprogrammingrequiresalargenumberoftreestructuresforeachgeneration,thestorageoverheadisverylarge.Spacecomplexityisatopicthatneedstobestudiedingeneticprogramming;expressingprogramswithstringscansavealotofstoragespace,butitismoredifficulttoperformgeneticoperations,suchascomparisonwhenselectingrandomintersectionsormutationpointsof"parents"Complexandneedtobeconverted.
FortheLisplanguage,itisastringitself,soitismoresuitabletouseastringtorepresentgeneticprograms;fortheClanguage,thesetwomethodscanbeselected.Sothereare4waysofcombining:Clanguage+treestructure,Clanguage+stringrepresentation,Lisp+treestructure,Lisp+stringrepresentation,ofwhichthethirdmethodisnotcommonlyused(theClanguagereferredtoheremeansinadditiontoLispMostoftheothercommonlanguages).
ItisseldomusedtoexpresstreestructureinLisplanguage,becauseitisnotnecessary.IftheClanguageisusedtorepresentthestringstructure,itissimilartotheLisplanguage,anditisrelativelysimple.YoucantreatthegeneticprogramasdataandexpresstheprogramasapseudoLisplanguage.Aftertheinheritanceisover,youcanuseitasaprogram.Ofcourse,itshouldbeexecutedasaprogramduringperformanceevaluation,whichwillbedescribedindetailbelow.
Програмекецутионметход
ForLisplanguage,programexecutionisrelativelysimple,becausethedatageneratedbygeneticsistheprogramandcanbeexecutedimmediately.FortheClanguage,itisverycomplicated,becausetheprogramsgeneratedbytheClanguagearejustdataandcannotbeexecuted.Forthisreason,aninterpretermustbedesignedtointerpretthegeneratedprogram,anddifferentinterpretersneedtobegeneratedforthetreestructureandthestringstructure.Butdifferentapplicationsneeddifferentinterpretationmethods,sotheexecutionmethodsafterinterpretationarealsodifferent.Inordertobeuniversal,anexecutioninterfaceisdesigned.Forallapplications,thesameinterpretercanbeused,whichiscalledavirtualmachine.Onlytheexecutionpartcanbechanged.Fordifferentapplications,differentexecutionfunctionsarecalled.
Евалуатионфунцтионселецтион
Fordifferentapplications,differentevaluationfunctionsneedtobeselected,soauniversalevaluationfunctioncannotbemadeintheprogramdesign.Theselectionoftheevaluationfunctioniscurrentlyasubjectthatneedstobestudied,andthereiscurrentlynouniversalandeffectivesettingmethod.Inthiscase,youcansetageneralinterface(usingthepolymorphismoftheclass),andsetdifferentevaluationfunctionsfordifferentapplications(usingasubclasstoimplementthisinterface).
Процес развоја
ThefirstexperimentsongeneticprogrammingwerepublishedbyStephenSmith(1980)andCramm(1985).JohnKoza(1992)alsowroteafamousbooktointroducegeneticprogramming.
Computerprogramsusinggeneticprogrammingcanbewritteninmanyprogramminglanguages.Intheearly(ortraditional)implementationofGP,programinstructionsanddatavalueswereorganizedinatreestructure,sothoseprogramminglanguagesthatoriginallyprovidedatreestructureweremostsuitableforGP,suchastheLisplanguageusedbyKoza.OtherformsofGPhavealsobeenpromotedandimplemented,suchasrelativelysimplelineargeneticprogrammingsuitablefortraditionalprogramminglanguages(suchasFortran,BASIC,andC).TherearecommercialGPsoftwarethatcombineslineargeneticprogrammingwithassemblylanguagetoobtainbetterperformance,andsomeimplementationmethodsdirectlygenerateassemblyprograms.
Theamountofcalculationrequiredforgeneticprogramming(processingalargenumberofcandidatecomputerprograms)issolargethatitcouldonlybeusedtosolvesomesimpleproblemsinthe1990s.Inrecentyears,withthedevelopmentofgeneticprogrammingtechnologyandtheexponentialincreaseinthecomputingpowerofthecentralprocessingunit,GPhasbeguntoproducealargenumberofsignificantresults.Forexample,around2004,GPachievednearly40achievementsinvariousfields:quantumcomputing,electronicdesign,gamecompetition,sorting,searchandsoon.Someofthesecomputer-generatedprograms(algorithms)areverysimilartoartificialinventionsafter2000,andeventworesultshaveresultedinnewinventionsthatcanbepatented.
Inthe1990s,itwasgenerallybelievedthatitwasverydifficulttodevelopatheoryforgeneticprogramming,andGPwasalsoatadisadvantageinvarioussearchtechnologies.After2000,thetheoryofGPhasmadesignificantdevelopment,andithasbecomepossibletoestablishanexactGPprobabilitymodelandMarkovchainmodel.Geneticprogramminghasawiderrangeofapplicationsthangeneticalgorithms(actuallyincludinggeneticalgorithms)
JuergenSchmidhuberfurtherproposedmacrogeneticprogramming,atechnologythatusesgeneticprogrammingtogenerateageneticprogrammingsystem.Somecommentsthinkthatmacro-geneticprogrammingisnotfeasibleintheory,butmoreresearchisneededtoconfirmit.