Discover MakerZone

MATLAB and Simulink resources for Arduino, LEGO, and Raspberry Pi

Learn more

Discover what MATLAB® can do for your career.

Opportunities for recent engineering grads.

Apply Today

Thread Subject:
FAIL message

Subject: FAIL message

From: Kevin

Date: 20 Feb, 2012 20:01:10

Message: 1 of 4

Hello!
I am creating functions with variables by using symbolic objects in MATLAB in order to do some further operations referring to that function. But with some functions when i run the program i get FAIL as the result for the function. One example is as follows:

x=sym('x',[1 2]);
F=-10*exp(-0.2*(x(1).^2+x(2).^2)^0.5);

when I run the code the result for F is FAIL!!

Can you please tell me what is the problem, and why this FAIL only occurs with some function??

Subject: FAIL message

From: Kevin

Date: 21 Feb, 2012 18:36:11

Message: 2 of 4

"Kevin " <k.amouzgar@gmail.com> wrote in message <jhu8q5$6fc$1@newscl01ah.mathworks.com>...
> Hello!
> I am creating functions with variables by using symbolic objects in MATLAB in order to do some further operations referring to that function. But with some functions when i run the program i get FAIL as the result for the function. One example is as follows:
>
> x=sym('x',[1 2]);
> F=-10*exp(-0.2*(x(1).^2+x(2).^2)^0.5);
>
> when I run the code the result for F is FAIL!!
>
> Can you please tell me what is the problem, and why this FAIL only occurs with some function??

even these two will result in FAIL:
Syms x
y=exp(x)
or
y-sin(x)

Subject: FAIL message

From: Christopher Creutzig

Date: 22 Feb, 2012 12:11:58

Message: 3 of 4

On 21.02.12 19:36, Kevin wrote:
> "Kevin " <k.amouzgar@gmail.com> wrote in message <jhu8q5$6fc$1@newscl01ah.mathworks.com>...
>> Hello!
>> I am creating functions with variables by using symbolic objects in MATLAB in order to do some further operations referring to that function. But with some functions when i run the program i get FAIL as the result for the function. One example is as follows:
>>
>> x=sym('x',[1 2]);
>> F=-10*exp(-0.2*(x(1).^2+x(2).^2)^0.5);
>>
>> when I run the code the result for F is FAIL!!
>>
>> Can you please tell me what is the problem, and why this FAIL only occurs with some function??
>
> even these two will result in FAIL:
> Syms x
> y=exp(x)
> or
> y-sin(x)

Works fine here. I suggest you try reinstalling MATLAB, and if that
doesn't help, contact support@mathworks.com, there seems to be something
wrong with your installation.



Christopher

Subject: FAIL message

From: Kevin

Date: 22 Feb, 2012 20:29:13

Message: 4 of 4

Christopher Creutzig <Christopher.Creutzig@mathworks.com> wrote in message <4F44DB8E.2090908@mathworks.com>...
> On 21.02.12 19:36, Kevin wrote:
> > "Kevin " <k.amouzgar@gmail.com> wrote in message <jhu8q5$6fc$1@newscl01ah.mathworks.com>...
> >> Hello!
> >> I am creating functions with variables by using symbolic objects in MATLAB in order to do some further operations referring to that function. But with some functions when i run the program i get FAIL as the result for the function. One example is as follows:
> >>
> >> x=sym('x',[1 2]);
> >> F=-10*exp(-0.2*(x(1).^2+x(2).^2)^0.5);
> >>
> >> when I run the code the result for F is FAIL!!
> >>
> >> Can you please tell me what is the problem, and why this FAIL only occurs with some function??
> >
> > even these two will result in FAIL:
> > Syms x
> > y=exp(x)
> > or
> > y-sin(x)
>
> Works fine here. I suggest you try reinstalling MATLAB, and if that
> doesn't help, contact support@mathworks.com, there seems to be something
> wrong with your installation.
>
>
>
> Christopher


Thanks Cristopher,
I reinstalled it , and now it works!

Tags for this Thread

What are tags?

A tag is like a keyword or category label associated with each thread. Tags make it easier for you to find threads of interest.

Anyone can tag a thread. Tags are public and visible to everyone.

Contact us