Save answer in Matlab

5 views (last 30 days)
JRC
JRC on 18 Mar 2014
Answered: JRC on 18 Mar 2014
I have big answers in the matlab and I need save each one them for to use in Maple.
There are any way of save this answer to after to use in software Maple?
What´s happening is that the Matlab don´t get to show the whole answer because the answer is very big.
Each answer have 4 pages or more. Don´t appear in the screen.
The answer is a matrix x(1), x(2), x(3),...
Thanks.
  2 Comments
Nitin
Nitin on 18 Mar 2014
Not sure what you are asking, please include some of your code here, it will be easier to assist you
dpb
dpb on 18 Mar 2014
This obviously is from symbolic. I don't have the toolbox so don't have any experience with it but your hope is to save the result instead of displaying it and try to simplify it.
Unfortunately, that may or may not succeed. I seriously doubt that Maple will have much luck with such a result even if you were able to get it to it.
Sounds like another tack to approach the problem is in order--perhaps if you step back and ask a question of "How do I solve ...?" you might get some more fruitful suggestions.

Sign in to comment.

Answers (2)

JRC
JRC on 18 Mar 2014
Edited: JRC on 18 Mar 2014
Thanks...
I am using symbolic in matlab and I work with dynamic programming. The dynamic programming to use very memory and the calculation (and answers) are very large.
I my calculation, I use the function simplify but yet is very big the answer.
I can´t to show the code here because I use it in my phd... sorry.
The fact is that I have a big answer symbolic in Matlab and I need save it for use in software Maple for optimization.
dpb, How is to save the result instead of displaying it?
Thanks again...

JRC
JRC on 18 Mar 2014
Nitin, good afternoon.
The answers of the code below is very big...
t = 10; J(t+1)=0;
for N=t:-1:1 sis1 = (lambda)*x(N)-0.0466*y(N);
F = 8*x(N)^2+0.2841*y(N);
JJ(N) = subs(F + J(N+1), {x(N+1)},{sis1});
JJ1(N)=simplify(JJ(N));
[p1(N)] = solve(JJ1(N), y(N));
[p(N)] = simplify(p1(N));
J1(N) = subs(JJ(N), {y(N)}, {p(N)});
J(N) = simplify(J1(N)); end
The code is incorrect but is a ideia than I have do. Have others things how define syms, num2str, etc, that I don´t wrote here...
Thanks...

Categories

Find more on Mathematics 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!