-
0
说明: 给定n种物品和一个背包,物品i的重量是Wi,价值是vi,被包容量是C,应该如何选择装入被包的物品,使得装入背包中物品的总价值最大?对于每种物品i,只有两种选择,装入或者不装入.
输入:第一行两个正整数n(物品数)和C(容量)
第二行n个正整数n,表示物品价值
第三行n个正整数n,表示物品重量
输出:第一行表示总价值
第二行n个数(0/1),0表示物品不装入,1表示装入
例如,
输入:
5 10
6 3 5 4 6
2 2 6 5 4
输出
15
1 1 0 0 1
(Species of a given n items and a backpack, the weight of item i is Wi, the value of vi, was packet capacity is C, should be how to choose a package of items to be loaded, the backpack load in the largest total value of goods? For each item i, there are only two options, loaded or not loaded. Input: the first line of the two positive integer n (the number of items) and C (capacity) of the second line of n positive integer n, that the value of the third line of n positive integer n, that the weight of output: the total value of the first line of the second line, said n number of (0/1), 0 that the items do not load, that load 1 for example, enter: 5,106,354,622 6 5 4 output 15 1 1 0 0 1)
- 2009-07-01 23:07:01下载
- 积分:1
-
guangfubingwangxitong
实用光伏并网系统、MATLAB/Simulink模型、、、、(Practical photovoltaic grid connected system, MATLAB/Simulink model,,,,)
- 2016-05-25 11:03:38下载
- 积分:1
-
stroke-width
说明: 根据签名骨架和二值签名,提取了签名图像的笔划宽度直方图。(extracte the stroke width historgram of signature images)
- 2011-03-23 01:25:11下载
- 积分:1
-
tezhengtiqu
用matlab程序对正常和故障的风电机组振动信号进行特征提取,提取时域的16个特征值(Using matlab program for normal and faulty wind turbine vibration signal feature extraction, extraction time domain 16 eigenvalues)
- 2015-03-26 22:42:08下载
- 积分:1
-
qiantanzuihuafangfadefazhanjiqiyouhuaruanjian
本文描述了最优化问题的基本概念、分类和通常的求解方法,全局最优化在特定领域里德最近发展,同时简单介绍了几个优化软件(This paper describes the basic concepts of optimization problems, classification and the usual method for solving global optimization of recent developments in specific areas Reid also introduced a few simple optimization software)
- 2010-10-05 14:44:56下载
- 积分:1
-
dct
DCT图像压缩算法。1.图象进行归一化 2.显示系数图象 3.重构及显示图象 4.显示误差图象 5.计算归一化图象的均方误差 (DCT image compression algorithm. 1. Images were normalized 2. Shows coefficient image 3. Reconstruction and display of images 4. Show the error images 5. Calculated normalized mean square error of image)
- 2010-06-02 11:30:28下载
- 积分:1
-
deriv2
这是一个压缩奇异值分解算法。该算法将一个矩阵进行奇异值分解。CSVD Compact singular value decomposition(This is a compression algorithm for singular value decomposition. The algorithm is a matrix singular value decomposition. CSVD Compact singular value decomposition)
- 2011-09-10 00:04:31下载
- 积分:1
-
source
输入信号为方波信号+高斯白噪声,方波信号基 频为1kHz,幅值为1,高斯白噪声方差为0.2, 均值为0,采样频率为20kHz。试用周期图法和 ARMA谱估计法(SVD-TLS)估计此信号的功率 谱,并分析比较其结果(The input signal is a square wave signal+ Gaussian white noise, square wave signal fundamental frequency 1kHz, amplitude is a Gaussian white noise variance is 0.2, the mean is 0, the sampling frequency is 20kHz. Try periodogram and ARMA spectral estimation method (SVD-TLS) estimate the power spectrum of this signal, and the analysis and comparison of the results)
- 2013-10-29 17:49:35下载
- 积分:1
-
matlab
通信工程基于Matlab仿真,用于基础的通信模型的设计以及仿真,图像显示更为直观。(Communication Engineering Simulation Based on Matlab)
- 2013-04-24 17:45:08下载
- 积分:1
-
polysimu1
10-channel polyphase filter的simulink程序(10-channel polyphase filter the simulink program)
- 2007-10-10 10:01:19下载
- 积分:1