/[escript]/branches/diaplayground/cusplibrary/cusp/graph/hilbert_curve.h
ViewVC logotype

Contents of /branches/diaplayground/cusplibrary/cusp/graph/hilbert_curve.h

Parent Directory Parent Directory | Revision Log Revision Log


Revision 4955 - (show annotations)
Tue May 20 04:33:15 2014 UTC (6 years, 2 months ago) by caltinay
File MIME type: text/plain
File size: 1491 byte(s)
added pristine copy of cusplibrary (apache license) to be used by ripley.

1 /*
2 * Copyright 2008-2009 NVIDIA Corporation
3 *
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
7 *
8 * http://www.apache.org/licenses/LICENSE-2.0
9 *
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
15 */
16
17 /*! \file hilbert_curve.h
18 * \brief Cluster points using a Hilbert space filling curve
19 */
20
21 #pragma once
22
23 #include <cusp/detail/config.h>
24
25 namespace cusp
26 {
27 namespace graph
28 {
29 /*! \addtogroup algorithms Algorithms
30 * \ingroup algorithms
31 * \{
32 */
33
34 /*! \p hilbert_curve : Uses a Hilbert space filling curve to partition
35 * a set of points in 2 or 3 dimensional space.
36 *
37 *
38 * \param Set of points in 2 or 3-D space
39 * \param number of partitions to construct
40 * \param partition assigned to each point
41 *
42 * \tparam Array coord
43 * \tparam size_t num_parts
44 * \tparam Array parts
45 *
46 * \see http://en.wikipedia.org/wiki/Hilbert_curve
47 */
48 template <class Array2d, class Array1d>
49 void hilbert_curve(const Array2d& coord, const size_t num_parts, Array1d& parts);
50
51 /*! \}
52 */
53
54
55 } // end namespace graph
56 } // end namespace cusp
57
58 #include <cusp/graph/detail/hilbert_curve.inl>
59

  ViewVC Help
Powered by ViewVC 1.1.26