global G_Ta;
global G_Da;
+if(length(mu)~=length(type)&&length(mu)~=1)
+ disp 'Error: Pleas set right type and mu parameters'
+ return
+end
+
for i = 1:times
if(size(G_Ta,1)>2)
nextF = G_Ta(end,1)*4;
A_stepAnIso(mu,type,eta,eps);
usedTime = G_Ta(end,:)
data = G_Da(end,:)
+ typeN = int2str(type);
- A_saveMesh(['anIso' int2str(type) '_' int2str(size(G_Ta,1))]);
+ A_saveMesh(['anIso' typeN(typeN~=' ') '_' int2str(size(G_Ta,1))]);
end
return
end
+if(length(mu)~=length(type)&&length(mu)~=1)
+ disp 'Error: Pleas set right type and mu parameters'
+ return
+end
+if(length(mu)==1)
+ mu = repmat(mu,length(type),1);
+end
+
time = zeros(1,3);
tic
[coordinates_fine,elements_fine,neigh_fine,f2s]=refineQuad(G_C,G_E,G_N,2);
time(1) = toc;
-
- tic
- A_fine = mex_build_AU(coordinates_fine,elements_fine,mu,type);
- time(2) = toc;
-
- b = sqrt(sum(quadNorm(coordinates_fine,elements_fine,'w').^2,2));
+
- x_fine = A_fine\b;
- xe_fine = x_fine'*A_fine*x_fine;
+ tic
+ dataAniso = size(G_E,1);
+ for i = 1:length(type)
+ A_fine = mex_build_AU(coordinates_fine,elements_fine,mu(i),type(i));
+
+ b = sqrt(sum(quadNorm(coordinates_fine,elements_fine,'w').^2,2));
+
+ x_fine = A_fine\b;
+
+ xe_fine = x_fine'*A_fine*x_fine;
+
+ ind = computeEstSlpMuTilde(x_fine,G_C,G_E,f2s);
- ind = computeEstSlpMuTilde(x_fine,G_C,G_E,f2s);
+ dataAniso = [dataAniso type sqrt(sum(ind)) xe_fine];
+ end
+ time(2) = toc;
+
marked = mark(x_fine(f2s)',ind,eta,eps);
% clear 'coordinates_fine' 'elements_fine' 'neigh_fine' 'f2s'
- dataAniso = [size(G_E,1) sqrt(sum(ind)) xe_fine];
+
if(size(G_E,1)~=length(marked))
disp 'Error: MarkierungsVektor ist fehlerhaft'
G_Ta(size(G_Ta,1)+1,1:4) = [size(G_E,1) time];
- G_Da(size(G_Da,1)+1,1:3) = dataAniso;
+ G_Da(size(G_Da,1)+1,1:length(dataAniso)) = dataAniso;
% plotShape(G_C,G_E,'');
return
end
+if(length(mu)~=length(type)&&length(mu)~=1)
+ disp 'Error: Pleas set right type and mu parameters'
+ return
+end
+if(length(mu)==1)
+ mu = repmat(mu,length(type),1);
+end
+
time = zeros(1,2);
tic
time(1) = toc;
tic
- A_fine = mex_build_AU(coordinates_fine,elements_fine,mu,type);
- time(2) = toc;
-
+ dataIso = size(G_E,1);
+ for i = type
+ A_fine = mex_build_AU(coordinates_fine,elements_fine,mu(i),type(i));
+
b = sqrt(sum(quadNorm(coordinates_fine,elements_fine,'w').^2,2));
x_fine = A_fine\b;
ind = computeEstSlpMuTilde(x_fine,G_C,G_E,f2s);
- dataIso = [size(G_E,1) sqrt(sum(ind)) xe_fine];
+ dataIso = [dataIso type sqrt(sum(ind)) xe_fine];
+ end
+ time(2) = toc;
G_C = coordinates_fine; G_E = elements_fine; G_N = neigh_fine;
G_Ti(size(G_Ti,1)+1,1:3) = [size(G_E,1) time];
- G_Di(size(G_Di,1)+1,1:3) = dataIso;
+ G_Di(size(G_Di,1)+1,1:length(dataIso)) = dataIso;
end