Main Page   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members   Related Pages  

rdManager.h

00001 // rdManager.h
00002 //+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
00003 // Copyright 2000, 2002, 2003 Realistic Dynamics, Inc.
00004 // All rights reserved.
00005 //
00006 // Please do not read, copy, distribute, or use without permission.
00007 // Contact: Frank C. Anderson, fca@RealisticDynamics.com
00008 //+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
00009 #ifndef __rdManager_h__
00010 #define __rdManager_h__
00011 
00012 
00013 // INCLUDES
00014 #include <rdObject.h>
00015 #include "rdSimulationDLL.h"
00016 #include <stdlib.h>
00017 #include <stdio.h>
00018 #include <rdTools.h>
00019 #include <rdModel.h>
00020 #include <rdControlSet.h>
00021 #include <rdIntegRKF.h>
00022 
00023 
00024 //=============================================================================
00025 //=============================================================================
00029 class RDSIMULATION_API rdManager
00030 {
00031 
00032 //=============================================================================
00033 // DATA
00034 //=============================================================================
00035 private:
00037    char _sessionName[rdObject_NAME_LENGTH];
00039    rdModel *_model;
00041    int _ny;
00043    double *_y;
00045    int _nyp;
00047    double *_yp;
00049    rdControlSet *_controlSet;
00052    rdControlSet *_defaultControlSet;
00054    rdIntegRKF *_integ;
00056    double _ti;
00058    double _tf;
00060    double _firstDT;
00061 
00062 //=============================================================================
00063 // METHODS
00064 //=============================================================================
00065 public:
00066    virtual ~rdManager();
00067    rdManager(rdModel *model,rdControlSet *aControlSet=NULL);
00068 private:
00069    void setNull();
00070    bool constructStates();
00071    bool constructIntegrator();
00072    bool constructStorage();
00073 
00074    //--------------------------------------------------------------------------
00075    // GET AND SET
00076    //--------------------------------------------------------------------------
00077 public:
00078    void setSessionName(const char *name);
00079    const char* getSessionName() const;
00080    rdModel* getModel() const;
00081    rdControlSet* setControlSet(rdControlSet *aControlSet);
00082    rdControlSet* getControlSet() const;
00083    rdIntegRKF* getIntegrator() const;
00084    void setInitialTime(double aTI);
00085    double getInitialTime() const;
00086    void setFinalTime(double aTF);
00087    double getFinalTime() const;
00088    void setFirstDT(double aDT);
00089    double getFirstDT() const;
00090 
00091    //--------------------------------------------------------------------------
00092    // EXECUTION
00093    //--------------------------------------------------------------------------
00094    bool initializeStates();
00095    bool initializeStates(double *aY,double *aYP=NULL);
00096    bool integrate();
00097    bool integrate(int startIndex);
00098    bool integrate(double startTime);
00099 
00100    //--------------------------------------------------------------------------
00101    // UTILITY
00102    //--------------------------------------------------------------------------
00103    rdControlSet* constructControlSet();
00104 
00105    //--------------------------------------------------------------------------
00106    // PRINT
00107    //--------------------------------------------------------------------------
00108 
00109 
00110 //=============================================================================
00111 }; // END of class rdManager
00112 //=============================================================================
00113 //=============================================================================
00114 
00115 #endif  // __rdManager_h__
00116 

Generated on Wed Aug 20 02:17:06 2003 for Simulation Software by doxygen1.3