1 /*=========================================================================
3 Program: Visualization Toolkit
4 Module: $RCSfile: vtkPointLoad.h,v $
6 Date: $Date: 2002/08/05 17:29:13 $
7 Version: $Revision: 1.36 $
9 Copyright (c) 1993-2002 Ken Martin, Will Schroeder, Bill Lorensen
11 See Copyright.txt or http://www.kitware.com/Copyright.htm for details.
13 This software is distributed WITHOUT ANY WARRANTY; without even
14 the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
15 PURPOSE. See the above copyright notice for more information.
17 =========================================================================*/
18 // .NAME vtkPointLoad - compute stress tensors given point load on semi-infinite domain
19 // .SECTION Description
20 // vtkPointLoad is a source object that computes stress tensors on a volume.
21 // The tensors are computed from the application of a point load on a
22 // semi-infinite domain. (The analytical results are adapted from Saada - see
23 // text.) It also is possible to compute effective stress scalars if desired.
24 // This object serves as a specialized data generator for some of the examples
28 // vtkTensorGlyph, vtkHyperStreamline
30 #ifndef __vtkPointLoad_h
31 #define __vtkPointLoad_h
33 #include "vtkImageSource.h"
35 class VTK_IMAGING_EXPORT vtkPointLoad : public vtkImageSource
38 vtkTypeRevisionMacro(vtkPointLoad,vtkImageSource);
39 void PrintSelf(ostream& os, vtkIndent indent);
42 // Construct with ModelBounds=(-1,1,-1,1,-1,1), SampleDimensions=(50,50,50),
44 static vtkPointLoad *New();
47 // Set/Get value of applied load.
48 vtkSetMacro(LoadValue,float);
49 vtkGetMacro(LoadValue,float);
52 // Specify the dimensions of the volume. A stress tensor will be computed for
53 // each point in the volume.
54 void SetSampleDimensions(int i, int j, int k);
57 // Specify the dimensions of the volume. A stress tensor will be computed for
58 // each point in the volume.
59 void SetSampleDimensions(int dim[3]);
60 vtkGetVectorMacro(SampleDimensions,int,3);
63 // Specify the region in space over which the tensors are computed. The point
64 // load is assumed to be applied at top center of the volume.
65 vtkSetVector6Macro(ModelBounds,float);
66 vtkGetVectorMacro(ModelBounds,float,6);
69 // Set/Get Poisson's ratio.
70 vtkSetMacro(PoissonsRatio,float);
71 vtkGetMacro(PoissonsRatio,float);
74 // Turn on/off computation of effective stress scalar. These methods do
75 // nothing. The effective stress is always computed.
76 void SetComputeEffectiveStress(int) {};
77 int GetComputeEffectiveStress() {return 1;};
78 void ComputeEffectiveStressOn() {};
79 void ComputeEffectiveStressOff() {};
85 virtual void ExecuteInformation();
86 virtual void ExecuteData(vtkDataObject *);
90 int SampleDimensions[3];
94 vtkPointLoad(const vtkPointLoad&); // Not implemented.
95 void operator=(const vtkPointLoad&); // Not implemented.