由买买提看人间百态

boards

本页内容为未名空间相应帖子的节选和存档,一周内的贴子最多显示50字,超过一周显示500字 访问原贴
CS版 - Algorithm - Hash Question??
相关主题
标识符真的不能带空格么?Wiki 战争(修改版)
How to organize the algorithm换个话题,当你发现一个牛顿级别的学霸错了,你该怎么办? (转载)
Algorithm 课程及教材选择疑问 (转载)算法问题,找出现频率最高的元素
关于计算机算法杂志ask a fortran question
question about google algorithm/architecture (转载)NP
滕尚华荣获2008年ACM理论计算机哥德尔(Godel)奖贴一道take home的面试题
Fulkerson Prize, Godel Prize,印度人得的不少啊a quick question about integer programming
Godel's Lost Paper to Neuman(zz) Count the number of ON bits in an integer.
相关话题的讨论汇总
话题: question话题: hash话题: algorithm话题: integers话题: hi
进入CS版参与讨论
1 (共1页)
p********0
发帖数: 186
1
Hi,
I have 5 integers, I want a function to unique map these 5 integers to 1
integer.
1, 2, 3, 4, 5
should have a different key
than 2, 3, 4, 5, 1
so simple summation would not work.
p********0
发帖数: 186
2
To make my question more clear,
five integers
x_[1}, x_{2}, ,,, x_{5}
s*****g
发帖数: 5159
3
Say you have five numbers, x1, x2, ..., x5。
let p1, p2, p3 .... be prime number in sequential increasing number.
x = p1^x1+p2^x2+......
This is a one-one perfect mapping.
Google Godel number.

【在 p********0 的大作中提到】
: Hi,
: I have 5 integers, I want a function to unique map these 5 integers to 1
: integer.
: 1, 2, 3, 4, 5
: should have a different key
: than 2, 3, 4, 5, 1
: so simple summation would not work.

j****a
发帖数: 1277
4
good one. will x = \sum_i (i*x_i) work?

【在 s*****g 的大作中提到】
: Say you have five numbers, x1, x2, ..., x5。
: let p1, p2, p3 .... be prime number in sequential increasing number.
: x = p1^x1+p2^x2+......
: This is a one-one perfect mapping.
: Google Godel number.

D****A
发帖数: 360
5
理论上没问题,实际计算很快就溢出

【在 s*****g 的大作中提到】
: Say you have five numbers, x1, x2, ..., x5。
: let p1, p2, p3 .... be prime number in sequential increasing number.
: x = p1^x1+p2^x2+......
: This is a one-one perfect mapping.
: Google Godel number.

q*******i
发帖数: 353
6
实际计算很快就溢出,是什么意思。

【在 D****A 的大作中提到】
: 理论上没问题,实际计算很快就溢出
1 (共1页)
进入CS版参与讨论
相关主题
Count the number of ON bits in an integer.question about google algorithm/architecture (转载)
请教几个算法题, 第一个滕尚华荣获2008年ACM理论计算机哥德尔(Godel)奖
紧急求助!Stochastic Integer Programming (转载)Fulkerson Prize, Godel Prize,印度人得的不少啊
Obama Google Onsite QuestionGodel's Lost Paper to Neuman(zz)
标识符真的不能带空格么?Wiki 战争(修改版)
How to organize the algorithm换个话题,当你发现一个牛顿级别的学霸错了,你该怎么办? (转载)
Algorithm 课程及教材选择疑问 (转载)算法问题,找出现频率最高的元素
关于计算机算法杂志ask a fortran question
相关话题的讨论汇总
话题: question话题: hash话题: algorithm话题: integers话题: hi