Document information
- University
- Politecnico di Milano
- Degree programme
- Biomedical Engineering
- Subject
- Mathematical and Numerical Methods in Engineering
- Classification
- Exam · Full exam
- Content
- Exam paper only
- Original format
- Text
- Searchable text
Full exam for Mathematical and Numerical Methods in Engineering in the Biomedical Engineering degree programme at Politecnico di Milano. The document covers: 12 points Exercise 1. - PART II - MATLAB: Take Ω = (−1,3), µ = 0.01, β = 10, boundary conditions u(−1) = 2, u(3) = 1, consider the following problem −µ u′′ + β u′ = x2 and the function esame provided by the form. (a) (2 points) Describe in the box below the Centered scheme
Full exam for Mathematical and Numerical Methods in Engineering in the Biomedical Engineering degree programme at Politecnico di Milano. The document covers: 12 points Exercise 1. - PART II - MATLAB: Take Ω = (−1,3), µ = 0.01, β = 10, boundary conditions u(−1) = 2, u(3) = 1, consider the following problem −µ u′′ + β u′ = x2 and the function esame provided by the form. (a) (2 points) Describe in the box below the Centered scheme
Import quality: text was extracted directly from the original document.
Representative passages recognised in different parts of the material. The full extracted text remains available to search, while this compact preview makes the page easier to read.
12 points Exercise 1. - PART II - MATLAB: Take Ω = (−1,3), µ = 0.01, β = 10, boundary conditions u(−1) = 2, u(3) = 1, consider the following problem −µ u′′ + β u′ = x2 and the function esame provided by the form. (a) (2 points) Describe in the box below the Centered scheme applied to the problem introduced above. Use the notation U_j to represent Uj (explaining their meaning). Report also the matrix/vector representation. Solution: Subdivide the space domain [ −1,3] in nodes xj = −1 +jh, j = 0, . . . ,M, with h = 3−(−1) M , and let Uj ≃ u(xj) be the approximation of the continuous solution. Then, the Centered scheme applied to the problem above reads: −µ Uj+1 − 2Uj + Uj−1 h2 + β Uj+1 − Uj−1 2h = x2 j , j = 1, . . . ,M − 1. In matrix/vector representation, we have: µ h2 A + β 2h B U = F , where (U)j = Uj, F = h x2 1 + 2µ h 2 + 2β 2h , . . . , x2 j , . . . , x2 M −1 + 1µ h 2 − 1β 2h iT , Aii = 2, Ai,i−1 = Ai,i+1 = −1 and zero elsewhere, Bii = 0, Bi,i−1 = −1, Bi,i+1 = 1 and zero elsewhere. (b) (1 point) Run the proposed code with the Centered scheme, h = 0.2 and the data reported in the text, writing in the box below all the instructions used to call the function. Solution: Function esame wants as input the expression of variable ϕ which regulates the stabiliza- tion. In this case, we do not have any stabilization, thus ϕ = 0. The Matlab instructions to call and run the function are: a = -1; b = 3; mu = 0.01; beta = 10; ua = 2; ub = 1; f = @(x) x.^2; h = 0.2; phizero = @(x) 0*x; % no stab [x, u] = esame(a, b, h, ua, ub, f, mu, beta, phizero); (c) (1 point) Run the proposed code with the Upwind method, h = 0.2 and with the data reported in the text, writing in the box below all the instructions used to call the function. Solution: In this case we want to add a…
First page of the document.