Тёмный

UHCL 36a Graduate Database Course - Linear Hashing - Part 1 

GaryBoetticher
Подписаться 6 тыс.
Просмотров 79 тыс.
50% 1

Опубликовано:

 

28 сен 2024

Поделиться:

Ссылка:

Скачать:

Готовим ссылку...

Добавить в:

Мой плейлист
Посмотреть позже
Комментарии : 49   
@TheKoffrig
@TheKoffrig 12 лет назад
Quite a wonderful set of tutorials. Sadly, not many professors have your gift of being able to explain these (not so hard after all) concepts. Many thanks!
@KonstantinosKonstantinidis1993
@KonstantinosKonstantinidis1993 10 лет назад
I think that in 5:13 he meant "10 mod 4" not "10 mod 2"
@EvanCarrollTheGreat
@EvanCarrollTheGreat 6 лет назад
I think what may be throwing people for a loop is the property of modulo. If you don't get that you won't be getting this video. Notice if something is %2=0, there is only a 50% chance (avg) that is %4=0. So by adding another bucket that is twice the factor of the previous modulo, in the process you split the modulo. Note: something can be crafted that doesn't. For instance, what would happen if you inserted 256 (divisible by 0,2,4,8,16,32,64,128), 10 times. I assume you'd split until you were under the capacity, and then you'd have a few overflow buckets for a long time. Really cool video. I'm local in Houston. Definitely want to meet sometime.
@themisscoolmia
@themisscoolmia 12 лет назад
Dr.Boetticher you are an amazing teacher!!Thank you for uploading videos like these...
@chaconne221
@chaconne221 10 лет назад
Studying for finals and this definitely helps! Thank you!
@mcanorhan
@mcanorhan 12 лет назад
as far as i know you determine the function to use according to n, the bucket to be split. specifically you first check appropriate number of last bits which is largest k that satisfies # buckets >= 2^k. In that case it is 1 since there are 3 buckets. Then you check last k bits. If it is smaller than n you consider last k+1 bits for the function, ow you consider last k bits as the function. In this case n=1 so if last bit is 0, use last 2 bits 2 hash. ow use last bit to hash.
@DeepakS64
@DeepakS64 11 лет назад
I did not understand why you took mod2 in the first split. Please help.
@axkibe
@axkibe 13 лет назад
He says you need to check all elements if they fall into the new bucket. But IMHO the key idea to linear hashing is you do not have to check all elements in case of a split. You only need to redistribute the elements in the Bucket (including its overflows) which is splitted. Otherwise the table would get much slower the larger it gets.
@bmgag19
@bmgag19 10 лет назад
so when he first hashes, he does 10 mod 2 because there are 2 buckets. that makes sense. but then when he needs to split and rehash, he does mod 4 on the first bucket, mod 2 on the second bucket, and mod 4 on the last bucket. why does he do this? why doesn't he do mod 3 for all the buckets because now there are 3 buckets?
@rohandas4395
@rohandas4395 9 лет назад
+bmgag19 Because then he'd have to rehash not just the elements in the bucket that was split, but *all* the elements in the table in its entirety. That's slow. At least, that's my understanding.
@vimanyuaggarwal1420
@vimanyuaggarwal1420 8 лет назад
The records originally in bucket 0 are distributed between the two buckets based on a different hashing function hi+1(K) = K mod 2M --- quoted from Ramez Elmasri
@JJBeatiful
@JJBeatiful 11 лет назад
Great video on linear hashing, definitely made it a lot more clear for me, much thanks.
@disculpa
@disculpa 13 лет назад
how do you know which hash function to use? After he adds 10 and there are buckets 0-2 he says bucket 0 and 2 use mod4 but bucket 1 still uses mod2. How do you know which hash function to use before you actually hash it....?
@elgoooooooooog
@elgoooooooooog 11 лет назад
at 5:09, in bucket 0, what if the 10 were a 11? 11 mod 4 remains 3, but the bucket id is up to 2, where to put 11 in this case?
@1ma4ighter
@1ma4ighter 13 лет назад
hey Gary, great video, i'm doin some late studying and this video helped majorly, i'm from south africa btw, there's just one thing i don't understand though :: i AM writing this evening after work but i'd still like to know: - innitially we would calculate the position of the value to add using (v mod 2), after the split happened the n pointer moved on bucket down and the value to mod with increased (2fold | by2)? ie: 4, but remained the same for the bucket to split ie: 2.
@danielng6799
@danielng6799 5 лет назад
Thanks for this video! Really helped me understand the concept!
@danamuise4117
@danamuise4117 8 лет назад
so mod 2 determines placement, sorted by odds & evens??
@joeblade2976
@joeblade2976 3 года назад
very clear explanation. way better than the paper and my teacher XD
@DarkScionify
@DarkScionify 11 лет назад
actually the formula for this mod 2 to mod 4 change is: k mod (Nx 2^L) N is the number of buckets (doesnt change after split) and L (Level) shows how much this file is doubled. So in this case after the first split L = 1 which means: k mod (2x2) -> k mod 4
@neerajagrawal586
@neerajagrawal586 6 лет назад
according to this logic after the second slipt it shoudve been l=2 and 2^2 =4 MEANING 2*4 = 8 but it didn't change.
@saeshd
@saeshd 11 лет назад
freaking amazing, he should like the best teacher of youtube!!!
@starless9
@starless9 10 лет назад
much clearer- thank you!
@Ben-rc9br
@Ben-rc9br 8 лет назад
Nice explanation. Thanks.
@apoorvabansal587
@apoorvabansal587 8 лет назад
Awesome! Thanks a lot!
@jQrgen
@jQrgen 10 лет назад
BEST VIDEO EVER
@bmgag19
@bmgag19 10 лет назад
There are just too many unexplained things in this video. I don't get how this is getting so many thumbs ups.
@PersianMG
@PersianMG 9 лет назад
This is at least 200 times better than my lectures slides.
@paulalwin91
@paulalwin91 7 лет назад
This video is quite good.
@EvanCarrollTheGreat
@EvanCarrollTheGreat 6 лет назад
Nothing is perfect. There is no perfect lesson for every student. Feel free to ask a question. And if you think something is explained elsewhere better please clue us off and bask in the upvotes.
@CvDb-mt4dl
@CvDb-mt4dl 7 лет назад
Thank you very much..!!!
@Xivilian
@Xivilian 10 лет назад
thanks a lot!
@anasonmania
@anasonmania 7 лет назад
dayı büyüksün thanks a lot!
@pradeeshbm5558
@pradeeshbm5558 3 месяца назад
Anyone from 2024?
@Cr3aHalO
@Cr3aHalO 8 лет назад
Thank you for this video. I wasn't sure if I understood everything the first time in course but now it's cristal clear for me :) Thanks a lot!
@이남섭-m5s
@이남섭-m5s 9 лет назад
As below the guy, That's exactly what i dont understand too. I couldnt get it clear that why he did the mod 4 not mod 3 and even it is true, why he did not the mod 4 on the second bucket.
@weaklyinformative
@weaklyinformative 9 лет назад
In linear hashing, buckets are split one at a time. The change from mod 2 to mod 4 bears the idea that it is relevant to look at one more bit in the key, since we are splitting this bucket into 2 ( alpha mod 2 is the same as looking the least significant bit of alpha, while alpha mod 4 is the same as looking the 2 least significant bits in alpha).
@thirdlinesniper3279
@thirdlinesniper3279 Год назад
gary the goat
@gardmikael
@gardmikael 11 лет назад
great. but you dont really explain why you cange n, or why you change from mod 2 to mod 4. Is h(K) = K mod 2^i, where i is the number of splits you made? its a bit diffuse
@1ma4ighter
@1ma4ighter 13 лет назад
could you please tell me why or/and how they increase and when i would do it please, thanks
@FFRN00B
@FFRN00B 3 года назад
Good video. The splitting + rehashing step confused the hell out of me before this lol.
@stylersimon1
@stylersimon1 11 лет назад
15 mod 4 = 3 It has to go in bucket Nr.3, which is also missing
@cawker1984
@cawker1984 13 лет назад
Another lifesaver! Thanks again Gary and keep these great vids coming :)
@TheEir999
@TheEir999 4 года назад
why we reset next to zero? If someone can help me to this step
@sandhyasvivek
@sandhyasvivek 6 лет назад
Thank you so much... Very much useful
@mcanorhan
@mcanorhan 12 лет назад
Thank you for the video.
@seanpuptreacy
@seanpuptreacy 12 лет назад
You sir are a legend!
@dimitrischatziparaschis8164
@dimitrischatziparaschis8164 10 лет назад
really helpfull!!
@seatoot1991
@seatoot1991 12 лет назад
Merci:)
@KupiDante
@KupiDante 12 лет назад
Thanks you for this useful video
Далее
UHCL 35a Graduate Database Course - Extendible Hashing
9:54
Hash Tables and Hash Functions
13:56
Просмотров 1,6 млн
Linear Hashing - Data Structures
43:50
Просмотров 7 тыс.
Understanding and implementing a Hash Table (in C)
24:54
Extendible Hashing
7:29
Просмотров 223 тыс.
Linear Hashing - A dynamic Hashing technique.
43:44
Просмотров 12 тыс.
Hashing Algorithms and Security - Computerphile
8:12
Database Indexing for Dumb Developers
15:59
Просмотров 60 тыс.
Hashing - Part 1:  Linear Probing
7:21
Просмотров 78 тыс.