際際滷

際際滷Share a Scribd company logo
2
1111 3333 1235 2378 1212 1456 2134 2345 1111 8231 2222 9999
00
01
10
11
g=2
l=2
l=2
l=2
l=2
global depth is 2
local depth is 2 and bucket size is 3
Most read
5
00
01
10
11
1111 3333 1235 2378 1212 1456 2134 2345 1111 8231 2222 9999
g=2
l=2
3333
l=2
l=2
1111
l=2
1235
010011
1235
11
Most read
12
1111 3333 1235 2378 1212 1456 2134 2345 1111 8231 2222 9999
000
001
010
011
g=3
1212 1456
l=2
3333 2345
l=2
2378 2134
l=2
1235
l=2
100
101
110
111
1111 1111 8211
l=3
l=3
9999
001111
111
Bucket overflow occurs again. As g = l,
directory structure should be doubled
again and same process will repeat.
Most read
Extendible Hashing
 Suppose that g=2 and bucket size = 3.
 Suppose that we have records with these keys and hash function
h(key) = key mod 64:
1111 23 010111
3333 5 000101
1235 19 010011
2378 10 001010
1212 60 111100
1456 48 110000
2134 22 010110
2345 41 101001
1111 23 010111
8231 39 100111
2222 46 101110
9999 15 001111
key h(key) = key mod 64 bit pattern
1111 3333 1235 2378 1212 1456 2134 2345 1111 8231 2222 9999
00
01
10
11
g=2
l=2
l=2
l=2
l=2
global depth is 2
local depth is 2 and bucket size is 3
1111 3333 1235 2378 1212 1456 2134 2345 1111 8231 2222 9999
00
01
10
11
g=2
l=2
l=2
l=2
l=2
1111
110111
11
1111
000101
00
01
10
11
1111 3333 1235 2378 1212 1456 2134 2345 1111 8231 2222 9999
g=2
l=2
l=2
l=2
1111
l=2
3333
01
3333
00
01
10
11
1111 3333 1235 2378 1212 1456 2134 2345 1111 8231 2222 9999
g=2
l=2
3333
l=2
l=2
1111
l=2
1235
010011
1235
11
1111 3333 1235 2378 1212 1456 2134 2345 1111 8231 2222 9999
00
01
10
11
g=2
1212 1456
l=2
3333 2345
l=2
2378 2134
l=2
1111 1235 1111
l=2
00
01
10
11
1111 3333 1235 2378 1212 1456 2134 2345 1111 8231 2222 9999
g=2
1212 1456
l=2
3333 2345
l=2
2378 2134
l=2
1111 1235 1111
l=2
8231
100111
11
Bucket overflow occurs. As g = l,
directory structure is doubled.
1111 3333 1235 2378 1212 1456 2134 2345 1111 8231 2222 9999
00
01
10
11
g=3
1212 1456
l=2
3333 2345
l=2
2378 2134
l=2
1111 1235 1111
l=2
00
01
10
11
1111 3333 1235 2378 1212 1456 2134 2345 1111 8231 2222 9999
000
001
010
011
g=3
1212 1456
l=2
3333 2345
l=2
2378 2134
l=2
l=2
100
101
110
111
l=3
l=3
1111 1235 1111
1111 3333 1235 2378 1212 1456 2134 2345 1111 8231 2222 9999
000
001
010
011
g=3
1212 1456
l=2
3333 2345
l=2
2378 2134
l=2
1235
l=2
100
101
110
111
1111 1111
l=3
l=3
8231
100111
111
8231
1111 3333 1235 2378 1212 1456 2134 2345 1111 8231 2222 9999
000
001
010
011
g=3
1212 1456
l=2
3333 2345
l=2
2378 2134
l=2
1235
l=2
100
101
110
111
1111 1111 8211
l=3
l=3
2222
101110
110
2222
1111 3333 1235 2378 1212 1456 2134 2345 1111 8231 2222 9999
000
001
010
011
g=3
1212 1456
l=2
3333 2345
l=2
2378 2134
l=2
1235
l=2
100
101
110
111
1111 1111 8211
l=3
l=3
9999
001111
111
Bucket overflow occurs again. As g = l,
directory structure should be doubled
again and same process will repeat.

