Path: news.mathworks.com!not-for-mail
From: "Dan Haeg" <haegd@msoe.edu>
Newsgroups: comp.soft-sys.matlab
Subject: Re: evaluating expressions obtained from UI. eval alternative
Date: Sat, 15 Mar 2008 18:39:05 +0000 (UTC)
Organization: Milwaukee School of Engineering
Lines: 23
Message-ID: <frh549$4r2$1@fred.mathworks.com>
References: <frfhl6$6ov$1@fred.mathworks.com>
Reply-To: "Dan Haeg" <haegd@msoe.edu>
NNTP-Posting-Host: webapp-03-blr.mathworks.com
Content-Type: text/plain; charset="ISO-8859-1"
Content-Transfer-Encoding: 8bit
X-Trace: fred.mathworks.com 1205606345 4962 172.30.248.38 (15 Mar 2008 18:39:05 GMT)
X-Complaints-To: news@mathworks.com
NNTP-Posting-Date: Sat, 15 Mar 2008 18:39:05 +0000 (UTC)
X-Newsreader: MATLAB Central Newsreader 475291
Xref: news.mathworks.com comp.soft-sys.matlab:457412



"Ilya " <ilyapoz@gmail.com> wrote in message
<frfhl6$6ov$1@fred.mathworks.com>...
> I often write user interfaces that require user to input
> analytical functions into edit boxes.
> But I haven't found a MATLAB function specificially designed
> to handle the scenario.
> 
> I tried different ways to acoomplish this:
> 1. I tried the subs function from symbolic math toolbox -
> it's roubust, but is veeeery slow ((
> 
> 2. Now I use eval. But it requires users to input
> expressions using non-matrix operators like .+ .* etc.
> Moreover, eval is not robust at all: users are able to
> execute almost any MATLAB command inside my UI. Yet, eval is
> not as fast as I want.
> 
> Any suggestions?
> TIA
> 

could you use inline?