Oasys.PRIMER.PrescribedOrientationRigid class

Constants

PrescribedOrientationRigid.ANGLES

Boundary is *BOUNDARY_PRESCRIBED_ORIENTATION_RIGID_ANGLES

PrescribedOrientationRigid.DIRCOS

Boundary is *BOUNDARY_PRESCRIBED_ORIENTATION_RIGID_DIRCOS

PrescribedOrientationRigid.EULERP

Boundary is *BOUNDARY_PRESCRIBED_ORIENTATION_RIGID_EULERP

PrescribedOrientationRigid.VECTOR

Boundary is *BOUNDARY_PRESCRIBED_ORIENTATION_RIGID_VECTOR

Properties

property PrescribedOrientationRigid.birth: float

Time prior to which the body moves freely under the action of other agents

property PrescribedOrientationRigid.body: integer

Reference axes: 0 for rotations about axes fixed in PIDA or 1 for those fixed in PIDB

property PrescribedOrientationRigid.death: float

Time when the body is freed from the restriction

property PrescribedOrientationRigid.exists(read only): boolean

true if prescribed orientation rigid exists, false if referred to but not defined

property PrescribedOrientationRigid.heading: string

PrescribedOrientationRigid heading

property PrescribedOrientationRigid.id: boolean

true if _ID option is set, false if not

property PrescribedOrientationRigid.include: integer

The Include file number that the prescribed orientation rigid is in

property PrescribedOrientationRigid.intrp: integer

Interpolation method: 1 for linear interpolation or 2 for cubic spline interpolation

property PrescribedOrientationRigid.intrp_1: integer

Interpolation method: 1 for linear interpolation or 2 for cubic spline interpolation

property PrescribedOrientationRigid.iseq: integer

Specifies the sequence in which the rotations are performed

property PrescribedOrientationRigid.ishft: integer

Angle shift: 1 for unaltered angle curves or 2 for angle data shift in LCIDQi curves eliminating discontinuities

property PrescribedOrientationRigid.lcidc11: integer

Load curve ID specifying direction cosine C11 as function of time

property PrescribedOrientationRigid.lcidc12: integer

Load curve ID specifying direction cosine C12 as function of time

property PrescribedOrientationRigid.lcidc13: integer

Load curve ID specifying direction cosine C13 as function of time

property PrescribedOrientationRigid.lcidc21: integer

Load curve ID specifying direction cosine C21 as function of time

property PrescribedOrientationRigid.lcidc22: integer

Load curve ID specifying direction cosine C22 as function of time

property PrescribedOrientationRigid.lcidc23: integer

Load curve ID specifying direction cosine C23 as function of time

property PrescribedOrientationRigid.lcidc31: integer

Load curve ID specifying direction cosine C31 as function of time

property PrescribedOrientationRigid.lcidc32: integer

Load curve ID specifying direction cosine C32 as function of time

property PrescribedOrientationRigid.lcidc33: integer

Load curve ID specifying direction cosine C33 as function of time

property PrescribedOrientationRigid.lcide1: integer

Load curve ID specifying Euler parameter e1 as function of time

property PrescribedOrientationRigid.lcide2: integer

Load curve ID specifying Euler parameter e2 as function of time

property PrescribedOrientationRigid.lcide3: integer

Load curve ID specifying Euler parameter e3 as function of time

property PrescribedOrientationRigid.lcide4: integer

Load curve ID specifying Euler parameter e4 as function of time

property PrescribedOrientationRigid.lcidq1: integer

Load curve ID specifying orientation angle q1 as function of time

property PrescribedOrientationRigid.lcidq2: integer

Load curve ID specifying orientation angle q2 as function of time

property PrescribedOrientationRigid.lcidq3: integer

Load curve ID specifying orientation angle q3 as function of time

property PrescribedOrientationRigid.lcids: integer

Load curve ID specifying spin speed of PIDB about axis parallel to vector

property PrescribedOrientationRigid.lcidv1: integer