More Related Content

What's hot (20)

12. Indexing and Hashing in DBMS
12. Indexing and Hashing in DBMS12. Indexing and Hashing in DBMS
12. Indexing and Hashing in DBMS
koolkampus
Knapsack problem using greedy approach
Knapsack problem using greedy approachKnapsack problem using greedy approach
Knapsack problem using greedy approach
padmeshagrekar
Map reduce in BIG DATA
Map reduce in BIG DATAMap reduce in BIG DATA
Map reduce in BIG DATA
GauravBiswas9
Code generation
Code generationCode generation
Code generation
Aparna Nayak
Critical section problem in operating system.
Critical section problem in operating system.Critical section problem in operating system.
Critical section problem in operating system.
MOHIT DADU
Knapsack Problem
Knapsack ProblemKnapsack Problem
Knapsack Problem
Jenny Galino
0 1 knapsack using branch and bound
0 1 knapsack using branch and bound0 1 knapsack using branch and bound
0 1 knapsack using branch and bound
Abhishek Singh
System Programming Unit II
System Programming Unit IISystem Programming Unit II
System Programming Unit II
Manoj Patil
Evolutionary models
Evolutionary modelsEvolutionary models
Evolutionary models
Pihu Goel
Informed and Uninformed search Strategies
Informed and Uninformed search StrategiesInformed and Uninformed search Strategies
Informed and Uninformed search Strategies
Amey Kerkar
Merge sort algorithm
Merge sort algorithmMerge sort algorithm
Merge sort algorithm
Shubham Dwivedi
Breadth First Search & Depth First Search
Breadth First Search & Depth First SearchBreadth First Search & Depth First Search
Breadth First Search & Depth First Search
Kevin Jadiya
Double Hashing.pptx
Double Hashing.pptxDouble Hashing.pptx
Double Hashing.pptx
VikasNirgude2
queue & its applications
queue & its applicationsqueue & its applications
queue & its applications
somendra kumar
Asymptotic Notation
Asymptotic NotationAsymptotic Notation
Asymptotic Notation
Protap Mondal
Planning in Artificial Intelligence
Planning in Artificial IntelligencePlanning in Artificial Intelligence
Planning in Artificial Intelligence
kitsenthilkumarcse
Lecture: Automata
Lecture: AutomataLecture: Automata
Lecture: Automata
Marina Santini
Simulated Annealing
Simulated AnnealingSimulated Annealing
Simulated Annealing
Joy Dutta
Segmentation in operating systems
Segmentation in operating systemsSegmentation in operating systems
Segmentation in operating systems
Dr. Jasmine Beulah Gnanadurai
Topological Sorting
Topological SortingTopological Sorting
Topological Sorting
ShahDhruv21
12. Indexing and Hashing in DBMS
12. Indexing and Hashing in DBMS12. Indexing and Hashing in DBMS
12. Indexing and Hashing in DBMS
koolkampus
Knapsack problem using greedy approach
Knapsack problem using greedy approachKnapsack problem using greedy approach
Knapsack problem using greedy approach
padmeshagrekar
Map reduce in BIG DATA
Map reduce in BIG DATAMap reduce in BIG DATA
Map reduce in BIG DATA
GauravBiswas9
Code generation
Code generationCode generation
Code generation
Aparna Nayak
Critical section problem in operating system.
Critical section problem in operating system.Critical section problem in operating system.
Critical section problem in operating system.
MOHIT DADU
Knapsack Problem
Knapsack ProblemKnapsack Problem
Knapsack Problem
Jenny Galino
0 1 knapsack using branch and bound
0 1 knapsack using branch and bound0 1 knapsack using branch and bound
0 1 knapsack using branch and bound
Abhishek Singh
System Programming Unit II
System Programming Unit IISystem Programming Unit II
System Programming Unit II
Manoj Patil
Evolutionary models
Evolutionary modelsEvolutionary models
Evolutionary models
Pihu Goel
Informed and Uninformed search Strategies
Informed and Uninformed search StrategiesInformed and Uninformed search Strategies
Informed and Uninformed search Strategies
Amey Kerkar
Breadth First Search & Depth First Search
Breadth First Search & Depth First SearchBreadth First Search & Depth First Search
Breadth First Search & Depth First Search
Kevin Jadiya
Double Hashing.pptx
Double Hashing.pptxDouble Hashing.pptx
Double Hashing.pptx
VikasNirgude2
queue & its applications
queue & its applicationsqueue & its applications
queue & its applications
somendra kumar
Asymptotic Notation
Asymptotic NotationAsymptotic Notation
Asymptotic Notation
Protap Mondal
Planning in Artificial Intelligence
Planning in Artificial IntelligencePlanning in Artificial Intelligence
Planning in Artificial Intelligence
kitsenthilkumarcse
Simulated Annealing
Simulated AnnealingSimulated Annealing
Simulated Annealing
Joy Dutta
Topological Sorting
Topological SortingTopological Sorting
Topological Sorting
ShahDhruv21

