This repository has been archived by the owner on Mar 4, 2023. It is now read-only.
/
MappedField.py
380 lines (345 loc) · 20.1 KB
/
MappedField.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
from abaqusConstants import *
from .AnalyticalField import AnalyticalField
from .OdbMeshRegionData import OdbMeshRegionData
class MappedField(AnalyticalField):
"""The MappedField object defines a spatially varying field whose value is calculated from
an external source data.
The MappedField object is derived from the AnalyticalField object.
Attributes
----------
name: str
A String specifying the repository key.
regionType: SymbolicConstant
A SymbolicConstant specifying the data source region type. It can be either an ODB mesh
or a cloud of points. Possible values are MESH and POINT. The default value is POINT.
partLevelData: Boolean
A Boolean specifying whether or not the point cloud source data are described in terms
of part level coordinates. If part level coordinates is employed, the local coordinate
system defined in **localCsys** will be ignored. The default value is OFF.
pointDataFormat: SymbolicConstant
A SymbolicConstant specifying point cloud source data format. Possible values are GRID
and XYZ. The default value is XYZ.
gridPointPlane: SymbolicConstant
A SymbolicConstant specifying the plane on which the point cloud source data of grid
format are described. Possible values are XYPLANE, YZPLANE, and XZPLANE. The default
value is XYPLANE.
defaultUnMappedValue: float
A Float specifying default parameter (field) value of target model region while its
value cannot be calculated from the data source. The default value is 0.0.
mappingAlgorithm: SymbolicConstant
A SymbolicConstant specifying the mapping algorithm for target surface, or on mesh
target model when the parameter value are located at nodes, for example nodal
temperatures. Possible values are SURFACE and VOLUMETRIC. The default value is SURFACE.
searchTolType: SymbolicConstant
A SymbolicConstant specifying searching tolerance type in terms of absolute value or a
fraction of the average of all element characteristic length in target model region.
Possible values are ABSOLUTE and RELATIVE. The default value is RELATIVE.
boundarySearchTol: float
A Float specifying the search distance tolerance value on the exterior boundary of
target model region. Source points within this distance will be included in computing
the parameter value of target region. This tolerance applies to both surface and
volumetric mapping. The default value is 0.01.
neighborhoodSearchTol: float
A Float specifying the search distance tolerance value used for distance weighting
algorithm. Source points within this distance will be included in computing the
parameter value of target region. This tolerance only applies to surface mapping. The
default value is 1000000.0.
negativeNormalSearchTol: float
A Float specifying the search distance tolerance value in the negative normal of target
surface region. Source points within this distance will be included in computing the
parameter value of target region. This tolerance only applies to surface mapping. The
default value is 0.15.
positiveNormalSearchTol: float
A Float specifying the search distance tolerance value in the positive normal of target
surface region. Source points within this distance will be included in computing the
parameter value of target region. This tolerance only applies to surface mapping. The
default value is 0.05.
scaleCoordinates: Boolean
A Boolean specifying whether or not to scale the user-supplied coordinate values from
the point cloud or indicated ODB. The default value is OFF.
gridPointData: tuple
A tuple of tuples of Floats specifying the point cloud source data of grid format. The
default value is an empty sequence.
xyzPointData: tuple
A tuple of tuples of Floats specifying the point cloud source data of XYZ format. Each
data item is defining the XYZ coordinates of a point and its field value. The default
value is an empty sequence.
odbMeshRegionData: OdbMeshRegionData
An :py:class:`~abaqus.Field.OdbMeshRegionData.OdbMeshRegionData` object specifying the external source data from ODB mesh region.
coordinateScalingFactors: float
A tuple of Floats specifying the scaling factors for the global 1, 2 and 3 directions.
The default value is (1.0, 1.0, 1.0).
localCsys: str
None or a :py:class:`~abaqus.Datum.DatumCsys.DatumCsys` object specifying the local coordinate system of the field. If
**localCsys=None**, the field is defined in the global coordinate system. The default
value is None.
description: str
A String specifying the description of the field. The default value is an empty string.
Notes
-----
This object can be accessed by:
.. code-block:: python
import fields
mdb.models[name].analyticalFields[name]
"""
# A String specifying the repository key.
name: str = ""
# A SymbolicConstant specifying the data source region type. It can be either an ODB mesh
# or a cloud of points. Possible values are MESH and POINT. The default value is POINT.
regionType: SymbolicConstant = POINT
# A Boolean specifying whether or not the point cloud source data are described in terms
# of part level coordinates. If part level coordinates is employed, the local coordinate
# system defined in *localCsys* will be ignored. The default value is OFF.
partLevelData: Boolean = OFF
# A SymbolicConstant specifying point cloud source data format. Possible values are GRID
# and XYZ. The default value is XYZ.
pointDataFormat: SymbolicConstant = XYZ
# A SymbolicConstant specifying the plane on which the point cloud source data of grid
# format are described. Possible values are XYPLANE, YZPLANE, and XZPLANE. The default
# value is XYPLANE.
gridPointPlane: SymbolicConstant = XYPLANE
# A Float specifying default parameter (field) value of target model region while its
# value cannot be calculated from the data source. The default value is 0.0.
defaultUnMappedValue: float = 0
# A SymbolicConstant specifying the mapping algorithm for target surface, or on mesh
# target model when the parameter value are located at nodes, for example nodal
# temperatures. Possible values are SURFACE and VOLUMETRIC. The default value is SURFACE.
mappingAlgorithm: SymbolicConstant = SURFACE
# A SymbolicConstant specifying searching tolerance type in terms of absolute value or a
# fraction of the average of all element characteristic length in target model region.
# Possible values are ABSOLUTE and RELATIVE. The default value is RELATIVE.
searchTolType: SymbolicConstant = RELATIVE
# A Float specifying the search distance tolerance value on the exterior boundary of
# target model region. Source points within this distance will be included in computing
# the parameter value of target region. This tolerance applies to both surface and
# volumetric mapping. The default value is 0.01.
boundarySearchTol: float = 0
# A Float specifying the search distance tolerance value used for distance weighting
# algorithm. Source points within this distance will be included in computing the
# parameter value of target region. This tolerance only applies to surface mapping. The
# default value is 1000000.0.
neighborhoodSearchTol: float = 1000000
# A Float specifying the search distance tolerance value in the negative normal of target
# surface region. Source points within this distance will be included in computing the
# parameter value of target region. This tolerance only applies to surface mapping. The
# default value is 0.15.
negativeNormalSearchTol: float = 0
# A Float specifying the search distance tolerance value in the positive normal of target
# surface region. Source points within this distance will be included in computing the
# parameter value of target region. This tolerance only applies to surface mapping. The
# default value is 0.05.
positiveNormalSearchTol: float = 0
# A Boolean specifying whether or not to scale the user-supplied coordinate values from
# the point cloud or indicated ODB. The default value is OFF.
scaleCoordinates: Boolean = OFF
# A tuple of tuples of Floats specifying the point cloud source data of grid format. The
# default value is an empty sequence.
gridPointData: tuple = ()
# A tuple of tuples of Floats specifying the point cloud source data of XYZ format. Each
# data item is defining the XYZ coordinates of a point and its field value. The default
# value is an empty sequence.
xyzPointData: tuple = ()
# An OdbMeshRegionData object specifying the external source data from ODB mesh region.
odbMeshRegionData: OdbMeshRegionData = None
# A tuple of Floats specifying the scaling factors for the global 1, 2 and 3 directions.
# The default value is (1.0, 1.0, 1.0).
coordinateScalingFactors: float = None
# None or a DatumCsys object specifying the local coordinate system of the field. If
# *localCsys*=None, the field is defined in the global coordinate system. The default
# value is None.
localCsys: str = None
# A String specifying the description of the field. The default value is an empty string.
description: str = ""
def __init__(
self,
name: str,
regionType: SymbolicConstant = POINT,
partLevelData: Boolean = OFF,
pointDataFormat: SymbolicConstant = XYZ,
gridPointPlane: SymbolicConstant = XYPLANE,
defaultUnMappedValue: float = 0,
mappingAlgorithm: SymbolicConstant = SURFACE,
searchTolType: SymbolicConstant = RELATIVE,
boundarySearchTol: float = 0,
neighborhoodSearchTol: float = 1000000,
negativeNormalSearchTol: float = 0,
positiveNormalSearchTol: float = 0,
scaleCoordinates: Boolean = OFF,
gridPointData: tuple = (),
xyzPointData: tuple = (),
coordinateScalingFactors: tuple = (),
localCsys: str = None,
description: str = "",
):
"""This method creates an MappedField object.
Notes
-----
This function can be accessed by:
.. code-block:: python
mdb.models[name].MappedField
Parameters
----------
name
A String specifying the repository key.
regionType
A SymbolicConstant specifying the data source region type. It can be either an ODB mesh
or a cloud of points. Possible values are MESH and POINT. The default value is POINT.
partLevelData
A Boolean specifying whether or not the point cloud source data are described in terms
of part level coordinates. If part level coordinates is employed, the local coordinate
system defined in *localCsys* will be ignored. The default value is OFF.
pointDataFormat
A SymbolicConstant specifying point cloud source data format. Possible values are GRID
and XYZ. The default value is XYZ.
gridPointPlane
A SymbolicConstant specifying the plane on which the point cloud source data of grid
format are described. Possible values are XYPLANE, YZPLANE, and XZPLANE. The default
value is XYPLANE.
defaultUnMappedValue
A Float specifying the parameter (field) value reported when a value cannot be
calculated from the data source. The default value is 0.0.
mappingAlgorithm
A SymbolicConstant specifying the mapping algorithm for target surface, or on mesh
target model when the parameter value are located at nodes, for example nodal
temperatures. Possible values are SURFACE and VOLUMETRIC. The default value is SURFACE.
searchTolType
A SymbolicConstant specifying searching tolerance type in terms of absolute value or a
fraction of the average of all element characteristic length in target model region.
Possible values are ABSOLUTE and RELATIVE. The default value is RELATIVE.
boundarySearchTol
A Float specifying the search distance tolerance value on the exterior boundary of
target model region. Source points within this distance will be included in computing
the parameter value of target region. This tolerance applies to both surface and
volumetric mapping. The default value is 0.01.
neighborhoodSearchTol
A Float specifying the search distance tolerance value used for distance weighting
algorithm. Source points within this distance will be included in computing the
parameter value of target region. This tolerance only applies to surface mapping. The
default value is 1000000.0.
negativeNormalSearchTol
A Float specifying the search distance tolerance value in the negative normal of target
surface region. Source points within this distance will be included in computing the
parameter value of target region. This tolerance only applies to surface mapping. The
default value is 0.15.
positiveNormalSearchTol
A Float specifying the search distance tolerance value in the positive normal of target
surface region. Source points within this distance will be included in computing the
parameter value of target region. This tolerance only applies to surface mapping. The
default value is 0.05.
scaleCoordinates
A Boolean specifying whether or not to scale the user-supplied coordinate values from
the point cloud or indicated ODB. The default value is OFF.
gridPointData
A sequence of sequences of Floats specifying the point cloud source data of grid format.
The default value is an empty sequence.
xyzPointData
A sequence of sequences of Floats specifying the point cloud source data of XYZ format.
Each data item is defining the XYZ coordinates of a point and its field value. The
default value is an empty sequence.
coordinateScalingFactors
A sequence of Floats specifying the scaling factors for the global 1, 2 and 3
directions. The default value is (1.0, 1.0, 1.0).
localCsys
None or a DatumCsys object specifying the local coordinate system of the field. If
*localCsys*=None, the field is defined in the global coordinate system. The default
value is None.
description
A String specifying the description of the field. The default value is an empty string.
Returns
-------
A MappedField object.
Raises
------
AbaqusException.
"""
super().__init__()
pass
def setValues(
self,
regionType: SymbolicConstant = POINT,
partLevelData: Boolean = OFF,
pointDataFormat: SymbolicConstant = XYZ,
gridPointPlane: SymbolicConstant = XYPLANE,
defaultUnMappedValue: float = 0,
mappingAlgorithm: SymbolicConstant = SURFACE,
searchTolType: SymbolicConstant = RELATIVE,
boundarySearchTol: float = 0,
neighborhoodSearchTol: float = 1000000,
negativeNormalSearchTol: float = 0,
positiveNormalSearchTol: float = 0,
scaleCoordinates: Boolean = OFF,
gridPointData: tuple = (),
xyzPointData: tuple = (),
coordinateScalingFactors: tuple = (),
localCsys: str = None,
description: str = "",
):
"""This method modifies the MappedField object.
Parameters
----------
regionType
A SymbolicConstant specifying the data source region type. It can be either an ODB mesh
or a cloud of points. Possible values are MESH and POINT. The default value is POINT.
partLevelData
A Boolean specifying whether or not the point cloud source data are described in terms
of part level coordinates. If part level coordinates is employed, the local coordinate
system defined in *localCsys* will be ignored. The default value is OFF.
pointDataFormat
A SymbolicConstant specifying point cloud source data format. Possible values are GRID
and XYZ. The default value is XYZ.
gridPointPlane
A SymbolicConstant specifying the plane on which the point cloud source data of grid
format are described. Possible values are XYPLANE, YZPLANE, and XZPLANE. The default
value is XYPLANE.
defaultUnMappedValue
A Float specifying the parameter (field) value reported when a value cannot be
calculated from the data source. The default value is 0.0.
mappingAlgorithm
A SymbolicConstant specifying the mapping algorithm for target surface, or on mesh
target model when the parameter value are located at nodes, for example nodal
temperatures. Possible values are SURFACE and VOLUMETRIC. The default value is SURFACE.
searchTolType
A SymbolicConstant specifying searching tolerance type in terms of absolute value or a
fraction of the average of all element characteristic length in target model region.
Possible values are ABSOLUTE and RELATIVE. The default value is RELATIVE.
boundarySearchTol
A Float specifying the search distance tolerance value on the exterior boundary of
target model region. Source points within this distance will be included in computing
the parameter value of target region. This tolerance applies to both surface and
volumetric mapping. The default value is 0.01.
neighborhoodSearchTol
A Float specifying the search distance tolerance value used for distance weighting
algorithm. Source points within this distance will be included in computing the
parameter value of target region. This tolerance only applies to surface mapping. The
default value is 1000000.0.
negativeNormalSearchTol
A Float specifying the search distance tolerance value in the negative normal of target
surface region. Source points within this distance will be included in computing the
parameter value of target region. This tolerance only applies to surface mapping. The
default value is 0.15.
positiveNormalSearchTol
A Float specifying the search distance tolerance value in the positive normal of target
surface region. Source points within this distance will be included in computing the
parameter value of target region. This tolerance only applies to surface mapping. The
default value is 0.05.
scaleCoordinates
A Boolean specifying whether or not to scale the user-supplied coordinate values from
the point cloud or indicated ODB. The default value is OFF.
gridPointData
A sequence of sequences of Floats specifying the point cloud source data of grid format.
The default value is an empty sequence.
xyzPointData
A sequence of sequences of Floats specifying the point cloud source data of XYZ format.
Each data item is defining the XYZ coordinates of a point and its field value. The
default value is an empty sequence.
coordinateScalingFactors
A sequence of Floats specifying the scaling factors for the global 1, 2 and 3
directions. The default value is (1.0, 1.0, 1.0).
localCsys
None or a DatumCsys object specifying the local coordinate system of the field. If
*localCsys*=None, the field is defined in the global coordinate system. The default
value is None.
description
A String specifying the description of the field. The default value is an empty string.
"""
pass