How to create finer mesh with material distributions?

조회 수: 2 (최근 30일)
SAMUEL AYINDE
SAMUEL AYINDE 2017년 1월 4일
편집: Mohammad Abouali 2017년 1월 5일
I have a matrix of number which represent the material distribution in finite elements. How can I create a finer mesh with these matrix in MATLAB? I need a code which I can use to create a remesh/finer mesh. For example, let us say I have a 30*30 matrix which denote the material distribution in finite elements. I need a code that I can use to generate a remesh/finer mesh in MATLAB. Thank you.
  댓글 수: 2
KSSV
KSSV 2017년 1월 5일
Can you show what you want with an example? image..a hand drawn image at least.
Massimo Zanetti
Massimo Zanetti 2017년 1월 5일
I have the feeling you need interp2 function, or something similar..

댓글을 달려면 로그인하십시오.

채택된 답변

Mohammad Abouali
Mohammad Abouali 2017년 1월 5일
편집: Mohammad Abouali 2017년 1월 5일
You can use imresize(). Something like this should work.
% Initializing a sample image
myImage = [0 1 1 1; ...
1 0 1 1; ...
1 0 0 1; ...
1 1 1 1];
imshow(myImage,'InitialMagnification',10000)
% using imresize to resize the image and refine it.
myRefinedImage = imresize(myImage,2,'nearest');
imshow(myRefinedImage,'InitialMagnification',10000)
Check the method options. if the value in image are label to a certain material so you need to use nearest. However, depending on your application you might need to use other methods.

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Image Filtering and Enhancement에 대해 자세히 알아보기

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by