od of Finite Elements II Assignment #1 Method of Finite Elements II Consider a steady state heat transfer problem (i.e. π is the temperature) in a one dimensional channel (of a unit cross-βsectional are) as a fluid flows through it with prescribed velocity π£ under a temperature gradient ππ π! π π£ = π ! 0 β€ π₯ β€ πΏ ππ₯ ππ₯ π π₯ = 0 = π! π π₯ = πΏ = π! where πΌ is the diffusivity of the fluid. The analytical solution of the problem is given by π! π π₯ β π! ππ₯π πΏ π₯ β 1 = 0 β€ π₯ β€ πΏ π! β π! ππ₯π π! β 1 where P! = !" ! is known as the Péclet number. Answer the following questions using the parameters: πΏ = 1, π! = 1, π! = 0. 1. Plot the behavior of the analytical solution for increasing values of P! and explain what you observe. Tip: For different values of P! , what are the insulating properties of the pipe? 2. Write the Weak form of the problem. 3a. Using Galerkinβs method, formulate the corresponding problem πΎπ = π and describe the properties of πΎ . Reminder: In Galerkin's method the same shape functions are used for the trial and weight function approximation). Extra Credit: Explain how the properties and structure of πΎ impact the solution process from a computational aspect. 3b. Given: πΌ=0.01, π£=1, linear shape functions, and a uniform discretization of the domain, modify the MATLAB code given, to solve this problem and obtain the nodal temperature solutions with a number of nodes πnp=20. Plot the FE and the analytical solution on the same figure and comment on the quality of the solution. Extra Credit: a) Can you think of one way to obtain a better solution (other than the one in 4.). ! b) Assuming the exact shape functions are given as π» = 1 π !! , is Gaussian integration still applicable? Explain your reasoning. Note: The main routine is FEMaxialbar.m. Make sure to properly modify the number of used nodes (nnp), the essential (e_bc) and natural (n_bc) boundary conditions in input_file.m and of course the setup of the element stiffness and force matrices based on your derivation for the Galerkin method (question 3a) in elem.m) 4. Using a Petrov-βGalerkin method, repeat question 3a and 3b. In a Petrov-βGalerkin method, the shape functions used for the trial and weight functions are different and are written given by: π! π’! π’ π₯ = π€ π₯ = π€! π! + πΎ β! ππ! , πππ π£ > 0 2 ππ₯ where πΎ = πππ‘β !! ! ! β ! !
© Copyright 2026 Paperzz