Strange behaviour of pde-toolbox in labeling or a bug?
Mostrar comentarios más antiguos
Hi, I'm new to pde-toolbox but this is kinda weird to me:
let's draw some rectangles in PDE Tollbox like:

but when I export Geometry Description and ... from Draw menu to matlab workspace and then decompose them using:
[g,bt] = decsg(gd,sf,ns) ;
plotting the resulted geometry by:
pdegplot(g)
this is what I get:

as could be seen, labels are randomly changed! any idea of what is happening here?
I'm using Matlab R2012b.
Respuesta aceptada
Más respuestas (1)
Bill Greene
el 19 de Oct. de 2013
0 votos
Hi,
The way I have dealt with the problem of defining coefficient matrices when I have had geometries similar to yours is to simply ignore the sub-domain numbers. I write a function to define the coefficient as shown in this doc page:
This page also shows how you can compute the centroid of each triangle inside this function. Then you simply assign coefficient values based on this location. In your case you can use the x-coordinate to determine which rectangle the element is in.
Hope that helps.
Bill
3 comentarios
Mohammad Monfared
el 20 de Oct. de 2013
Bill Greene
el 20 de Oct. de 2013
Without knowing the physics of your problem, I can't really say much definitive. It is not uncommon to have a single scalar equation for u and a "c" coefficient that has different terms in the x and y directions to reflect different properties in those directions. But, for a single PDE, the "a" coefficient is also a scalar. If you have more than one value for "a", I would guess you are missing an equation. That would mean u is a vector with two components.
Bill
Mohammad Monfared
el 21 de Oct. de 2013
Editada: Mohammad Monfared
el 21 de Oct. de 2013
Categorías
Más información sobre Boundary Conditions en Centro de ayuda y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!