Viewers also liked (7)

Chapter13
Chapter13Chapter13
Chapter13
gourab87
Application of Stack - Yadraj Meena
Application of Stack - Yadraj MeenaApplication of Stack - Yadraj Meena
Application of Stack - Yadraj Meena
Dipayan Sarkar
stack presentation
stack presentationstack presentation
stack presentation
Shivalik college of engineering
Computer ethics
Computer ethicsComputer ethics
Computer ethics
onur karaman
Seminar algorithms of web
Seminar algorithms of webSeminar algorithms of web
Seminar algorithms of web
Stefanos Anastasiadis
Stack implementation using c
Stack implementation using cStack implementation using c
Stack implementation using c
Rajendran
4.4 external hashing
4.4 external hashing4.4 external hashing
4.4 external hashing
Krish_ver2
Chapter13
Chapter13Chapter13
Chapter13
gourab87
Application of Stack - Yadraj Meena
Application of Stack - Yadraj MeenaApplication of Stack - Yadraj Meena
Application of Stack - Yadraj Meena
Dipayan Sarkar
Computer ethics
Computer ethicsComputer ethics
Computer ethics
onur karaman
Stack implementation using c
Stack implementation using cStack implementation using c
Stack implementation using c
Rajendran
4.4 external hashing
4.4 external hashing4.4 external hashing
4.4 external hashing
Krish_ver2

Recently uploaded (7)

presentationnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnn
presentationnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnpresentationnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnn
presentationnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnn
AuroraCrudeli
喝愕悋喝悋悛悋惠喝悋慍正惘悋喝(悋惡惘悸喝悛喝惺惘悋)
喝愕悋喝悋悛悋惠喝悋慍正惘悋喝(悋惡惘悸喝悛喝惺惘悋)喝愕悋喝悋悛悋惠喝悋慍正惘悋喝(悋惡惘悸喝悛喝惺惘悋)
喝愕悋喝悋悛悋惠喝悋慍正惘悋喝(悋惡惘悸喝悛喝惺惘悋)
Qalb Salim T'alim Qur'an
惠愆悋惡悋惠 愕惘悸 悋 惺 愕悋 悋悋悧 惠惶 悖悛悽惘悋悋悋惠
惠愆悋惡悋惠 愕惘悸 悋 惺 愕悋 悋悋悧 惠惶 悖悛悽惘悋悋悋惠惠愆悋惡悋惠 愕惘悸 悋 惺 愕悋 悋悋悧 惠惶 悖悛悽惘悋悋悋惠
惠愆悋惡悋惠 愕惘悸 悋 惺 愕悋 悋悋悧 惠惶 悖悛悽惘悋悋悋惠
Qalb Salim T'alim Qur'an
Presentaci坦n Universitaria Trabajo de Fin de Grado Geom辿trico Minimalista Cre...
Presentaci坦n Universitaria Trabajo de Fin de Grado Geom辿trico Minimalista Cre...Presentaci坦n Universitaria Trabajo de Fin de Grado Geom辿trico Minimalista Cre...
Presentaci坦n Universitaria Trabajo de Fin de Grado Geom辿trico Minimalista Cre...
MirandaGonzlez12
Comprehensive Dictionary Of Ket Elizaveta Kotorova Andrey Nefedov Eds
Comprehensive Dictionary Of Ket Elizaveta Kotorova Andrey Nefedov EdsComprehensive Dictionary Of Ket Elizaveta Kotorova Andrey Nefedov Eds
Comprehensive Dictionary Of Ket Elizaveta Kotorova Andrey Nefedov Eds
wadudehnot0t
Essentials Of Vascular Surgery For The General Surgeon 1st Edition Vivian Gahtan
Essentials Of Vascular Surgery For The General Surgeon 1st Edition Vivian GahtanEssentials Of Vascular Surgery For The General Surgeon 1st Edition Vivian Gahtan
Essentials Of Vascular Surgery For The General Surgeon 1st Edition Vivian Gahtan
krkgtkuyp896
惠愆悋惡正悋惠喝喝愕惘悸喝悋悋惠忰悸喝悒喝喝愕惘悸喝悋悋悧惆悸
惠愆悋惡正悋惠喝喝愕惘悸喝悋悋惠忰悸喝悒喝喝愕惘悸喝悋悋悧惆悸惠愆悋惡正悋惠喝喝愕惘悸喝悋悋惠忰悸喝悒喝喝愕惘悸喝悋悋悧惆悸
惠愆悋惡正悋惠喝喝愕惘悸喝悋悋惠忰悸喝悒喝喝愕惘悸喝悋悋悧惆悸
Qalb Salim T'alim Qur'an
presentationnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnn
presentationnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnpresentationnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnn
presentationnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnn
AuroraCrudeli
喝愕悋喝悋悛悋惠喝悋慍正惘悋喝(悋惡惘悸喝悛喝惺惘悋)
喝愕悋喝悋悛悋惠喝悋慍正惘悋喝(悋惡惘悸喝悛喝惺惘悋)喝愕悋喝悋悛悋惠喝悋慍正惘悋喝(悋惡惘悸喝悛喝惺惘悋)
喝愕悋喝悋悛悋惠喝悋慍正惘悋喝(悋惡惘悸喝悛喝惺惘悋)
Qalb Salim T'alim Qur'an
惠愆悋惡悋惠 愕惘悸 悋 惺 愕悋 悋悋悧 惠惶 悖悛悽惘悋悋悋惠
惠愆悋惡悋惠 愕惘悸 悋 惺 愕悋 悋悋悧 惠惶 悖悛悽惘悋悋悋惠惠愆悋惡悋惠 愕惘悸 悋 惺 愕悋 悋悋悧 惠惶 悖悛悽惘悋悋悋惠
惠愆悋惡悋惠 愕惘悸 悋 惺 愕悋 悋悋悧 惠惶 悖悛悽惘悋悋悋惠
Qalb Salim T'alim Qur'an
Presentaci坦n Universitaria Trabajo de Fin de Grado Geom辿trico Minimalista Cre...
Presentaci坦n Universitaria Trabajo de Fin de Grado Geom辿trico Minimalista Cre...Presentaci坦n Universitaria Trabajo de Fin de Grado Geom辿trico Minimalista Cre...
Presentaci坦n Universitaria Trabajo de Fin de Grado Geom辿trico Minimalista Cre...
MirandaGonzlez12
Comprehensive Dictionary Of Ket Elizaveta Kotorova Andrey Nefedov Eds
Comprehensive Dictionary Of Ket Elizaveta Kotorova Andrey Nefedov EdsComprehensive Dictionary Of Ket Elizaveta Kotorova Andrey Nefedov Eds
Comprehensive Dictionary Of Ket Elizaveta Kotorova Andrey Nefedov Eds
wadudehnot0t
Essentials Of Vascular Surgery For The General Surgeon 1st Edition Vivian Gahtan
Essentials Of Vascular Surgery For The General Surgeon 1st Edition Vivian GahtanEssentials Of Vascular Surgery For The General Surgeon 1st Edition Vivian Gahtan
Essentials Of Vascular Surgery For The General Surgeon 1st Edition Vivian Gahtan
krkgtkuyp896
惠愆悋惡正悋惠喝喝愕惘悸喝悋悋惠忰悸喝悒喝喝愕惘悸喝悋悋悧惆悸
惠愆悋惡正悋惠喝喝愕惘悸喝悋悋惠忰悸喝悒喝喝愕惘悸喝悋悋悧惆悸惠愆悋惡正悋惠喝喝愕惘悸喝悋悋惠忰悸喝悒喝喝愕惘悸喝悋悋悧惆悸
惠愆悋惡正悋惠喝喝愕惘悸喝悋悋惠忰悸喝悒喝喝愕惘悸喝悋悋悧惆悸
Qalb Salim T'alim Qur'an