Load curve ID specifying vector measure number v1 as function of time

property PrescribedOrientationRigid.lcidv2: integer

Load curve ID specifying vector measure number v2 as function of time

property PrescribedOrientationRigid.lcidv3: integer

Load curve ID specifying vector measure number v3 as function of time

property PrescribedOrientationRigid.model(read only): integer

The Model number that the prescribed orientation rigid is in

property PrescribedOrientationRigid.option: constant

The Boundary Prescribed Orientation Rigid option. Can be PrescribedOrientationRigid.DIRCOS, PrescribedOrientationRigid.ANGLES, PrescribedOrientationRigid.EULERP or PrescribedOrientationRigid.VECTOR

property PrescribedOrientationRigid.pida: integer

Part ID for rigid body A

property PrescribedOrientationRigid.pidb: integer

Part ID for rigid body B whose orientation is prescribed

property PrescribedOrientationRigid.toffset: integer

Time offset flag

property PrescribedOrientationRigid.valspin: float

Constant value for spin speed of PIDB about axis parallel to vector. Used when LCIDS is 0

Constructor

classmethod PrescribedOrientationRigid(model, option, pidb, label=Oasys.gRPC.defaultArg, heading=Oasys.gRPC.defaultArg)

Create a new PrescribedOrientationRigid object

Parameters:
Returns:

PrescribedOrientationRigid object

Return type:

dict

Example

To create a new prescribed orientation rigid in model m with part ID 10 and suffix _DIRCOS:

por = Oasys.PRIMER.PrescribedOrientationRigid(m, Oasys.PRIMER.PrescribedOrientationRigid.DIRCOS, 10)

Static methods

classmethod PrescribedOrientationRigid.Create(model, modal=Oasys.gRPC.defaultArg)

Starts an interactive editing panel to create a boundary prescribed orientation rigid definition

Parameters:
  • model (Model) – Model that the prescribed orientation rigid will be created in

  • 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:

PrescribedOrientationRigid object (or None if not made)

Return type:

dict

Example

To start creating a boundary prescribed orientation rigid definition in model m:

por = Oasys.PRIMER.PrescribedOrientationRigid.Create(m)
classmethod PrescribedOrientationRigid.First(model)

Returns the first prescribed orientation rigid in the model

Parameters:

model (Model) – Model to get first prescribed orientation rigid in

Returns:

PrescribedOrientationRigid object (or None if there are no prescribed orientation rigids in the model)

Return type:

PrescribedOrientationRigid

Example

To get the first prescribed orientation rigid in model m:

por = Oasys.PRIMER.PrescribedOrientationRigid.First(m)
classmethod PrescribedOrientationRigid.FlagAll(model, flag)

Flags all of the prescribed orientation rigids in the model with a defined flag

Parameters:
  • model (Model) – Model that all prescribed orientation rigids will be flagged in

  • flag (Flag) – Flag to set on the prescribed orientation rigids

Returns:

No return value

Return type:

None

Example

To flag all of the prescribed orientation rigids with flag f in model m:

Oasys.PRIMER.PrescribedOrientationRigid.FlagAll(m, f)
classmethod PrescribedOrientationRigid.GetAll(model)

Returns a list of PrescribedOrientationRigid objects for all of the prescribed orientation rigids in a model in PRIMER

Parameters:

model (Model) – Model to get prescribed orientation rigids from

Returns:

List of PrescribedOrientationRigid objects

Return type:

list

Example

To make a list of PrescribedOrientationRigid objects for all of the prescribed orientation rigids in model m

por = Oasys.PRIMER.PrescribedOrientationRigid.GetAll(m)
classmethod PrescribedOrientationRigid.GetFlagged(model, flag)

Returns a list of PrescribedOrientationRigid objects for all of the flagged prescribed orientation rigids in a model in PRIMER

Parameters:
  • model (Model) – Model to get prescribed orientation rigids from

  • flag (Flag) – Flag set on the prescribed orientation rigids that you want to retrieve

