PDE toolbox heat transfer solution
3 visualizaciones (últimos 30 días)
Mostrar comentarios más antiguos
I am modeling a rectangular cooling body with the PDE toolbox, and need to keep track of the temperature of the points on the boundary of the body. I thought that by finding where my x and y values are greatest in the point matrix 'p' I could find the node locations of the boundary points, and put those into the solution vector 'u' to find how these points change temperature, quantitatively, through time. However, when I search for the lowest temperatures in the solution vector, they do not match with the node points that I found in my 'p' matrix. I can understand this to a point, because the corner will lose heat faster than the edges, even part way into the body near the corner. However, I am getting values of 200˚ when I should be getting values around 10˚, so it's definitely not sampling the edge, but rather the interior of the body somewhere. Does anyone know the relationship between a node value in the point matrix 'p' and a node value in the solution vector 'u?' The code I used is below:
% p(1,1:2577) is x values of points
% p(2,1:2577) is y values of points
% u(1:2577,1:201) is solution vector for points from time 1 to time 201
bminx=find(p(1,:)==(min(p(1,:))));
bmaxx=find(p(1,:)==(max(p(1,:))));
bminy=find(p(2,:)==(min(p(2,:))));
bmaxy=find(p(2,:)==(max(p(2,:))));
% finds the borders of cooling rectangular body, creates vectors of the node points
% size(bminy) = 41 x 1, same for the other three
borders=unique([bminx,bmaxx,bminy,bmaxy])
% creates vectors of all node points, deleting any replicates. There are only 4 replicates, because each corner of the rectangle is counted twice.
% size(borders)= 160 x 1
Thus u(borders,201) should give me the 160 lowest temperatures for the cooling body, since the only heat flow is from the body to the significantly cooler boundaries. But it doesn't, and when I find the 160 lowest temperatures for the cooling body by using
find(u(:,201)<50)
the node points it gives are significantly different from those that I calculated should comprise the border. I can't find any relationship between the two, and am at a loss for how they related, but would like to know how this works. Any input would be great, thanks!
0 comentarios
Respuesta aceptada
Bill Greene
el 7 de Abr. de 2012
>Does anyone know the relationship between a node value in the point matrix 'p' and a node value in the solution vector 'u?
The ith column in p corresponds to the ith row in u (for the scalar PDE case which I assume is what you have).
I suggest that you turn on the "Show Node Labels" option in the Mesh menu of pdetool, run an analysis, and do a color plot of the result. You should be able to (roughly) compare the plotted results with those in the u-vector for specific node numbers.
Bill
Más respuestas (0)
Ver también
Categorías
Más información sobre Boundary Conditions en Help Center y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!