Pressure Analysis.AddPressure(DataRepresentation param1)

Creates a new child Pressure. DataRepresentation.Field will use the Field object for working with tabular data DataRepresentation.Flexible allows the use of the following types when the pressure is defined as a normal to a surface: Quantity: The unit must be a valid Pressure unit string: It is interpreted as s table if it matches a Table name. Else it is interpreted as an expresion Table: A table object can be specified.

Examples

"""The following example creates a pressure on the first face of the first body for the first part.""" model = ExtAPI.DataModel.Project.Model pressure = model.Analyses[0].AddPressure() # Add a pressure. part1 = model.Geometry.Children[0] # Get the first part. body1 = part1.Children[0] # Get the first body. face1 = body1.GetGeoBody().Faces[0] # Get the first face of the body. selection = ExtAPI.SelectionManager.CreateSelectionInfo(SelectionTypeEnum.GeometryEntities) # Create an empty selection. selection.Entities = [face1] # Add the face to the selection. pressure.Location = selection # Assign the selection to the pressure. pressure.Magnitude.Inputs[0].DiscreteValues = [Quantity("0 [s]"), Quantity("1 [s]")] # Set the time values. pressure.Magnitude.Output.DiscreteValues = [Quantity("10 [Pa]"), Quantity("20 [Pa]")] # Set the magnitudes.

Parameters

Return Value

Type: Pressure
Returns the object created.