Returns:

List of PrescribedOrientationRigid objects

Return type:

list

Example

To make a list of PrescribedOrientationRigid objects for all of the prescribed orientation rigids in model m flagged with f

por = Oasys.PRIMER.PrescribedOrientationRigid.GetFlagged(m, f)
classmethod PrescribedOrientationRigid.GetFromID(model, number)

Returns the PrescribedOrientationRigid object for a prescribed orientation rigid ID

Parameters:
  • model (Model) – Model to find the prescribed orientation rigid in

  • number (integer) – number of the prescribed orientation rigid you want the PrescribedOrientationRigid object for

Returns:

PrescribedOrientationRigid object (or None if prescribed orientation rigid does not exist)

Return type:

PrescribedOrientationRigid

Example

To get the PrescribedOrientationRigid object for prescribed orientation rigid 100 in model m

por = Oasys.PRIMER.PrescribedOrientationRigid.GetFromID(m, 100)
classmethod PrescribedOrientationRigid.Last(model)

Returns the last prescribed orientation rigid in the model

Parameters:

model (Model) – Model to get last prescribed orientation rigid in

Returns:

PrescribedOrientationRigid object (or None if there are no prescribed orientation rigids in the model)

Return type:

PrescribedOrientationRigid

Example

To get the last prescribed orientation rigid in model m:

por = Oasys.PRIMER.PrescribedOrientationRigid.Last(m)
classmethod PrescribedOrientationRigid.Select(flag, prompt, limit=Oasys.gRPC.defaultArg, modal=Oasys.gRPC.defaultArg)

Allows the user to select prescribed orientation rigids using standard PRIMER object menus

