版權(quán)說明:本文檔由用戶提供并上傳,收益歸屬內(nèi)容提供方,若內(nèi)容存在侵權(quán),請進(jìn)行舉報或認(rèn)領(lǐng)
文檔簡介
1、,an introductionto computer science,計算機科學(xué)引論,xiang, hui shandong university,2,chapter 12: theory of computation,12.1 functions and their computation 12.2 turing machines 12.3 universal programming languages 12.4 a noncomputable function 12.5 complexity of problems 12.6 public-key cryptography,3,funct
2、ions,function: a correspondence between a collection of possible input values and a collection of possible output values so that each possible input is assigned a single output,4,functions (continued),computing a function: determining the output value associated with a given set of input values nonc
3、omputable function: a function that cannot be computed by any algorithm,5,figure 12.1 an attempt to display the function that converts measurements in yards into meters,6,figure 12.2 the components of a turing machine,7,turing machine operation,inputs at each step state value at current tape positio
4、n actions at each step write a value at current tape position move read/write head change state,8,figure 12.3 a turing machine for incrementing a value,9,church-turing thesis,the functions that are computable by a turing machine are exactly the functions that can be computed by any algorithmic means
5、.,10,universal programming language,a language with which a solution to any computable function can be expressed examples: “bare bones” and most popular programming languages,11,the bare bones language,bare bones is a simple, yet universal language. statements clear name; incr name; decr name; while
6、 name not 0 do; end;,12,figure 12.4 a bare bones program for computing x x y,13,figure 12.5 a bare bones implementation of the instruction “copy today to tomorrow”,14,the halting problem,given the encoded version of any program, return 1 if the program is self-terminating, or 0 if the program is not
7、.,15,figure 12.6 testing a program for self-termination,16,figure 12.7 proving the unsolvability of the halting program,17,complexity of problems,time complexity: the number of instruction executions required unless otherwise noted, “complexity” means “time complexity.” a problem is in class o(f(n)
8、if it can be solved by an algorithm in q(f(n). a problem is in class q(f(n) if the best algorithm to solve it is in class q(f(n).,18,figure 12.8 a procedure mergelists for merging two lists,19,figure 12.9 the merge sort algorithm implemented as a procedure mergesort,20,figure 12.10 the hierarchy of
9、problems generated by the merge sort algorithm,21,figure 12.11 graphs of the mathematical expressions n, lg n, n lg n, and n2,22,p versus np,class p: all problems in any class q(f(n), where f(n) is a polynomial class np: all problems that can be solved by a nondeterministic algorithm in polynomial t
10、ime nondeterministic algorithm = an “algorithm” whose steps may not be uniquely and completely determined by the process state whether the class np is bigger than class p is currently unknown.,23,figure 12.12 a graphic summation of the problem classification,24,public-key cryptography,key: a value u
11、sed to encrypt or decrypt a message public key: used to encrypt messages private key: used to decrypt messages rsa: a popular public key cryptographic algorithm relies on the (presumed) intractability of the problem of factoring large numbers,25,encrypting the message 10111,encrypting keys: n = 91 and e = 5 10111two = 23ten 23e = 235 = 6,436,343 6,436,343 91 has a remainder of 4 4ten = 100two therefore, encrypted version of 10111 is 100.,26,decrypting the message 100,decrypting keys: d = 29, n = 91 100two = 4ten 4d = 429 = 288,230,376,151,711,744 288,230,376,151,711,744 91 ha
溫馨提示
- 1. 本站所有資源如無特殊說明,都需要本地電腦安裝OFFICE2007和PDF閱讀器。圖紙軟件為CAD,CAXA,PROE,UG,SolidWorks等.壓縮文件請下載最新的WinRAR軟件解壓。
- 2. 本站的文檔不包含任何第三方提供的附件圖紙等,如果需要附件,請聯(lián)系上傳者。文件的所有權(quán)益歸上傳用戶所有。
- 3. 本站RAR壓縮包中若帶圖紙,網(wǎng)頁內(nèi)容里面會有圖紙預(yù)覽,若沒有圖紙預(yù)覽就沒有圖紙。
- 4. 未經(jīng)權(quán)益所有人同意不得將文件中的內(nèi)容挪作商業(yè)或盈利用途。
- 5. 人人文庫網(wǎng)僅提供信息存儲空間,僅對用戶上傳內(nèi)容的表現(xiàn)方式做保護(hù)處理,對用戶上傳分享的文檔內(nèi)容本身不做任何修改或編輯,并不能對任何下載內(nèi)容負(fù)責(zé)。
- 6. 下載文件中如有侵權(quán)或不適當(dāng)內(nèi)容,請與我們聯(lián)系,我們立即糾正。
- 7. 本站不保證下載資源的準(zhǔn)確性、安全性和完整性, 同時也不承擔(dān)用戶因使用這些下載資源對自己和他人造成任何形式的傷害或損失。
最新文檔
- 2026年岳陽樓區(qū)衛(wèi)健系統(tǒng)事業(yè)單位公開招聘工作人員23人備考題庫含答案詳解
- 2025年紹興市上虞區(qū)中醫(yī)醫(yī)院醫(yī)共體公開招聘編外人員備考題庫(三)有答案詳解
- 2026年《中國文化報》社有限公司招聘備考題庫含答案詳解
- 2026年國家空間科學(xué)中心空間環(huán)境探測重點實驗室硬件測試人員招聘備考題庫及一套完整答案詳解
- 2026年天津醫(yī)科大學(xué)總醫(yī)院導(dǎo)診員崗位(北方輔醫(yī)外包項目)招聘備考題庫及一套參考答案詳解
- 2026年中國瑞達(dá)投資發(fā)展集團(tuán)有限公司招聘備考題庫含答案詳解
- 銀行電信詐騙內(nèi)控制度
- 日本內(nèi)控制度
- 支付公司內(nèi)控制度
- 民政局內(nèi)控制度
- DB54∕T 0527-2025 西藏自治區(qū)好住宅技術(shù)標(biāo)準(zhǔn)
- 人形機器人數(shù)據(jù)訓(xùn)練中心項目規(guī)劃設(shè)計方案
- 2026年內(nèi)蒙古化工職業(yè)學(xué)院單招職業(yè)適應(yīng)性考試題庫帶答案
- 2025年教育系統(tǒng)教師年度考核的個人工作總結(jié)
- 2025年留置看護(hù)考試題庫及答案
- 2025民航華東空管局畢業(yè)生招聘58人筆試歷年參考題庫附帶答案詳解
- 《怎樣選材》課件
- 2025年四川省甘孜教師職稱考試(理論知識)在線模擬題庫及答案
- 2025四川綿陽市江油鴻飛投資(集團(tuán))有限公司招聘40人(公共基礎(chǔ)知識)測試題附答案解析
- 2026年河南省職業(yè)病診斷醫(yī)師資格(塵肺病類)高分突破必練試題庫(含答案)
- 2026年浙江高考英語題庫及答案
評論
0/150
提交評論