I know this part of the discussion is kind of old, but that error message cyberdyne quoted is likely to occur if for example the user were to store the output of the call to the factor function to a variable named factor in the Command Window. [Though it appears the text of the error message may have changed in the decade+ since the original message.]
syms a b c
f = a*b+a*c
f =
factor = factor(f) % This first call works
factor =
z = factor(f) % This second one does not, since factor is now a variable
Error using indexing (line 918) Invalid MATLAB indexing or symbolic function definition. Symbolic function arguments must be symbolic variables and function body must be convertible to sym expression.
Error in indexing (line 962) R_tilde = builtin('subsref',L_tilde,Idx);
Impossibile completare l'azione a causa delle modifiche apportate alla pagina. Ricarica la pagina per vedere lo stato aggiornato.
Translated by
Seleziona un sito web
Seleziona un sito web per visualizzare contenuto tradotto dove disponibile e vedere eventi e offerte locali. In base alla tua area geografica, ti consigliamo di selezionare: .
Puoi anche selezionare un sito web dal seguente elenco:
Come ottenere le migliori prestazioni del sito
Per ottenere le migliori prestazioni del sito, seleziona il sito cinese (in cinese o in inglese). I siti MathWorks per gli altri paesi non sono ottimizzati per essere visitati dalla tua area geografica.