01 Fin Tip Insulation - Effect on Qf

  • Upload
    quanckm

  • View
    213

  • Download
    0

Embed Size (px)

Citation preview

  • 7/27/2019 01 Fin Tip Insulation - Effect on Qf

    1/18

    Fin Tip Insulation Effect On Qf ME433 COMSOL INSTRUCTIONS

    FIN TIP INSULATION: EFFECT ON Qf

    Problem Statement

    In this module, we will examine the extent to which insulating the tip of a fin plays a role

    on total heat transferQf. As shown in diagram 1, one end of a cylindrical fin ismaintained at T0. Two cases are considered at the tip: (A) insulated tip and (B) heat

    transfer by convection at the tip. Heat is removed from the surface of the fin to thesurroundings by convection. Assuming constant h, k, and T, we will compute total heat

    transfer, Qf, for both of the cases. We will then compare the results of the two cases with

    each other to make a judgment and comment on what the effect of insulating a fin tip onheat transfer rate is. Thermal and geometric parameters for the model are listed below.

    Diagram 1 Insulated RodKnown quantities:

    L = 30 cmr0 = 0.5 cm

    T0 = 100 C

    T = 20 C

    k= 160 W/mCh = 10 W/m

    2C

    Observations

    SinceBi

  • 7/27/2019 01 Fin Tip Insulation - Effect on Qf

    2/18

    Fin Tip Insulation Effect On Qf ME433 COMSOL INSTRUCTIONS

    5. Using COMSOL and an additional software of your choice (i.e. MATLAB, Excel,), compare temperature distribution T(x) obtained by COMSOL with the

    predicted theoretical distributions derived in chapter 3 of your textbook for both

    of the cases. Do COMSOL results agree well with the theory? A sample answer

    for this question using MATLAB is provided.

    Modeling with COMSOL Multiphysics

    MODEL NAVIGATOR

    This is our starting point in the model where you define the very basics of the problem,

    such as the number of dimensions, type of coordinate system, and most importantly the

    application mode which agrees with the physical phenomena of the problem.

    We will model this problem with a 3 dimensional cylindrical fin. Since we are not

    intending to look at the field flow outside the fin, we will only need to work with theHeat Transfer Module. We are also modeling the process as steady state. For this setup:

    1. Start COMSOL Multiphysics.

    2. In the Space dimension list select 3D (under the New Tab).

    3. From the list of application modes select Heat Transfer Module General HeatTransfer Steady State Analysis

    4. Click OK.

    - 2 -

  • 7/27/2019 01 Fin Tip Insulation - Effect on Qf

    3/18

    Fin Tip Insulation Effect On Qf ME433 COMSOL INSTRUCTIONS

    GEOMETRY MODELING

    In this step, we will create a 3 dimensional cylindrical geometry that will be used as a

    model for our problem. To do this:

    1. Select Draw

    Cylinder option from menus at the top.

    2. In the newly appearing Cylinder window, specify the cylinder Radius and

    Height (length) as 0. 5e- 2 and 30e- 2, respectively.

    3. Enter - 0. 5e- 2 for the y and z axis base point fields. This will place the fincentered at the origin.

    4. Enter 1 and 0 in the x and z axis direction vector fields, respectively. Thiswill align the fin in the x direction and place the base of the fin in the y zplane.

    5. Click OK.

    6. Click on Zoom Extents button in the main toolbar to zoom into thegeometry.

    You should see your 3D fin now selected in light red color in the main program window.

    You can try to orbit, pan, and zoom to investigate the geometry you just made. In

    particular, try to explore what the following buttons do: , , , , , , , .

    - 3 -

  • 7/27/2019 01 Fin Tip Insulation - Effect on Qf

    4/18

    Fin Tip Insulation Effect On Qf ME433 COMSOL INSTRUCTIONS

    Note: If you made errors in this step, you can still correct them. Make sure the geometry

    you created is shown in a light red color in the main window, then select Draw Object Properties from the menus at the top. This will bring the Cylinder definition

    window back up.

    PHYSICS SETTINGS CASE A: INSULATED TIP

    Physics settings in COMSOL consist of two parts: (1) Subdomain settings and (2)boundary conditions. The subdomain settings let us specify fins material, initial

    conditions and modes of heat transfer (i.e. conduction and/or convection). The boundaryconditions settings are used to specify what is happening at the boundaries of the

    geometry.

    Subdomain Settings:

    1. From the Physics menu select Subdomain Settings (equivalently, press F8).

    2. Select Subdomain 1 in the Subdomain selection field.

    3. Enter 160 in the field for thermal conductivity k.

    4. Click OK

    Observe that COMSOL provides the governing equation for conduction on the top

    left corner of the Subdomain Settings window. Also, the fields for the density and

    heat capacity do not play a role in steady state analysis.

    - 4 -

  • 7/27/2019 01 Fin Tip Insulation - Effect on Qf

    5/18

    Fin Tip Insulation Effect On Qf ME433 COMSOL INSTRUCTIONS

    Boundary Conditions:

    1. From the Physics menu open the Boundary Settings (F7) dialog box.

    2. Apply the following boundary conditions:

    BOUNDARY BOUNDARY CONDITION COMMENTS

    1 Temperature Enter 100+273. 15 in the T0 field

    2, 3, 4, 5 Heat FluxEnter 10 in the h field

    Enter 20+273. 15 in the Tinf field

    6 Thermal Insulation

    3. Click OK to apply and close the Boundary Settings dialogue.

    Observe that: (1) by selecting the boundary numbers in the Boundary selection field,

    the selected boundaries are highlighted in red on the actual geometry of the fin;

    alternatively, you could have selected a boundary by clicking on the geometry itself, and

    (2) the types of boundaries for convection/conduction, such as heat fluxes, temperatures,or thermal insulations and more are all described mathematically in the upper part of the

    window.

    The condition for boundary 1 is the base temperature T0, as described in the problem

    definition. The heat flux boundary condition for boundaries 2 5 allows us to model

    conductive convective interface at these boundaries. With q0 equal to zero we obtaina condition that implies that conductive heat transfer is equal to convective heat transfer

    at those boundaries with constant h. The thermal insulation condition applied to boundary

    4 (the tip) implies that there is no convective heat transfer taking place.

    - 5 -

  • 7/27/2019 01 Fin Tip Insulation - Effect on Qf

    6/18

    Fin Tip Insulation Effect On Qf ME433 COMSOL INSTRUCTIONS

    MESH GENERATION

    To minimize the computational time without compromising much accuracy of the

    solution, we must change the default meshing parameters. To do this,

    1. Select Mesh

    Free Mesh Parameters (F9) from the menus at the top.

    2. Switch to the Edge tab in the new Free Mesh Parameters window.

    3. Select edges 1, 2, 4, and 6, at the same time in the Edge selection field.

    4. Switch to the Distribution tab.

    5. Enable the Constrained edge element distribution checkbox.

    6. Enter 4 as the number of edge elements.

    7. Click the Mesh Selected button.

    8. Select edge 7 in the Edge selection field.

    9. Enable the Constrained edge element distribution checkbox.

    10.Enter 10 as the number of edge elements.

    11.Enable the Distribution checkbox.

    12.Enter 5 as the element ratio.

    13.Change the distribution method to Exponential.

    - 6 -

  • 7/27/2019 01 Fin Tip Insulation - Effect on Qf

    7/18

    Fin Tip Insulation Effect On Qf ME433 COMSOL INSTRUCTIONS

    - 7 -

    14.Click the Mesh Selected button.

    15.Click the OK button.

    16.Switch to the boundary mode by selecting the following button: .

    17.In the main window (with the fin geometry), select the base boundary of the fin.

    18.Apply the mapped boundary meshing by pressing the following button: .

    19.Switch to the subdomain mode by selecting the following button: .

    20.Apply the mapped subdomain meshing by pressing the following button: .

    Your mesh is now complete. If you did not encounter any errors in the meshing steps, itshould resemble the one shown below.

    We are now ready to compute and obtain the solution.

  • 7/27/2019 01 Fin Tip Insulation - Effect on Qf

    8/18

    Fin Tip Insulation Effect On Qf ME433 COMSOL INSTRUCTIONS

    - 8 -

    COMPUTING AND SAVING THE SOLUTION

    In this step we define the type of analysis to be performed. We are interested in stationary

    analysis here, which we previously selected in the Model Navigator. Therefore, nomodifications need to be made. To enable the solver, proceed with the following steps:

    1. From the Solve menu select Solve Problem. (Allow few seconds for solution)

    2. Save your work on desktop by choosing File Save. Name the file accordingto the naming convention given in the Introduction to COMSOL Multiphysics

    document.

    The result that you obtain should resemble the following boundary color map:

    By default, your immediate result may be given as a slice distribution diagram instead of

    the boundary one shown above. The next section (Postprocessing and Visualization) willhelp you in obtaining the above and other diagrams, extracting temperature distribution

    data from the solution, and computing the heat transfer rate Qfthrough COMSOL).

  • 7/27/2019 01 Fin Tip Insulation - Effect on Qf

    9/18

    Fin Tip Insulation Effect On Qf ME433 COMSOL INSTRUCTIONS

    - 9 -

    POSTPROCESSING AND VISUALIZATION

    After solving the problem, we would like to be able to look at the solution. COMSOL

    offers us a number of different ways to look at our temperature field. In this problemwill deal with 3D color maps, heat transfer rate computation, 1D temperature distributio

    wen

    lots, and data extraction. We will then address the questions of COMSOL solution

    eed a more flexible data plotting utility. We will use MATLAB as a choice of post

    btaining the 3D Boundary Temperature Color Map:

    1. From the Postprocessing menu open Plot Parameters dialog box (F12).

    2. Under the General tab, enable the Boundary plot type.

    3. Deselect any other plot types, except Geometry edges as shown below (left):

    pvalidity and compare the results to theoretical predictions. To do this effectively, we willn

    computational and plotting program to address these questions. However, if you do not

    feel comfortable using MATLAB, you may use the software of your choice.

    O

    4. Change the Plot in option to New Figure using the drop down menu.

    5. Switch to Boundary tab.

    6. Change the unit of temperature to degrees Celsius.

    7. Click the Apply button.

  • 7/27/2019 01 Fin Tip Insulation - Effect on Qf

    10/18

    Fin Tip Insulation Effect On Qf ME433 COMSOL INSTRUCTIONS

    - 10 -

    Clicking the Apply button will keep the Plot Parameters window open. If you have

    me, experiment with other plot types for a few minutes. As you look through results,tinotice which quantities are being plotted.

    After you click the Apply button, a separate window will pop up with the 3D

    temperature color map. You can still interactively orbit, zoom, and pan around thegeometry. Clicking the Default 3D View button will show the default trimetric viewof the results. Clicking the , , buttons will position the geometry of the fin with th

    z, x, and y axis pointing normal to the computer monitor, with the axis vector direction

    pointing towards the user. Clicking twice consecutively on either of these but

    e

    tons willegate the axis vector direction (pointing normal to the computer monitor in a direction

    ay want to save it as

    n image for future discussion. This may be done as follows:

    . Click the save

    n

    away from the user)

    Saving Color Maps:

    After you have selected a view that shows the results clearly, you m

    a

    1 button in your figure with results. This will bring up anExport Image window.

    For a 4 by 6 image, acceptable image quality settings are given in the figure below. Ifyou need higher image quality, increase the DPI value.

    2. Change your Export Image value settings to the ones in the above figure.

    3. Click the Export button.

    4. Name and save the image.

  • 7/27/2019 01 Fin Tip Insulation - Effect on Qf

    11/18

    Fin Tip Insulation Effect On Qf ME433 COMSOL INSTRUCTIONS

    - 11 -

    As an example, the image shown below was processed with the same settings as above. I

    shows temperature distribution of the fin slice in x y plane. The triangles represent theheat flux. The size of the triangles represen

    t

    ts the amount of heat flux at a point.

    Computing Total Heat Transfer Qf:

    1. From the Postprocessing menu select Boundary Integration option.

    2. Select boundaries 2 to 6 in the boundary selection field.

    setting to Normal total heat flux.3. In the Subdomain Integration dialog window, change Predefined Quantities

    4. Click the OK button. The value of the integral (solution) is displayed atprograms prompt on the bottom. In this case, Qf= 4.48 W.

    D Plots and Data Extraction:

    Da

    o present numerical data, they are better suited for an

    hen specific quantitative data is needed, such as(x,0,0), 1D plots should be the choice of representation. In addition, such quantitative

    1

    t ,a such as T(x,0,0) can be best represented on a 1D plot. While the color maps

    showing temperature distribution d

    verall qualitative representation. WoT

  • 7/27/2019 01 Fin Tip Insulation - Effect on Qf

    12/18

    Fin Tip Insulation Effect On Qf ME433 COMSOL INSTRUCTIONS

    - 12 -

    data representation makes it easier to compare and verify. Here, we will first plot

    2. Switch to the Line/Extrusion tab.

    3. Change the unit of temperature to degrees Celsius.

    4. Enter 0 and 0. 3 for thex0 andx1 coordinates in cross section line data field

    Enter - 0. 5e- 2 fory0,y1,z0, andz1 coordinate fields.

    5. Click the OK button.

    T(x,0,0). Secondly, we will extract T(x,0,0) to a text file. To do this,

    1. Select Postprocessing Cross Section Plot Parameters option.

    .

    ata to a

    6. Click the export current data plot

    You should now get an exponentially decaying graph showing T(x,0,0). This is the

    temperature variation along the length of the fin at the center line. To export this d

    xt file,te

    button.

    7. Click Browse and navigate to your saving folder (say Desktop).

    _i nsul at ed. t xt . (Note: do not forget to type the .txt

    extension in the name of the file).

    8. Name the file Tx_comsol

    Make sure you remember where you save this data file. You will need it later for analysis

    with MATLAB.

  • 7/27/2019 01 Fin Tip Insulation - Effect on Qf

    13/18

    Fin Tip Insulation Effect On Qf ME433 COMSOL INSTRUCTIONS

    - 13 -

    CASE B: NON INSULATED TIP

    Prior to moving on to this case, make sure you have saved all the color maps you need

    nd extracted the data T(x,0,0) to a text file. If you did not, finish those tasks first beforea

    you continue with case B.

    LOADING PREVIOUS FILE

    Since this is the same problem with simple modification on

    odel you saved earlier by double clicking on it. If you already

    one boundary, first load the

    have it open, continue bymmodifying its physics settings.

    PHYSICS SETTINGS

    Boundary Conditions:

    Simple boundary modification is needed for enabling convection at the tip of the fin. Todo this,

    1. Press F7 to load the Boundary Settings window.

    2. Select boundary 6 in the Boundary selection field.

    3. Change the Boundary condition to Heat flux.

    4. Enter these quantities in their appropriate fields: h = 10, Tinf= 20 + 273.15.

    5. Click the OK button.

  • 7/27/2019 01 Fin Tip Insulation - Effect on Qf

    14/18

    Fin Tip Insulation Effect On Qf ME433 COMSOL INSTRUCTIONS

    - 14 -

    RECOMPUTING

    1. From the Solve menu select Solve Problem. Allow a few seconds for thecomputation.

    POSTPROCESSING

    As you probably can see from the 3D color map for this case, there is hardly anydifference when compared to case A. It is hard to note quantitative differences from these

    color maps. We will therefore use COMSOL to just compute the total heat transferqfandextract the COMSOL T(x,0,0) data to a text file. The procedures for doing this are the

    same as in case A.

    1. Follow the same procedure as in case A to find the total heat transferQf. Startfrom page 11, section on Computing the total heat transferQf. The COMSOL

    value ofQffor case B (non insulated tip) is about q = 4.495 W.

    2. Extract the COMSOL T(x,0,0) data to a text file for this case. Name the file

    Tx_comsol _non_i nsul at ed. t xt and save it in the same location that where you

    saved your data for case A. Make sure you have and know where you save thesefiles as you will need them for further analysis.

    With the amount of data gathered by this time, you are in a position to answer the

    questions posed in the Assignment section on page 1. A sample for question 5 using

    MATLAB script is provided in the Appendix. You are advised to use this sample toanswer question 5.

    This completes COMSOL modeling procedures for this problem.

  • 7/27/2019 01 Fin Tip Insulation - Effect on Qf

    15/18

    Fin Tip Insulation Effect On Qf ME433 COMSOL INSTRUCTIONS

    - 15 -

    Modeling with MATLAB

    ou saved your 2 COMSOL data files. (Note: ef f ect_of _ i nsul at i ng_f i n_t i p. m file isf this document as well. To access the file directly from this

    ocument, select View Navigation Panels Attachements and then save

    o fully reprinted in this appendix.

    Solution with the Fin Heat Equation Solution

    d and graph our COMSOL data in MATLAB and compare it

    pen MATLAB by double clicking its icon

    This part of modeling procedures describes how to create comparative T(x) using

    MATLAB. Obtain the file named ef f ect_of _ i nsul at i ng_f i n_t i p. m from Blackboard

    prior to following these procedures.Important: save this file in the same directory where

    yattached to the PDF version o

    d

    ef f ect_of _ i nsul at i ng_f i n_t i p. m in the same directory where you saved your 2

    COMSOL data files). In case you cannot obtain ef f ect_of _ i nsul at i ng_f i n_t i p. m filefrom the above sources, it is als

    Comparing COMSOL

    Now we are ready to loa

    with the fin heat equation solution. Follow the steps below to complete this problem:

    1. O on the Desktop.

    ing File Open [%Your

    . The script

    ta comparison will appear

    you will be presented with 3 plots showing

    mperature distribution comparisons. Theoretical heat transfer rates for both of the cases

    will be displayed in the main Command Window in MATLAB. Save these results foryour module report.

    Results Plotted with MATLAB

    2. Load effect_of_insulating_fin_tip.m file by selectSelected Saving Directory%] effect_of_insulating_fin_tip.m

    program responsible for COMSOL data import and da

    in a new window.

    3. Press F5 to run the script. MATLAB editor will display a warning message. ClickChange Directory to run the script.

    If there are no errors in the process,

    te

  • 7/27/2019 01 Fin Tip Insulation - Effect on Qf

    16/18

    Fin Tip Insulation Effect On Qf ME433 COMSOL INSTRUCTIONS

    - 16 -

  • 7/27/2019 01 Fin Tip Insulation - Effect on Qf

    17/18

    Fin Tip Insulation Effect On Qf ME433 COMSOL INSTRUCTIONS

    - 17 -

    APPENDIX

    s on

    Sampl e MATLAB Scr i pt For COMSOL Modul e: ( X) I NSULATI NG FI N TI P: EFFECT ON qf

    h = 10;r = 0. 005;

    % Ambi ent t emper at ure, [ degC] Case A: I nsul ated Ti p

    % Di spl ayi ng Theor . qf , [ W]

    ol _ i nsul ated(: , 2) ; % ext r act s COMSOL T(x, 0, 0) , [ degC] _comsol _a = Tx_comsol _a( 1: 200, 1) ; % del etes ext r aneous dat a

    OMSOL T( x, 0, 0) f i gure1 = f i gure( ' I nver t Hardcopy' , ' of f ' , . . . %\

    ' Col ormap' , [ 1 1 1 ] , . . . % | - > Sett i ng up t he f i gure' Col or ' , [ 1 1 1]) ; %/

    pl ot ( x, Tx_a, ' r+' ) ; % Pl ott i ng theor. T(x) hol d on % Freezi ng the f i gurepl ot( comsol _coords_a, Tx_comsol _a, ' k' ) % Pl ot t i ng COMSOL T( x, 0, 0) l egend( ' Equat i on [ 3. 82] ' , ' COMSOL Sol ut i on' ) %\

    box of f % | xl abel ( ' x, (m)' ) % | yl abel ( ' Temper ature, ( deg C) ' ) % | set ( get ( gca, ' YLabel ' ) , . . . % |

    ' f onts i ze' , 20, . . . % | ' Font Name' , ' Ti mes New Roman' , . . . % | - > Cosmet i cs' Font Angl e' , ' i t al i c' ) % |

    set ( get ( gca, ' XLabel ' ) , . . . % | ' f onts i ze' , 20, . . . % | ' Font Name' , ' Ti mes New Roman' , . . . % | ' Font Angl e' , ' i t al i c' ) %/

    %% CASE B: Convect i on at t he Ti p of t he Fi n

    MATLAB script

    If you could not obtain this script from the Blackboard or the PDF file, you may copy itfrom here into notepad and save it in the same directory where you saved your 2

    COMSOL data files. You will most likely get hard to spot syntax errors if you copy

    the script this way. It is therefore highly advised that you use the other 2 method

    obtaining this script instead of the copying method.

    % ######################################################ME 433 - Heat Transf er %

    %%% I MPORTANT: Save t hi s f i l e i n t he same f ol der wi t h your% "Tx_comsol _i nsul ated. t xt" and

    "Tx_comsol _non_i nsul at ed. t xt" f i l es. %% ######################################################%cl c ; % Cl ear s t he UI prompt cl ear; % Cl ear s var i abl es f r ommemory%%% Const ant Quanti t i esk = 160; % Fi n' s Conduct i vi t y, [ W/ m- K]

    % Heat Tr anf . Coef f . at f i n' s surf ace, [ W/ m 2- K]% Fi n' s radi us, [ m]

    L = 0. 3; % Fi n' s l engt h, [ m] C = 2*pi *r; % Fi n' s ci r cumf er ence, [ m] Ac = pi *r 2; % Fi n' s conduct i on area, [ m 2] m = ( h*C/ ( k*Ac)) ( 1/ 2) ; % Fi n parameter , [ 1/ m]

    To = 100; % Base t emper at ure, [ degC] Ti nf = 20;%%% Comput i ng Theoret i cal qf and T( x): qf _a = ( k*Ac*C*h) ( 1/ 2) *( To - Ti nf ) *t anh( m*L); % Fi n' s Heat Transf er Rate, [ W] di sp( ' Theor et i cal qf ( case A) , [ i n Wat t s] = ' ) ; di sp( qf _a);

    = 0: . 01: L ; % x - coordi nate di scr i t i zat i on, [m]x

    Tx_a = cosh( m*( L - x) ) . / ( cosh( m*L) ) *( To - Ti nf ) + Ti nf ; % T(x) f or t he above Fi n, [ degC]% Loadi ng and ext r act i ng COMSOL resul t s f or T( x, 0, 0) l oad Tx_comsol _i nsul at ed. t xt ; % l oads COMSOL t ext dat a f i l e i nto memorycomsol _coor ds_a = Tx_comsol _i nsul ated( : , 1) ; % ext r act s COMSOL x - axi s coordi nat es, [ m]comsol _coords_a = comsol _coords_a( 1: 200, 1) ; % del etes ext r aneous dat a

    Tx_comsol _a = Tx_comsTx% Pl ot t i ng Theor et i cal T( x) and C

  • 7/27/2019 01 Fin Tip Insulation - Effect on Qf

    18/18

    Fin Tip Insulation Effect On Qf ME433 COMSOL INSTRUCTIONS

    - 18 -

    % Comput i ng Theoret i cal qf and T( x): t er m1 = ( si nh( m*L) + ( h/ ( m*k)) *cosh( m*L)) / ( cosh( m*L) + ( h/ ( m*k)) *si nh( m*L)) ;qf _b = ( k*Ac*C*h) ( 1/ 2) *( To - Ti nf ) *t erm1; % Fi n' s Heat Transf er Rate, [ W] di sp( ' Theor et i cal qf ( case B) , [ i n Wat t s] = ' ) ; di sp( qf _b); % Di spl ayi ng Theor . qf , [ W] t erm2 = ( cosh( m*( L - x) ) + ( h/ ( m*k)) *si nh( m*( L - x) ) ) . / ( cosh( m*L) + ( h/ ( m*k)) *si nh( m*L)) ;

    Tx_b = t er m2*( To - Ti nf ) + Ti nf ; % T(x) f or t he above Fi n, [ degC]

    % Loadi ng and ext r act i ng COMSOL resul t s f or T( x, 0, 0)

    l oad Tx_comsol _non_ i nsul at ed. t xt ; % l oads COMSOL t ext dat a f i l e i nto memorycomsol _coor ds_b = Tx_comsol _non_i nsul ated( : , 1) ; % ext r act s COMSOL x - axi s coor di nat es,[ m] comsol _coords_b = comsol _coords_b( 1: 200, 1) ; % del etes ext r aneous dat a

    Tx_comsol _b = Tx_comsol _non_i nsul at ed( : , 2) ; % ext r act s COMSOL T(x, 0, 0) , [ degC] Tx_comsol _b = Tx_comsol _b( 1: 200, 1) ; % del etes ext r aneous dat a

    % Pl ott i ng Theoret i cal T(x) and COMSOL T(x, 0, 0) f i gure2 = f i gure( ' I nver t Hardcopy' , ' of f ' , . . . %\

    ' Col ormap' , [ 1 1 1 ] , . . . % | - > Sett i ng up t he f i gure' Col or ' , [ 1 1 1] ) ; %/

    pl ot ( x, Tx_b, ' r+' ) ; % Pl ott i ng theor. T(x) hol d on % Freezi ng the f i gurepl ot( comsol _coords_b, Tx_comsol _b, ' k' ) % Pl ot t i ng COMSOL T( x, 0, 0) l egend( ' Equat i on [ 3. 80] ' , ' COMSOL Sol ut i on' ) %\

    of f % | abel ( ' x, ( m)' ) % |

    ' Temper ature, ( deg C) ' ) % | set ( get ( gca, ' YLabel ' ) , . . . % | ' f onts i ze' , 20, . . . % | ' Font Name' , ' Ti mes New Roman' , . . . % | - > Cosmet i cs' Font Angl e' , ' i t al i c' ) % |

    set ( get( gca, ' XLabel ' ) , . . . % | ' f onts i ze' , 20, . . . % | ' Font Name' , ' Ti mes New Roman' , . . . % | ' Font Angl e' , ' i t al i c' ) %/

    %% Comprehensi ve Pl ot f i gure3 = f i gure( ' I nver t Hardcopy' , ' of f ' , . . . %\

    ' Col ormap' , [ 1 1 1 ] , . . . % | - > Sett i ng up the f i gure' Col or ' , [1 1 1] ) ; %/

    pl ot ( comsol _coords_a, Tx_comsol _a, comsol _coords_b, Tx_comsol _b)hol d onpl ot ( x,Tx_a, ' +' , x, Tx_b, ' +' )l egend( ' COMSOL Sol ut i on ( case A) ' , ' COMSOL Sol ut i on ( case B) ' , . . .

    ' Equat i on [ 3. 82] ' , ' Equati on [ 3. 80] ' ) %\ box of f % | xl abel ( ' x, (m)' ) % | yl abel ( ' Temper ature, ( deg C) ' ) % | set ( get ( gca, ' YLabel ' ) , . . . % |

    ' f onts i ze' , 20, . . . % | - > Cosmet i cs' Font Name' , ' Ti mes New Roman' , . . . % | ' FontAngl e' , ' i t al i c' ) % |

    set ( get ( gca, ' XLabel ' ) , . . . % | ' f onts i ze' , 20, . . . % | ' Font Name' , ' Ti mes New Roman' , . . . % | ' FontAngl e' , ' i t al i c' ) %/

    This completes MATLAB modeling procedures for this problem.

    boxxl

    yl abel (