필터 지우기
필터 지우기

How to Simplify a system of equations and find possible substitions (symbolic toolbox?

조회 수: 1 (최근 30일)
Hello,
i've got 8 symbolic expressions and i want to simplify this system of equations together. So i've there identical expressions in 2 or more equations the number of mathematical computations can be reduced.
It is a symbolic problem using the symbolic toolbox.
  댓글 수: 4
Dyuman Joshi
Dyuman Joshi 2024년 1월 9일
What would you do with the simplifed system? Solve it for the parameters?
Torben
Torben 2024년 1월 9일
Using the 8 derivations directly for some kind of online RLS-algorithm

댓글을 달려면 로그인하십시오.

채택된 답변

Walter Roberson
Walter Roberson 2024년 1월 9일
If you use matlabFunction and request that it be written to a file, then the default is to optimize. The optimization step involves searching for common subexpressions and assigning them to variables and reusing the variables.
The end result is a .m file that is intended for numeric calculation.
Caution: not very long ago, optimization was badly broken, so test before trusting.
  댓글 수: 3
Steven Lord
Steven Lord 2024년 1월 9일
If you're not using matlabFunction you could use the subexpr function.
Walter Roberson
Walter Roberson 2024년 1월 9일
I haven't tested over the last couple of releases, but not very long ago, the optimization phase had a series of problems for a number of years. It was completely unusuable for longer expressions.

댓글을 달려면 로그인하십시오.

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Symbolic Math Toolbox에 대해 자세히 알아보기

제품


릴리스

R2023b

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by