This repository has been archived by the owner on Mar 4, 2023. It is now read-only.
/
XYData.py
746 lines (675 loc) · 33.6 KB
/
XYData.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
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
import typing
from abaqusConstants import *
from .QuantityType import QuantityType
from ..PathAndProbe.Path import Path
# prevent circular imports
class Odb:
pass
class XYData:
"""The XYData object is used to store values and attributes associated with XYData type
objects.
XYData objects can be created using the methods described below. The methods accessed
via the Session object cause the XYData object to be added to the session.xyData
repository.
Temporary XYData objects will be created if no name is supplied. Temporary XYData
objects will be added to the session.xyData repository but automatically deleted when
they are not used anymore. Temporary XYData objects are also created as a result of math
operations found in the abaqusMath module.
Attributes
----------
sourceType: SymbolicConstant
A SymbolicConstant specifying the source type of the :py:class:`~abaqus.XY.XYData.XYData` object. Possible values are
FROM_ODB, FROM_KEYBOARD, FROM_ASCII_FILE, FROM_OPERATION, and FROM_USER_DEFINED.
fileName: str
A String specifying the source file name of the :py:class:`~abaqus.XY.XYData.XYData` object.
description: str
A String specifying the complete description of the :py:class:`~abaqus.XY.XYData.XYData` object.
Notes
-----
This object can be accessed by:
.. code-block:: python
import visualization
session.charts[name].axes1[i].axisData.curves[i].data
session.charts[name].axes2[i].axisData.curves[i].data
session.charts[name].curves[name].data
session.curves[name].data
session.defaultChartOptions.defaultAxis1Options.axisData.curves[i].data
session.defaultChartOptions.defaultAxis2Options.axisData.curves[i].data
import odbAccess
session.odbs[name].userData.xyDataObjects[name]
session.xyDataObjects[name]
session.xyPlots[name].charts[name].axes1[i].axisData.curves[i].data
session.xyPlots[name].charts[name].axes2[i].axisData.curves[i].data
session.xyPlots[name].charts[name].curves[name].data
session.xyPlots[name].curves[name].data
"""
# A SymbolicConstant specifying the source type of the XYData object. Possible values are
# FROM_ODB, FROM_KEYBOARD, FROM_ASCII_FILE, FROM_OPERATION, and FROM_USER_DEFINED.
sourceType: SymbolicConstant = None
# A String specifying the source file name of the XYData object.
fileName: str = ""
# A String specifying the complete description of the XYData object.
description: str = ""
@typing.overload
def __init__(
self,
data: tuple,
name: str = "",
sourceDescription: str = "",
contentDescription: str = "",
positionDescription: str = "",
legendLabel: str = "",
xValuesLabel: str = "",
yValuesLabel: str = "",
axis1QuantityType: QuantityType = QuantityType(),
axis2QuantityType: QuantityType = QuantityType(),
):
"""This method creates an XYData object from a sequence of *X–Y* data pairs.
Notes
-----
This function can be accessed by:
.. code-block:: python
session.XYData
xyPlot.XYData
Parameters
----------
data
A sequence of pairs of Floats specifying the *X–Y* data pairs.
name
The repository key. If the name is not supplied while creating the XYData object using
xyPlot.XYData, a default name in the form _temp#_ is generated and the XYData object is
temporary. (This argument is required if the method is accessed from the session
object.)
sourceDescription
A String specifying the source of the *X–Y* data (e.g., “Entered from keyboard”, “Taken
from ASCII file”, “Read from an ODB”, etc.). The default value is an empty string.
contentDescription
A String specifying the content of the *X–Y* data (e.g., “field 1 vs. field 2”). The
default value is an empty string.
positionDescription
A String specifying additional information about the *X–Y* data (e.g., “for whole
model”). The default value is an empty string.
legendLabel
A String specifying the label to be used in the legend. The default value is the name of
the XYData object.
xValuesLabel
A String specifying the label for the X-values. This value may be overridden if the
*X–Y* data are combined with other *X–Y* data. The default value is an empty string.
yValuesLabel
A String specifying the label for the Y-values. This value may be overridden if the
*X–Y* data are combined with other *X–Y* data. The default value is an empty string.
axis1QuantityType
A QuantityType object specifying the QuantityType object associated to the X -axis1-
values.
axis2QuantityType
A QuantityType object specifying the QuantityType object associated to the Y -axis2-
values.
Returns
-------
An XYData object.
"""
pass
@typing.overload
def __init__(self, objectToCopy: "XYData"):
"""This method creates an XYData object by copying an existing XYData object.
Notes
-----
This function can be accessed by:
.. code-block:: python
session.XYData
xyPlot.XYData
Parameters
----------
objectToCopy
An XYData object to be copied.
Returns
-------
An XYData object.
"""
pass
def __init__(self, *args, **kwargs):
pass
def XYDataFromFile(
self,
fileName: str,
name: str = "",
sourceDescription: str = "",
contentDescription: str = "",
positionDescription: str = "",
legendLabel: str = "",
xValuesLabel: str = "",
yValuesLabel: str = "",
axis1QuantityType: QuantityType = QuantityType(),
axis2QuantityType: QuantityType = QuantityType(),
xField: int = 1,
yField: int = 2,
skipFrequency: int = None,
):
"""This method creates an XYData object from data in an ASCII file.
Notes
-----
This function can be accessed by:
.. code-block:: python
session.XYData
xyPlot.XYData
Parameters
----------
fileName
A String specifying the name of the file from which the *X–Y* data will be read.
name
The repository key. If the name is not supplied, a default name in the form _temp#_ is
generated and the XYData object is temporary.
sourceDescription
A String specifying the source of the *X–Y* data (e.g., “Entered from keyboard”, “Taken
from ASCII file”, “Read from an ODB”, etc.). The default value is an empty string.
contentDescription
A String specifying the content of the *X–Y* data (e.g., “field 1 vs. field 2”). The
default value is an empty string.
positionDescription
A String specifying additional information about the *X–Y* data (e.g., “for whole
model”). The default value is an empty string.
legendLabel
A String specifying the label to be used in the legend. The default value is the name of
the XYData object.
xValuesLabel
A String specifying the label for the X-values. This value may be overridden if the
*X–Y* data are combined with other *X–Y* data. The default value is an empty string.
yValuesLabel
A String specifying the label for the Y-values. This value may be overridden if the
*X–Y* data are combined with other *X–Y* data. The default value is an empty string.
axis1QuantityType
A QuantityType object specifying the QuantityType object associated to the X -axis1-
values.
axis2QuantityType
A QuantityType object specifying the QuantityType object associated to the Y -axis2-
values.
xField
An Int specifying the field from which the *X*-data will be read. Fields are delimited
by spaces, tabs, or commas. The default value is 1.
yField
An Int specifying the field from which the *Y*-data will be read. Fields are delimited
by spaces, tabs, or commas. The default value is 2.
skipFrequency
An Int specifying how often data rows will be skipped. A *skipFrequency* of 1 means skip
every other row. The first row is always read. Possible values are *skipFrequency* ≥≥ 0.
The default value is 0 (data are read from every row).
Returns
-------
An XYData object.
Raises
------
InvalidNameError
RangeError
"""
pass
def XYDataFromHistory(
self,
odb: Odb,
outputVariableName: str,
steps: tuple,
name: str = "",
sourceDescription: str = "",
contentDescription: str = "",
positionDescription: str = "",
legendLabel: str = "",
skipFrequency: int = None,
numericForm: SymbolicConstant = REAL,
complexAngle: float = 0,
stepTuple: int = None,
):
"""This method creates an XYData object by reading history data from an Odb object.
Notes
-----
This function can be accessed by:
.. code-block:: python
session.XYData
xyPlot.XYData
Parameters
----------
odb
An Odb object specifying the output database from which data will be read.
outputVariableName
A String specifying the output variable from which the *X–Y* data will be read.
steps
A sequence of Strings specifying the names of the steps from which data will be
extracted.
name
The repository key. If the name is not supplied, a default name in the form _temp#_ is
generated and the XYData object is temporary (this argument is required if the method is
accessed from the session object).
sourceDescription
A String specifying the source of the *X–Y* data (for example, “Entered from keyboard”,
“Taken from ASCII file”, “Read from an ODB”, etc.). The default value is an empty
string.
contentDescription
A String specifying the content of the *X–Y* data (for example, “field 1 vs. field 2”).
The default value is an empty string.
positionDescription
A String specifying additional information about the *X–Y* data (for example, “for whole
model”). The default value is an empty string.
legendLabel
A String specifying the label to be used in the legend. The default value is the name of
the XYData object.
skipFrequency
An Int specifying how often data frames will be skipped. If *skipFrequency*=1, Abaqus
will skip every other frame. The first frame is always read. Possible values are
*skipFrequency* ≥≥ 0. The default value is 0 (data are read from every frame).
numericForm
A SymbolicConstant specifying the numeric form in which to display results that contain
complex numbers. Possible values are COMPLEX_MAGNITUDE, COMPLEX_PHASE, REAL, IMAGINARY,
and COMPLEX_VAL_AT_ANGLE. The default value is REAL.
complexAngle
A Float specifying the angle (in degrees) at which to display results that contain
complex numbers when *numericForm*=COMPLEX_VAL_AT_ANGLE. The default value is 0.
stepTuple
A tuple of Integers specifying the steps to include when extracting data.
Returns
-------
An XYData object.
Raises
------
InvalidNameError
RangeError
"""
pass
def xyDataListFromField(
self,
odb: Odb,
outputPosition: SymbolicConstant,
variable: tuple[tuple],
elementSets: tuple = (),
elementLabels: tuple = (),
nodeSets: tuple = (),
nodeLabels: tuple = (),
numericForm: SymbolicConstant = REAL,
complexAngle: float = 0,
operator: SymbolicConstant = None,
) -> list["XYData"]:
"""This method creates a list of XYData objects by reading field data from an Odb object.
Notes
-----
This function can be accessed by:
.. code-block:: python
session.XYData
xyPlot.XYData
Parameters
----------
odb
An Odb object specifying the output database from which data will be read.
outputPosition
A SymbolicConstant specifying the position from which output will be read. Possible
values are ELEMENT_CENTROID, ELEMENT_NODAL, INTEGRATION_POINT, and NODAL.
variable
A tuple of tuples containing the descriptions of variables for which to extract data
from the field. Each tuple specifies the following:Variable label: A String specifying
the variable; for example, 'U'.Variable output position: A SymbolicConstant specifying
the output position. Possible values are ELEMENT_CENTROID, ELEMENT_FACE, ELEMENT_NODAL,
GENERAL_PARTICLE, INTEGRATION_POINT, NODAL, WHOLE_ELEMENT, WHOLE_MODEL,
WHOLE_PART_INSTANCE, and WHOLE_REGION.Refinement: A tuple specifying the refinement. If
the refinement tuple is omitted, data are written for all components and invariants (if
applicable). This element is required if the location dictionary (the following element
in the tuple) is included. The refinement tuple contains the following:Type: A
SymbolicConstant specifying the type of refinement. Possible values are INVARIANT and
COMPONENT.Label: A String specifying the invariant or the component; for example,
'Mises' or 'S22'.Location: An optional Dictionary specifying the location. The
dictionary contains pairs of the following:A String specifying the category selection
label.A String specifying the section point label.For example,
variable=('S',INTEGRATION_POINT, ((COMPONENT, 'S22' ), ), )
variable=(('S',INTEGRATION_POINT, ((COMPONENT, 'S11' ), ), ), ('U',NODAL,((COMPONENT, 'U1'),)),)
variable=(('S', INTEGRATION_POINT, ((INVARIANT, 'Mises' ), ),{'shell < STEEL > < 3 section points >':'SNEG, (fraction = -1.0)', }), )
`
elementSets
A sequence of Strings specifying element sets or a String specifying a single element
set.
elementLabels
A sequence of expressions specifying element labels per part instance in the model. Each
part instance element expression is a sequence of a String specifying the part instance
name and a sequence of element expressions; for example,
`(('partInstance1',(1,'7','3:15;3'),), ('partInstance2','8'),))`. The element
expressions can be any of the following:An Int specifying a single element label; for
example, `1`.A String specifying a single element label; for example, `'7'`.A String
specifying a sequence of element labels; for example, `'3:5'` and `'3:15:3'`.
nodeSets
A sequence of Strings specifying node sets or a String specifying a single node set.
nodeLabels
A sequence of expressions specifying node labels per part instance in the model. Each
part instance node expression is a sequence of a String specifying the part instance
name and a sequence of node expressions; for example,
`(('partInstance1',(1,'7','3:15;3'),), ('partInstance2','8'),))`. The node expressions
can be any of the following:An Int specifying a single node label; for example, `1`.A
String specifying a single node label; for example, `'7'`.A String specifying a sequence
of node labels; for example, `'3:5'` and `'3:15:3'`.
numericForm
A SymbolicConstant specifying the numeric form in which to display results that contain
complex numbers. Possible values are COMPLEX_MAGNITUDE, COMPLEX_PHASE, REAL, IMAGINARY,
and COMPLEX_VAL_AT_ANGLE. The default value is REAL.
complexAngle
A Float specifying the angle (in degrees) at which to display results that contain
complex numbers when *numericForm*=COMPLEX_VAL_AT_ANGLE. The default value is 0.
operator
A SymbolicConstant specifying the mathematical, trigonometric, logarithmic, exponential,
or other operations. Possible values are ADD, SUBTRACT, MULTIPLY, DIVIDE, POWER,
MINIMUM, MAXIMUM, AVERAGE, RANGE, SRSS, ABSOLUTE, UNARY_NEGATIVE, COSINE,
HYPERBOLIC_COSINE, INVERSE_COSINE, SINE, HYPERBOLIC_SINE, INVERSE_SINE, TANGENT,
HYPERBOLIC_TANGENT, INVERSE_TANGENT, EXPONENTIAL, NATURAL_LOG, LOG, SQUARE_ROOT,
NORMALIZE, DEG2RAD, RAD2DEG, SMOOTH, SWAP, AVERAGE_ALL, MAXIMUM_ENVELOPE,
MINIMUM_ENVELOPE, and RANGE_ALL. If no value is defined, no operation will be performed
on the data, and the data will be saved as is.
Returns
-------
A list of XYData objects.
Raises
------
InvalidNameError
RangeError
"""
pass
def XYDataFromFreeBody(
self,
odb: Odb,
force: Boolean = ON,
moment: Boolean = OFF,
heatFlowRate: Boolean = OFF,
resultant: Boolean = ON,
comp1: Boolean = OFF,
comp2: Boolean = OFF,
comp3: Boolean = OFF,
):
"""This method creates a list of XYData objects by computing free body data from an Odb
object.
Notes
-----
This function can be accessed by:
.. code-block:: python
session.XYData
xyPlot.XYData
Parameters
----------
odb
An Odb object specifying the output database from which data will be read.
force
A boolean indicating whether to compute the force. The default is ON.
moment
A boolean indicating whether to compute the moment. The default is OFF.
heatFlowRate
A boolean indicating whether to compute the heat flow rate resultant magnitude. It is
extracted only for viewcut based freebodies. The default is OFF.
resultant
A boolean indicating whether to compute the resultant. It applies only to *force* and
*moment*. The default is ON.
comp1
A boolean indicating whether to compute the first component. It applies only to *force*
and *moment*. The default is OFF.
comp2
A boolean indicating whether to compute the second component. It applies only to *force*
and *moment*. The default is OFF.
comp3
A boolean indicating whether to compute the third component. It applies only to *force*
and *moment*. The default is OFF.
Returns
-------
A list of XYData objects.
Raises
------
InvalidNameError
RangeError
"""
pass
def XYDataFromShellThickness(
self,
odb: Odb,
outputPosition: SymbolicConstant,
variable: SymbolicConstant,
elementSets: tuple = (),
elementLabels: tuple = (),
nodeSets: tuple = (),
nodeLabels: tuple = (),
numericForm: SymbolicConstant = REAL,
complexAngle: float = 0,
):
"""This method creates a list of XYData objects by reading through the thickness field data
from an Odb object.
Notes
-----
This function can be accessed by:
.. code-block:: python
session.XYData
xyPlot.XYData
Parameters
----------
odb
An Odb object specifying the output database from which data will be read.
outputPosition
A SymbolicConstant specifying the position from which output will be read. Possible
values are ELEMENT_CENTROID, ELEMENT_NODAL, INTEGRATION_POINT, and NODAL.
variable
A tuple of tuples containing the descriptions of variables for which to extract data
from the field. Each tuple specifies the following:Variable label: A String specifying
the variable; for example, 'U'.Variable output position: A SymbolicConstant specifying
the output position. Possible values are ELEMENT_CENTROID, ELEMENT_FACE, ELEMENT_NODAL,
GENERAL_PARTICLE, INTEGRATION_POINT, NODAL, WHOLE_ELEMENT, WHOLE_MODEL,
WHOLE_PART_INSTANCE, and WHOLE_REGION.Refinement: A tuple specifying the refinement. If
the refinement tuple is omitted, data are written for all components and invariants (if
applicable). This element is required if the location dictionary (the following element
in the tuple) is included. The refinement tuple contains the following:Type: A
SymbolicConstant specifying the type of refinement. Possible values are INVARIANT and
COMPONENT.Label: A String specifying the invariant or the component; for example,
'Mises' or 'S22'.Location: An optional Dictionary specifying the location. The
dictionary contains pairs of the following:A String specifying the category selection
label.A String specifying the section point label.For example,`variable=
('S',INTEGRATION_POINT, ( (COMPONENT, 'S22' ), ), ) variable= (('S',INTEGRATION_POINT,
((COMPONENT, 'S11' ), ), ), ('U',NODAL,((COMPONENT, 'U1'),)),) variable=
(('S', INTEGRATION_POINT, ((INVARIANT, 'Mises' ), ), {'shell < STEEL > < 3
section points >':'SNEG, (fraction = -1.0)', }), )`
elementSets
A sequence of Strings specifying element sets or a String specifying a single element
set.
elementLabels
A sequence of expressions specifying element labels per part instance in the model. Each
part instance element expression is a sequence of a String specifying the part instance
name and a sequence of element expressions; for example,
`(('partInstance1',(1,'7','3:15;3'),), ('partInstance2','8'),))`. The element
expressions can be any of the following:An Int specifying a single element label; for
example, `1`.A String specifying a single element label; for example, `'7'`.A String
specifying a sequence of element labels; for example, `'3:5'` and `'3:15:3'`.
nodeSets
A sequence of Strings specifying node sets or a String specifying a single node set.
nodeLabels
A sequence of expressions specifying node labels per part instance in the model. Each
part instance node expression is a sequence of a String specifying the part instance
name and a sequence of node expressions; for example,
`(('partInstance1',(1,'7','3:15;3'),), ('partInstance2','8'),))`. The node expressions
can be any of the following:An Int specifying a single node label; for example, `1`.A
String specifying a single node label; for example, `'7'`.A String specifying a sequence
of node labels; for example, `'3:5'` and `'3:15:3'`.
numericForm
A SymbolicConstant specifying the numeric form in which to display results that contain
complex numbers. Possible values are COMPLEX_MAGNITUDE, COMPLEX_PHASE, REAL, IMAGINARY,
and COMPLEX_VAL_AT_ANGLE. The default value is REAL.
complexAngle
A Float specifying the angle (in degrees) at which to display results that contain
complex numbers when *numericForm*=COMPLEX_VAL_AT_ANGLE. The default value is 0.
Returns
-------
A list of XYData objects.
Raises
------
InvalidNameError
RangeError
"""
pass
def XYDataFromPath(
self,
path: Path,
name: str,
includeIntersections: Boolean,
shape: SymbolicConstant,
pathStyle: SymbolicConstant,
numIntervals: int,
labelType: SymbolicConstant,
viewport: str = "",
removeDuplicateXYPairs: Boolean = True,
includeAllElements: Boolean = False,
step: int = None,
frame: int = None,
variable: SymbolicConstant = None,
deformedMag: float = None,
numericForm: SymbolicConstant = REAL,
complexAngle: float = 0,
projectOntoMesh: Boolean = False,
projectionTolerance: float = 0,
):
"""This method creates an XYData object from path information.
Notes
-----
This function can be accessed by:
.. code-block:: python
session.XYData
xyPlot.XYData
Parameters
----------
path
A Path object to use in *X–Y* data generation.
name
A String specifying the repository key:for *session* 'name' is required argument and for
*xyPlot* 'name' is optional argument.
includeIntersections
A Boolean specifying whether to include *X–Y* data for the intersections between the
path and element faces or edges. The default value is False.
shape
A SymbolicConstant specifying the model shape to use. Possible values are UNDEFORMED and
DEFORMED.
pathStyle
A SymbolicConstant specifying the path style. Possible values are PATH_POINTS and
UNIFORM_SPACING.
numIntervals
An Int specifying the number of uniform-spacing intervals. The default value is 10.
labelType
A SymbolicConstant specifying the *X*-label type to use. Possible values are
NORM_DISTANCE, SEQ_ID, TRUE_DISTANCE, TRUE_DISTANCE_X, TRUE_DISTANCE_Y, TRUE_DISTANCE_Z,
X_COORDINATE, Y_COORDINATE and Z_COORDINATE.
viewport
A String specifying the viewport name or an Int specifying the viewport id from which to
obtain values. The default is the current viewport.
removeDuplicateXYPairs
A Boolean specifying whether to remove duplicate XY values from the final result. The
default value is True.
includeAllElements
A Boolean specifying whether to include elements which do not lie in the direction of
the path. The default value is False.
step
An Int identifying the step from which to obtain values. The default value is the
current step.
frame
An Int identifying the frame from which to obtain values. The default value is the
current frame.
variable
A tuple of tuples containing the descriptions of variables for which to extract data
along the path. The default value is the current variable. Each tuple specifies the
following:Variable label: A String specifying the variable; for example, 'U'.Variable
output position: A SymbolicConstant specifying the output position. Possible values are
ELEMENT_CENTROID, ELEMENT_FACE, ELEMENT_NODAL, GENERAL_PARTICLE, INTEGRATION_POINT,
NODAL, WHOLE_ELEMENT, WHOLE_MODEL, WHOLE_PART_INSTANCE, and WHOLE_REGION.Refinement: A
tuple specifying the refinement. If the refinement tuple is omitted, data are written
for all components and invariants (if applicable). This element is required if the
location dictionary (the following element in the tuple) is included. The refinement
tuple contains the following:Type: A SymbolicConstant specifying the type of refinement.
Possible values are INVARIANT and COMPONENT.Label: A String specifying the invariant or
the component; for example, 'Mises' or 'S22'.Location: An optional Dictionary specifying
the location. The dictionary contains pairs of the following:A String specifying the
category selection label.A String specifying the section point label.For
example,`variable= ('S',INTEGRATION_POINT, ( (COMPONENT, 'S22' ), ), ) variable=
(('S',INTEGRATION_POINT, ((COMPONENT, 'S11' ), ), ), ('U',NODAL,((COMPONENT,
'U1'),)),) variable= (('S', INTEGRATION_POINT, ((INVARIANT, 'Mises' ), ),
{'shell < STEEL > < 3 section points >':'SNEG,
(fraction = -1.0)', }), )`
deformedMag
A tuple of three Floats specifying the deformation magnitude in the *X-*, *Y-*, and
*Z-*planes. The default value is (1, 1, 1).
numericForm
A SymbolicConstant specifying the numeric form in which to display results that contain
complex numbers. Possible values are COMPLEX_MAGNITUDE, COMPLEX_PHASE, REAL, IMAGINARY,
and COMPLEX_VAL_AT_ANGLE. The default value is REAL.
complexAngle
A Float specifying the angle (in degrees) at which to display results that contain
complex numbers when *numericForm*=COMPLEX_VAL_AT_ANGLE. The default value is 0.
projectOntoMesh
A Boolean to specify whether to consider the data points that do not lie on or inside
the mesh. The default value is False.
projectionTolerance
A Float specifying the tolerance value for the projected distance considered for the
data extraction when *projectOntoMesh*= True. The default value is 0.
Returns
-------
If *variable* specified has one fieldoutput: Returns an XYData object.
If *variable* specified has more than one fieldoutputs: Returns list of XYData objects.
Raises
------
- If *path* is invalid:
ErrorPathNotFound: Path not found.
- If *viewport* is invalid:
ErrorCurrentVPNotFound: Current viewport not found.
- If *step* and/or *frame* are invalid:
ErrorInvalidUserStepAndFrame: The user step and frame specified have not been defined.
- If the *variable* argument is empty:
ErrorNoVarInPathExtract: No variable selection for XY data extraction from path.
- If the specified output variable is not available in the output database:
ErrorUnavailableSelectedVariable: The selected variable is not available for the
current frame.
- If the specified output variable cannot be used to obtain *X–Y* data:
ErrorUnusableVarInPathExtract: Specified variable cannot be used in XY data extraction
from path.
- If the SymbolicConstant specifying the refinement type is invalid:
ErrorUnsupportedRefinementType: Unsupported refinement type.
- If the label specifying the refinement invariant or component is invalid:
ErrorInvalidRefinementSpecification: Invalid refinement specification.
- If *deformedMag* does not contain three Floats:
ErrorDeformedMagTupleInPathExtract: Deformed magnification tuple must contain X, Y and
Z values.
"""
pass
def save(self):
"""This method saves a temporary XYData. The name of the XYData is changed to "XYData-#".
If the XYData is already saved, nothing is done.
"""
pass
def setValues(
self,
sourceDescription: str = "",
contentDescription: str = "",
positionDescription: str = "",
legendLabel: str = "",
xValuesLabel: str = "",
yValuesLabel: str = "",
axis1QuantityType: QuantityType = QuantityType(),
axis2QuantityType: QuantityType = QuantityType(),
):
"""This method modifies the XYData object.
Parameters
----------
sourceDescription
A String specifying the source of the *X–Y* data (e.g., “Entered from keyboard”, “Taken
from ASCII file”, “Read from an ODB”, etc.). The default value is an empty string.
contentDescription
A String specifying the content of the *X–Y* data (e.g., “field 1 vs. field 2”). The
default value is an empty string.
positionDescription
A String specifying additional information about the *X–Y* data (e.g., “for whole
model”). The default value is an empty string.
legendLabel
A String specifying the label to be used in the legend. The default value is the name of
the XYData object.
xValuesLabel
A String specifying the label for the X-values. This value may be overridden if the
*X–Y* data are combined with other *X–Y* data. The default value is an empty string.
yValuesLabel
A String specifying the label for the Y-values. This value may be overridden if the
*X–Y* data are combined with other *X–Y* data. The default value is an empty string.
axis1QuantityType
A QuantityType object specifying the QuantityType object associated to the X -axis1-
values.
axis2QuantityType
A QuantityType object specifying the QuantityType object associated to the Y -axis2-
values.
"""
pass