VR-Forces 5.0.2 Developer's Guide
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
1DRegularTableFn.h
Go to the documentation of this file.
1 /*********************************************************************
2 ** Copyright (c) 2013 MaK Technologies, Inc.
3 ** All rights reserved.
4 *********************************************************************/
5 
8 
9 #pragma once
10 
11 #include <stdio.h>
12 #include <vlutil/vlMachineTypes.h>
14 #include <readerWriter/rwReal.h>
16 
23 
24 #include "vrfutil/vrfutilDefines.h"
26 {
27 public:
28 
31 
34  parentRegistry = NULL);
36  parentRegistry = NULL);
37 
39  Dt1DRegularTableFn(const DtReal bottom,
40  const DtReal top,
41  const DtReal inc,
42  const DtReal* data);
43 
45  virtual ~Dt1DRegularTableFn();
46 
49 
51  Dt1DRegularTableFn(const DtString& name, const Dt1DRegularTableFn& orig,
52  DtReaderWriterRegistry* parentRegistry = NULL);
53  Dt1DRegularTableFn(const DtSymbolString& name, const Dt1DRegularTableFn& orig,
54  DtReaderWriterRegistry* parentRegistry = NULL);
55 
58 
60  virtual bool init(const DtReal value);
61 
67  virtual bool init(const DtReal bottom, const DtReal top, const DtReal inc,
68  const DtReal* data);
69 
71  virtual bool init(const DtReal bottom, const DtReal top, const DtReal inc,
72  const DtNLengthRealVector& data);
73 
77  virtual const char* readerWriterType() const;
78 
79  bool operator==(const Dt1DRegularTableFn&) const;
80 
81 private:
85 
86 public:
87 
89  virtual DtReal lookup(DtReal coordinate1,...) const;
90  virtual DtReal lookup(const DtReal* coordinates) const;
91 
93  virtual DtReal integrate(DtReal lower, DtReal upper,...) const;
94 
96  virtual void getSelf(DtlObjPtr args, const DtReaderWriter::SearchPaths& searchPaths,
97  const DtVariableBindingsList& variableBindings);
98 
100  virtual void putData(std::string& fp, int indentLevel = 0);
101  virtual DtlObjPtr getData(DtlObjPtr args, const DtReaderWriter::SearchPaths& searchPaths,
102  const DtVariableBindingsList& variableBindings);
103 
105  void putSelf(std::string& fp, int indentLevel = 0, bool writeUnspecified = false,
106  const DtFilename& path = DtReaderWriter::appPath());
107 
108 protected:
109 
110  DtReal mySpan;
115  DtReal * myDomain;
116  DtReal * mySlope;
117 
118 };
bool operator==(const DtReaderWriter &) const
Equivalence operator.
DtNLengthRealVector myData
Definition: 1DRegularTableFn.h:114
Definition: symbolString.h:20
virtual void putData(std::string &fp, int indentLevel=0)=0
Write/get data.
DtReal * myDomain
Definition: 1DRegularTableFn.h:115
DtReal mySpan
Definition: 1DRegularTableFn.h:110
class Dt1DRegularTableFn:
Definition: 1DRegularTableFn.h:25
virtual const char * readerWriterType() const
Used to supply a string type that this reader writer type is. This can be used in place of dynamic-ca...
Definition: readerWriterRegistry.h:39
DtBaseTableFunction & operator=(const DtBaseTableFunction &orig)
assignment operator
virtual DtlObjPtr getData(DtlObjPtr args, const DtReaderWriter::SearchPaths &searchPaths, const DtVariableBindingsList &variableBindings)=0
Deriving class overrides these to get/put class specific data.
DtRwReal myDomainBottom
Definition: 1DRegularTableFn.h:112
std::list< const DtRwVariableBindings * > DtVariableBindingsList
Definition: readerWriterRegistry.h:29
std::vector< DtFilename > SearchPaths
Definition: readerWriter.h:92
Description: DtNLengthRealVector is a named, readable/writable vector of integers of arbitrary length...
Definition: nLengthRealVector.h:26
virtual void getSelf(DtlObjPtr args, const DtReaderWriter::SearchPaths &searchPaths=SearchPaths(), const DtVariableBindingsList &variableBindings=nullVariableReference())
Top level to read itself from an input stream. searchPath is passed down to all DtReaderWriter member...
virtual void putSelf(std::string &fp, int indentLevel=0, bool writeUnspecified=false, const DtFilename &path=DtFilename::nullFilename())
Top level call to write itself to file. If write unspecified is true, will write entries that are uns...
Description: Readable, Writable DtReal (double)
Definition: rwReal.h:27
class DtBaseTableFunction:
Definition: baseTableFunction.h:25
#define DT_DLL_vrfutil
This file is used to determine how to build Disable inconsistent dll linkage warning Visual Studio 6...
Definition: vrfutilDefines.h:34
virtual DtReal integrate(DtReal lower0, DtReal upper0,...) const =0
Integrate the function over a range.
DtRwReal myDomainTop
Definition: 1DRegularTableFn.h:111
DtRwReal myInc
Definition: 1DRegularTableFn.h:113
virtual bool init(DtU32 dim)
Initialize the function to a dimension.
DtReal * mySlope
Definition: 1DRegularTableFn.h:116
static const DtFilename & appPath()
Gets the current working directory. The first time this accessor is called, it determines the current...
virtual DtReal lookup(DtReal coordinate1,...) const =0
Look up data.

Document ID: Generated on Sun Dec 4 20:22:03 EST 2022 from SVN revision 249613
Copyright © 2005-2021 MAK Technologies. All Rights Reserved (www.mak.com)