Extendible hashing

  • 1. Extendible Hashing Suppose that g=2 and bucket size = 3. Suppose that we have records with these keys and hash function h(key) = key mod 64: 1111 23 010111 3333 5 000101 1235 19 010011 2378 10 001010 1212 60 111100 1456 48 110000 2134 22 010110 2345 41 101001 1111 23 010111 8231 39 100111 2222 46 101110 9999 15 001111 key h(key) = key mod 64 bit pattern
  • 2. 1111 3333 1235 2378 1212 1456 2134 2345 1111 8231 2222 9999 00 01 10 11 g=2 l=2 l=2 l=2 l=2 global depth is 2 local depth is 2 and bucket size is 3
  • 3. 1111 3333 1235 2378 1212 1456 2134 2345 1111 8231 2222 9999 00 01 10 11 g=2 l=2 l=2 l=2 l=2 1111 110111 11 1111
  • 4. 000101 00 01 10 11 1111 3333 1235 2378 1212 1456 2134 2345 1111 8231 2222 9999 g=2 l=2 l=2 l=2 1111 l=2 3333 01 3333
  • 5. 00 01 10 11 1111 3333 1235 2378 1212 1456 2134 2345 1111 8231 2222 9999 g=2 l=2 3333 l=2 l=2 1111 l=2 1235 010011 1235 11
  • 6. 1111 3333 1235 2378 1212 1456 2134 2345 1111 8231 2222 9999 00 01 10 11 g=2 1212 1456 l=2 3333 2345 l=2 2378 2134 l=2 1111 1235 1111 l=2
  • 7. 00 01 10 11 1111 3333 1235 2378 1212 1456 2134 2345 1111 8231 2222 9999 g=2 1212 1456 l=2 3333 2345 l=2 2378 2134 l=2 1111 1235 1111 l=2 8231 100111 11 Bucket overflow occurs. As g = l, directory structure is doubled.
  • 8. 1111 3333 1235 2378 1212 1456 2134 2345 1111 8231 2222 9999 00 01 10 11 g=3 1212 1456 l=2 3333 2345 l=2 2378 2134 l=2 1111 1235 1111 l=2 00 01 10 11
  • 9. 1111 3333 1235 2378 1212 1456 2134 2345 1111 8231 2222 9999 000 001 010 011 g=3 1212 1456 l=2 3333 2345 l=2 2378 2134 l=2 l=2 100 101 110 111 l=3 l=3 1111 1235 1111
  • 10. 1111 3333 1235 2378 1212 1456 2134 2345 1111 8231 2222 9999 000 001 010 011 g=3 1212 1456 l=2 3333 2345 l=2 2378 2134 l=2 1235 l=2 100 101 110 111 1111 1111 l=3 l=3 8231 100111 111 8231
  • 11. 1111 3333 1235 2378 1212 1456 2134 2345 1111 8231 2222 9999 000 001 010 011 g=3 1212 1456 l=2 3333 2345 l=2 2378 2134 l=2 1235 l=2 100 101 110 111 1111 1111 8211 l=3 l=3 2222 101110 110 2222
  • 12. 1111 3333 1235 2378 1212 1456 2134 2345 1111 8231 2222 9999 000 001 010 011 g=3 1212 1456 l=2 3333 2345 l=2 2378 2134 l=2 1235 l=2 100 101 110 111 1111 1111 8211 l=3 l=3 9999 001111 111 Bucket overflow occurs again. As g = l, directory structure should be doubled again and same process will repeat.