Oasys.PRIMER.GeneralizedWeld class¶
Constants¶
- GeneralizedWeld.BUTT¶
GeneralizedWeld is *CONSTRAINED_GENERALIZED_WELD_BUTT
- GeneralizedWeld.COMBINED¶
GeneralizedWeld is *CONSTRAINED_GENERALIZED_WELD_COMBINED
- GeneralizedWeld.CROSS_FILLET¶
GeneralizedWeld is *CONSTRAINED_GENERALIZED_WELD_CROSS_FILLET
- GeneralizedWeld.FILLET¶
GeneralizedWeld is *CONSTRAINED_GENERALIZED_WELD_FILLET
- GeneralizedWeld.SPOT¶
GeneralizedWeld is *CONSTRAINED_GENERALIZED_WELD_SPOT
Properties¶
- property GeneralizedWeld.a: float¶
Width of fillet (
GeneralizedWeld.FILLET
,GeneralizedWeld.CROSS_FILLET
)
- property GeneralizedWeld.alpha: float¶
Weld angle (
GeneralizedWeld.FILLET
,GeneralizedWeld.CROSS_FILLET
)
- property GeneralizedWeld.beta: float¶
Failure parameter (
GeneralizedWeld.FILLET
,GeneralizedWeld.BUTT
,GeneralizedWeld.CROSS_FILLET
)
- property GeneralizedWeld.cid: integer¶
- property GeneralizedWeld.d: float¶
Thickness of weld (
GeneralizedWeld.BUTT
)
- property GeneralizedWeld.epsf: float¶
Effective plastic strain at failure (
GeneralizedWeld.SPOT
,GeneralizedWeld.FILLET
,GeneralizedWeld.BUTT
,GeneralizedWeld.CROSS_FILLET
)
- property GeneralizedWeld.exists(read only): boolean¶
true if gwld exists, false if referred to but not defined
- property GeneralizedWeld.filter: integer¶
Number of force vectors saved for filtering
- property GeneralizedWeld.id: boolean¶
true if _ID option is set, false if not
- property GeneralizedWeld.l: float¶
Length of weld (
GeneralizedWeld.FILLET
,GeneralizedWeld.BUTT
,GeneralizedWeld.CROSS_FILLET
)
- property GeneralizedWeld.label: integer¶
Constrained Generalized weld number
- property GeneralizedWeld.lt: float¶
Transverse length (
GeneralizedWeld.BUTT
)
- property GeneralizedWeld.m: float¶
Exponent for shear force (
GeneralizedWeld.SPOT
)
- property GeneralizedWeld.model(read only): integer¶
The
Model
number that the generalized weld is in
- property GeneralizedWeld.n: float¶
Exponent for normal force (
GeneralizedWeld.SPOT
)
- property GeneralizedWeld.npr: integer¶
Number of individual nodal pairs in cross fillet and combined weld
- property GeneralizedWeld.nprt: integer¶
Printout option
- property GeneralizedWeld.option: constant¶
GeneralizedWeld type. Can be
GeneralizedWeld.SPOT
,GeneralizedWeld.FILLET
,GeneralizedWeld.BUTT
,GeneralizedWeld.CROSS_FILLET
,GeneralizedWeld.COMBINED
- property GeneralizedWeld.sigf: float¶
Stress at failure (
GeneralizedWeld.FILLET
)
- property GeneralizedWeld.sigy: float¶
Stress at failure (
GeneralizedWeld.BUTT
,GeneralizedWeld.CROSS_FILLET
)
- property GeneralizedWeld.sn: float¶
Normal force at failure (
GeneralizedWeld.SPOT
)
- property GeneralizedWeld.ss: float¶
Shear force at faliure (
GeneralizedWeld.SPOT
)
- property GeneralizedWeld.tfail: float¶
Failure time for constraint set (
GeneralizedWeld.SPOT
,GeneralizedWeld.FILLET
,GeneralizedWeld.BUTT
,GeneralizedWeld.CROSS_FILLET
)
- property GeneralizedWeld.w: float¶
Width of flange (
GeneralizedWeld.FILLET
,GeneralizedWeld.CROSS_FILLET
)
- property GeneralizedWeld.wid: integer¶
Constrained Generalized weld number (identical to label)
- property GeneralizedWeld.window: float¶
Filter time window
Constructor¶
- classmethod GeneralizedWeld(model, option, nsid, cid=Oasys.gRPC.defaultArg, filter=Oasys.gRPC.defaultArg, window=Oasys.gRPC.defaultArg, npr=Oasys.gRPC.defaultArg, nprt=Oasys.gRPC.defaultArg, wid=Oasys.gRPC.defaultArg)¶
Create a new
GeneralizedWeld
object
- Parameters:
model (Model) –
Model
that gwld will be created inoption (constant) – Constrained generalized weld type (any)
nsid (integer) –
Set
Node Set IDcid (integer) – Optional.
Coordinate System
IDfilter (integer) – Optional. Number of force vectors saved for filtering
window (float) – Optional. Filter time window
npr (integer) – Optional. Number of individual nodal pairs in cross fillet and combined weld
nprt (integer) – Optional. Printout option
wid (integer) – Optional. Constrained Generalized weld number
- Returns:
GeneralizedWeld object
- Return type:
dict
Example
To create a new gwld 1000 of type SPOT in model m with specifiction: nsid, cid, filter, window, nprt are 91, 92, 81, 0.5, 82 respectively
w = Oasys.PRIMER.GeneralizedWeld(m, Oasys.PRIMER.GeneralizedWeld.SPOT, 91, 92, 81, 0.5, 82, 1000)
Static methods¶
- classmethod GeneralizedWeld.BlankAll(model, redraw=Oasys.gRPC.defaultArg)¶
Blanks all of the generalized welds in the model
- Parameters:
model (Model) –
Model
that all generalized welds will be blanked inredraw (boolean) – Optional. If model should be redrawn or not. If omitted redraw is false. If you want to do several (un)blanks and only redraw after the last one then use false for all redraws apart from the last one. Alternatively you can redraw using
View.Redraw()
- Returns:
No return value
- Return type:
None
Example
To blank all of the generalized welds in model m:
Oasys.PRIMER.GeneralizedWeld.BlankAll(m)
- classmethod GeneralizedWeld.BlankFlagged(model, flag, redraw=Oasys.gRPC.defaultArg)¶
Blanks all of the flagged generalized welds in the model
- Parameters:
model (Model) –
Model
that all the flagged generalized welds will be blanked inflag (Flag) – Flag set on the generalized welds that you want to blank
redraw (boolean) – Optional. If model should be redrawn or not. If omitted redraw is false. If you want to do several (un)blanks and only redraw after the last one then use false for all redraws apart from the last one. Alternatively you can redraw using
View.Redraw()
- Returns:
No return value
- Return type:
None
Example
To blank all of the generalized welds in model m flagged with f:
Oasys.PRIMER.GeneralizedWeld.BlankFlagged(m, f)
- classmethod GeneralizedWeld.Create(model, modal=Oasys.gRPC.defaultArg)¶
Starts an interactive editing panel to create a gwld
- Parameters:
model (Model) –
Model
that the gwld will be created inmodal (boolean) – Optional. If this window is modal (blocks the user from doing anything else in PRIMER until this window is dismissed). If omitted the window will be modal
- Returns:
GeneralizedWeld object (or None if not made)
- Return type:
dict
Example
To start creating a generalized weld in model m:
gw = Oasys.PRIMER.GeneralizedWeld.Create(m)
- classmethod GeneralizedWeld.First(model)¶
Returns the first generalized weld in the model
- Parameters:
model (Model) –
Model
to get first generalized weld in- Returns:
GeneralizedWeld object (or None if there are no generalized welds in the model)
- Return type:
GeneralizedWeld
Example
To get the first generalized weld in model m:
gw = Oasys.PRIMER.GeneralizedWeld.First(m)
- classmethod GeneralizedWeld.FirstFreeLabel(model, layer=Oasys.gRPC.defaultArg)¶
Returns the first free generalized weld label in the model. Also see
GeneralizedWeld.LastFreeLabel()
,GeneralizedWeld.NextFreeLabel()
andModel.FirstFreeItemLabel()
- Parameters:
- Returns:
GeneralizedWeld label
- Return type:
int
Example
To get the first free generalized weld label in model m:
label = Oasys.PRIMER.GeneralizedWeld.FirstFreeLabel(m)
- classmethod GeneralizedWeld.FlagAll(model, flag)¶
Flags all of the generalized welds in the model with a defined flag
- Parameters:
model (Model) –
Model
that all generalized welds will be flagged inflag (Flag) – Flag to set on the generalized welds
- Returns:
No return value
- Return type:
None
Example
To flag all of the generalized welds with flag f in model m:
Oasys.PRIMER.GeneralizedWeld.FlagAll(m, f)
- classmethod GeneralizedWeld.GetAll(model)¶
Returns a list of GeneralizedWeld objects for all of the generalized welds in a model in PRIMER
- Parameters:
model (Model) –
Model
to get generalized welds from- Returns:
List of GeneralizedWeld objects
- Return type:
list
Example
To make a list of GeneralizedWeld objects for all of the generalized welds in model m
gw = Oasys.PRIMER.GeneralizedWeld.GetAll(m)
- classmethod GeneralizedWeld.GetFlagged(model, flag)¶
Returns a list of GeneralizedWeld objects for all of the flagged generalized welds in a model in PRIMER
- Parameters:
model (Model) –
Model
to get generalized welds fromflag (Flag) – Flag set on the generalized welds that you want to retrieve
- Returns:
List of GeneralizedWeld objects
- Return type:
list
Example
To make a list of GeneralizedWeld objects for all of the generalized welds in model m flagged with f
gw = Oasys.PRIMER.GeneralizedWeld.GetFlagged(m, f)
- classmethod GeneralizedWeld.GetFromID(model, number)¶
Returns the GeneralizedWeld object for a generalized weld ID
- Parameters:
model (Model) –
Model
to find the generalized weld innumber (integer) – number of the generalized weld you want the GeneralizedWeld object for
- Returns:
GeneralizedWeld object (or None if generalized weld does not exist)
- Return type:
GeneralizedWeld
Example
To get the GeneralizedWeld object for generalized weld 100 in model m
gw = Oasys.PRIMER.GeneralizedWeld.GetFromID(m, 100)
- classmethod GeneralizedWeld.Last(model)¶
Returns the last generalized weld in the model
- Parameters:
model (Model) –
Model
to get last generalized weld in- Returns:
GeneralizedWeld object (or None if there are no generalized welds in the model)
- Return type:
GeneralizedWeld
Example
To get the last generalized weld in model m:
gw = Oasys.PRIMER.GeneralizedWeld.Last(m)
- classmethod GeneralizedWeld.LastFreeLabel(model, layer=Oasys.gRPC.defaultArg)¶
Returns the last free generalized weld label in the model. Also see
GeneralizedWeld.FirstFreeLabel()
,GeneralizedWeld.NextFreeLabel()
and seeModel.LastFreeItemLabel()
- Parameters:
- Returns:
GeneralizedWeld label
- Return type:
int
Example
To get the last free generalized weld label in model m:
label = Oasys.PRIMER.GeneralizedWeld.LastFreeLabel(m)
- classmethod GeneralizedWeld.NextFreeLabel(model, layer=Oasys.gRPC.defaultArg)¶
Returns the next free (highest+1) generalized weld label in the model. Also see
GeneralizedWeld.FirstFreeLabel()
,GeneralizedWeld.LastFreeLabel()
andModel.NextFreeItemLabel()
- Parameters:
- Returns:
GeneralizedWeld label
- Return type:
int
Example
To get the next free generalized weld label in model m:
label = Oasys.PRIMER.GeneralizedWeld.NextFreeLabel(m)
- classmethod GeneralizedWeld.Pick(prompt, limit=Oasys.gRPC.defaultArg, modal=Oasys.gRPC.defaultArg, button_text=Oasys.gRPC.defaultArg)¶
Allows the user to pick a generalized weld
- Parameters:
prompt (string) – Text to display as a prompt to the user
limit (Model or Flag) – Optional. If the argument is a
Model
then only generalized welds from that model can be picked. If the argument is aFlag
then only generalized welds that are flagged with limit can be selected. If omitted, or None, any generalized welds from any model can be selected. from any modelmodal (boolean) – Optional. If picking is modal (blocks the user from doing anything else in PRIMER until this window is dismissed). If omitted the pick will be modal
button_text (string) – Optional. By default the window with the prompt will have a button labelled ‘Cancel’ which if pressed will cancel the pick and return None. If you want to change the text on the button use this argument. If omitted ‘Cancel’ will be used
- Returns:
GeneralizedWeld object (or None if not picked)
- Return type:
dict
Example
To pick a generalized weld from model m giving the prompt ‘Pick generalized weld from screen’:
gw = Oasys.PRIMER.GeneralizedWeld.Pick('Pick generalized weld from screen', m)
- classmethod GeneralizedWeld.RenumberAll(model, start)¶
Renumbers all of the generalized welds in the model
- Parameters:
model (Model) –
Model
that all generalized welds will be renumbered instart (integer) – Start point for renumbering
- Returns:
No return value
- Return type:
None
Example
To renumber all of the generalized welds in model m, from 1000000:
Oasys.PRIMER.GeneralizedWeld.RenumberAll(m, 1000000)
- classmethod GeneralizedWeld.RenumberFlagged(model, flag, start)¶
Renumbers all of the flagged generalized welds in the model
- Parameters:
model (Model) –
Model
that all the flagged generalized welds will be renumbered inflag (Flag) – Flag set on the generalized welds that you want to renumber
start (integer) – Start point for renumbering
- Returns:
No return value
- Return type:
None
Example
To renumber all of the generalized welds in model m flagged with f, from 1000000:
Oasys.PRIMER.GeneralizedWeld.RenumberFlagged(m, f, 1000000)
- classmethod GeneralizedWeld.Select(flag, prompt, limit=Oasys.gRPC.defaultArg, modal=Oasys.gRPC.defaultArg)¶
Allows the user to select generalized welds using standard PRIMER object menus
- Parameters:
flag (Flag) – Flag to use when selecting generalized welds
prompt (string) – Text to display as a prompt to the user
limit (Model or Flag) – Optional. If the argument is a
Model
then only generalized welds from that model can be selected. If the argument is aFlag
then only generalized welds that are flagged with limit can be selected (limit should be different to flag). If omitted, or None, any generalized welds can be selected. from any modelmodal (boolean) – Optional. If selection is modal (blocks the user from doing anything else in PRIMER until this window is dismissed). If omitted the selection will be modal
- Returns:
Number of generalized welds selected or None if menu cancelled
- Return type:
int
Example
To select generalized welds from model m, flagging those selected with flag f, giving the prompt ‘Select generalized welds’:
Oasys.PRIMER.GeneralizedWeld.Select(f, 'Select generalized welds', m)To select generalized welds, flagging those selected with flag f but limiting selection to generalized welds flagged with flag l, giving the prompt ‘Select generalized welds’:
Oasys.PRIMER.GeneralizedWeld.Select(f, 'Select generalized welds', l)
- classmethod GeneralizedWeld.SketchFlagged(model, flag, redraw=Oasys.gRPC.defaultArg)¶
Sketches all of the flagged generalized welds in the model. The generalized welds will be sketched until you either call
GeneralizedWeld.Unsketch()
,GeneralizedWeld.UnsketchFlagged()
,Model.UnsketchAll()
, or delete the model
- Parameters:
model (Model) –
Model
that all the flagged generalized welds will be sketched inflag (Flag) – Flag set on the generalized welds that you want to sketch
redraw (boolean) – Optional. If model should be redrawn or not after the generalized welds are sketched. If omitted redraw is true. If you want to sketch flagged generalized welds several times and only redraw after the last one then use false for redraw and call
View.Redraw()
- Returns:
No return value
- Return type:
None
Example
To sketch all generalized welds flagged with flag in model m:
Oasys.PRIMER.GeneralizedWeld.SketchFlagged(m, flag)
- classmethod GeneralizedWeld.Total(model, exists=Oasys.gRPC.defaultArg)¶
Returns the total number of generalized welds in the model
- Parameters:
model (Model) –
Model
to get total forexists (boolean) – Optional. true if only existing generalized welds should be counted. If false or omitted referenced but undefined generalized welds will also be included in the total
- Returns:
number of generalized welds
- Return type:
int
Example
To get the total number of generalized welds in model m:
total = Oasys.PRIMER.GeneralizedWeld.Total(m)
- classmethod GeneralizedWeld.UnblankAll(model, redraw=Oasys.gRPC.defaultArg)¶
Unblanks all of the generalized welds in the model
- Parameters:
model (Model) –
Model
that all generalized welds will be unblanked inredraw (boolean) – Optional. If model should be redrawn or not. If omitted redraw is false. If you want to do several (un)blanks and only redraw after the last one then use false for all redraws apart from the last one. Alternatively you can redraw using
View.Redraw()
- Returns:
No return value
- Return type:
None
Example
To unblank all of the generalized welds in model m:
Oasys.PRIMER.GeneralizedWeld.UnblankAll(m)
- classmethod GeneralizedWeld.UnblankFlagged(model, flag, redraw=Oasys.gRPC.defaultArg)¶
Unblanks all of the flagged generalized welds in the model
- Parameters:
model (Model) –
Model
that the flagged generalized welds will be unblanked inflag (Flag) – Flag set on the generalized welds that you want to unblank
redraw (boolean) – Optional. If model should be redrawn or not. If omitted redraw is false. If you want to do several (un)blanks and only redraw after the last one then use false for all redraws apart from the last one. Alternatively you can redraw using
View.Redraw()
- Returns:
No return value
- Return type:
None
Example
To unblank all of the generalized welds in model m flagged with f:
Oasys.PRIMER.GeneralizedWeld.UnblankFlagged(m, f)
- classmethod GeneralizedWeld.UnflagAll(model, flag)¶
Unsets a defined flag on all of the generalized welds in the model
- Parameters:
model (Model) –
Model
that the defined flag for all generalized welds will be unset inflag (Flag) – Flag to unset on the generalized welds
- Returns:
No return value
- Return type:
None
Example
To unset the flag f on all the generalized welds in model m:
Oasys.PRIMER.GeneralizedWeld.UnflagAll(m, f)
- classmethod GeneralizedWeld.UnsketchAll(model, redraw=Oasys.gRPC.defaultArg)¶
Unsketches all generalized welds
- Parameters:
model (Model) –
Model
that all generalized welds will be unblanked inredraw (boolean) – Optional. If model should be redrawn or not after the generalized welds are unsketched. If omitted redraw is true. If you want to unsketch several things and only redraw after the last one then use false for redraw and call
View.Redraw()
- Returns:
No return value
- Return type:
None
Example
To unsketch all generalized welds in model m:
Oasys.PRIMER.GeneralizedWeld.UnsketchAll(m)
- classmethod GeneralizedWeld.UnsketchFlagged(model, flag, redraw=Oasys.gRPC.defaultArg)¶
Unsketches all flagged generalized welds in the model
- Parameters:
model (Model) –
Model
that all generalized welds will be unsketched inflag (Flag) – Flag set on the generalized welds that you want to unsketch
redraw (boolean) – Optional. If model should be redrawn or not after the generalized welds are unsketched. If omitted redraw is true. If you want to unsketch several things and only redraw after the last one then use false for redraw and call
View.Redraw()
- Returns:
No return value
- Return type:
None
Example
To unsketch all generalized welds flagged with flag in model m:
Oasys.PRIMER.GeneralizedWeld.UnsketchAll(m, flag)
Instance methods¶
- GeneralizedWeld.AssociateComment(comment)¶
Associates a comment with a generalized weld
- Parameters:
comment (Comment) –
Comment
that will be attached to the generalized weld- Returns:
No return value
- Return type:
None
Example
To associate comment c to the generalized weld gw:
gw.AssociateComment(c)
- GeneralizedWeld.Blank()¶
Blanks the generalized weld
- Returns:
No return value
- Return type:
None
Example
To blank generalized weld gw:
gw.Blank()
- GeneralizedWeld.Blanked()¶
Checks if the generalized weld is blanked or not
- Returns:
True if blanked, False if not
- Return type:
bool
Example
To check if generalized weld gw is blanked:
if gw.Blanked(): do_something..
- GeneralizedWeld.Browse(modal=Oasys.gRPC.defaultArg)¶
Starts an edit panel in Browse mode
- Parameters:
modal (boolean) – Optional. If this window is modal (blocks the user from doing anything else in PRIMER until this window is dismissed). If omitted the window will be modal
- Returns:
no return value
- Return type:
None
Example
To Browse generalized weld gw:
gw.Browse()
- GeneralizedWeld.ClearFlag(flag)¶
Clears a flag on the generalized weld
- Parameters:
flag (Flag) – Flag to clear on the generalized weld
- Returns:
No return value
- Return type:
None
Example
To clear flag f for generalized weld gw:
gw.ClearFlag(f)
- GeneralizedWeld.Copy(range=Oasys.gRPC.defaultArg)¶
Copies the generalized weld. The target include of the copied generalized weld can be set using
Options.copy_target_include
- Parameters:
range (boolean) – Optional. If you want to keep the copied item in the range specified for the current include. Default value is false. To set current include, use
Include.MakeCurrentLayer()
- Returns:
GeneralizedWeld object
- Return type:
GeneralizedWeld
Example
To copy generalized weld gw into generalized weld z:
z = gw.Copy()
- GeneralizedWeld.DetachComment(comment)¶
Detaches a comment from a generalized weld
- Parameters:
comment (Comment) –
Comment
that will be detached from the generalized weld- Returns:
No return value
- Return type:
None
Example
To detach comment c from the generalized weld gw:
gw.DetachComment(c)
- GeneralizedWeld.Edit(modal=Oasys.gRPC.defaultArg)¶
Starts an interactive editing panel
- Parameters:
modal (boolean) – Optional. If this window is modal (blocks the user from doing anything else in PRIMER until this window is dismissed). If omitted the window will be modal
- Returns:
no return value
- Return type:
None
Example
To Edit generalized weld gw:
gw.Edit()
- GeneralizedWeld.Flagged(flag)¶
Checks if the generalized weld is flagged or not
- Parameters:
flag (Flag) – Flag to test on the generalized weld
- Returns:
True if flagged, False if not
- Return type:
bool
Example
To check if generalized weld gw has flag f set on it:
if gw.Flagged(f): do_something..
- GeneralizedWeld.GetCombinedData(index)¶
Returns the combined data for a specific nodal pair as a list
- Parameters:
index (integer) – Index you want the data for. Note that indices start at 0
- Returns:
A list containing the data (tfail, epsf, sigy, beta, l, w, a, alpha, nodea, nodeb, ncid, wtyp)
- Return type:
list
Example
To get the data for the 3rd node pair for generalized weld gw:
data = gw.GetCombinedData(2)
- GeneralizedWeld.GetComments()¶
Extracts the comments associated to a generalized weld
- Returns:
List of Comment objects (or None if there are no comments associated to the node)
- Return type:
list
Example
To get the list of comments associated to the generalized weld gw:
comm_list = gw.GetComments()
- GeneralizedWeld.GetCrossFilletData(index)¶
Returns the cross fillet data for a specific nodal pair as a list
- Parameters:
index (integer) – Index you want the data for. Note that indices start at 0
- Returns:
A list containing the data (nodea, nodeb, ncid)
- Return type:
list
Example
To get the data for the 3rd node pair for generalized weld gw:
data = gw.GetCrossFilletData(2)
- GeneralizedWeld.GetParameter(prop)¶
Checks if a GeneralizedWeld property is a parameter or not. Note that object properties that are parameters are normally returned as the integer or float parameter values as that is virtually always what the user would want. For this function to work the JavaScript interpreter must use the parameter name instead of the value. This can be done by setting the
Options.property_parameter_names
option to true before calling the function and then resetting it to false afterwards.. This behaviour can also temporarily be switched by using theGeneralizedWeld.ViewParameters()
method and ‘method chaining’ (see the examples below)
- Parameters:
prop (string) – generalized weld property to get parameter for
- Returns:
Parameter object if property is a parameter, None if not
- Return type:
dict
Example
To check if GeneralizedWeld property gw.example is a parameter:
Oasys.PRIMER.Options.property_parameter_names = True if gw.GetParameter(gw.example): do_something... Oasys.PRIMER.Options.property_parameter_names = FalseTo check if GeneralizedWeld property gw.example is a parameter by using the GetParameter method:
if gw.ViewParameters().GetParameter(gw.example): do_something..
- GeneralizedWeld.Keyword()¶
Returns the keyword for this gwld (*CONSTRAINED_GENERALIZED_WELD_xxxx). Note that a carriage return is not added. See also
GeneralizedWeld.KeywordCards()
- Returns:
string containing the keyword
- Return type:
str
Example
To get the keyword for generalized weld gw:
key = gw.Keyword()
- GeneralizedWeld.KeywordCards()¶
Returns the keyword cards for the gwld. Note that a carriage return is not added. See also
GeneralizedWeld.Keyword()
- Returns:
string containing the cards
- Return type:
str
Example
To get the cards for generalized weld gw:
cards = gw.KeywordCards()
- GeneralizedWeld.Next()¶
Returns the next generalized weld in the model
- Returns:
GeneralizedWeld object (or None if there are no more generalized welds in the model)
- Return type:
GeneralizedWeld
Example
To get the generalized weld in model m after generalized weld gw:
gw = gw.Next()
- GeneralizedWeld.Previous()¶
Returns the previous generalized weld in the model
- Returns:
GeneralizedWeld object (or None if there are no more generalized welds in the model)
- Return type:
GeneralizedWeld
Example
To get the generalized weld in model m before generalized weld gw:
gw = gw.Previous()
- GeneralizedWeld.SetCombinedData(index, data)¶
Sets the combined data for a specific nodal pair
- Parameters:
index (integer) – Index you want to set the data for. Note that indices start at 0
data (List of numbers) – List containing the data. The list length should be 12 (tfail, epsf, sigy, beta, l, w, a, alpha, nodea, nodeb, ncid, wtyp)
- Returns:
No return value
- Return type:
None
Example
To set the data for the 3rd nodal pair for generalized weld gw to the values in list adata:
gw.SetCombinedData(2, adata)
- GeneralizedWeld.SetCrossFilletData(index, data)¶
Sets the cross fillet data for a specific nodal pair
- Parameters:
index (integer) – Index you want to set the data for. Note that indices start at 0
data (List of numbers) – List containing the data. The list length should be 3 (nodea, nodeb, ncid)
- Returns:
No return value
- Return type:
None
Example
To set the data for the 3rd nodal pair for generalized weld gw to the values in list adata:
gw.SetCrossFilletData(2, adata)
- GeneralizedWeld.SetFlag(flag)¶
Sets a flag on the generalized weld
- Parameters:
flag (Flag) – Flag to set on the generalized weld
- Returns:
No return value
- Return type:
None
Example
To set flag f for generalized weld gw:
gw.SetFlag(f)
- GeneralizedWeld.Sketch(redraw=Oasys.gRPC.defaultArg)¶
Sketches the generalized weld. The generalized weld will be sketched until you either call
GeneralizedWeld.Unsketch()
,GeneralizedWeld.UnsketchAll()
,Model.UnsketchAll()
, or delete the model
- Parameters:
redraw (boolean) – Optional. If model should be redrawn or not after the generalized weld is sketched. If omitted redraw is true. If you want to sketch several generalized welds and only redraw after the last one then use false for redraw and call
View.Redraw()
- Returns:
No return value
- Return type:
None
Example
To sketch generalized weld gw:
gw.Sketch()
- GeneralizedWeld.Unblank()¶
Unblanks the generalized weld
- Returns:
No return value
- Return type:
None
Example
To unblank generalized weld gw:
gw.Unblank()
- GeneralizedWeld.Unsketch(redraw=Oasys.gRPC.defaultArg)¶
Unsketches the generalized weld
- Parameters:
redraw (boolean) – Optional. If model should be redrawn or not after the generalized weld is unsketched. If omitted redraw is true. If you want to unsketch several generalized welds and only redraw after the last one then use false for redraw and call
View.Redraw()
- Returns:
No return value
- Return type:
None
Example
To unsketch generalized weld gw:
gw.Unsketch()
- GeneralizedWeld.ViewParameters()¶
Object properties that are parameters are normally returned as the integer or float parameter values as that is virtually always what the user would want. This function temporarily changes the behaviour so that if a property is a parameter the parameter name is returned instead. This can be used with ‘method chaining’ (see the example below) to make sure a property argument is correct
- Returns:
GeneralizedWeld object
- Return type:
dict
Example
To check if GeneralizedWeld property gw.example is a parameter by using the
GeneralizedWeld.GetParameter()
method:if gw.ViewParameters().GetParameter(gw.example): do_something..
- GeneralizedWeld.Xrefs()¶
Returns the cross references for this generalized weld
- Returns:
Xrefs object
- Return type:
dict
Example
To get the cross references for generalized weld gw:
xrefs = gw.Xrefs()