Clear Filters
Clear Filters

problem plotting integral function 3D

1 view (last 30 days)
Bart
Bart on 6 Mar 2012
Hei,
I'm trying to take a look at a function that displays the ratios of 2 surfaces of a function. The code is as follows:
>> ton = 0.1:.1:60;
>> trest = 0.1:.1:60;
>> t2 = ((a1.*(trest - b1).^c1)+d1).*i.^(i.*((a2.*trest.^b2) + c2)) + ((a3.*(trest-b3).^c3)+d3);
>> [X,Y] = meshgrid(ton,trest);
>> G = (int(a*exp(b*t) + c*exp(d*t),t,t2,trest+t2));
Warning: Explicit integral could not be found.
>> F = int(a*exp(b*t) + c*exp(d*t),t,ton,trest+t2);
Warning: Explicit integral could not be found.
>> A = G./F
>> surf(A,X,Y)
??? Error using ==> surf at 78
Data dimensions must agree.
All the a's, i's and b's etc have all been given their respective values. The way I'm syntaxing this code is where the problem lies I think. I'm not sure how to solve the problem though :/

Answers (1)

Bart
Bart on 6 Mar 2012
Does anybody have any idea why the A changes to a sym variable?
  2 Comments
Bart
Bart on 6 Mar 2012
Found out that I need to change ton and trest to X and Y after the meshgrid command + redefine t2.
Not sure if this solves everyhting yet.
Bart
Bart on 6 Mar 2012
still have the Data dimensions must agree error :(

Sign in to comment.

Community Treasure Hunt

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

Start Hunting!