merge sort give a set S of n integers and another integer x, determine whether or not there exits two elements in S whose sum is exactly x.
标签: determine integers another integer
上传时间: 2013-12-23
上传用户:xmsmh
附录MATLAB 图像处理命令 1.applylut 功能: 在二进制图像中利用lookup 表进行边沿操作。 语法: A = applylut(BW,lut) 举例 lut = makelut( sum(x(:)) == 4 ,2) BW1 = imread( text.tif ) BW2 = applylut(BW1,lut) imshow(BW1) figure, imshow(BW2) 相关命令: makelut 2.bestblk 功 举例
标签: applylut lut MATLAB lookup
上传时间: 2015-09-08
上传用户:gundamwzc
使用到的参数跟谈到弹性网络的那一章里头所讲的是一样的, ke 则是终止条件。如果 step 被打勾,则程式在每一步之间会暂停 100毫秒(或其他使用者输入的数值)。如果 Random 被打勾,则程式会以系统时间作为乱数产生器的种子数,否则,就以使用者输入的数( Random 右边那一格)为种子数。 你可以利用 load 来载入推销员问题档与其最佳解,如此便可比较弹性网络所找出来的解与最佳解差了多少。 Central, Radius, and Error 这三个参数的前两个,只影响弹性网络的起使位置和大小,对求解没有影响。第三个参数代表城市与网络点之间的容忍距离,也就是说,如果某城市与某网络点之间的距离,小于容忍距离,那就把这个城市当成是被该网络点所拜访。 按下小 w按钮会将目前的结果与参数值写到“en.out”这个档案。使得我们可以很方便地来比较不同参数的效果。
上传时间: 2013-12-17
上传用户:84425894
Distribution generator Here is a simple generator which can build some distributions with given properties. Distributions generator (compile with -lm) Typical use might be: ./distributions -u -m 1 -M 10 -n 100 -s 500 Generates a distribution of 100 uniform random numbers between 1 and 10, such that the sum of numbers is 500. ./distributions -p -2.2 -m 1 -M 100 -n 200 -s 500 Idem with 200 numbers between 1 and 100 following a power law with exponent -
标签: generator distributions Distribution simple
上传时间: 2014-01-27
上传用户:sammi
Implement the step 2 of two-level logic minimization. Our goal is to find the minimum (exact minimum) sum-of-products expression for a given function.
标签: minimization Implement the two-level
上传时间: 2014-01-09
上传用户:无聊来刷下
从Keil C51 的内存空间管理方式入手,着重讨论实时操作系统在任务调度时的重入问题,分析一些解决 重入的基本方式与方法:分析实时操作系统任务调度的占先性,提出非占先的任务调度是能更适合于 Keil C51 的一种调度方式。为此,构造这一实时操作系统,并有针对性地介绍此系统的堆管理方法、任务 的建立以及任务的切换等。
上传时间: 2013-12-26
上传用户:84425894
We have a group of N items (represented by integers from 1 to N), and we know that there is some total order defined for these items. You may assume that no two elements will be equal (for all a, b: a<b or b<a). However, it is expensive to compare two items. Your task is to make a number of comparisons, and then output the sorted order. The cost of determining if a < b is given by the bth integer of element a of costs (space delimited), which is the same as the ath integer of element b. Naturally, you will be judged on the total cost of the comparisons you make before outputting the sorted order. If your order is incorrect, you will receive a 0. Otherwise, your score will be opt/cost, where opt is the best cost anyone has achieved and cost is the total cost of the comparisons you make (so your score for a test case will be between 0 and 1). Your score for the problem will simply be the sum of your scores for the individual test cases.
标签: represented integers group items
上传时间: 2016-01-17
上传用户:jeffery
To date tests are still the best solution mankind has found to deliver working software. This book is the sum of four years of research and practice in the testing field. The practice comes from my IT consulting background, first at Octo Technology and then at Pivolis the research comes from my involvement with open source development at night and on weekends.
标签: solution software mankind deliver
上传时间: 2014-01-11
上传用户:sclyutian
针对Silicon labs的C8051F020 mcu 的全双工SPI调试主器件部分程序,对其接收到的从器件(也是F020mcu)的数据包会从串口1中发送至PC,从串口助手中可以看到.开发环境为KeilC,需要U-EC3仿真器下载至mcu中,方可调试.
标签: C8051F020 mcu Silicon F020
上传时间: 2014-01-08
上传用户:yuzsu
本文档提供JSR120无线消息API规范的说明,也描述Sum的RI的API.
上传时间: 2014-12-07
上传用户:baitouyu