VTK
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
vtkPBGLRMATGraphSource.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkPBGLRMATGraphSource.h
5 
6  Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
7  All rights reserved.
8  See Copyright.txt or http://www.kitware.com/Copyright.htm for details.
9 
10  This software is distributed WITHOUT ANY WARRANTY; without even
11  the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
12  PURPOSE. See the above copyright notice for more information.
13 
14 =========================================================================*/
15 /*-------------------------------------------------------------------------
16  Copyright 2008 Sandia Corporation.
17  Under the terms of Contract DE-AC04-94AL85000 with Sandia Corporation,
18  the U.S. Government retains certain rights in this software.
19 -------------------------------------------------------------------------*/
20 /*
21  * Copyright (C) 2008 The Trustees of Indiana University.
22  * Use, modification and distribution is subject to the Boost Software
23  * License, Version 1.0. (See http://www.boost.org/LICENSE_1_0.txt)
24  */
67 #ifndef __vtkPBGLRMATGraphSource_h
68 #define __vtkPBGLRMATGraphSource_h
69 
70 #include "vtkInfovisParallelModule.h" // For export macro
71 #include "vtkGraphAlgorithm.h"
72 
73 class vtkGraph;
74 class vtkPVXMLElement;
75 
76 class VTKINFOVISPARALLEL_EXPORT vtkPBGLRMATGraphSource : public vtkGraphAlgorithm
77 {
78 public:
79  static vtkPBGLRMATGraphSource* New();
81  void PrintSelf(ostream& os, vtkIndent indent);
82 
84 
86  vtkGetMacro(NumberOfVertices, vtkIdType);
88 
91  virtual void SetNumberOfVertices(vtkIdType value);
92 
94 
96  vtkGetMacro(NumberOfEdges, vtkIdType);
97  vtkSetClampMacro(NumberOfEdges, vtkIdType, 0, VTK_ID_MAX);
99 
101  void SetProbabilities(double A, double B, double C, double D);
102 
104  void GetProbabilities(double *A, double *B, double *C, double *D);
105 
107 
109  vtkSetMacro(IncludeEdgeWeights, bool);
110  vtkGetMacro(IncludeEdgeWeights, bool);
111  vtkBooleanMacro(IncludeEdgeWeights, bool);
113 
115 
116  vtkSetStringMacro(EdgeWeightArrayName);
117  vtkGetStringMacro(EdgeWeightArrayName);
119 
121 
123  vtkSetMacro(AllowSelfLoops, bool);
124  vtkGetMacro(AllowSelfLoops, bool);
125  vtkBooleanMacro(AllowSelfLoops, bool);
127 
129 
130  vtkSetMacro(GeneratePedigreeIds, bool);
131  vtkGetMacro(GeneratePedigreeIds, bool);
132  vtkBooleanMacro(GeneratePedigreeIds, bool);
134 
136 
137  vtkSetStringMacro(VertexPedigreeIdArrayName);
138  vtkGetStringMacro(VertexPedigreeIdArrayName);
140 
142 
143  vtkSetStringMacro(EdgePedigreeIdArrayName);
144  vtkGetStringMacro(EdgePedigreeIdArrayName);
146 
148 
151  vtkSetMacro(Seed, int);
152  vtkGetMacro(Seed, int);
154 
155 protected:
158  vtkIdType NumberOfVertices;
159  vtkIdType NumberOfEdges;
160  double A;
161  double B;
162  double C;
163  double D;
167  int Seed;
171 
172  virtual int RequestData(
173  vtkInformation*,
174  vtkInformationVector**,
175  vtkInformationVector*);
176 
178 
179  virtual int RequestDataObject(vtkInformation*,
180  vtkInformationVector** inputVector,
181  vtkInformationVector* outputVector);
183 
184 private:
185  vtkPBGLRMATGraphSource(const vtkPBGLRMATGraphSource&); // Not implemented
186  void operator=(const vtkPBGLRMATGraphSource&); // Not implemented
187 };
188 
189 #endif
190 
static vtkGraphAlgorithm * New()
Superclass for algorithms that produce only graph as output.
Base class for graph data types.
Definition: vtkGraph.h:288
void PrintSelf(ostream &os, vtkIndent indent)
virtual int RequestDataObject(vtkInformation *request, vtkInformationVector **inputVector, vtkInformationVector *outputVector)
virtual int RequestData(vtkInformation *request, vtkInformationVector **inputVector, vtkInformationVector *outputVector)
a distributed graph with random edges built accorting to the recursive matrix (R-MAT) model...