Erweiterte Auswertung und Ausnahmenbehandlung
Auswerten von Ausdrücken, Erfassen von Daten zu Fehlern
MATLAB® umfasst Funktionen zur indirekten Auswertung von Ausdrücken und zum Erfassen von Daten über Fehler.
Jeder MATLAB-Code, der einen Fehler erfasst und eine Ausnahme ausgibt, konstruiert ein MException-Objekt. MATLAB kann entweder vordefinierte Ausnahmen oder von Ihnen erstellte Ausnahmen ausgeben.
Funktionen
Themen
- Alternatives to the eval Function
Although the
evalfunction is very powerful and flexible, it is not always the best solution to a programming problem. In many instances, there are recommended alternative approaches to usingeval. - Exception Handling in a MATLAB Application
It is a good programming practice to include error checking in your programs to ensure reliable operation under all conditions. You can decide how your programs respond to different types of errors.