Parameters:
  • flag (Flag) – Flag to use when selecting prescribed orientation rigids

  • prompt (string) – Text to display as a prompt to the user

  • limit (Model or Flag) – Optional. If the argument is a Model then only prescribed orientation rigids from that model can be selected. If the argument is a Flag then only prescribed orientation rigids that are flagged with limit can be selected (limit should be different to flag). If omitted, or None, any prescribed orientation rigids can be selected. from any model

  • modal (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 prescribed orientation rigids selected or None if menu cancelled

Return type:

int

Example

To select prescribed orientation rigids from model m, flagging those selected with flag f, giving the prompt ‘Select prescribed orientation rigids’:

Oasys.PRIMER.PrescribedOrientationRigid.Select(f, 'Select prescribed orientation rigids', m)

To select prescribed orientation rigids, flagging those selected with flag f but limiting selection to prescribed orientation rigids flagged with flag l, giving the prompt ‘Select prescribed orientation rigids’:

Oasys.PRIMER.PrescribedOrientationRigid.Select(f, 'Select prescribed orientation rigids', l)
classmethod PrescribedOrientationRigid.SketchFlagged(model, flag, redraw=Oasys.gRPC.defaultArg)

Sketches all of the flagged prescribed orientation rigids in the model. The prescribed orientation rigids will be sketched until you either call PrescribedOrientationRigid.Unsketch(), PrescribedOrientationRigid.UnsketchFlagged(), Model.UnsketchAll(), or delete the model

Parameters:
  • model (Model) – Model that all the flagged prescribed orientation rigids will be sketched in

  • flag (Flag) – Flag set on the prescribed orientation rigids that you want to sketch

  • redraw (boolean) – Optional. If model should be redrawn or not after the prescribed orientation rigids are sketched. If omitted redraw is true. If you want to sketch flagged prescribed orientation rigids 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 prescribed orientation rigids flagged with flag in model m:

Oasys.PRIMER.PrescribedOrientationRigid.SketchFlagged(m, flag)
classmethod PrescribedOrientationRigid.Total(model, exists=Oasys.gRPC.defaultArg)

Returns the total number of prescribed orientation rigids in the model

Parameters:
  • model (Model) – Model to get total for

  • exists (boolean) – Optional. true if only existing prescribed orientation rigids should be counted. If false or omitted referenced but undefined prescribed orientation rigids will also be included in the total

Returns:

number of prescribed orientation rigids

Return type:

int

Example

To get the total number of prescribed orientation rigids in model m:

total = Oasys.PRIMER.PrescribedOrientationRigid.Total(m)
classmethod PrescribedOrientationRigid.UnflagAll(model, flag)

Unsets a defined flag on all of the prescribed orientation rigids in the model

Parameters:
  • model (Model) – Model that the defined flag for all prescribed orientation rigids will be unset in

  • flag (Flag) – Flag to unset on the prescribed orientation rigids

Returns:

No return value

Return type:

None

Example

To unset the flag f on all the prescribed orientation rigids in model m:

Oasys.PRIMER.PrescribedOrientationRigid.UnflagAll(m, f)
classmethod PrescribedOrientationRigid.UnsketchAll(model, redraw=Oasys.gRPC.defaultArg)

Unsketches all prescribed orientation rigids

Parameters:
  • model (Model) – Model that all prescribed orientation rigids will be unblanked in

  • redraw (boolean) – Optional. If model should be redrawn or not after the prescribed orientation rigids 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 prescribed orientation rigids in model m:

Oasys.PRIMER.PrescribedOrientationRigid.UnsketchAll(m)
classmethod PrescribedOrientationRigid.UnsketchFlagged(model, flag, redraw=Oasys.gRPC.defaultArg)

Unsketches all flagged prescribed orientation rigids in the model

Parameters:
  • model (Model) – Model that all prescribed orientation rigids will be unsketched in

  • flag (Flag) – Flag set on the prescribed orientation rigids that you want to unsketch

  • redraw (boolean) – Optional. If model should be redrawn or not after the prescribed orientation rigids 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 prescribed orientation rigids flagged with flag in model m:

Oasys.PRIMER.PrescribedOrientationRigid.UnsketchAll(m, flag)

Instance methods

PrescribedOrientationRigid.AssociateComment(comment)

Associates a comment with a prescribed orientation rigid

Parameters:

comment (Comment) – Comment that will be attached to the prescribed orientation rigid

Returns:

No return value

Return type:

None

Example

To associate comment c to the prescribed orientation rigid por:

por.AssociateComment(c)
PrescribedOrientationRigid.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 prescribed orientation rigid por:

por.Browse()
PrescribedOrientationRigid.ClearFlag(flag)

Clears a flag on the prescribed orientation rigid

Parameters:

flag (Flag) – Flag to clear on the prescribed orientation rigid

Returns:

No return value

Return type:

None

Example

To clear flag f for prescribed orientation rigid por:

por.ClearFlag(f)
PrescribedOrientationRigid.Copy(range=Oasys.gRPC.defaultArg)

Copies the prescribed orientation rigid. The target include of the copied prescribed orientation rigid 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:

PrescribedOrientationRigid object

Return type:

PrescribedOrientationRigid

Example

To copy prescribed orientation rigid por into prescribed orientation rigid z:

z = por.Copy()
PrescribedOrientationRigid.DetachComment(comment)

Detaches a comment from a prescribed orientation rigid

Parameters:

comment (Comment) – Comment that will be detached from the prescribed orientation rigid

Returns:

No return value

Return type:

None

Example

To detach comment c from the prescribed orientation rigid por:

por.DetachComment(c)
PrescribedOrientationRigid.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 prescribed orientation rigid por:

por.Edit()
PrescribedOrientationRigid.Flagged(flag)

Checks if the prescribed orientation rigid is flagged or not

Parameters:

flag (Flag) – Flag to test on the prescribed orientation rigid

Returns:

True if flagged, False if not

Return type:

bool

Example

To check if prescribed orientation rigid por has flag f set on it:

if por.Flagged(f):
    do_something..
PrescribedOrientationRigid.GetComments()

Extracts the comments associated to a prescribed orientation rigid

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 prescribed orientation rigid por:

comm_list = por.GetComments()
PrescribedOrientationRigid.GetParameter(prop)

Checks if a PrescribedOrientationRigid 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 the PrescribedOrientationRigid.ViewParameters() method and ‘method chaining’ (see the examples below)

Parameters:

prop (string) – prescribed orientation rigid property to get parameter for

Returns:

Parameter object if property is a parameter, None if not

Return type:

dict

Example

To check if PrescribedOrientationRigid property por.example is a parameter:

Oasys.PRIMER.Options.property_parameter_names = True
if por.GetParameter(por.example):
    do_something...
Oasys.PRIMER.Options.property_parameter_names = False

To check if PrescribedOrientationRigid property por.example is a parameter by using the GetParameter method:

if por.ViewParameters().GetParameter(por.example):
    do_something..
PrescribedOrientationRigid.Keyword()

Returns the keyword for this prescribed orientation rigid. Note that a carriage return is not added. See also PrescribedOrientationRigid.KeywordCards()

Returns:

string containing the keyword

Return type:

str

Example

To get the keyword for prescribed orientation rigid por:

key = por.Keyword()
PrescribedOrientationRigid.KeywordCards()

Returns the keyword cards for the prescribed orientation rigid. Note that a carriage return is not added. See also PrescribedOrientationRigid.Keyword()

Returns:

string containing the cards

Return type:

str

Example

To get the cards for prescribed orientation rigid por:

cards = por.KeywordCards()
PrescribedOrientationRigid.Next()

Returns the next prescribed orientation rigid in the model

Returns:

PrescribedOrientationRigid object (or None if there are no more prescribed orientation rigids in the model)

Return type:

PrescribedOrientationRigid

Example

To get the prescribed orientation rigid in model m after prescribed orientation rigid por:

por = por.Next()
PrescribedOrientationRigid.Previous()

Returns the previous prescribed orientation rigid in the model

Returns:

PrescribedOrientationRigid object (or None if there are no more prescribed orientation rigids in the model)

Return type:

PrescribedOrientationRigid

Example

To get the prescribed orientation rigid in model m before prescribed orientation rigid por:

por = por.Previous()
PrescribedOrientationRigid.SetFlag(flag)

Sets a flag on the prescribed orientation rigid

Parameters:

flag (Flag) – Flag to set on the prescribed orientation rigid

Returns:

No return value

Return type:

None

Example

To set flag f for prescribed orientation rigid por:

por.SetFlag(f)
PrescribedOrientationRigid.Sketch(redraw=Oasys.gRPC.defaultArg)

Sketches the prescribed orientation rigid. The prescribed orientation rigid will be sketched until you either call PrescribedOrientationRigid.Unsketch(), PrescribedOrientationRigid.UnsketchAll(), Model.UnsketchAll(), or delete the model

Parameters:

redraw (boolean) – Optional. If model should be redrawn or not after the prescribed orientation rigid is sketched. If omitted redraw is true. If you want to sketch several prescribed orientation rigids 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 prescribed orientation rigid por:

por.Sketch()
PrescribedOrientationRigid.Unsketch(redraw=Oasys.gRPC.defaultArg)

Unsketches the prescribed orientation rigid

Parameters:

redraw (boolean) – Optional. If model should be redrawn or not after the prescribed orientation rigid is unsketched. If omitted redraw is true. If you want to unsketch several prescribed orientation rigids 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 prescribed orientation rigid por:

por.Unsketch()
PrescribedOrientationRigid.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:

PrescribedOrientationRigid object

Return type:

dict

Example

To check if PrescribedOrientationRigid property por.example is a parameter by using the PrescribedOrientationRigid.GetParameter() method:

if por.ViewParameters().GetParameter(por.example):
    do_something..
PrescribedOrientationRigid.Xrefs()

Returns the cross references for this prescribed orientation rigid

Returns:

Xrefs object

Return type:

dict

Example

To get the cross references for prescribed orientation rigid por:

xrefs = por.Xrefs()