How do I create conditional statements in Symbolic Math Toolbox 3.1.3 (R14 SP3)?
1 Ansicht (letzte 30 Tage)
Ältere Kommentare anzeigen
I would like to create a discontinous, conditional, symbolic function in MATLAB. When I try to use > (or <) I get the following error:
??? Function 'gt' is not defined for values of class 'sym'.
Akzeptierte Antwort
MathWorks Support Team
am 27 Jun. 2009
The ability to perform conditional operations is not available in Symbolic Math Toolbox 3.1.3 (R14 SP3). Boolean logic is available in the Extended Symbolic Math Toolbox 3.1.3 (R14 SP3).
Conditional operation can be approximated using the Symbolic Math step function, HEAVISIDE. Please note that the HEAVISIDE function returns NaN for heaviside(0), and so the resultant symbolic function is not defined for every value.
0 Kommentare
Weitere Antworten (0)
Siehe auch
Kategorien
Mehr zu Symbolic Math Toolbox finden Sie in Help Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!