Spatial Search Contact Search Algorithm

Slides:



Advertisements
Similar presentations
Lists: An internal look
Advertisements

Trees for spatial indexing
Data Models There are 3 parts to a GIS: GUI Tools
Christian Lauterbach COMP 770, 2/16/2009. Overview  Acceleration structures  Spatial hierarchies  Object hierarchies  Interactive Ray Tracing techniques.
Collisions and Intersections When objects move, test for collision. When projecting surfaces, check for intersections. (Many slides adapted from Amitabh.
Nearest Neighbor Finding Using Kd-tree Ref: Andrew Moore’s PhD thesis (1991)Andrew Moore’s PhD thesis.
Computer graphics & visualization Collisions. computer graphics & visualization Simulation and Animation – SS07 Jens Krüger – Computer Graphics and Visualization.
Yicheng Tu, § Shaoping Chen, §¥ and Sagar Pandit § § University of South Florida, Tampa, Florida, USA ¥ Wuhan University of Technology, Wuhan, Hubei, China.
Searching on Multi-Dimensional Data
Introduction to Spatial Database System Presented by Xiaozhi Yu.
Course Outline Introduction in algorithms and applications Parallel machines and architectures Overview of parallel machines, trends in top-500 Cluster.
Computing 3D Geometry Directly From Range Images Sarah F. Frisken and Ronald N. Perry Mitsubishi Electric Research Laboratories.
Asst. Prof. Yusuf Sahillioğlu
Ray Tracing Acceleration Structures Solomon Boulos 4/16/2004.
10/2/20061 Algorithms on grids Natasha Gelfand Geometry Seminar Fall 2006.
Spatial Information Systems (SIS) COMP Spatial access methods: Indexing.
Data Structures for Orthogonal Range Queries
Quick Review of Apr 15 material Overflow –definition, why it happens –solutions: chaining, double hashing Hash file performance –loading factor –search.
Caching I Andreas Klappenecker CPSC321 Computer Architecture.
Bounding Volume Hierarchies and Spatial Partitioning Kenneth E. Hoff III COMP-236 lecture Spring 2000.
Chapter 5: Path Planning Hadi Moradi. Motivation Need to choose a path for the end effector that avoids collisions and singularities Collisions are easy.
1Notes. 2 Time integration for particles  Back to the ODE problem, either  Accuracy, stability, and ease-of- implementation are main issues  Obviously.
Hybrid Bounding Volumes for Distance Queries Distance Query returns the minimum distance between two geometric models Major application is path planning.
Large-Scale Content-Based Image Retrieval Project Presentation CMPT 880: Large Scale Multimedia Systems and Cloud Computing Under supervision of Dr. Mohamed.
Domain decomposition in parallel computing Ashok Srinivasan Florida State University COT 5410 – Spring 2004.
Outline Who am I? What is research? My Research Higher studies opportunities in Australia Getting jobs in IT industry Presented by: Muhammad Aamir Cheema,
Acceleration Digital Image Synthesis Yung-Yu Chuang 10/4/2005 with slides by Mario Costa Sousa and Pat Hanrahan.
Computer Graphics 2 Lecture x: Acceleration Techniques for Ray-Tracing Benjamin Mora 1 University of Wales Swansea Dr. Benjamin Mora.
Data Structures for Computer Graphics Point Based Representations and Data Structures Lectured by Vlastimil Havran.
Object Oriented Data Structures
CSE 872 Dr. Charles B. Owen Advanced Computer Graphics1 Polygon Meshes and other modeling tools Object representation Polygon meshes Normals Scene graphs.
Brute Force Average of 88 checks Worst possible algorithm if there is a ship in the bottom right cell Best search: 25.
1 Speeding Up Ray Tracing Images from Virtual Light Field Project ©Slides Anthony Steed 1999 & Mel Slater 2004.
CSE 381 – Advanced Game Programming Quickhull and GJK.
Data Structures for Orthogonal Range Queries A New Data Structure and Comparison to Previous Work. Application to Contact Detection in Solid Mechanics.
Project 2 Presentation & Demo Course: Distributed Systems By Pooja Singhal 11/22/
Clustering Uncertain Data Speaker: Ngai Wang Kay.
Mehdi Mohammadi March Western Michigan University Department of Computer Science CS Advanced Data Structure.
B.Sc. Matej Gomboši Determining differences between two sets of polygons Laboratory for Geometric Modelling and Multimedia Algorithms Faculty of Electrical.
The Application of The Improved Hybrid Ant Colony Algorithm in Vehicle Routing Optimization Problem International Conference on Future Computer and Communication,
Pierre Alliez The Computational Geometry Algorithm Library.
© M. Gross, ETH Zürich, 2014 Informatik I für D-MAVT (FS 2014) Exercise 12 – Data Structures – Trees Sorting Algorithms.
Geoffrey Duval (ISAE-SUPAERO) Naples, October 1 st, 2012.
Computational Geometry Piyush Kumar (Lecture 5: Range Searching) Welcome to CIS5930.
Copyright © CISST ERC, 2000 Engineering Research Center for Computer Integrated Surgical Systems and Technology Finding point-pairs Given an a, find a.
File StructuresFile StructureSNU-OOPSLA Lab1 Chap1. Introduction to File Structures File Structures by Folk, Zoellick, and Riccardi.
Domain decomposition in parallel computing Ashok Srinivasan Florida State University.
Advanced topics Advanced Multimedia Technology: Computer Graphics Yung-Yu Chuang 2006/01/04 with slides by Brian Curless, Zoran Popovic, Mario Costa Sousa.
CSE554Contouring IISlide 1 CSE 554 Lecture 5: Contouring (faster) Fall 2015.
Outline ● Introduction – What is the problem ● Generate stochastic textures ● Improve realism ● High level approach - Don't just jump into details – Why.
Ray Tracing Acceleration (5). Ray Tracing Acceleration Techniques Too Slow! Uniform grids Spatial hierarchies K-D Octtree BSP Hierarchical grids Hierarchical.
APE'07 IV INTERNATIONAL CONFERENCE ON ADVANCES IN PRODUCTION ENGINEERING June 2007 Warsaw, Poland M. Nowakiewicz, J. Porter-Sobieraj Faculty of.
UNC Chapel Hill David A. O’Brien Automatic Simplification of Particle System Dynamics David O’Brien Susan Fisher Ming C. Lin Department of Computer Science.
DGrid: A Library of Large-Scale Distributed Spatial Data Structures Pieter Hooimeijer,
COMP 3500 Introduction to Operating Systems Directory Structures Block Management Dr. Xiao Qin Auburn University
School of Computing Clemson University Fall, 2012
RoboVis Alistair Wick.
CSE 554 Lecture 5: Contouring (faster)
Graphs Chapter 15 introduces graphs which are probably the most general and commonly-used data structure. This lecture introduces heaps, which are used.
Bounding Volume Hierarchies and Spatial Partitioning
Paul P.H. Wilson UW-Madison Fusion Technology Institute
classes and objects review
Visible-Surface Detection Methods
Bounding Volume Hierarchies and Spatial Partitioning
Linked lists Motivation: we can make arrays, but their functionality is slightly limited and can be difficult to work with Biggest issue: size management.
C-obstacle Query Computation for Motion Planning
Digital Image Synthesis Yung-Yu Chuang 10/4/2005
GENERAL VIEW OF KRATOS MULTIPHYSICS
Course Outline Introduction in algorithms and applications
cse 521: design and analysis of algorithms
Presentation transcript:

Spatial Search Contact Search Algorithm Nelson Lafontaine

Outlook Aviable Method Spatial Searching The user configure file. Searching my Objects.

Spatial Search Available Methods Brute Force Point to Point Search Kdtree Quadtree,Octree Bins Hybrid Object to Object Search

1 2 3 4 5 Spatial Search Algorithm Brute Force Cloud Point NodesArrayType = mode_part.Nodes(); double distance = 1E15; double dist _comp = 0.00; array_1d<double, 3> vector_distance; for ( Modelpart::NodeIterator inode = pNodes.begin(); inode != pNode.end(); inode++ ){ distance = 1E15; for ( Modelpart::NodeIterator jnode = pNodes.begin(); jnode != pNode.end( ) && jnode!=inode ; jnode++){ vector_distance = inode->Coordinates() – jnode->Coordinates(); dist_com = inner_prod(vector_distance, vector_distance ); If(dist_comp<distande ) inode->GetValue(NEAR_NODE ) = (*jnode).base(); } } 1 2 3 4 5 Very Expensive!!!!!!!!!! Searching Operation O(N2)

Point to Point Search Domain Decomposition. Kd-tree Robust for irregular distribution Slower than others due to the cash miss

Point to Point Search Domain Decomposition. Quadtree, Oc-tree Middle Point Average Point

Spatial Search Algorithm Bins Good for regular distributions Robust Very fast. Or(β*n) CPU and RAM efficient. Easy to implement. Ly lx Lx

Point to Point Search Using the Point Search. -----Bucket types------ typedef Bucket< TDim, PointType, PointVector, PointTypePointer, PointIterator, DistanceIterator > BucketType; typedef Bins<Tdim. PointType, PointVector, PointTypePointer, PointIterator, DistanceIterator > StaticBins typedef Tree< KDTreePartition<BucketType> > tree;         // Kdtree typedef Tree< OCTreePartition<BucketType> > tree;         // Octree typedef Tree < Static Bins > tree; // BinsTree ------ Creation------ tree nodes_tree(list_of_new_nodes.begin(),list_of_new_nodes.end(),bucket_size); h

Point to Point Search Using the Point Search. Loop over found Nodes. NodesArrayType = mode_part.Nodes(); double distance = 1E15; double dist _comp = 0.00; array_1d<double, 3> vector_distance; for ( Modelpart::NodeIterator inode = pNodes.begin(); inode != pNode.end(); inode++ ){ distance = 1E15; number_of _point_in _radius = nodes_tree .SearchInRadius(*inode , radius, Results.begin(), ResultsDistances.begin(),  MaximumNumberOfResults); for (PointIterator it_found = Result.begin(); it_found!=Result.begin() + number_of _point_in _radius; it_found ++) { vector_distance = inode->Coordinates() – jnode->Coordinates(); dist_com = inner_prod(vector_distance, vector_distance ); If(dist_comp<distande ) inode->GetValue(NEAR_NODE ) = (*jnode).base() } } http://kratos.cimne.upc.es/projects/kratos/repository/entry/kratos/applications/MeshingApplication/custom_utilities/projection.h Very Good Searching Operation O(NLog(N))

Spatial Search Algorithm Object Bins ( Dynamic or Static ) Components: Objects or Points Bounding Box Cells It can be any geometry

Spatial Search Algorithm Bins. Usage List of all Pair of Contacts. Given an object (in bin or not in bin) it can return the contacts objects. Lets you know the location of an object contended or not contained in the bin. It can used to interpolate data between different meshes. List of all the nearby object

Spatial Search Algorithm Bins. Usage List Pair Contacts. Given an object return its contacts. Save the pointers of two objects in contact. Cell Pair 3-2 (4, 5) For each cell in bin For each object in cell Verify Geometric Intersection. (Brute Force) 4 2 1 5 3 Objects in contact.

Spatial Search Algorithm Bins. Encreasing efficiency. Intersection Object to Cell or Box to Cell? Advantage of Object to Cell: Check whether the object is contended in the cell. Less searches operations.

Spatial Search Algorithm Using the Spatial Search algorithm based in Objects List of all objects in model (Objects_Container ) Creation of the Object: BinsDynamicObject<My_Configure> Bins(Begin , End ) Note : The Bins class is a generic class. Contact pair list Bins.SearchContact(mPairContacts); Particle contact list Loop in Objects Container rBinsObjectDynamic.SearchObjectsInner(*it, Result); }

