Surf plot 2D diffusion FEA
1 view (last 30 days)
Show older comments
Hy,
I'm trying to code a 2D diffusion problem. In the center from -1(mm) to +1(mm) both in x and y direction, the concentration of the solute is 100. The solutes then starts to diffuse in x and y direction with different rate (i.e. the diffusivities in x and y directions are different).
My code is working fine, but when I plot the initial condition (shown in the attached image) using the surf plot, the plot shows the initial condition as yellow color on the grid from -1 to +1.5, but this is misleading. The initial condition is between -1 to 1. I think this is because how the surf plot interprets the matrix and defines the color. You can see in the following images that the Z values on the grid points (the value of concentration) on the top and right hand side of the yellow region is zero.
What I need is to make a plot that shows the initial condition correctly (in this graph only from -1 to +1 colored yellow).
Is there any ways to solve this problem?
I attached the code as well.
Thanks a lot
0 Comments
See Also
Categories
Find more on Lighting, Transparency, and Shading in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!