Entering a formula by user

1 visualizzazione (ultimi 30 giorni)
Karel
Karel il 25 Lug 2012
Is there a function which allows me to ask for a formula, while the prgram is beeing used, and subsequently use that formula?

Risposta accettata

Nirmal
Nirmal il 25 Lug 2012
aMatrix = magic(5);
expression = input('Enter the name of a matrix: ','s');
if (exist(expression,'var'))
mesh(eval(expression))
end

Più risposte (0)

Categorie

Scopri di più su Modeling in Help Center e File Exchange

Tag

Prodotti

Community Treasure Hunt

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

Start Hunting!

Translated by