Spatial Search Algorithm Using static and dynamic object Bins. Creating the bins BinsObjectDynamic<Configure>  rBinsObjectDynamic(mBoundaryElements.begin(), mBoundaryElements.end());  BinsObjectStatic<Configure>  rBinsObjectDynamic(mBoundaryElements.begin(), mBoundaryElements.end());  http://kratos.cimne.upc.es/projects/kratos/repository/entry/kratos/kratos/utilities/spatial_containers_configure.h

Spatial Search Algorithm Using static and dynamic object Bins. ResultContainerType Result; IteratorType it_begin = List_of_object.begin(); IteratorType it_begin = List_of_object.end(); for(IteratorType it = it_begin ; it!=it_end; it++) rBinsObjectDynamic.SearchObjectInner(*it, Result); rBinsObjectDynamic.SearchObjectInCell(*it, Result); rBinsObjectDynamic.SearchContacts(PairContacts); http://kratos.cimne.upc.es/projects/kratos/repository/entry/kratos/applications/structural_application/custom_utilities/boundary_conditions_and_contact_utilities.h List of contacts objects of particular object. List of nearby objects of particular object. Contact Pair List

Spatial Search Algorithm The user configure file: Very easy to make and use. The main attributes and methods need to be defined The containers Compute bounding box. Intersection between objects. Function for increasing efficiency Intersection between cells and objects

