PBowlLoading.hGo to the documentation of this file.00001 //=============================================================================== 00002 //# COPYRIGHT (C): Woody's license (by BJ): 00003 // ``This source code is Copyrighted in 00004 // U.S., for an indefinite period, and anybody 00005 // caught using it without our permission, will be 00006 // mighty good friends of ourn, cause we don't give 00007 // a darn. Hack it. Compile it. Debug it. Run it. 00008 // Yodel it. Enjoy it. We wrote it, that's all we 00009 // wanted to do.'' 00010 // 00011 //# PROJECT: Object Oriented Finite Element Program 00012 //# PURPOSE: Plastic Bowl (aka Domain Reduction) implementation: 00013 //# This file contains the class definition for PBowlLoading. 00014 //# PBowlLoading is a subclass of loadPattern, 00015 //# which implements the plastic bowl loading 00016 //# (aka Domain Reduction Method) as described 00017 //# by Jacobo Bielak et al. 00018 //# CLASS: PBowlLoading 00019 //# 00020 //# VERSION: 0.61803398874989 (golden section) 00021 //# LANGUAGE: C++ 00022 //# TARGET OS: all... 00023 //# DESIGN: Zhaohui Yang, Boris Jeremic 00024 //# PROGRAMMER(S): Jinxiu Liao, Zhaohui Yang, Boris Jeremic 00025 //# 00026 //# 00027 //# DATE: 21Oct2002 00028 //# UPDATE HISTORY: 31Oct2002 fixed some memory leaks 00029 //# 04Nov2002 changed the way plastic bowl elements are 00030 //# input. 00031 //# 10Nov2002 Zeroing diagonal and out of diagaonal blocks 00032 //# for b<->e nodes 00033 //# 13Nov2002 changes to split "b" and "e" nodes within 00034 //# the plastic bowl elements. Also, simple definition of 00035 //# of cubic bowl is now facilitated ... 00036 //# 00037 //# 00038 //# 00039 //=============================================================================== 00040 00041 #ifndef PBowlLoading_h 00042 #define PBowlLoading_h 00043 00044 // Purpose: 00045 #include <LoadPattern.h> 00046 #include <Matrix.h> 00047 #include <Domain.h> 00048 #include <NodeIter.h> 00049 #include <Node.h> 00050 #include <ElementIter.h> 00051 #include <Element.h> 00052 #include <stdlib.h> 00053 #include <Channel.h> 00054 #include <ErrorHandler.h> 00055 00056 #include <OPS_Globals.h> 00057 00058 class Vector; 00059 class Matrix; 00060 00061 class PBowlLoading : public LoadPattern 00062 { 00063 public: 00064 PBowlLoading(); 00065 PBowlLoading(int tag, 00066 const char *PBEfName, 00067 const char *DispfName, 00068 const char *AccefName, 00069 double theTimeIncr=1.0, 00070 double theFactor=1.0, 00071 // coordinates of "b" nodes for cubic plastic bowl 00072 double xplus = 0.0, 00073 double xminus = 0.0, 00074 double yplus = 0.0, 00075 double yminus = 0.0, 00076 double zplus = 0.0, 00077 double zminus = 0.0); 00078 ~PBowlLoading(); 00079 00080 void setDomain(Domain *theDomain); 00081 void applyLoad(double time); 00082 void Print(OPS_Stream &s, int flag =0); 00083 00084 // methods for o/p 00085 int sendSelf(int commitTag, Channel &theChannel); 00086 int recvSelf(int commitTag, Channel &theChannel, 00087 FEM_ObjectBroker &theBroker); 00088 00089 // method to obtain a blank copy of the LoadPattern 00090 LoadPattern *getCopy(void); 00091 00092 protected: 00093 //void addPBElements(const ID &PBEle); //Adding plastic bowl elements 00094 //void addPBNodes(const ID &PBNodes); //Adding plastic bowl nodes 00095 //void addPBLoads(const Matrix &PBLoads); //Adding plastic bowl loades 00096 void CompPBLoads(); //Finding all plastic bowl nodes and compute the equivalent forces from plastic bowl loading 00097 const Vector & getNodalLoad(int node, double time); //Getting the nodal load computed from plastic bowl loading corresponding to time 00098 00099 private: 00100 ID *PBowlElements; // vector containing the plastic bowling elements 00101 ID *ExteriorNodes; // vector containing the nodes on plastic bowl except boundary nodes 00102 ID *BoundaryNodes; // vector containing the nodes on the boundary of the plastic bowl 00103 Matrix *PBowlLoads; // matrix containing the plastic bowling loads 00104 00105 Matrix *U; // vector to store input displ. for all nodes and all time steps 00106 int UnumDataPoints; // number of data points 00107 Matrix *Udd; // vector to store input accel. for all nodes and all time steps 00108 int UddnumDataPoints;// number of data points 00109 00110 int thetimeSteps; 00111 00112 00113 //Coordinates for the plastic box 00114 double PBTimeIncr; // specifies the time increment used in load path vector 00115 double cFactor; // additional factor on the returned load factor 00116 double xPlus; // x-coor for the right surface 00117 double xMinus; // x-coor for the left surface 00118 double yPlus; // y-coor for the right surface 00119 double yMinus; // y-coor for the left surface 00120 double zPlus; // z-coor for the up surface 00121 double zMinus; // z-coor for the bottom surface 00122 00123 bool LoadComputed; // flag to indicate whether the equivalent force has been computed 00124 }; 00125 00126 #endif |