Discussion Closed This discussion was created more than 6 months ago and has been closed. To start a new discussion with a link back to this one, click here.
How to access the number of elements in each oscillation
Posted 13.08.2023, 18:08 GMT-4 Microfluidics, Mesh 8 Replies
Please login with a confirmed email address before reporting spam
Hi,
I'm modelling an active nematic in a 2D geometry. In my simulation, I observed oscillations. Please, how can I access the number of elements mesh in each of the oscillation? And how can I increase the mesh in each of the oscillation without increasing the mesh for the entire domain?
I have attached the figure that has the oscillations.
Attachments:
Please login with a confirmed email address before reporting spam
This area of physics is not my specialty, but: (1) that 2D problem doesn't look especially computationally large, and (2) it seems you have plenty of oscillations, so it doesn't look to me like you would save much in terms of complexity by trying to limit regions of high mesh density. Why not just increase the number of elements overall, if you want more detail? And if you are running into memory issues, consider using an iterative solver (if you aren't already) or a different discretization. If that advice doesn't help, then I suggest you post your .mph file to the forum to allow for more detailed study by others.
-------------------Scientific Applications & Research Associates (SARA) Inc.
www.comsol.com/partners-consultants/certified-consultants/sara
Please login with a confirmed email address before reporting spam
Thank you for your reply. (1) The problem is not computationally large at the moment. (2) I just want to find out the number of elements in each of the oscillation. The idea is that, if the mesh in each of the oscillation is small, what if I increase the number of elements, would the oscillations disappear or still remain? Although, I have tried to double the number of mesh but I still obtained the same result.
Please login with a confirmed email address before reporting spam
Obtaining the same physics results, but with numerical models that employ different mesh densities, is usually desirable.
-------------------Scientific Applications & Research Associates (SARA) Inc.
www.comsol.com/partners-consultants/certified-consultants/sara
Please login with a confirmed email address before reporting spam
how can I access the number of elements mesh in each of the oscillation?
I don't see why it makes sense to do this.
The sensible thing to do is to choose a mesh size substantially smaller than the wavelength of the oscillations. Do this, look at the wavelength of the oscillations, and compare. If there is a large number of mesh elements per oscillation the solution is probably good. If you want to be sure, double the mesh density and check to see if the solution remains almost unchanged.
In many wave-type problems the number of mesh elements needed per wavelength is often not very large. (Often) 10 is generous and 6 may be adequate.
The other thing OP can do is to plot the mesh, or even superimpose the mesh plot on the solution.
As Robert noted, in 2D this is a very small problem. Mesh overkill is easy to obtain here. It's advisable for OP to become familar enough with advanced meshing options to customize the mesh if needed.
And as always, posting an mph file might help get better advice.
Please login with a confirmed email address before reporting spam
Obtaining the same physics results, but with numerical models that employ different mesh densities, is usually desirable.
Thank you Robert
Please login with a confirmed email address before reporting spam
how can I access the number of elements mesh in each of the oscillation?
I don't see why it makes sense to do this.
The sensible thing to do is to choose a mesh size substantially smaller than the wavelength of the oscillations. Do this, look at the wavelength of the oscillations, and compare. If there is a large number of mesh elements per oscillation the solution is probably good. If you want to be sure, double the mesh density and check to see if the solution remains almost unchanged.
In many wave-type problems the number of mesh elements needed per wavelength is often not very large. (Often) 10 is generous and 6 may be adequate.
The other thing OP can do is to plot the mesh, or even superimpose the mesh plot on the solution.
As Robert noted, in 2D this is a very small problem. Mesh overkill is easy to obtain here. It's advisable for OP to become familar enough with advanced meshing options to customize the mesh if needed.
And as always, posting an mph file might help get better advice.
Hi Davi,
I started using COMSOL. I have attached my mph file. What I did was to double the mesh and the oscillations are still observed.
Attachments:
Please login with a confirmed email address before reporting spam
Apparently the question you asked is not the question you had.
The question you really have is "why is the result of the simulation different from what I expect?"
I can't help with that because I don't know anything about the physics of liquid crystals. I can say that the number of mesh elements is plenty large.
In general when the result of a simulation does not agree with expectations then either the simulation is wrong, the expectation is wrong, or both.
Please login with a confirmed email address before reporting spam
Thank you Dave. I have been able to resolve this. Please, how can I make the attached figure bigger than this. I used 4096 by 450 pixels
Attachments:
Note that while COMSOL employees may participate in the discussion forum, COMSOL® software users who are on-subscription should submit their questions via the Support Center for a more comprehensive response from the Technical Support team.
Suggested Content
- FORUM Access Stiffness Matrix for each Parameter Sweep Value
- BLOG Designing a Sensor Package for a High-G Accelerometer via Simulation
- FORUM How to access global functions defined in COMSOL with matlab?
- KNOWLEDGE BASE What Does Degrees of Freedom (DOFs) Mean in COMSOL Multiphysics?
- FORUM Finding inductance in meshed elements