DOC PREVIEW
UMD CMSC 878R - Lecture 13

This preview shows page 1-2-3-23-24-25-26-47-48-49 out of 49 pages.

Save
View full document
View full document
Premium Document
Do you want full access? Go Premium and unlock all 49 pages.
Access to all documents
Download any document
Ad free experience
View full document
Premium Document
Do you want full access? Go Premium and unlock all 49 pages.
Access to all documents
Download any document
Ad free experience
View full document
Premium Document
Do you want full access? Go Premium and unlock all 49 pages.
Access to all documents
Download any document
Ad free experience
View full document
Premium Document
Do you want full access? Go Premium and unlock all 49 pages.
Access to all documents
Download any document
Ad free experience
View full document
Premium Document
Do you want full access? Go Premium and unlock all 49 pages.
Access to all documents
Download any document
Ad free experience
View full document
Premium Document
Do you want full access? Go Premium and unlock all 49 pages.
Access to all documents
Download any document
Ad free experience
View full document
Premium Document
Do you want full access? Go Premium and unlock all 49 pages.
Access to all documents
Download any document
Ad free experience
View full document
Premium Document
Do you want full access? Go Premium and unlock all 49 pages.
Access to all documents
Download any document
Ad free experience
View full document
Premium Document
Do you want full access? Go Premium and unlock all 49 pages.
Access to all documents
Download any document
Ad free experience
View full document
Premium Document
Do you want full access? Go Premium and unlock all 49 pages.
Access to all documents
Download any document
Ad free experience
Premium Document
Do you want full access? Go Premium and unlock all 49 pages.
Access to all documents
Download any document
Ad free experience

Unformatted text preview:

