DirectFB is a thin library that provides hardware graphics acceleration, input device handling and abstraction, integrated windowing system with support for translucent windows and multiple display layers on top of the Linux Framebuffer Device.
1) Write a function reverse(A) which takes a matrix A of arbitrary dimensions as input and returns a matrix B consisting of the columns of A in reverse order. Thus for example, if
A = 1 2 3 then B = 3 2 1
4 5 6 6 5 4
7 8 9 9 8 7
Write a main program to call reverse(A) for the matrix A = magic(5). Print to the screen both A and reverse(A).
2) Write a program which accepts an input k from the keyboard, and which prints out the smallest fibonacci number that is at least as large as k. The program should also print out its position in the fibonacci sequence. Here is a sample of input and output:
Enter k>0: 100
144 is the smallest fibonacci number greater than or equal to 100.
It is the 12th fibonacci number.
北京大學ACM比賽題目
Write a program to read four lines of upper case (i.e., all CAPITAL LETTERS) text input (no more than 72 characters per line) from the input file and print a vertical histogram that shows how many times each letter (but not blanks, digits, or punctuation) appears in the all-upper-case input. Format your output exactly as shown.
PlotSphereIntensity(azimuth, elevation)
PlotSphereIntensity(azimuth, elevation, intensity)
h = PlotSphereIntensity(...)
Plots the intensity (as color) of a number of points on a unit sphere.
Input:
azimuth (phi), in degrees
elevation (theta), in degrees
intensity (optional, if not provided, a green sphere is produced)
All inputs must be vectors or matrices of the same size. Data does not have to be evenly spaced. When there aren t enough points to draw a smooth sphere, additional points (with color) are interpolated.
Output:
h - a handle to the patch object
The axes are also plotted:
positive x axis is red
positive y axis is green
positive z axis is blue
The neuro-fuzzy software for identification and data analysis has been implemented in the MATLAB language ver. 4.2.
The software trains a fuzzy architecture, inspired to Takagi-Sugeno approach, on the basis of a training set of N (single) output-(multi) input samples.
The returned model has the form
1) if input1 is A11 and input 2 is A12 then output =f1(input1,input2)
2) if input1 is A21 and input 2 is A22 then output =f2(input1,input2)
看不懂,據高手說,非常有用。
vhdl編寫,8b—10b 編解碼器設計
Encoder:
8b/10b Encoder (file: 8b10b_enc.vhd)
Synchronous clocked inputs (latched on each clock rising edge)
8-bit parallel unencoded data input
KI input selects data or control encoding
Asynchronous active high reset initializes all logic
Encoded data output
10-bit parallel encoded output valid 1 clock later
Decoder:
8b/10b Decoder (file: 8b10b_dec.vhd)
Synchronous clocked inputs (latched on each clock rising edge)
10-bit parallel encoded data input
Asynchronous active high reset initializes all logic
Decoded data, disparity and KO outputs
8-bit parallel unencoded output valid 1 clock later