Overture
Version 25
Main Page
Namespaces
Classes
Files
File List
File Members
Overture.v25.d
include
UserDefinedMapping1.h
Go to the documentation of this file.
1
#ifndef USER_DEFINED_MAPPING1_H
2
#define USER_DEFINED_MAPPING1_H "UserDefinedMapping1.h"
3
4
#include "
Mapping.h
"
5
6
//-------------------------------------------------------------
7
// Here is a derived class to define a user defined mapping
8
//
9
//-------------------------------------------------------------
10
11
class
UserDefinedMapping1
:
public
Mapping
12
{
13
public
:
14
15
// Here are different options
16
enum
UserDefinedMappingEnum
17
{
18
unitSquare
,
19
helicalWire
,
20
filletForTwoCylinders
,
21
blade
22
};
23
24
25
26
27
UserDefinedMapping1
();
28
29
// Copy constructor is deep by default
30
UserDefinedMapping1
(
const
UserDefinedMapping1
&,
const
CopyType
copyType=
DEEP
);
31
32
~UserDefinedMapping1
();
33
34
UserDefinedMapping1
&
operator =
(
const
UserDefinedMapping1
& X0 );
35
36
void
map
(
const
realArray
&
r
,
realArray
& x,
realArray
& xr =
Overture::nullRealDistributedArray
(),
37
MappingParameters
& params =
Overture::nullMappingParameters
() );
38
39
void
basicInverse
(
const
realArray
& x,
realArray
& r,
realArray
& rx =
Overture::nullRealDistributedArray
(),
40
MappingParameters
& params =
Overture::nullMappingParameters
() );
41
42
virtual
void
mapS
(
const
RealArray
& r,
RealArray
& x,
RealArray
&xr =
Overture::nullRealArray
(),
43
MappingParameters
& params =
Overture::nullMappingParameters
());
44
45
virtual
void
basicInverseS
(
const
RealArray
& x,
46
RealArray
& r,
47
RealArray
& rx =
Overture::nullRealArray
(),
48
MappingParameters
& params =
Overture::nullMappingParameters
());
49
50
virtual
int
get
(
const
GenericDataBase
& dir,
const
aString
& name);
// get from a database file
51
virtual
int
put
(
GenericDataBase
& dir,
const
aString
& name)
const
;
// put to a database file
52
53
void
getParameters
(
IntegerArray
& ipar,
RealArray
& rpar )
const
;
54
void
setParameters
(
const
IntegerArray
& ipar,
const
RealArray
& rpar );
55
56
Mapping
*
make
(
const
aString
&
mappingClassName
);
57
aString
getClassName
()
const
{
return
UserDefinedMapping1::className
; }
58
59
int
update
(
MappingInformation
& mapInfo ) ;
60
61
protected
:
62
63
UserDefinedMappingEnum
mappingType
;
64
65
aString
className
;
66
RealArray
rp
;
67
IntegerArray
ip
;
68
69
int
bladeSetup
(
MappingInformation
& mapInfo);
70
71
private
:
72
//
73
// Virtual member functions used only through class ReferenceCounting:
74
//
75
virtual
ReferenceCounting
&
operator=
(
const
ReferenceCounting
& x)
76
{
return
operator=
((
UserDefinedMapping1
&)x); }
77
virtual
void
reference(
const
ReferenceCounting
& x)
78
{ reference((
UserDefinedMapping1
&)x); }
// *** Conversion to this class for the virtual = ****
79
virtual
ReferenceCounting
* virtualConstructor(
const
CopyType
ct =
DEEP
)
const
80
{ return ::new
UserDefinedMapping1
(*
this
, ct); }
81
82
};
83
84
85
#endif
86
87
Generated on Fri Jan 4 2013 10:18:01 for Overture by
1.8.3