Please login with a confirmed email address before reporting spam
Posted:
1 decade ago
Feb 7, 2012, 10:40 a.m. EST
I don't think it possible to set up a model geometry (is that what you want?) from a bitmap.
Cheers
Edgar
I don't think it possible to set up a model geometry (is that what you want?) from a bitmap.
Cheers
Edgar
Please login with a confirmed email address before reporting spam
Posted:
1 decade ago
Feb 7, 2012, 11:14 a.m. EST
Hey Edgar,
yes, it is, because the biofilm structure I need is very complicated. It's neither possible nor reliable to draw it with any software. I want to use the image I got from OCT analysis.
Do you know if it's possible to import txt files? The results can also be saved in txt files.
Thanks!
Chunyan
Hey Edgar,
yes, it is, because the biofilm structure I need is very complicated. It's neither possible nor reliable to draw it with any software. I want to use the image I got from OCT analysis.
Do you know if it's possible to import txt files? The results can also be saved in txt files.
Thanks!
Chunyan
Please login with a confirmed email address before reporting spam
Posted:
1 decade ago
Feb 7, 2012, 11:20 a.m. EST
Hi Chunyan,
I think you must render the bitmap into a compatible vector format. This may be dxf or one of the available interfaces for CAD software like SolidWorks. I don't know what can be imported by textfiles. Maybe the COMSOL support can help.
However, very complicated biological structures will result in complicated geometries that are difficult to mesh and solve.
My advice would be to draw something simplified and start with it.
Cheers
Edgar
Hi Chunyan,
I think you must render the bitmap into a compatible vector format. This may be dxf or one of the available interfaces for CAD software like SolidWorks. I don't know what can be imported by textfiles. Maybe the COMSOL support can help.
However, very complicated biological structures will result in complicated geometries that are difficult to mesh and solve.
My advice would be to draw something simplified and start with it.
Cheers
Edgar
Please login with a confirmed email address before reporting spam
Posted:
1 decade ago
Feb 7, 2012, 11:47 a.m. EST
Hello Edgar,
thank you very much for your suggestions. I've just checked that it's possible to convert bmp images into dxf format. Will try that out. Thanks!!!!!
Regards!
Chunyan
Hello Edgar,
thank you very much for your suggestions. I've just checked that it's possible to convert bmp images into dxf format. Will try that out. Thanks!!!!!
Regards!
Chunyan
Please login with a confirmed email address before reporting spam
Posted:
1 decade ago
Oct 15, 2012, 8:17 p.m. EDT
Hi Chunyan,
Did you succeed to simulate flow on converted file. I converted a .png file to DXF file and imported to COMSOL. However at the end the solution does not converge. I think we have the same problem, since I am also trying to simulate flow on image acquired from CT. Please let me know if you have found a solution.
Regards,
saeid
Hi Chunyan,
Did you succeed to simulate flow on converted file. I converted a .png file to DXF file and imported to COMSOL. However at the end the solution does not converge. I think we have the same problem, since I am also trying to simulate flow on image acquired from CT. Please let me know if you have found a solution.
Regards,
saeid
Please login with a confirmed email address before reporting spam
Posted:
1 decade ago
Oct 16, 2012, 4:02 a.m. EDT
hello Saeid,
i did succeed in doing flow simulation with image imported. First right click on "Definition" under your model, select "Functions"--->"Image", then import image, define the scale of your image.
Afterwards you may need to define different viscosity for the bulk liquid and for the image part. it is done: right click on "Definition", select "Functions"---->"Analytic", in the "Expression" text box, you can define different properties corresponding to the gray level.
in my case, it is water and i used binary image. it is defined as: mu*(im2(x,y)<0.1)+mu*1e9*(im2(x,y)>=0.1) i consider that there is no water flow in the space occupied by the image. so i gave viscosity of the image part with 1e9 times higher than the area not occupied by the image. in this way, you can also define other properties simply by correcting them to the gray value.
Hope it can help you a little bit.
Chunyan :)
hello Saeid,
i did succeed in doing flow simulation with image imported. First right click on "Definition" under your model, select "Functions"--->"Image", then import image, define the scale of your image.
Afterwards you may need to define different viscosity for the bulk liquid and for the image part. it is done: right click on "Definition", select "Functions"---->"Analytic", in the "Expression" text box, you can define different properties corresponding to the gray level.
in my case, it is water and i used binary image. it is defined as: mu*(im2(x,y)=0.1) i consider that there is no water flow in the space occupied by the image. so i gave viscosity of the image part with 1e9 times higher than the area not occupied by the image. in this way, you can also define other properties simply by correcting them to the gray value.
Hope it can help you a little bit.
Chunyan :)
Please login with a confirmed email address before reporting spam
Posted:
1 decade ago
Oct 16, 2012, 8:34 p.m. EDT
Hi Chunyan,
Thanks for your reply.
You saeid you imported a binary image (segmented image). May I ask about the format of your original and the imported image? Is it 2D or 3D? I converted a 2D .png image of a sphere pack to .DXF but there are some artifacts in converted image which I think are the main reasons for divergence. Would you please advise me on that?
Best regards,
saeid
Hi Chunyan,
Thanks for your reply.
You saeid you imported a binary image (segmented image). May I ask about the format of your original and the imported image? Is it 2D or 3D? I converted a 2D .png image of a sphere pack to .DXF but there are some artifacts in converted image which I think are the main reasons for divergence. Would you please advise me on that?
Best regards,
saeid
Please login with a confirmed email address before reporting spam
Posted:
1 decade ago
Oct 18, 2012, 10:23 a.m. EDT
Hello Saeid,
i did 2D simulation. 3D is my next goal. i am working on that. I don't know how to convert image into geometry. A friend just told me yesterday that it's possible to do it with Matlab. But i don't know how to do it yet because i am very bad at programming. If you are good at that, you may try to do it with matlab.
Good luck!
Chunyan
Hello Saeid,
i did 2D simulation. 3D is my next goal. i am working on that. I don't know how to convert image into geometry. A friend just told me yesterday that it's possible to do it with Matlab. But i don't know how to do it yet because i am very bad at programming. If you are good at that, you may try to do it with matlab.
Good luck!
Chunyan
Please login with a confirmed email address before reporting spam
Posted:
1 decade ago
Nov 2, 2012, 4:54 p.m. EDT
Please let us know of your progress in 3D...
Please let us know of your progress in 3D...
Please login with a confirmed email address before reporting spam
Posted:
1 decade ago
Jan 30, 2013, 4:07 a.m. EST
Dear Chunyan,
I hope everything is going well with you.
I was reviewing some previous posts, looking for a possble way to export a segmented image to COMSOL as a geometry and not as a mesh. I came through this posted by you:
"i did succeed in doing flow simulation with image imported. First right click on "Definition" under your model, select "Functions"--->"Image", then import image, define the scale of your image. "
I was going to try this method for a 2D image, but I could not find "image" under "function" in definition node. Which COMSOL version you were talking about?
By the way, have you succeeded to export 3D image as a geometry to COMSOL?
I used Simpleware software and generated mesh from my 3D image and exported to COMSOL. It worked nice but for larger size of images you need lots of RAM to generate mesh and I could not do that with Simpleware and that is why I am trying to export my image to COMSOL as a geometry and let COMSOL mesh it for simulation.
Regrads,
Saeid
Dear Chunyan,
I hope everything is going well with you.
I was reviewing some previous posts, looking for a possble way to export a segmented image to COMSOL as a geometry and not as a mesh. I came through this posted by you:
"i did succeed in doing flow simulation with image imported. First right click on "Definition" under your model, select "Functions"--->"Image", then import image, define the scale of your image. "
I was going to try this method for a 2D image, but I could not find "image" under "function" in definition node. Which COMSOL version you were talking about?
By the way, have you succeeded to export 3D image as a geometry to COMSOL?
I used Simpleware software and generated mesh from my 3D image and exported to COMSOL. It worked nice but for larger size of images you need lots of RAM to generate mesh and I could not do that with Simpleware and that is why I am trying to export my image to COMSOL as a geometry and let COMSOL mesh it for simulation.
Regrads,
Saeid
Please login with a confirmed email address before reporting spam
Posted:
10 years ago
Apr 21, 2015, 6:18 a.m. EDT
Hi I have SEM report which is in jpg format these image has to be imported to the comsol so that i have to define material . it is a composite of two material, i am finding thermal residual stress on it,,please tell me how to proceed. and how i can change the temparature parameter.
Hi I have SEM report which is in jpg format these image has to be imported to the comsol so that i have to define material . it is a composite of two material, i am finding thermal residual stress on it,,please tell me how to proceed. and how i can change the temparature parameter.
Please login with a confirmed email address before reporting spam
Posted:
10 years ago
Apr 21, 2015, 6:20 a.m. EDT
Hi I have SEM report which is in jpg format these image has to be imported to the comsol so that i have to define material . it is a composite of two material, i am finding thermal residual stress on it,,please tell me how to proceed. and how i can change the temparature parameter.
files are attaached
Hi I have SEM report which is in jpg format these image has to be imported to the comsol so that i have to define material . it is a composite of two material, i am finding thermal residual stress on it,,please tell me how to proceed. and how i can change the temparature parameter.
files are attaached
Gunnar Andersson
COMSOL Employee
Please login with a confirmed email address before reporting spam
Posted:
10 years ago
Apr 21, 2015, 7:51 a.m. EDT
You can define an Image function and use the value from it when setting up your physics.
You can define an Image function and use the value from it when setting up your physics.
Please login with a confirmed email address before reporting spam
Posted:
10 years ago
Apr 21, 2015, 10:50 a.m. EDT
On the subject of JPEG: it's dangerous because JPEG contains compression artifacts: anomalous oscillations in intensity near edges. PNG is better. But you can trivially convert between image types with a suitable software, for example "ImageMagick" tools, in particular "convert", does it quickly and effectively. Then you don't need to worry any more about JPEG load-save cycles causing further degradation to your data.
I'm very interested in this subject myself. In computer graphics, for example POV-Ray, there's the notion of a "bump map" which perturbs surfaces along their normal using an image. In POV-Ray it's done using a linear perturbation applied to the scattering direction of light. But it could also be applied to a displacement field. The challenge is mapping a 2-dimensional image to a 3-dimensional surface. For example maps between a 2-dimensional map and the near-spherical earth surface is a nontrivial topic.
Anyway, I'd just convert the images to PNG.
On the subject of JPEG: it's dangerous because JPEG contains compression artifacts: anomalous oscillations in intensity near edges. PNG is better. But you can trivially convert between image types with a suitable software, for example "ImageMagick" tools, in particular "convert", does it quickly and effectively. Then you don't need to worry any more about JPEG load-save cycles causing further degradation to your data.
I'm very interested in this subject myself. In computer graphics, for example POV-Ray, there's the notion of a "bump map" which perturbs surfaces along their normal using an image. In POV-Ray it's done using a linear perturbation applied to the scattering direction of light. But it could also be applied to a displacement field. The challenge is mapping a 2-dimensional image to a 3-dimensional surface. For example maps between a 2-dimensional map and the near-spherical earth surface is a nontrivial topic.
Anyway, I'd just convert the images to PNG.
Please login with a confirmed email address before reporting spam
Posted:
10 years ago
Apr 21, 2015, 11:37 a.m. EDT
Hello Devendrakumar,
there are two ways to work with images in COMSOL.
The first one is to using image function as Gunnar said. It is described in previous answers.
The second one needs Matlab LiveLink. If you do have that module, check how to use the function "mphimage2geom' in the user guide. The function can convert your image into geometry. It supports quite some image formats. So then you can assign a lot of different properties to your geometry, which is not possible with the first method. There is example how to use the function in the user guide. Especially in the end when you want to calculate something, for example boundary flux, it is possible with this method, but not the first one.
To your specific question, I am very bad in thermal dynamics. Can't really give any tip for your specific question. Sorry for that. Hope this will somehow help you a little bit.
Hello Devendrakumar,
there are two ways to work with images in COMSOL.
The first one is to using image function as Gunnar said. It is described in previous answers.
The second one needs Matlab LiveLink. If you do have that module, check how to use the function "mphimage2geom' in the user guide. The function can convert your image into geometry. It supports quite some image formats. So then you can assign a lot of different properties to your geometry, which is not possible with the first method. There is example how to use the function in the user guide. Especially in the end when you want to calculate something, for example boundary flux, it is possible with this method, but not the first one.
To your specific question, I am very bad in thermal dynamics. Can't really give any tip for your specific question. Sorry for that. Hope this will somehow help you a little bit.
Please login with a confirmed email address before reporting spam
Posted:
10 years ago
May 12, 2015, 8:57 a.m. EDT
hello Li Chunyan,
i read u did succeed the process of SEM into Comsol, how?can i get in touch with u
hello Li Chunyan,
i read u did succeed the process of SEM into Comsol, how?can i get in touch with u
Please login with a confirmed email address before reporting spam
Posted:
8 years ago
Jun 12, 2016, 11:59 p.m. EDT
Hello Chunyan,
mphimage2geom cammond unforunatly only works for 2D geometry. If I want to do 3D, do you know how? I have several MRI images and I want COMSOL to plot them in 3D.
Thank you!
Fei
Hello Chunyan,
mphimage2geom cammond unforunatly only works for 2D geometry. If I want to do 3D, do you know how? I have several MRI images and I want COMSOL to plot them in 3D.
Thank you!
Fei
Please login with a confirmed email address before reporting spam
Posted:
8 years ago
Oct 24, 2016, 10:45 p.m. EDT
What programs did you use to convert png files into dxf format?
i have an X-ray CT image, and binarized it using imagej.
Exportable image formats are png, jpg etc... but comsol cannot import them directly.
Therefore I imported them to Autocad and exported it to dxf files, it still did not work out.
What programs did you use to import those grey scale value?
Would my binarized images work fine with your method?
What programs did you use to convert png files into dxf format?
i have an X-ray CT image, and binarized it using imagej.
Exportable image formats are png, jpg etc... but comsol cannot import them directly.
Therefore I imported them to Autocad and exported it to dxf files, it still did not work out.
What programs did you use to import those grey scale value?
Would my binarized images work fine with your method?
Please login with a confirmed email address before reporting spam
Posted:
8 years ago
Jan 20, 2017, 5:13 a.m. EST
Hi
Can you please tell how did you import dxf file in geometry.
Thanks..
Hi
Can you please tell how did you import dxf file in geometry.
Thanks..
Jeff Hiller
COMSOL Employee
Please login with a confirmed email address before reporting spam
Posted:
8 years ago
Mar 13, 2017, 9:20 a.m. EDT
Hello Nisha,
2D dxf files can be imported with just the core COMSOL Multiphysics.
For 3D dxf files, you will need to have one of the optional COMSOL products for CAD import.
See the CAD Specification Chart
www.comsol.com/products/specifications/cad/ for more details.
Best regards,
Jeff
Hello Nisha,
2D dxf files can be imported with just the core COMSOL Multiphysics.
For 3D dxf files, you will need to have one of the optional COMSOL products for CAD import.
See the CAD Specification Chart https://www.comsol.com/products/specifications/cad/ for more details.
Best regards,
Jeff