Different a coefficient for each element not possible anymore with solvepde?
4 次查看(过去 30 天)
显示 更早的评论
In Matlab 2015a I was using the pde solver for a problem in which the a coefficient was different for each Element:
u = assempde(problem,p,e,t,c,a,f);
'a' was a 1xN matrix with N the number of elements.
In version 2016a I get the remark that I should not use assempde anymore, but solvepde instead. So I was transferring all my code to the new functions. But when defining the coefficients:
specifyCoefficients(problem,'m',0,'d',0,'c',c,'a',a,'f',f);
I get the error: "Size of the matrix 'a' is not consistent with the pde.PDEModel/PDESystemSize property." Is it not possible anymore to define an a coefficient which is dependent on the element?
0 个评论
回答(1 个)
Alan Weiss
2016-10-13
Sorry, but to use the latest solvers, I think that you will need to update your coefficient syntax to functional form. This form has the benefit that it works with quadratic elements as well as linear elements.
Alan Weiss
MATLAB mathematical toolbox documentation
0 个评论
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Eigenvalue Problems 的更多信息
产品
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!