How do I solve this error?
Show older comments
Output of the function must be the same size as the input. If FUN is an array-valued integrand, set the 'ArrayValued' option to
true.
B=3.1e98;
R=8.313;
Ea=6.28e5 ;
Omega=integral (@(t) B* exp(-Ea./(R.* V)),0,1);
Accepted Answer
More Answers (1)
Sulaymon Eshkabilov
on 9 Sep 2021
There are a few errs in your tiny code. Here is the corrected one:
load V.mat
B=3.1e98;
R=8.313;
Ea=6.28e5 ;
% Check your formulation in this function handle that presumably should contain variable "t"!
Fun=@(t)(B*exp(-Ea./(R.* V)));
Omega=integral(Fun,0,1, 'ArrayValued',true);
Categories
Find more on Loops and Conditional Statements in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!