FreeEquation.hh

Go to the documentation of this file.
00001 #ifndef FREE_EQUATION_HH
00002 #define FREE_EQUATION_HH
00003 
00004 // Copyright (c) 2002-2005 The University of Cincinnati.  All rights
00005 // reserved.
00006 
00007 // You may modify, distribute, and use the software contained in this
00008 // package under the terms of the "GNU LIBRARY GENERAL PUBLIC LICENSE"
00009 // version 2, June 1991. A copy of this license agreement can be found in
00010 // the file "LGPL", distributed with this archive.
00011 
00012 // Authors: Vinod Chamarty                    chamarv@ececs.uc.edu
00013 //          Sameer Kher                       kherss@ececs.uc.edu
00014 //          Vikram Krishnamachary       
00015 
00016 #include "tyvis/Component.hh"
00017 #include "tyvis/VHDLType.hh"
00018 #include "tyvis/adouble.h"
00019 #include "tyvis/adutils.h"
00020 
00021 class _savant_entity_ams_elab;
00022 
00026 class freeEquation : public component {
00027 public:
00028   
00039    freeEquation(_savant_entity_ams_elab *designPtr, component **&parent_equation, int caseValue, const char* name, 
00040                 adouble (*functionPtr) (component *, adouble*), int noOfVariables, ...);
00041 
00049   freeEquation(const char* name, adouble (*functionPtr) (component *, adouble*),
00050                int noOfVariables, VHDLType **Qty);
00051 
00053   virtual eqnType getEquationType() {
00054     return equationType;
00055   }
00056 
00058   virtual ~freeEquation(void);
00059 
00061   virtual void init();
00062 
00064   virtual int pointerAllocation();
00065 
00072   virtual int findBranch(int posNode, int negNode);
00073 
00075   virtual int load();
00076 
00078   virtual char * getEquationKind(){
00079     return "FREE";   
00080   }
00081 
00083   Quantity **getQuantities();
00084    
00086   int getNumberOfQuantities();
00087 
00089   list<int*> *formNodeSet();
00090 
00092   virtual bool getConsCheck(){
00093     return conservativeCheck;
00094   }
00095   
00100   int findFreeQuantity(int toCheck);
00101 
00104   virtual component* getImplicitEquationList();
00105 
00107   virtual void add(component *comp);
00108   
00115   int loadImplicitEqns(Quantity* qty);
00116 
00119   int loadImplicitEqns();
00120 
00122   void initializeImplicitEqns();
00123   
00125   int pointerAllocationForImplicitEqns();
00126 
00127 protected:
00128 
00129 private:
00131   adouble (*functionPointer) (component *, adouble*);
00132    
00134   spREAL **dcMatrixPointers;
00135 
00137   spREAL **transientMatrixPointers;
00138 
00140   int branch;
00141 
00143   int numberOfQuantities;
00144 
00146   Quantity** freeQty;
00147     
00149   bool conservativeCheck;
00150 
00152   int* base;
00153 
00155   component *implicitEquationList;
00156 
00157 };
00158 
00159 #endif

Generated on Fri Mar 31 11:05:08 2006 for Tyvis by  doxygen 1.4.6