diff --git a/SearchStructures/doc/SearchStructures/CGAL/Range_segment_tree_traits.h b/SearchStructures/doc/SearchStructures/CGAL/Range_segment_tree_traits.h index f573fd59ee9..412d191dffa 100644 --- a/SearchStructures/doc/SearchStructures/CGAL/Range_segment_tree_traits.h +++ b/SearchStructures/doc/SearchStructures/CGAL/Range_segment_tree_traits.h @@ -2,7 +2,7 @@ namespace CGAL { /*! -\ingroup PkgRangeSegmentTreesD +\ingroup PkgRangeSegmentTreesDTraitsClasses The class `Range_segment_tree_traits_set_2` is a range and segment tree traits class for the 2-dimensional point class from the \cgal kernel. The class is @@ -34,7 +34,7 @@ std::pair Interval; namespace CGAL { /*! -\ingroup PkgRangeSegmentTreesD +\ingroup PkgRangeSegmentTreesDTraitsClasses The class `Range_segment_tree_traits_set_3` is a range and segment tree traits class for the 3-dimensional point class from the \cgal kernel. @@ -66,7 +66,7 @@ std::pair Interval; namespace CGAL { /*! -\ingroup PkgRangeSegmentTreesD +\ingroup PkgRangeSegmentTreesDTraitsClasses The class `Range_tree_traits_map_2` is a range tree traits class for the 2-dimensional point class from the \cgal kernel, where data of @@ -100,7 +100,7 @@ std::pair Interval; namespace CGAL { /*! -\ingroup PkgRangeSegmentTreesD +\ingroup PkgRangeSegmentTreesDTraitsClasses The class `Range_tree_traits_map_3` is a range and segment tree traits class for the 3-dimensional point class from the \cgal kernel, where data of @@ -134,7 +134,7 @@ std::pair Interval; namespace CGAL { /*! -\ingroup PkgRangeSegmentTreesD +\ingroup PkgRangeSegmentTreesDTraitsClasses The class `Segment_tree_traits_map_2` is a segment tree traits class for the 2-dimensional point class from the \cgal kernel, where data of @@ -168,7 +168,7 @@ std::pair,T> Interval; namespace CGAL { /*! -\ingroup PkgRangeSegmentTreesD +\ingroup PkgRangeSegmentTreesDTraitsClasses The class `Segment_tree_traits_map_3` is a segment tree traits class for the 3-dimensional point class from the \cgal kernel, where data of diff --git a/SearchStructures/doc/SearchStructures/CGAL/Range_tree_d.h b/SearchStructures/doc/SearchStructures/CGAL/Range_tree_d.h index ed6944cb9b6..715c1eaf460 100644 --- a/SearchStructures/doc/SearchStructures/CGAL/Range_tree_d.h +++ b/SearchStructures/doc/SearchStructures/CGAL/Range_tree_d.h @@ -2,7 +2,10 @@ namespace CGAL { /*! -\ingroup PkgRangeSegmentTreesD +\ingroup PkgRangeSegmentTreesDSearchStructure + +\brief A \f$ d\f$-dimensional range tree stores points and can be used to determine all +points that lie inside a given \f$ d\f$-dimensional interval. Implementation -------------- diff --git a/SearchStructures/doc/SearchStructures/CGAL/Range_tree_k.h b/SearchStructures/doc/SearchStructures/CGAL/Range_tree_k.h index 3be43886a92..89ae7102fc9 100644 --- a/SearchStructures/doc/SearchStructures/CGAL/Range_tree_k.h +++ b/SearchStructures/doc/SearchStructures/CGAL/Range_tree_k.h @@ -2,7 +2,7 @@ namespace CGAL { /*! -\ingroup PkgRangeSegmentTreesD +\ingroup PkgRangeSegmentTreesDSearchStructure An object of the class `Range_tree_k` is a \f$ k\f$-dimensional range tree that can store k-dimensional keys of type `Key`. diff --git a/SearchStructures/doc/SearchStructures/CGAL/Segment_tree_d.h b/SearchStructures/doc/SearchStructures/CGAL/Segment_tree_d.h index b24573facfc..4bda0f7a94a 100644 --- a/SearchStructures/doc/SearchStructures/CGAL/Segment_tree_d.h +++ b/SearchStructures/doc/SearchStructures/CGAL/Segment_tree_d.h @@ -2,7 +2,9 @@ namespace CGAL { /*! -\ingroup PkgRangeSegmentTreesD +\ingroup PkgRangeSegmentTreesDSearchStructure + +\brief A \f$ d\f$-dimensional segment tree stores \f$ d\f$-dimensional intervals and can be used to find all intervals that enclose, partially overlap, or contain a query interval, which may be a point. Implementation -------------- diff --git a/SearchStructures/doc/SearchStructures/CGAL/Segment_tree_k.h b/SearchStructures/doc/SearchStructures/CGAL/Segment_tree_k.h index 73b0a7da167..de7b64c0fd1 100644 --- a/SearchStructures/doc/SearchStructures/CGAL/Segment_tree_k.h +++ b/SearchStructures/doc/SearchStructures/CGAL/Segment_tree_k.h @@ -2,7 +2,7 @@ namespace CGAL { /*! -\ingroup PkgRangeSegmentTreesD +\ingroup PkgRangeSegmentTreesDSearchStructure An object of the class `Segment_tree_k` is a \f$ k\f$-dimensional segment tree that can store k-dimensional intervals of type `Interval`. diff --git a/SearchStructures/doc/SearchStructures/CGAL/Tree_base.h b/SearchStructures/doc/SearchStructures/CGAL/Tree_base.h index 8672c701647..6c911ad7cdf 100644 --- a/SearchStructures/doc/SearchStructures/CGAL/Tree_base.h +++ b/SearchStructures/doc/SearchStructures/CGAL/Tree_base.h @@ -14,11 +14,10 @@ classes for the data items (`Data` and `Window`). Example -------------- -The following figures show a number of rectangles and a \f$ 2\f$-dimensional +The following figures show a number of rectangles and a 2-dimensional segment tree built on them. -\image html segment_ex2.gif "Two dimensional interval data." -\image html segment_ex4.gif "Two dimensional segment tree according to the interval data." +\image html segment_ex2.gif "Two dimensional interval data and the corresponding segment tree." */ template< typename Data, typename Window > class Tree_anchor : public Tree_base { diff --git a/SearchStructures/doc/SearchStructures/CGAL/Tree_traits.h b/SearchStructures/doc/SearchStructures/CGAL/Tree_traits.h index f64a36dce95..1c6894e72df 100644 --- a/SearchStructures/doc/SearchStructures/CGAL/Tree_traits.h +++ b/SearchStructures/doc/SearchStructures/CGAL/Tree_traits.h @@ -2,7 +2,7 @@ namespace CGAL { /*! -\ingroup PkgRangeSegmentTreesD +\ingroup PkgRangeSegmentTreesDTraitsClasses `tree_interval_traits` is a template class that provides an interface to data items. It is similar to @@ -142,7 +142,7 @@ static bool comp(Key& key1, Key& key2); namespace CGAL { /*! -\ingroup PkgRangeSegmentTreesD +\ingroup PkgRangeSegmentTreesDTraitsClasses `tree_point_traits` is a template class that provides an interface to data items. diff --git a/SearchStructures/doc/SearchStructures/PackageDescription.txt b/SearchStructures/doc/SearchStructures/PackageDescription.txt index 1b9ad035d27..6677ab21009 100644 --- a/SearchStructures/doc/SearchStructures/PackageDescription.txt +++ b/SearchStructures/doc/SearchStructures/PackageDescription.txt @@ -1,6 +1,13 @@ /// \defgroup PkgRangeSegmentTreesD dD Range and Segment Trees /// \defgroup PkgRangeSegmentTreesDConcepts Concepts /// \ingroup PkgRangeSegmentTreesD + +/// \defgroup PkgRangeSegmentTreesDTraitsClasses Traits Classes +/// \ingroup PkgRangeSegmentTreesD + +/// \defgroup PkgRangeSegmentTreesDSearchStructure Search Structures +/// \ingroup PkgRangeSegmentTreesD + /*! \addtogroup PkgRangeSegmentTreesD \todo check generated documentation diff --git a/SearchStructures/doc/SearchStructures/SearchStructures.txt b/SearchStructures/doc/SearchStructures/SearchStructures.txt index 41116c36882..53488f55e2d 100644 --- a/SearchStructures/doc/SearchStructures/SearchStructures.txt +++ b/SearchStructures/doc/SearchStructures/SearchStructures.txt @@ -162,7 +162,7 @@ functions are non trivial. The design concept is illustrated in the figure below. -\image html rsd.gif +\image html rsd.gif Design of the range and segment tree data structure. The symbol triangle means that the lower class is derived from the upper class. E.g. in order to define a two dimensional multilayer tree, which consists of a range tree in the first dimension and a segment @@ -290,26 +290,12 @@ interval (`window_query`). The pictures below show a two-dimensional and a \f$d\f$-dimensional range tree. - - -
-A two-dimensional range tree -A d-dimensional range tree -
- - -
-A two-dimensional range tree. The -tree is a binary search tree on the first dimension. Each -sublayer tree of a vertex v is a binary search tree on the -second -dimension. The data items in a sublayer tree of v are -all data items of the subtree of v - -A d-dimensional range tree. For -each layer of the tree, one -sublayer tree is illustrated. -
+\image html range2.gif "A two and a d-dimensional range tree." + +The 2-dimensional tree is a binary search tree on the first dimension. Each sublayer tree of a vertex `v` is a binary search tree on the second dimension. The data items in a sublayer tree of `v` are all data items of the subtree of `v`. + +For the d-dimensional range tree, the figure shows one sublayer tree for each +layer of the tree. The tree can be built in \f$ O(n\log^{d-1} n)\f$ time and needs \f$ O(n\log^{d-1} n)\f$ space. The \f$ d\f$-dimensional points that lie in the @@ -317,7 +303,7 @@ needs \f$ O(n\log^{d-1} n)\f$ space. The \f$ d\f$-dimensional points that lie in where \f$ n\f$ is the total number of points and \f$ k\f$ is the number of reported points. -\subsection secrange_tree_ex Example for Range Tree on Map-like Data +\subsection secrange_tree_ex Example for %Range Tree on Map-like Data The following example program uses the predefined `Range_tree_2` data structure together with the predefined traits class `Range_tree_map_traits_2` which has two template @@ -434,32 +420,19 @@ contained in a given \f$ d\f$-dimensional interval (`window_query`). An example of a one-dimensional segment tree and an example of a two-dimensional segment tree are shown below. - - - - - -
-A one-dimensional segment
-tree -A d-dimensional segment tree -
+\image html segment2.gif "A one and a two dimensional segment tree" - - -
-A one-dimensional segment -tree. The segments and the corresponding elementary intervals +For the one-dimensional segment +tree the segments and the corresponding elementary intervals are shown below the tree. The arcs from the nodes point to their subsets. - -A two-dimensional segment -tree. The first layer of the tree is built according to the + +For the two-dimensional segment +tree we see that the first layer of the tree is built according to the elementary intervals of the first dimension. Each -sublayer tree of a vertex v is a segment tree according to -the second dimension of all data items of v. -
+sublayer tree of a vertex `v` is a segment tree according to +the second dimension of all data items of `v`. + The tree can be built in \f$ O(n\log^{d} n)\f$ time and needs \f$ O(n\log^{d} n)\f$ space. diff --git a/SearchStructures/doc/SearchStructures/fig/range2.gif b/SearchStructures/doc/SearchStructures/fig/range2.gif index 4020afb28e3..79468641daf 100644 Binary files a/SearchStructures/doc/SearchStructures/fig/range2.gif and b/SearchStructures/doc/SearchStructures/fig/range2.gif differ diff --git a/SearchStructures/doc/SearchStructures/fig/segment2.gif b/SearchStructures/doc/SearchStructures/fig/segment2.gif index 15cd156628e..f016f237958 100644 Binary files a/SearchStructures/doc/SearchStructures/fig/segment2.gif and b/SearchStructures/doc/SearchStructures/fig/segment2.gif differ diff --git a/SearchStructures/doc/SearchStructures/fig/segment_ex2.gif b/SearchStructures/doc/SearchStructures/fig/segment_ex2.gif index d9deee119e5..11eaf7d58bf 100644 Binary files a/SearchStructures/doc/SearchStructures/fig/segment_ex2.gif and b/SearchStructures/doc/SearchStructures/fig/segment_ex2.gif differ