CMSC 858M/AMSC 698R Fast Multipole MethodsOutlineData Structures and FMMData Structures and FMM (2)Data Structures and FMM (3)Hierarchical Space SubdivisionBinary TreesWhat are k-d trees?Why 2d-trees?It is easy to convert k-d tree into 2d-tree and back (for cubic boxes) Hierarchy in 2d-tree2d-treesHierarchical Numbering (Indexing) in 2d-trees. Numbering (Indexing) String.Hierarchical Numbering in 2d-trees. Number at the Level.Hierarchical Numbering in 2d-trees. Universal Number.Parent Index (Number)Children Indices (Numbers)A couple of examples:Can it be even faster?Matlab Program for Parent FindingSpatial OrderingScalingScaling (2)Binary Ordering (1)Binary Ordering (2) Finding the number of the box containing a given pointBinary Ordering (3) Finding the number of the box containing a given point (2)Binary Ordering (4) Finding the center of a given box.Binary Ordering (5) Neighbor findingOrdering in d-dimensions (1). Bit Interleaving.Ordering in d-dimensions (2). Bit Interleaving (2). Example.Ordering in d-dimensions (3). Convention for Children Ordering.Ordering in d-dimensions (4). Finding the number of the box containing a given point.Ordering in d-dimensions (5). Finding the number of the box containing a given point (2). Algorithm and Example.Bit DeinterleavingBit deinterleving (2). Example.Finding the center of a given box.Neighbor Finding Neighbor Finding (2). Example. Spatial Data StructuringSome properties of 2d-tree hierarchy.Threshold LevelSome Practical Issues Related to Spatial OrderingSpatial Data SortingSpatial Data Sorting (2)After data sorting we need to find the maximum level of space subdivision that will be employedThe threshold level determination algorithm in O(N) timeBinary Search in Sorted ListOperations on SetsPractical recommendations for the FMMCMSC 858M/AMSC 698R Fast Multipole Methods Nail A. Gumerov & Ramani Duraiswami Lecture 13Outline • Data Structures and FMM • Hierarchical Space Subdivision – Binary Trees, Quadtrees, Octrees; – k-d trees; – 2d-trees. Definitions. • Hierarchical Numbering (Indexing) • Spatial Ordering – Scaling. – Binary ordering. – Ordering in d-dimensions. – Bit interleaving and deinterleaving – Algorithms for finding the box index, box center, parents, children, and neighbors. – Examples.Data Structures and FMM • Spatial grouping techniques are employed in various versions of the FMM (SL_FMM, RML_FMM, AML_FMM, etc.) • All major components of the FMM are interrelated: truncated factorization, error bounds, translation operations, and spatial grouping.Data Structures and FMM (2) • Since the complexity of FMM should not exceed O(N2) (at M~N), data organization should be provided for efficient numbering, search, and operations with these data. • Some naive approaches can utilize search algorithms that result in O(N2) complexity of the FMM (and so they kill the idea of the FMM). • In d-dimensions O(NlogN) complexity for operations with data can be achieved. • Some caution is needed while utilizing standard (library) routines on sets. If using such routines always check the complexity of the algorithm! • Understanding of complexity of each FMM procedure is crucial. Normally it is worth to develop your own library for operations with FMM data (using standard routines as their complexity is satisfactory).Data Structures and FMM (3) • Approaches include: – Data preprocessing • Sorting • Building lists (such as neighbor lists): requires memory, potentially can be avoided; • Building and storage of trees: requires memory, potentially can be avoided; – Operations with data during the FMM algorithm • Operations on data sets; • Search procedures. • Preferable algorithms: – Avoid unnecessary memory usage; – Use fast (constant and logarithmic) search procedures; – Employ bitwise operations; – Can be parallelized.Hierarchical Space Subdivision Historically: • Binary trees (1D), Quadtrees (2D), Octrees (3D); • For dimensions larger than 3 (sometimes for d=2 and 3 also) k-d trees. • We will consider a concept of 2d-tree: – d=1 – binary; – d=2 – quadtree; – d=3 – octree; – d=4 – hexatree; – and so on..Binary Trees L R L R L R L R Target segment coordinates: LRRL L R L R L R L RWhat are k-d trees? Target box coordinates: RBRTLBRT L R T B L R T B R L T B L R T B R L B T R L T B R L T B R L T B Like a binary tree!Why 2d-trees? It is possible to use k-d trees in the FMM (while in this course we mainly focus on 2d-trees) Simply, because It is convenient in the FMM to enclose a cube into a sphere with easy determination of the neighborhood of similar boxes. k-d tree 2d-treeIt is easy to convert k-d tree into 2d-tree and back (for cubic boxes) Target box coordinates: RBRTLBRT →(RB)(RT)(LB)(RT) R L B T R L T B R L T B R L T B LB LT RB RT LB LT RB RT LB LT RB RT LB LT RB RT quad-tree = 22-tree k-2 treeHierarchy in 2d-tree Level 1 Level 0 Level 2 Level 3 Parent Self Child Child Child Child Neighbor (Sibling) Neighbor Neighbor Neighbor Neighbor Neighbor Neighbor (Sibling) Neighbor (Sibling) Level 1 Level 0 Level 2 Level 3 Level 1 Level 0 Level 2 Level 3 Parent Self Child Child Child Child Neighbor (Sibling) Neighbor Neighbor Neighbor Neighbor Neighbor Neighbor (Sibling) Neighbor (Sibling)2d-trees 2-tree (binary)22-tree (quad)2d-tree0123LevelChildrenParentNeighbor(Sibling)Maybe NeighborSelfNumberof Boxes12d22d23d2-tree (binary)22-tree (quad)2d-tree0123LevelChildrenParentNeighbor(Sibling)Maybe NeighborSelfNumberof Boxes12d22d23dHierarchical Numbering (Indexing) in 2d-trees. Numbering (Indexing) String. 0012131333311102000222111111111111111000000000000000202222222222222223 3333333333333330012131333311102000222111111111111111000000000000000202222222222222223 333333333333333Numbering in quad-tree Numbering string The large black box has the numbering string (2,3); The small black box has the numbering string (3,1,2);Hierarchical Numbering in 2d-trees. Number at the Level. 0012131333311102000222111111111111111000000000000000202222222222222223 3333333333333330012131333311102000222111111111111111000000000000000202222222222222223 333333333333333Numbering in quad-tree The large black box has the numbering string (2,3). So its number is 234=1110. The small black box has the numbering string (3,1,2). So its number is 3124=5410. In general: Number at level l is:Hierarchical Numbering in 2d-trees. Universal Number.


View Full Document

UMD CMSC 878R - Lecture 13

Download Lecture 13
Our administrator received your request to download this document. We will send you the file to your email shortly.
Loading Unlocking...
Login

Join to view Lecture 13 and access 3M+ class-specific study document.

or
We will never post anything without your permission.
Don't have an account?
Sign Up

Join to view Lecture 13 2 2 and access 3M+ class-specific study document.

or

By creating an account you agree to our Privacy Policy and Terms Of Use

Already a member?