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:
problem with symbolic integration

Subject: problem with symbolic integration

From: babak yazdanpanah

Date: 4 May, 2010 07:19:06

Message: 1 of 2

hi,
I had written a code that has a symbolic integration in it,and i want a result based on a symbolic variable 'n' so that i could use it in other parts of my code.
the problem is that when i input more than the digit '4' , for' k',MATLAB sends me an answer that is useless for me or in another word i cant use that answer for the other calculations of my code.try it.here is that part of my code that i mentioned at the top:
syms n tt g
h=.01;
k=input('please specify the volume fraction:');
KAm=17;
KAc=29;
KAn=(KAc-KAm)*((2*g+h)/(2*h))^k+KAm;
o=int(1/KAn,g,-h/2,n);
disp(o)
please help me for God's sake...it is so urgent...please please please....

Subject: problem with symbolic integration

From: Steven Lord

Date: 4 May, 2010 14:07:39

Message: 2 of 2


"babak yazdanpanah" <babak.yazdanpanah@gmail.com> wrote in message
news:hrohpa$7d9$1@fred.mathworks.com...
> hi,
> I had written a code that has a symbolic integration in it,and i want a
> result based on a symbolic variable 'n' so that i could use it in other
> parts of my code.
> the problem is that when i input more than the digit '4' , for' k',MATLAB
> sends me an answer that is useless for me or in another word i cant use
> that answer for the other calculations of my code.try it.here is that
> part of my code that i mentioned at the top:
> syms n tt g h=.01;
> k=input('please specify the volume fraction:');
> KAm=17;
> KAc=29;
> KAn=(KAc-KAm)*((2*g+h)/(2*h))^k+KAm;
> o=int(1/KAn,g,-h/2,n);
> disp(o)
> please help me for God's sake...it is so urgent...please please please....

I tried this with k equal to 5 in MATLAB 7.10 (release R2010a) and it
returned an answer. Since you haven't said what makes that answer "useless
for me", there's nothing really we can do to help you. Perhaps if you
explained that point, someone may be able to help you.

--
Steve Lord
slord@mathworks.com
comp.soft-sys.matlab (CSSM) FAQ: http://matlabwiki.mathworks.com/MATLAB_FAQ

Tags for this Thread

No tags are associated with 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