K-均值聚類算法的編程實現。包括逐點聚類和批處理聚類。K-均值聚類的的時間復雜度是n*k*m,其中n為樣本數,k為類別數,m為樣本維數。這個時間復雜度是相當客觀的。因為如果用每秒10億次的計算機對50個樣本采用窮舉法分兩類,尋找最優(yōu),列舉一遍約66.7天,分成3類,則要約3500萬年。針對算法局部最優(yōu)的缺點,本人正在編制模擬退火程序進行改進。希望及早奉給大家,傾聽高手教誨。
上傳時間: 2015-03-18
上傳用戶:yuanyuan123
此為編譯原理實驗報告 學習消除文法左遞規(guī)算法,了解消除文法左遞規(guī)在語法分析中的作用 內含 設計算法 目的 源碼 等等.... 算法:消除左遞歸算法為: (1)把文法G的所有非終結符按任一種順序排列成P1,P2,…Pn 按此順序執(zhí)行 (2)FOR i:=1 TO n DO BEGIN FOR j:=1 DO 把形如Pi→Pjγ的規(guī)則改寫成 Pi→δ1γ δ2γ … δkγ。其中Pj→δ1 δ2 … δk是關于Pj的所有規(guī)則; 消除關于Pi規(guī)則的直接左遞歸性 END (3)化簡由(2)所得的文法。即去除那些從開始符號出發(fā)永遠無法到達的非終結符的 產生規(guī)則。
上傳時間: 2015-03-29
上傳用戶:極客
算法介紹 矩陣求逆在程序中很常見,主要應用于求Billboard矩陣。按照定義的計算方法乘法運算,嚴重影響了性能。在需要大量Billboard矩陣運算時,矩陣求逆的優(yōu)化能極大提高性能。這里要介紹的矩陣求逆算法稱為全選主元高斯-約旦法。 高斯-約旦法(全選主元)求逆的步驟如下: 首先,對于 k 從 0 到 n - 1 作如下幾步: 從第 k 行、第 k 列開始的右下角子陣中選取絕對值最大的元素,并記住次元素所在的行號和列號,在通過行交換和列交換將它交換到主元素位置上。這一步稱為全選主元。 m(k, k) = 1 / m(k, k) m(k, j) = m(k, j) * m(k, k),j = 0, 1, ..., n-1;j != k m(i, j) = m(i, j) - m(i, k) * m(k, j),i, j = 0, 1, ..., n-1;i, j != k m(i, k) = -m(i, k) * m(k, k),i = 0, 1, ..., n-1;i != k 最后,根據在全選主元過程中所記錄的行、列交換的信息進行恢復,恢復的原則如下:在全選主元過程中,先交換的行(列)后進行恢復;原來的行(列)交換用列(行)交換來恢復。
上傳時間: 2015-04-09
上傳用戶:wang5829
Windows下讀寫硬件的工具. RW - Read & Write utility, for hardware engineers, firmware (BIOS) engineers, driver developers, QA engineers, performance test engineers, diagnostic engineers, etc., This utility access almost all the computer hardware, including PCI (PCI Express), PCI Index/Data, Memory, Memory Index/Data, I/O Space, I/O Index/Data, Super I/O, Clock Generator, DIMM SPD, SMBus Device, CPU MSR Registers, ATA/ATAPI Identify Data, ACPI Tables Dump (include AML decode), Embedded Controller, USB Information and LPT Remote Access. And also an Command Window is provided to access hardware manually.
標簽: engineers firmware hardware Windows
上傳時間: 2015-07-01
上傳用戶:xc216
RW - Read & Write utility, for hardware engineers, firmware (BIOS) engineers, driver developers, QA engineers, performance test engineers, diagnostic engineers, etc., This utility access almost all the computer hardware, including PCI (PCI Express), PCI Index/Data, Memory, Memory Index/Data, I/O Space, I/O Index/Data, Super I/O, Clock Generator, DIMM SPD, SMBus Device, CPU MSR Registers, ATA/ATAPI Identify Data, ACPI Tables Dump (include AML decode), Embedded Controller, USB Information and LPT Remote Access. And also an Command Window is provided to access hardware manually. Website1: http://rw.net-forces.com/ Website2: http://home.kimo.com.tw/ckimchan.tw/ Website3: http://jacky5488.myweb.hinet.net/ For best view, please change the screen resolution to 1024 x 768 (or above) pixels.
標簽: engineers developers firmware hardware
上傳時間: 2013-12-22
上傳用戶:王楚楚
給定n 個整數a ,a , ,an 1 2 組成的序列, a n i | |£ ,1 £ i £ n。如果對于i £ j ,有 0 = å = j k i k a ,則稱序列區(qū)間i i j a , a , , a +1 為一個零和區(qū)間,相應的區(qū)間長度為j-i+1。
上傳時間: 2015-07-23
上傳用戶:zhangzhenyu
給定n 個整數a ,a , ,an 1 2 組成的序列, a n i | |£ ,1 £ i £ n。如果對于i £ j ,有 0 = å = j k i k a ,則稱序列區(qū)間i i j a , a , , a +1 為一個零和區(qū)間,相應的區(qū)間長度為j-i+1。
上傳時間: 2013-12-21
上傳用戶:偷心的海盜
TV-tree的c實現源碼,對應原文章K.-I. Lin, H. V. Jagadish, C. Faloutsos: The TV-Tree: An Index Structure for High-Dimensional Data.
上傳時間: 2014-11-26
上傳用戶:lxm
This section contains a brief introduction to the C language. It is intended as a tutorial on the language, and aims at getting a reader new to C started as quickly as possible. It is certainly not intended as a substitute for any of the numerous textbooks on C. 2. write a recursive function FIB (n) to find out the nth element in theFibanocci sequence number which is 1,1,2,3,5,8,13,21,34,55,…3. write the prefix and postfix form of the following infix expressiona + b – c / d + e * f – g * h / i ^ j4. write a function to count the number of nodes in a binary tr
標簽: introduction the contains intended
上傳時間: 2013-12-23
上傳用戶:liansi
已知:Sn= 1+1/2+1/3+…+1/n。顯然對于任意一個整數K,當n足夠大的時候,Sn大于K。 現給出一個整數K(1<=k<=15),要求計算出一個最小的n;使得Sn>K。 Input 鍵盤輸入 k Output 屏幕輸出 n Sample Input 1 Sample Output 2 Source
上傳時間: 2014-01-25
上傳用戶:ruixue198909