Indexing & searching techniques in database

Embed Size (px)

Citation preview

  • 8/10/2019 Indexing & searching techniques in database

    1/19

    EL Online - IIT Bombay

    //C|/Documents%20and%20Settings/iitkrana1/My%20Documents/Google%20Talk%20Received%20Files/ist_data/lecture1/main.html[6/14/2012 3:12:20

    Course Name Indexing and Searching Techniques in Databases

    Department of Computer Science and Engineering

    InstructorDr. Arnab Bhattacharya

    http://www.cse.iitk.ac.in/users/arnabb/http://www.cse.iitk.ac.in/users/arnabb/
  • 8/10/2019 Indexing & searching techniques in database

    2/19

  • 8/10/2019 Indexing & searching techniques in database

    3/19

    ctives_template

    /C|/Documents%20and%20Settings/iitkrana1/My%20Documents/Google%20Talk%20Received%20Files/ist_data/lecture1/1_2.htm[6/14/2012 3:12:20 PM]

    Module 1: Basics and BackgroundLecture 1: Basic Database Queries

    General setting

    Database of objects

  • 8/10/2019 Indexing & searching techniques in database

    4/19

    ctives_template

    /C|/Documents%20and%20Settings/iitkrana1/My%20Documents/Google%20Talk%20Received%20Files/ist_data/lecture1/1_3.htm[6/14/2012 3:12:21 PM]

    Module 1: Basics and BackgroundLecture 1: Basic Database Queries

    General setting

    Database of objects

    Each object has dimensions

    No particular database design assumed

  • 8/10/2019 Indexing & searching techniques in database

    5/19

    ctives_template

    /C|/Documents%20and%20Settings/iitkrana1/My%20Documents/Google%20Talk%20Received%20Files/ist_data/lecture1/1_4.htm[6/14/2012 3:12:21 PM]

    Module 1: Basics and BackgroundLecture 1: Basic Database Queries

    General setting

    Database of objects

    Each object has dimensions

    No particular database design assumed

    Query is an object with the same dimensions

  • 8/10/2019 Indexing & searching techniques in database

    6/19

    ctives_template

    /C|/Documents%20and%20Settings/iitkrana1/My%20Documents/Google%20Talk%20Received%20Files/ist_data/lecture1/1_5.htm[6/14/2012 3:12:21 PM]

    Module 1: Basics and BackgroundLecture 1: Basic Database Queries

    Exact match query or Point query

    Point query: Given and , return all objects such that

  • 8/10/2019 Indexing & searching techniques in database

    7/19

    ctives_template

    /C|/Documents%20and%20Settings/iitkrana1/My%20Documents/Google%20Talk%20Received%20Files/ist_data/lecture1/1_6.htm[6/14/2012 3:12:21 PM]

    Module 1: Basics and BackgroundLecture 1: Basic Database Queries

    Exact match query or Point query

    Point query: Given and , return all objects such that

    The concept of equality (operator =) needs to be precisely defined

    For example, iff all the dimensions individually are the same,

    i.e.

  • 8/10/2019 Indexing & searching techniques in database

    8/19

    ctives_template

    /C|/Documents%20and%20Settings/iitkrana1/My%20Documents/Google%20Talk%20Received%20Files/ist_data/lecture1/1_7.htm[6/14/2012 3:12:21 PM]

    Module 1: Basics and BackgroundLecture 1: Basic Database Queries

    Exact match query or Point query

    Point query: Given and , return all objects such that

    The concept of equality (operator =) needs to be precisely defined

    For example, iff all the dimensions individually are the same,

    i.e.

    Equality can be defined over a subset of the dimensions as well

    For example ,

  • 8/10/2019 Indexing & searching techniques in database

    9/19

    ctives_template

    /C|/Documents%20and%20Settings/iitkrana1/My%20Documents/Google%20Talk%20Received%20Files/ist_data/lecture1/1_8.htm[6/14/2012 3:12:21 PM]

    Module 1: Basics and BackgroundLecture 1: Basic Database Queries

    Extended setting

    Database of objects

    Each object has dimensions

    Query is an object with the same dimensions

  • 8/10/2019 Indexing & searching techniques in database

    10/19

    ctives_template

    /C|/Documents%20and%20Settings/iitkrana1/My%20Documents/Google%20Talk%20Received%20Files/ist_data/lecture1/1_9.htm[6/14/2012 3:12:22 PM]

    Module 1: Basics and BackgroundLecture 1: Basic Database Queries

    Extended setting

    Database of objects

    Each object has dimensions

    Query is an object with the same dimensions

    Distance function between two objects

  • 8/10/2019 Indexing & searching techniques in database

    11/19

    ctives_template

    /C|/Documents%20and%20Settings/iitkrana1/My%20Documents/Google%20Talk%20Received%20Files/ist_data/lecture1/1_10.htm[6/14/2012 3:12:22 PM]

    Module 1: Basics and BackgroundLecture 1: Basic Database Queries

    Extended setting

    Database of objects

    Each object has dimensions

    Query is an object with the same dimensions

    Distance function between two objects

    If dimensions are defined, distance function can be, for example,Euclidean, Manhattan , etc.

    Can be over a subset of dimensions

  • 8/10/2019 Indexing & searching techniques in database

    12/19

    ctives_template

    /C|/Documents%20and%20Settings/iitkrana1/My%20Documents/Google%20Talk%20Received%20Files/ist_data/lecture1/1_11.htm[6/14/2012 3:12:22 PM]

    Module 1: Basics and BackgroundLecture 1: Basic Database Queries

    Extended setting

    Database of objects

    Each object has dimensions

    Query is an object with the same dimensions

    Distance function between two objects

    If dimensions are defined, distance function can be, for example,Euclidean, Manhattan , etc.

    Can be over a subset of dimensions

    Otherwise, can be a metric distance

  • 8/10/2019 Indexing & searching techniques in database

    13/19

    ctives_template

    /C|/Documents%20and%20Settings/iitkrana1/My%20Documents/Google%20Talk%20Received%20Files/ist_data/lecture1/1_12.htm[6/14/2012 3:12:22 PM]

    Module 1: Basics and BackgroundLecture 1: Basic Database Queries

    Extended setting

    Database of objects

    Each object has dimensions

    Query is an object with the same dimensions

    Distance function between two objects

    If dimensions are defined, distance function can be, for example,Euclidean, Manhattan , etc.

    Can be over a subset of dimensions

    Otherwise, can be a metric distance

    If is not a metric distance, then the problem is much harder

  • 8/10/2019 Indexing & searching techniques in database

    14/19

  • 8/10/2019 Indexing & searching techniques in database

    15/19

    ctives_template

    /C|/Documents%20and%20Settings/iitkrana1/My%20Documents/Google%20Talk%20Received%20Files/ist_data/lecture1/1_14.htm[6/14/2012 3:12:22 PM]

    Module 1: Basics and BackgroundLecture 1: Basic Database Queries

    Similarity search

    Range query: Given , , and range , return all objects such

    that

  • 8/10/2019 Indexing & searching techniques in database

    16/19

    ctives_template

    /C|/Documents%20and%20Settings/iitkrana1/My%20Documents/Google%20Talk%20Received%20Files/ist_data/lecture1/1_15.htm[6/14/2012 3:12:22 PM]

    Module 1: Basics and BackgroundLecture 1: Basic Database Queries

    Similarity search

    Range query: Given , , and range , return all objects such

    that

    Nearest neighbour (kNN) query : Given , , and number of nearest

    neighbour , return objects such that

    | | = and for any

  • 8/10/2019 Indexing & searching techniques in database

    17/19

    ctives_template

    /C|/Documents%20and%20Settings/iitkrana1/My%20Documents/Google%20Talk%20Received%20Files/ist_data/lecture1/1_16.htm[6/14/2012 3:12:23 PM]

    Module 1: Basics and BackgroundLecture 1: Basic Database Queries

    Similarity search

    Range query: Given , , and range , return all objects such

    that

    Nearest neighbour (kNN) query : Given , , and number of nearest

    neighbour , return objects such that

    | | = and for any

    Window query: Given and ranges in each dimension

    , return all objects such that

  • 8/10/2019 Indexing & searching techniques in database

    18/19

  • 8/10/2019 Indexing & searching techniques in database

    19/19