Вы находитесь на странице: 1из 18

Exercise 10

Time Dependent Boundary


Conditions

Objective:
■ Model an aluminum plate.

■ Use microfunctions to apply time dependent


boundary conditions to the plate corners.

■ Run a transient analysis to produce time dependent


results.

PATRAN 312 Exercises - Version 7.5 10-1


10-2 PATRAN 312 Exercises - Version 7.5
Exercise 10 Time Dependent Boundary Conditions

Model Description:
In this exercise you will define MACROs and microfunctions. MACRO
definitions are edited into a template.dat.apnd file which you create in the
same directory as your database.

MACRO definitions link Template ID’s (TID’s) which are applied in the
Loads/BCs form to Microfunction ID’s (MFID’s) which are defined in the
Fields form. A microfunction can be a function of time or various
temperature functions. This provides a mechanism for defining time or
temperature varying heat load or temperature boundary conditions. Only
constant or spatially varying loads or boundary conditions can be defined
directly in the Loads/BCs forms.

In this exercise we will sample three of the available microfunctions: a sine


wave, a flip-flop function and a linearly interpolated data table. These
functions are applied to three of the four corners of an aluminum plate
modelled from shell elements. The fourth plate corner will have a constant
boundary temperature.
T111 T121

Figure 1

{
t
t T111 100 if t < 60
T121 = 150 if 60< t < 180
0 100
100 if t > 180
30 125
60 160 0.15 m
120 160 111
210 100
121
360 100
Aluminum Plate
0.01 m thick
0.15 m (MID =1)

T11
T1

1 11

t
t
T11 = 15 sin(4*Pi*t/360 + 3*Pi/2) + 115
T1 = 100

PATRAN 312 Exercises - Version 7.5 10-3


Open a new database

Exercise Overview:
■ Create a new database named exercise_10.db. Set Tolerance to
Default, and the Analysis Code to MSC/THERMAL.

■ Create a 0.15m x 0.15m plate surface.

■ Mesh the surface with an IsoMesh of quad4 elements, global


edge length of 0.015.

■ Apply element properties to the quad4’s defining them as shell


elements having a material name (MID) of 1 and a thickness of
0.01m.

■ Create 3 time dependent microfunctions using Fields and


Create/Non Spatial/General.

■ Define 4 temperature boundary condition in Loads/BC’s, 1 fixed


nodal temperature in the lower left corner of the plate and 3
variable nodal temperatures on the remaining corners.

■ Open a new window (shell) and in the directory which contains


the database and edit a file named template.dat.apnd creating
the MACRO definitions.

■ Prepare and submit the model for analysis specifying that it is


a transient analysis from t=0s to t=360s with output each 30s,
that the global initial temperature is 100oC, and that all
calculations and output should be oC.

■ Read the results files using Shareware and plot results for
several time steps. Do not delete the database from your
directory since it will be used in a future exercise.

■ Quit MSC/PATRAN.

Exercise Procedure:
Open a new 1. Open a new database named exercise_10.db.
database Within your window environment change directories to a convenient
working directory. Run MSC/PATRAN by typing p3 in your xterm window.

Next, select File from the Menu Bar and select New… from the drop-down
menu. Assign the name exercise_10.db to the new database by clicking in
the New Database Name box and entering exercise_10.

Select OK to create the new database.

File

10-4 PATRAN 312 Exercises - Version 7.5


Exercise 10 Time Dependent Boundary Conditions

New
New Database Name exercise_10
OK

MSC/PATRAN will open a Viewport and change various Main Form


selections from a ghosted appearance to a bold format. When the New Model
Preferences form appears on your screen, set the Tolerance to Default, and
the Analysis Code to MSC/THERMAL. Select OK to close the New Model
Preferences form.

Tolerance ◆ Default
Analysis Code MSC/THERMAL
OK

2. Create a 0.15m x 0.15m plate surface. Create plate


Select the Geometry Applications radio button. Create a surface using the geometry
following Action, Object, and Method. Click in the appropriate list boxes to
edit the default values and change them to values listed below.

◆ Geometry
Create/Surface/XYZ
Vector Coordinate List <0.15 0.15 0>
Apply

The resulting model is shown below.

Y
Z X

PATRAN 312 Exercises - Version 7.5 10-5


IsoMesh the surfaces

3. Mesh the surface with an IsoMesh of quad4 elements, global


IsoMesh the edge length of 0.015.
surfaces
Select the Finite Elements Applications radio button. Set the Action,
Object, and Type to Create/Mesh/Surface. Change the Global Edge Length
to 0.015 and select Surface 1 for inclusion in the Surface List.

◆ Finite Elements
Create/Mesh/Surface
Global Edge Length 0.015
Surface List <click on Surface 1 in
the viewport>
Apply

Use the Tool Bar Label Control icon to turn on node labels only.

First select then

Close

The display should now appear as shown below.

10-6 PATRAN 312 Exercises - Version 7.5


Exercise 10 Time Dependent Boundary Conditions

4. Apply element properties to the Quad4’s defining


them as shell elements having a Material Name Apply
(MID) of 1 and a thickness of 0.01m. element
Select the Properties Applications radio button. Set the Action, Dimension, properties
and Type to Create/2D/Shell. Enter Property Set Name Prop1. Select the
Input Properties... box. Click in the Material Name box and enter 1. Enter
0.01 in the Shell Corner Thickness list box. Select OK to close the
form.Click in the Select Members box and select Surface 1 in the viewport.
Select Add then Apply in the Element Properties form to complete the
element property definition.

◆ Properties
Create/2D/Shell
Property Set Name Prop1
Input Properties...
Material Name 1
Shell Corner Thickness 0.01
Ok
Select Members <select Surface 1 in the viewport>
Add
Apply

5. Create 3 time dependent microfunctions using Create micro-


Fields and Create/Non Spatial/General.
functions
Microfunctions are created in the Fields form using the Action/Object/
Method Create/Non Spatial/General. After selecting Input Data. The
General Field Input Data form will show the complete list of microfunctions
in the Select Function Term: list box.

Figure 1 contains the data required for entry into the various microfunction
forms. The entries and selection below will guide you through the process
of creating the microfunctions. An image of each completed microfunction
form is included to facilitate microfunction entry.

◆ Fields
Create/Non Spatial/General
Field Name Tsine

PATRAN 312 Exercises - Version 7.5 10-7


Create micro-functions

Input Data...
Select Function Term mfid_sine_wave
Micro Function ID 11
P1 Value 15.0
P2 Value 0.034907
P3 Value 4.71239
P4 Value 115.0
OK
OK
Apply

The Micro Function form should appear as shown below.


Micro Function: Sine Wave
Define Micro Function
Option 3
Sine Wave
F(X) = P1 * SIN(P2 * X + P3) + P4

Micro Function ID (MFID) Micro Function Option


11 3

Micro Function Description

Independent Variable Type Reciprocal Micro Function


Time

P1 Value P2 Value
15 0.034907

P3 Value P4 Value
4.712389 115.0

OK Defaults Cancel

10-8 PATRAN 312 Exercises - Version 7.5


Exercise 10 Time Dependent Boundary Conditions

Field Name Ttable


Input Data...
Select Function Term mfid_indx_linr_tabl
Micro Function ID 111
Independent Variable, (X) 0.0
Value, Function(X) 100.0
Enter
Independent Variable, (X) 30.0
Value, Function(X) 125.0
Enter
Independent Variable, (X) 60.0
Value, Function(X) 160.0
Enter
Independent Variable, (X) 120.0
Value, Function(X) 160.0
Enter
Independent Variable, (X) 210.0
Value, Function(X) 100.0
Enter
Independent Variable, (X) 360.0
Value, Function(X) 100.0
Enter
OK
OK
Apply

PATRAN 312 Exercises - Version 7.5 10-9


Create micro-functions

The Micro Function form should appear as shown below.


Micro Function: Indexed Linear Interpolation
Define Micro Function F(X) 5
Option 18 4
6
7
Indexed Linear Interpolation 1 2
3
8
of a Data Table X

Micro Function ID (MFID) Micro Function Option


111 18
Micro Function Description

Independent Variable Type Reciprocal Micro Function


Time
Bound Tables
Tabular Data
Independent Variable Dependent Value
2 30.0 125.0
3 60.0 160.0
4 120.0 160.0
5 210.0 100.0
6 360.0 100.0

Selected Data

Field Name Tflip_flop


Input Data...
Select Function Term mfid_flip_flop
Micro Function ID 121
P1 Value 60.0
P2 Value 180.0
P3 Value 150.0
P4 Value 100.0
OK
OK
Apply

10-10 PATRAN 312 Exercises - Version 7.5


Exercise 10 Time Dependent Boundary Conditions

The Micro Function form should appear as shown below.


Micro Function: Flip Flop Function
Define Micro Function
Option 15
Flip Flop Function
If P1<= X < P2, Then F(X) = P3
Else F(X) = P4

Microfunction ID (MFID) Microfunction Option


121 15
Microfunction Description

Independent Variable Type Reciprocal Microfunction


Time

P1 Value P2 Value
60.0 180.0
P3 Value P4 Value

150.0 100.0

OK Defaults Cancel

6. Define 4 temperature boundary condition in Loads/ Apply


BCs, 1 fixed nodal temperature in the lower left
corner of the plate and 3 variable nodal temperatures boundary
on the remaining corners. conditions
Begin applying boundary conditions. Select the Load/BCs Applications
radio button. Create a fixed 100oC nodal boundary temperature named T1.
In the Input Data form define the fixed temperature. In the Select Applications
Region form pick Node 1 located in the lower left corner of the plate.

◆ Load/BCs
Create/Temperature/Nodal
Option: Fixed
New Set Name T1
Input Data...
Fixed Temperature 100.0

PATRAN 312 Exercises - Version 7.5 10-11


Apply boundary conditions

OK
Select Application Region...
Geometry Filter ◆ FEM
Select Nodes <select Node 1>
Add
OK
Apply

Create a variable boundary temperature named T11 with Template Id 2 in


the Input Data form. In the Select Applications Region form pick Node 11
located in the lower right corner of the plate. Repeat these steps for New Set
Name T111 with Template ID 3 on Node 111 and T121 with Template ID 4
on Node 121.

◆ Load/BCs
Create/Temperature/Nodal
Option: Variable
New Set Name T11
Input Data...
Template ID 2
OK
Select Application Region...
Select Nodes <select Node 11>
Add
OK
Apply

Repeat these steps for New Set Name T111 with Template ID 3 on Node 111
and or New Set Name T121 with Template ID 4 on Node 121.

New Set Name T111


Input Data...
Template ID 3
OK

10-12 PATRAN 312 Exercises - Version 7.5


Exercise 10 Time Dependent Boundary Conditions

Select Application Region...


Select Nodes <select Node 111>
Add
OK
Apply
New Set Name T121
Input Data...
Template ID 4
OK
Select Application Region...
Select Nodes <select Node 121>
Add
OK
Apply

With boundary conditions applied the model should appear as shown below

PATRAN 312 Exercises - Version 7.5 10-13


In unix create template.dat.apnd file

7. Open a new window (shell) and in the directory which contains


the database vi edit a file named template.dat.apnd creating
In unix create the MACRO definitions.
template.dat.
apnd file Using the system editor, create and edit the file template.dat.apnd in the
directory which contains your database and where MSC/PATRAN is
running (You may need to open a new window.). The format for the
MACRO functions are as follows:

MACRO tid micro_function_count node1 node2 scale_factor

mfid(1) mfid(2)... mfid(n)

tid: where,

This is a Template ID number (entered in the Loads/BCs form).

micro_function_count:

Number of microfunctions that will be assembled (grouped) in this MACRO


function.

node1 & node2:

Node ID numbers used if temperature or a temperature difference is used for


the microfunction argument. {e.g. for radiosity difference σ*(T14-T24) (T1
and T2 temperatures at Node 1 and 2 respectively)}

scale_factor:

Optional scale factor for the MACRO function.

mfid#:

Integer ID number (pointer) of the microfunction. This is the MFID number


you used in the microfunction definition.

Note: MACRO is a key word and must be typed in uppercase.

Use the following chart to help you define the MACRO functions for the
temperature boundary conditions assigned to Nodes 11, 111, and 121.

Table 1:

TID# Micro_function_count Node 1 Node 2 scale_factor mfid#

2 1 0 0 1 11
3 1 0 0 1 111
4 1 0 0 1 121

Note: Nodes 1 and 2 are set to zero since the argument is time.

10-14 PATRAN 312 Exercises - Version 7.5


Exercise 10 Time Dependent Boundary Conditions

Shown below is the final form of the template.dat.apnd file created for this
exercise. Note that any comment lines must be started with an * in column
1 and make sure that there are no blank lines especially at the end of the file.

*================
MACRO 2 1 0 0 1.0
11
MACRO 3 1 0 0 1.0
111
MACRO 4 1 0 0 1.0
121
*================

8. Prepare and submit the model for analysis.


Prepare and
Select the Analysis Applications radio button to prepare the analysis. Select
the parameter forms reviewing and changing the settings as shown below. run analysis
The analysis is submitted by selecting Apply in the Analysis form.

◆ Analysis
Analyze/Full Model/Full Run
Solution Type...
Select Thermal Solution ◆ 1, Transient Run
OK
Solution Parameters...
Calculation Temperature Scale ◆ Celsius
Run Control Parameters...
Stop Time 360.0

Initial Temperature = 100.0

OK
OK
Output Requests...
Units Scale for Output Temperatures ◆ Celsius

PATRAN 312 Exercises - Version 7.5 10-15


Read and plot results

Print Interval Controls...


Initial Print Interval 30.0

OK
OK
Apply

9. Read the results files using Utilities and plot results for several
Read and plot time steps. Do not delete the database from your directory since
results it will be used in a future exercise.

From within MSC/PATRAN the only indication that the analysis has
successfully finished is the existence of nrX.nrf.01 (“x” will range from 1-
12) results files in a subdirectory one level below your working directory.

P3 was initiated from a working directory which contained the


exercise_010.db database. Applying the analysis created a new subdirectory
with the same name as the Job Name, exercise_10/. By using Read Result
in the Analysis form and Selecting Results File... you can filter down to the
Job Name subdirectory and check for the existence of a results file

Utilities provides a results reader under Thermal which facilitates reading


the results of transient runs. If you do not have Shareware installed or is
unavailable then skip to the instructions below which tell you how to read
the results from the Analysis form.

Utilities
Thermal
Thermal Results Reader...
Disclaimer
OK
Directories <path>/exercise_10

Filter

All your nr.nrf.01 files should appear in the Selected Files list box. Edit the
end of the path and file in the Selected File box to end in nr*.

Selected File <path>/exercise_10/nr*

OK
Apply

10-16 PATRAN 312 Exercises - Version 7.5


Exercise 10 Time Dependent Boundary Conditions

All the files will be read into the database. Since the analysis does not
involve convection template ID’s, the results template that is used in reading
the files detects that there are no such entries and creates a warning message
for each occurrence. This warning is irrelevant to this analysis. When the
warning messages cease. Click OK in the Warning form.

Select Close to exit the Utilities.

Warning
OK
Close

[OPTIONAL METHOD follows. Use only if necessary]

If for whatever reason Utilities are unavailable you can use the standard
MSC/PATRAN method of reading the results files. However, a Global
Variable for Time will not be created in the Result Cases. This will
adversely affect the animation subsequently created in Exercise 19.

◆ Analysis
Read Results/Result Entities
Select Results File...
Directories <path>/exercise_10

Filter
Available Files nr0.nrf.01

OK
Select Rslt Template File...
Files pthermal_1_nodal.res_tmpl

OK
Apply

Once you have selected a Results Template you can repeat the Select
Results File... step and hit Apply on the Read Results form without again
selecting a template.

Select Results File...


Available Files nr1.nrf.01

OK

PATRAN 312 Exercises - Version 7.5 10-17


Quit MSC/Patran

Apply

Repeat these steps for each nr#.nrf.01 file until all results are read.

[END OPTIONAL METHOD]

After results are read in by either method, plot the results. To plot the results
use the Results Application radio button. Select results for t=150s.

◆ Results
Create/Quick Plot
Select Result Cases TIME: 1.5000000000D+02 S...

Select Fringe Result Temperature,

Select the Fringe Attributes icon.

Display: Element Edges


Label Style...
Label Format: Fixed
Significant figures 4 <use slider bar>
OK
Apply

The posted results are for t=150s. The model should now appear as shown
on the front panel of this exercise. Feel free to post results from other times
to verify your results.

Do not delete the database when you finish this exercise it will be used in a
future exercise. In that exercise we will animate the results to display the
model’s behavior through time.

10. Quit MSC/PATRAN


Quit MSC/
Patran To stop MSC/PATRAN select File on the Menu Bar and select Quit from
the drop-down menu.

10-18 PATRAN 312 Exercises - Version 7.5

Вам также может понравиться