response ex6

This commit is contained in:
Gundolf Haase 2026-01-15 12:05:56 +01:00
commit 4cd85941b9
3 changed files with 21 additions and 1 deletions

View file

@ -1,6 +1,6 @@
clear; clc; close all;
pList = [5, 10, 20, 100];
nIter = 9;
nIter = 5;
figure;
tiledlayout(2,2)
@ -22,6 +22,10 @@ for ip = 1:length(pList)
K(1,:) = 0;
K(1,1) = 1;
F(1) = -atan(p);
% GH: Dirichlet boundary conditions at x=+1
K(end,:) = 0;
K(end,end) = 1;
F(end) = atan(p);
u = K \ F;

BIN
Sheet6/Sheet6.pdf Normal file

Binary file not shown.

16
Sheet6/gh_response.txt Normal file
View file

@ -0,0 +1,16 @@
h- and r-adaptivity.
A:
* h-adaptivity gets worse with increasing p (not correct)
* GH: choose nIter=1 ==> all solutions are incorrect
* GH: choose nIter=20 ==> all solutions are correct
* GH: nIter = 5 and Dirchlet bc at x=1.5 ==> aweful for p=20, 100
Integration of f(x) is not accurate enough. ==> better integration formula needed, see integral(...)
B:
* h-adaptivity is correct
C:
* r-adaptivity
looks suspicious, but similar to Mandl