- Inconsistent initial conditions: The initial conditions for “u1” might not be compatible with the imposed boundary conditions. Make sure that the initial conditions are consistent with the boundary conditions and the equation being solved.
- Incompatible PDE formulation: The PDE formulation might not be appropriate for the given problem. Check if the PDE and boundary conditions accurately represent the problem you are trying to solve.
- Incorrect equation setup: Verify that the equations and their corresponding boundary conditions are correctly defined in the “modelTwoDomain” object. Ensure that the equation indices and edge specifications are accurate.
- Numerical instability: It is possible that the PDE solver encounters numerical instability for certain values of “vq”. Try adjusting the solver settings, such as the time step size or spatial discretization, to improve stability.
Boundary conditions: mechanical system
2 次查看(过去 30 天)
显示 更早的评论
first of all, sorry if the question is silly, again my inexperience:
I have this code:
T=0.05
for j = 1:numel(edges)
edge = edges(j);
F = griddedInterpolant(ti,ac,"linear","nearest");
vq = F(T);
applyBoundaryCondition(modelTwoDomain,"mixed","Edge",[edge,edge],"u",vq,"EquationIndex",1,"q",[0 0],"g",0);
end
I go through the values contained in the matrix edges, and in those edges I need to impose that u1=vq and diff(u1,x) =0.
If I am not wrong I have to apply a mixed boundary condition.
When I try to solve the pde:
res=solvepde(modelTwoDomain,tlist);
It just works when vq=0.
What am I doing wrong?
Thanks very much for your patience, and help. Eventually I will grasp how this works.
Thanks again
0 个评论
回答(1 个)
Nithin Kumar
2023-8-24
编辑:Nithin Kumar
2023-8-24
Hi Jorge,
I understand that you are facing an issue while solving the PDE for the values other than “vq=0”.
If the “solvepde” function works only for vq = 0, it suggests that the “applyBoundaryCondition” function is correctly imposing the boundary condition 'u1 = vq and diff(u1, x) = 0' on the specified edge. However, the issue might lie in the formulation of the PDE problem or the initial conditions.
Here are a few possible reasons why the “solvepde” function might only work for 'vq = 0':
For more information regarding solving the system of PDEs, kindly refer to the following documentation:
I hope this answer helps you.
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 PDE Solvers 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!