Spatial Search Algorithm The user configure file: The containers Definition of type of object´s container. Iterators and pointers. List Contacts Pairs.

Spatial Search Algorithm Advance. The user configure file: Compute bounding box function The minimum and maximum point of the object. static inline void CalculateBoundingBox( PointerType& p, PointType& pmin, PointType& pmax) { } Intersection between objects function Geometric intersection tools. Many intersection algorithms can be found in computational geometry books. static inline bool Intersection(const PointerType& p1, const PointerType& p2) { ….. }

Spatial Search Algorithm The user configure file: Intersection object and Cell. Increasing the efficiency: Avoid search contacts in cells that no have intersection with the object. Very useful. Geometric tools for intersection between objects and cell (a cell can be reinterpreted like an uniform rectangular shape geometry). static inline bool IntersectionBox(const PointerType& p, const PointType& pmin, const PointType& pmax) { Important Note: return always a true value if you do not have in hand the this kind of algorithm } {} …..{}

Spatial Search Algorithm The user configure file. A Little view Spatial Search Algorithm The user configure file. A Little view. Configure.h /// typedef Definitions typedef ContainerType ResultContainerType; typedef IteratorType ResultIteratorType; typedef Pair<PointerType> ContactPairType; typedef std::vector<ContactPairType> ContainerContactType; typedef ContainerContactType::iterator IteratorContactType; /// the most important methods static inline bool Intersection(const PointerType& p1, const PointerType& p2) static inline void CalculateBoundingBox( PointerType& p, PointType& pmin, PointType& pmax) static inline bool IntersectionBox(const PointerType& p, const PointType& pmin, const PointType& pmax) http://kratos.cimne.upc.es/projects/kratos/repository/entry/kratos/kratos/utilities/spatial_containers_configure.h

Spatial Search Algorithm More details visit us at http://kratos-wiki.cimne.upc.edu/index.php/How_to_use_the_Spatial_Containers Thanks