Please login with a confirmed email address before reporting spam
Posted:
4 years ago
2020年11月30日 GMT-5 10:57
Hi, YS Chen. I think you can see how different they are by working with the maltab command windows and the livelink for matlabe user's guide. Mpheval and mphinterp are preferred to get the values what you want. Unless you want to use getU to get the solution from the solver, and then use setU to reset the solution.
All the best,
Songcai
Hi, YS Chen. I think you can see how different they are by working with the maltab command windows and the livelink for matlabe user's guide. Mpheval and mphinterp are preferred to get the values what you want. Unless you want to use getU to get the solution from the solver, and then use setU to reset the solution.
All the best,
Songcai
Lars Gregersen
COMSOL Employee
Please login with a confirmed email address before reporting spam
Posted:
4 years ago
2020年12月3日 GMT-5 02:53
mphinterp is the most easy to use function for getting data out of Comsol. It performs interpolation of the solution on the coordinates you specify while taking into account the shape function and order that the model uses.
mpheval returns values for the entire mesh. It returns coordinoates and values for the mesh. You have to use the argument 'refine' in order to adjust the detail. Note the refine=1 is the default even if you are using second order elements.
mphgetu returns the raw solution vector directly from the Comsol solvers. It interpretations depend on the shape functions, mesh etc., which you can get information about using mphxmeshinfo. This is a low level function and requires that you understand how FEM works.
All three functions return data based on the solution vector and the data returned by xmheshinfo.
-------------------
Lars Gregersen
Comsol Denmark
mphinterp is the most easy to use function for getting data out of Comsol. It performs interpolation of the solution on the coordinates you specify while taking into account the shape function and order that the model uses.
mpheval returns values for the entire mesh. It returns coordinoates and values for the mesh. You have to use the argument 'refine' in order to adjust the detail. Note the refine=1 is the default even if you are using second order elements.
mphgetu returns the raw solution vector directly from the Comsol solvers. It interpretations depend on the shape functions, mesh etc., which you can get information about using mphxmeshinfo. This is a low level function and requires that you understand how FEM works.
All three functions return data based on the solution vector and the data returned by xmheshinfo.