The algorith divides rows in to four equal groups. The rows are then used to from a distance graph which is then transformed into a matrix. girth of eight is maintained by avoiding six-cycles in the graph construction
標(biāo)簽: rows The algorith distance
上傳時(shí)間: 2014-01-15
上傳用戶:kelimu
This example sets up the PLL in x10/2 mode, divides SYSCLKOUT by six to reach a 25Mhz HSPCLK (assuming a 30Mhz XCLKIN). The clock divider in the ADC is not used so that the ADC will see the 25Mhz on the HSPCLK. Interrupts are enabled and the EVA is setup to generate a periodic ADC SOC on SEQ1. Two channels are converted, ADCINA3 and ADCINA2.
標(biāo)簽: SYSCLKOUT example divides HSPCLK
上傳時(shí)間: 2014-01-25
上傳用戶:ljt101007
浮點(diǎn)數(shù)基本運(yùn)算 浮點(diǎn)數(shù)的基本運(yùn)算主要有四則運(yùn)算、符號(hào)處理、大小比較,以及浮點(diǎn)數(shù)分柝等。 包含頭文件 "fn.hpp" #include "fn.hpp" 浮點(diǎn)數(shù)基本運(yùn)算 浮點(diǎn)數(shù)的基本運(yùn)算中有加、減、乘、除、取負(fù)、絕對(duì)值、相等比較等。 加減乘除 加、減、乘、除四個(gè)運(yùn)算極為相似,都是需要兩個(gè)參數(shù),結(jié)果當(dāng)然也是浮點(diǎn)數(shù)了。 例子: // 加 減 乘 除 btil::fn::plus<f1, f2>::value // f1+f2 的結(jié)果 btil::fn::minus<f1, f2>::value // f1-f2 的結(jié)果 btil::fn::multiplies<f1, f2>::value // f1*f2 的結(jié)果 btil::fn::divides<f1, f2>::value // f1/f2 的結(jié)果 plus<f1, f2>::value::f_val // f1+f2 的結(jié)果的值 struct one { static const double f_val = 1.0 } // 兩個(gè)浮點(diǎn)數(shù) struct two { static const double f_val = 2.0 } minus<two, plus<divides<one, two>::value, one>::value >::value::f_val == 0.5 取負(fù) 取負(fù)運(yùn)算就是取一個(gè)浮點(diǎn)數(shù)的負(fù)數(shù)。
標(biāo)簽: 浮點(diǎn)數(shù) 運(yùn)算 四則運(yùn)算 比較
上傳時(shí)間: 2014-12-06
上傳用戶:exxxds
自己用C編寫的小游戲,DOS界面哦,可以運(yùn)行。 浮點(diǎn)數(shù)基本運(yùn)算 浮點(diǎn)數(shù)的基本運(yùn)算主要有四則運(yùn)算、符號(hào)處理、大小比較,以及浮點(diǎn)數(shù)分柝等。 包含頭文件 "fn.hpp" #include "fn.hpp" 浮點(diǎn)數(shù)基本運(yùn)算 浮點(diǎn)數(shù)的基本運(yùn)算中有加、減、乘、除、取負(fù)、絕對(duì)值、相等比較等。 加減乘除 加、減、乘、除四個(gè)運(yùn)算極為相似,都是需要兩個(gè)參數(shù),結(jié)果當(dāng)然也是浮點(diǎn)數(shù)了。 例子: // 加 減 乘 除 btil::fn::plus<f1, f2>::value // f1+f2 的結(jié)果 btil::fn::minus<f1, f2>::value // f1-f2 的結(jié)果 btil::fn::multiplies<f1, f2>::value // f1*f2 的結(jié)果 btil::fn::divides<f1, f2>::value // f1/f2 的結(jié)果 plus<f1, f2>::value::f_val // f1+f2 的結(jié)果的值 struct one { static const double f_val = 1.0 } // 兩個(gè)浮點(diǎn)數(shù) struct two { static const double f_val = 2.0 } minus<two, plus<divides<one, two>::value, one>::value >::value::f_val == 0.5 取負(fù) 取負(fù)運(yùn)算就是取一個(gè)浮點(diǎn)數(shù)的負(fù)數(shù)。
上傳時(shí)間: 2014-12-06
上傳用戶:jichenxi0730
數(shù)字運(yùn)算,判斷一個(gè)數(shù)是否接近素?cái)?shù) A Niven number is a number such that the sum of its digits divides itself. For example, 111 is a Niven number because the sum of its digits is 3, which divides 111. We can also specify a number in another base b, and a number in base b is a Niven number if the sum of its digits divides its value. Given b (2 <= b <= 10) and a number in base b, determine whether it is a Niven number or not. Input Each line of input contains the base b, followed by a string of digits representing a positive integer in that base. There are no leading zeroes. The input is terminated by a line consisting of 0 alone. Output For each case, print "yes" on a line if the given number is a Niven number, and "no" otherwise. Sample Input 10 111 2 110 10 123 6 1000 8 2314 0 Sample Output yes yes no yes no
上傳時(shí)間: 2015-05-21
上傳用戶:daguda
參考網(wǎng)上的提供的代碼,我把uCosII移植到MSP430f149上,分三個(gè)任務(wù),分別是485通訊,鍵盤掃描,LED顯示,可供參考!- Refers to code which on-line provides, I transplant uCosII to MSP430f149 on, divides three duties, respectively is 485 communications, scanning, LED demonstrated
標(biāo)簽: on-line uCosII Refers which
上傳時(shí)間: 2013-12-11
上傳用戶:xieguodong1234
Input : A set S of planar points Output : A convex hull for S Step 1: If S contains no more than five points, use exhaustive searching to find the convex hull and return. Step 2: Find a median line perpendicular to the X-axis which divides S into SL and SR SL lies to the left of SR . Step 3: Recursively construct convex hulls for SL and SR. Denote these convex hulls by Hull(SL) and Hull(SR) respectively. Step 4: Apply the merging procedure to merge Hull(SL) and Hull(SR) together to form a convex hull. Time complexity: T(n) = 2T(n/2) + O(n) = O(n log n)
標(biāo)簽: contains Output convex planar
上傳時(shí)間: 2017-02-19
上傳用戶:wyc199288
cordic methods describe essentially the same algorithm that with suitably chosen inputs can be used to calculate a whole range of scientific functions including sin, cos, tan, arctan, arcsin, arccos, sinh, cosh, tanh, arctanh, log, exp, square root and even multiply and divide. the method dates back to volder [1959], and due to its versatility and compactness, it made possible the microcoding of the hp35 pocket scientific calculator in 1972. here is some code to illustrate the techniques. ive split the methods into three parts linear, circular and hyperbolic. in the hp35 microcode these would be unified into one function (for space reasons). because the linear mode can perform multiply and divide, you only need add/subtract and shift to complete the implementation. you can select in the code whether to do the multiples and divides also by cordic means. other multiplies and divides are all powers of 2 (these dont count). to eliminate these too, would involve ieee hackery.
標(biāo)簽: essentially algorithm describe suitably
上傳時(shí)間: 2017-03-02
上傳用戶:litianchu
蟲蟲下載站版權(quán)所有 京ICP備2021023401號(hào)-1