unzip

Basicdefinition

Decompressionistorestoreadocument,fileandotherthingscompressedbysoftwaretothewaytheywerebeforecompression.

Howtouse

Thewaytodecompressthefileis:right-clicktheicon-decompressthefile-confirm(providedthattherelevantdecompressionsoftwareisinstalledandtheright-clickmenuisassociated),afterthedecompressioniscompleted,itwillbeAnewfileappearsinthedirectorywherethecompressedfileislocated.Thisfileisthefileyoudecompressed,butitmaynotbeonefile,butiscomposedofmultiplefiles.

Compressionprinciple

Becausetheinformationprocessedbythecomputerisexpressedintheformofbinarynumbers,thecompressionsoftwareistomarkthesamestringinthebinaryinformationwithspecialcharacterstoachievecompression.Purpose.Tohelpunderstandfilecompression,pleaseimagineapictureofblueskyandwhitecloudsinyourmind.Forthousandsofmonotonouslyrepeatingbluepixels,insteadofdefining"blue,blue,blue..."onebyonealongstringofcolors,itisbettertotellthecomputer:"Fromthisposition,store1117blues.The"imagepoint"issimpleandcangreatlysavestoragespace.Thisisaverysimpleexampleofimagecompression.Infact,allcomputerfilesarestoredintheformof"1"and"0"inthefinalanalysis,justlikebluedots.Aslongasthereasonablemathematicalcalculationformulaisused,thefilevolumecanbegreatlycompressedtoachieve"datalosslessness".Dense"effect.Ingeneral,compressioncanbedividedintolossyandlosslesscompression.Ifthelossofindividualdatadoesnotcausemuchimpact,itisagoodideatoignorethematthistime.Thisislossycompression.Lossycompressioniswidelyusedinanimation,soundandimagefiles.Typicalrepresentativesarethevideofileformatmpeg,themusicfileformatmp3andtheimagefileformatjpg.However,inmorecases,thecompresseddatamustbeaccurate,andpeoplehavedesignedlosslesscompressionformats,suchascommonzip,rar,andsoon.Compressionsoftwareisnaturallyatoolthatusescompressionprinciplestocompressdata.Thefilesgeneratedaftercompressionarecalledarchives,andthevolumeisonlyafractionoftheoriginalsizeorevensmaller.Ofcourse,thecompressedpackageisalreadyanotherfileformat.Ifyouwanttousethedatainit,youmustfirstrestorethedatawithcompressionsoftware.Thisprocessiscalleddecompression.Commoncompressionsoftwareincludeswinzip,winrar,etc.

Lossycompressionandlosslesscompression

Thetypeofcompressiondiscussedaboveiscalledlosslesscompressionbecausethefileyourecreateisexactlythesameastheoriginalfile.Alllosslesscompressionisbasedontheideaof​​turningafileintoa"smaller"formtofacilitatetransmissionorstorage,andrestoringitaftertheotherpartyreceivesitinordertoreuseit.

Lossycompressionisverydifferentfromthis.Theseprogramsdirectlyremove"unnecessary"informationandtailorthefiletomakeitsmaller.Thistypeofcompressioniswidelyusedtoreducethefilesizeofbitmapimages,becausethesizeofbitmapimagesisusuallyverylarge.Inordertounderstandhowlossycompressionworks,letusseehowyourcomputercompressesascannedphoto.

Forsuchfiles,thecompressionrateoflosslesscompressionprogramsisusuallynothigh.Althoughmostofthepicturelooksthesame—forexample,theentireskyisblue—butmostofthepixelsareslightlydifferent.Inordertomakethepicturesmallerwithoutreducingitsresolution,youmustchangethecolorvalueofcertainpixels.Ifthepicturecontainsalotofbluesky,theprogramwillpickabluethatcanbeusedforallpixels.Then,theprogramrewritesthefileandusesthisinformationforallskypixelvalues.

Ifthecompressionschemeisselectedproperly,youwillnotnoticeanychanges,butthefilesizewillbesignificantlyreduced.Ofcourse,forlossycompression,youcannotrestoretheoriginalfileafterthefileiscompressed.Youmustacceptthecompressionprogram'sreinterpretationoftheoriginalfile.Therefore,ifyouneedtofullyreproducetheoriginalcontent(suchassoftwareapplications,databases,andpresidentialinauguralspeeches),youshouldnotusethiscompression.

Advantages

Sohowgoodisthismechanism?Thefilecompressionratiodependsonmanyfactors,includingfiletype,filesize,andcompressionscheme.

Inmostlanguages​​intheworld,certainlettersandwordsoftenappeartogetherinthesamepattern.Itispreciselybecauseofthishighredundancythatthecompressionrateoftextfileswillbeveryhigh.Generally,thecompressionratioofatextfileofasuitablesizecanreach50%orhigher.Mostprogramminglanguages​​arealsohighlyredundantbecausetheyhaverelativelyfewcommands,andcommandsoftenadoptasetpattern.Forfilesthatcontainalargeamountofnon-repetitiveinformation(suchasimagesorMP3files),thismechanismcannotbeusedtoobtainahighcompressionrate,becausetheydonotcontainpatternsthatarerepeatedmultipletimes.

Ifthefilehasalargenumberofrepetitivepatterns,thecompressionratiowillusuallyincreaseasthefilesizeincreases.Thiscanbeseeninourexample-iftheKennedyspeechweextractislonger,youwillfindthatthepatterninourdictionaryappearsmultipletimes,soyoucansavemorefilespacethrougheachdictionaryentry.Inaddition,forlargerfiles,theremaybemoregeneralpatternsthatcancreatemoreefficientdictionaries.

Inaddition,filecompressionefficiencyalsodependsonthespecificalgorithmusedbythecompressionprogram.Someprogramscanbetterfindpatternsincertaintypesoffiles,sotheycancompressthesetypesoffilesmoreefficiently.Someothercompressionprogramsusedictionariesinthedictionary,whichmakesthemperformwellwhencompressinglargefiles,buttheyarenotefficientwhencompressingsmallerfiles.Althoughallcompressionprogramsinthiscategoryarebasedonthesamebasicidea,theyareimplementedindifferentways.Programdevelopersarealwaystryingtoestablishabettercompressionmechanism.

Relatedintroduction

ThecompressedfilesdownloadedfromtheInternetarelikelytocontainviruses.Itisbesttoscanthembeforeopeningthem.

ThewinrarsoftwarecanalsoThecompressedfileinrarorzipformatisconvertedtoaself-extractingformatinexeformat.Thecompressedfileismuchsmallerthantheoriginalfile.Thedefaultsettingis59%oftheoriginalsize.Youcanalsosetityourselfaccordingtoyouractualsituation.

Actually,winrarhasnothingtodowithcompressionorcompression.Therearemanysimilarsoftwareonthemarket.7zipisagoodchoice,allofwhichsupportself-extractingformat,thecompressionrateishigherthanrar,anditisfree.

Related Articles
TOP