Message Boards Message Boards

0
|
4185 Views
|
1 Reply
|
0 Total Likes
View groups...
Share
Share this post:

Question on transition from Mathematica to Matlab using Tomatlab.m

Posted 4 years ago

I am trying to calculate some function with Mathematica and move it to the Matlab, and I would appreciate it if you help me.

  1. The Tomatlab.m produces Derivative(1)(sin)(2.*y) from Mathematica to Matlab. However, there is no function like Derivative(1)(sin)(2.*y) in Matlab. So, I was wondering how Derivative(1)(sin)(2.*y) is calculated? Is it cos(2.*y) or 2*cos(2.*y)? in Matlab Code?** The different representation says that Derivative(1)(sin)(2.*y) = sin'[2.*y]., but still not sure sin'[2.*y] = cos[2.*y] or 2cos[2.*y]

  2. Even if I use the Tomatlab.m file, I have to modify my code in Matlab to run the code. For example, I have to change (s+(-1).*t) to bsxfun(@minus,t,s'). Since my code is complicated, I have been struggling with the dimension error when I changed these things. Is there any function or file like Tomatlab.m that I can directly use the code output without modification? I saw that there is another function Math link that transfer the code output from Mathematica to Matlab. Any Ideas about this function?

Thank you.

exp(1).^(logsigma+(-1).*logthetat+(-2).*logthetax+(-1/2).*exp(1) ...
  .^((-1).*logthetat).*(s+(-1).*t).^2+(-1/2).*exp(1).^((-1).* ...
  logthetax).*(x+(-1).*y).^2).*(R.*((-1)+s)+(-1).*s).^(-1).*((-1).* ...  
  exp(1).^(2.*logthetax).*R.*(s+(-1).*t)+exp(1).^logthetat.*(R.*(( ...
  -1)+s)+(-1).*s).*((x+(-1).*y).^2.*\[Alpha]+(-1).*exp(1).^logthetax.*\
(\[Alpha]+ ...R.*((-1).*x+y).*sin(2.*y))+2.*exp(1).^(2.*logthetax).*R.* ...
  **Derivative(1)(sin)(2.*y)**));
POSTED BY: Jinhyeun Kim

Have you tried @Sz. third party software MATlink?

Also you could read up on the other Maple, very amusing :D

POSTED BY: Raspi Rascal
Reply to this discussion
Community posts can be styled and formatted using the Markdown syntax.
Reply Preview
Attachments
Remove
or Discard

Group Abstract Group Abstract