Are there any restrictions on the Mass matrix for solving a DAE system using ode23t?
조회 수: 3 (최근 30일)
이전 댓글 표시
Hello,
When working with ode23t or ode15s, are there any restrictions on the Mass matrix to be used?
I already know that in these cases the Mass Matrix can be singular.
In particular, I am interested in knowing if matrices like M can be used, where M is defined as follows:
M = [1 1 1 0; 1 0 0 0; 0 0 0 0; 0 0 0 1]
Please note that this Mass matrix represents a system with 4 differential variables but only 3 differential equations.
Thank you very much for your kind help.
Best regards
Nicolas
댓글 수: 0
채택된 답변
Torsten
2023년 2월 6일
편집: Torsten
2023년 2월 6일
There are no restrictions on the mass matrix for ode23t or ode15s except for that it cannot be the zero matrix (which would mean you only have algebraic equations).
Compare the options concerning the mass matrix for the different solvers here:
댓글 수: 4
Torsten
2023년 2월 7일
If n are the differential variables and m are differential equations
? Maybe you mean:
If n is the sum of differential and algebraic equations and m is the number of differential equations with n >> m ...
I always try to solve algebraic equations explicitly if possible in order not to include them in the system for ode15s. But if it's not possible in your case, just try how the integrator can cope with it.
Usually, it's not easy for the solver to deduce the time derivatives of algebraic equations as it would be necessary in your case:
M = [1 1 1 1; 0 0 0 0;0 0 0 0;0 0 0 0]
I made good experience with RADAU5 for such problems available under
also with a MATLAB interface.
As a test case, the code has an example for electrical circuits where such problems seem to appear quite often.
추가 답변 (0개)
참고 항목
카테고리
Help Center 및 File Exchange에서 Ordinary Differential Equations에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!