Drexel dragonThe Math ForumDonate to the Math Forum



Search All of the Math Forum:

Views expressed in these public forums are not endorsed by Drexel University or The Math Forum.


Math Forum » Discussions » Software » comp.soft-sys.matlab

Topic: Simple definite Integration; Not able to integrate
Replies: 1   Last Post: Feb 1, 2013 12:06 PM

Advanced Search

Back to Topic List Back to Topic List Jump to Tree View Jump to Tree View  
Steven Lord

Posts: 17,944
Registered: 12/7/04
Re: Simple definite Integration; Not able to integrate
Posted: Feb 1, 2013 12:06 PM
  Click to see the message monospaced in plain text Plain Text   Click to reply to this topic Reply



"SAI KANTAREDDY" <reddynithin91@gmail.com> wrote in message
news:kego7g$c4s$1@newscl01ah.mathworks.com...
> p=1300; v=1/60; rho=8000;
> c=674; sig=0.0015; a=0.0000051;
> Temp_o =30; x=0.05; y=0.05; z=0.05; t_o=0.18;
>
> f =@(t) [(t_o-t)^(-0.5)]/[sig^2+8*a*(t_o-t)]*exp(-2*((x-v*t)^2
> +y^2)/(sig^2+8*a*(t_o-t))-(z^2)/(4*a*(t_o-t)));
>
> temp=quadgk(f,0,0.18)
>
> it says:
> ??? Error using ==> mpower
> Inputs must be a scalar and a square matrix.


If you want to perform elementwise operations (which you do, for QUADGK)
instead of matrix operations, use operators like ".^", ".*", and "./"
instead of "^", "*", and "/".

--
Steve Lord
slord@mathworks.com
To contact Technical Support use the Contact Us link on
http://www.mathworks.com




Point your RSS reader here for a feed of the latest messages in this topic.

[Privacy Policy] [Terms of Use]

© Drexel University 1994-2014. All Rights Reserved.
The Math Forum is a research and educational enterprise of the Drexel University School of Education.