# Tagged Questions

Questions related to creating Mathematica functionality inspired by MATLAB--a proprietary numerical computing environment developed by MathWorks. This includes data import/export and other interoperability questions related to MATLAB programs, scripts, or related software.

104 views

### open Matlab sheet and plot

I have managed to import my data into mathematica, but I can't find a way to show the plot the way it was in the lab (Matlab automatically generated file usually show me a graph). Is there a way ...
172 views

### Matlab to Mathematica conversion [closed]

Is there a list of corresponding commands between Mathematica and Matlab, including Solve, NSolve, ...
31 views

### Lift and projection method in Least Squares Inverse Eigenvalue Problems [closed]

I need to implement the lift and projection method proposed by XUZHOU CHEN AND MOODY T. CHU in http://www4.ncsu.edu/~mtchu/Research/Papers/lsiep.pdf on page 7 in ...
131 views

### How to write this Matlab code in Mathematica

I have a small hiccup here. I am trying to write my Matlab code for a dynamical system in Mathematica. I have managed to get most of it except one part. The Mathematica code for the system is ...
82 views

### Mathematica does not import .mat file correctly [closed]

I have .mat file that contains a binary (0,1) matrix with size 100*100*100. I have used this syntax to import it in mathematica ...
336 views

### Does NRoots own an abstract counterpart? If not, can we write one?

We know when solving linear algebra equations, despite its abstract syntax, LinearSolve is much faster compared to Solve: ...
79 views

### how to import a matlab 3 dimensional array into mathematica

I have created a three dimensional array "data" in matlab by using the following commands : ...
256 views

### Differences between FFT and analytical Fourier Transform

In MATLAB, if I perform an FFT on a simple Gaussian spot with a phase grating: ...
60 views

### Theodorus Spiral [closed]

If the successive hypotenuses of the Theodorus Spiral are getting longer but the difference between the lengths is getting smaller reducing the distance between windings to pi, why pi?
171 views

### What is the Mathematica equivalent for corr2?

What is the Mathematica equivalent for MATLAB's corr2, which gives the correlation coefficient of two 2D matrices?
54 views

### How to import columns of data (.mat file)

I have a two 100x2 .mat file and I would like to get the elements stored as pairwise entries i.e. something like data = [{a1,b1},{a2,b2}..{a100,b100}]. Can someone help me do this efficiently?
148 views

### TransferFunctionModel and BodePlot shows different result between Mathematica and Matlab

I was doing the TransferFunctionModel and BodePlot. But the result from Mathematica and Matlab are different. The function is as follows: ...
113 views

### How to convert a matrix to MATLAB format? [duplicate]

I want to convert the following 16x16 matrix containing the variable n and some integers into matlab programming language: ...
168 views

### data manipulation in log-log scale

Say that I have the following: y[t_] := 2 + (2/10)*(1 - Exp[-t/11]) timedat = N[Table[{t, y[t]}, {t, 0, 10, 1/1000}]]; How is it possible to construct an ...
909 views

### What is the difference between Mathematica and Matlab? [closed]

I am totally a beginner to Wolfram products and I'm searching for a software to solve my math problems with. Like this math problem that I've solved using $\LaTeX$ in ...
92 views

### Transformation Matlab assignments to Mathematica expressions

From a simulation software, I obtain in a matlab file my algebro-differential equations in the following way : C_p_e = C_state/C_c; C_p_f = I_state/I_i; R_p_e = R_r*C_p_f; I_p_e = ...
445 views

### converting Matlab program to Mathematica code

I have the following Matlab program; ...
156 views

### The CorrelationMatrix is equal to corrcoef of Matlab?

How can I generate a matrix which is equivalent to the results of the "correlation coefficients" command (corrcoef) in Matlab? When I make a LinearModelFit, I can get a CorrelationMatrix, but is this ...
4k views

### How to get Matlab data imported with the same dimensions?

I have some Matlab image data with the following dimensions (output is from Matlab): >> size(im) ans = 86 86 3 45 The data imports just fine ...
222 views

### Having trouble translating Matlab fsolve into Mathematica

I searched the site and found that someone said FindRoot is equivalent to fsolve, however, without proper options, ...
275 views

### Making Mathematica function files like in MATLAB

I'm a MATLAB user trying to get familiar with Mathematica. I have long Mathematica sheet that spits out some matrices at the end after much math. I want to run a loop over couple of different initial ...
75 views

### How to apply different colors to different contours

I have searched the forum, I hope this isn't a duplicate question. I try to apply unique color for every contour line with the same elevation. In short, I want to create a MATLAB style contour plot. ...
357 views

### Any solution to transfer data between Python and Mathematica

I think Mathematica handles .mat file not very well, python is pretty good at this kind of jobs. In this site, there are plenty of question related to calling Mathematica from Python, or calling ...
172 views

### Is there an equivalent of â€śpmtmâ€ť of MATLAB?

Recently I'm spending my time implementing some patients' analysis using Mathematica Classify function. But I need to rewrite some MATLAB functions for computing ...
100 views

### Exporting the NDSolve to matlab with the argument

a = Table[Evaluate[y[x] /. sol], {x, 0, 10, 0.01}]; Export["a.mat", a]; works just fine but ...
269 views

### NIntegrate over a list of functions

This question is the result of these other two questions. Question 1 and 2. I thought it would be better to ask a new question rather than deleting previous one. I think When ...
484 views

### Numerical integration's speed

Consider this numerical integration of Bessel function: Do[NIntegrate[BesselJ[2, x], {x, 0, 10000}], {i, 1, 100}] // AbsoluteTiming {4.033403, Null} This is ...
234 views

### Slow evaluation of NIntegrate when used as a pure function

I asked a perhaps related question here. Here is my code in below. The goal is that to define a function which must be integrated numerically. The function itself first is calculated over different ...
120 views

### System Identification from test data

I've been looking for a way to model a simple SISO system from test data using Mathematica. Something similar to MATLAB's System Identification Toolkit, that estimates a transfer function from the ...
1k views

### Dramatic speed difference of code on Matlab and Mathematica

Background: I was trying to convert a Matlab code (fluid simulation, SPH method) into a Mathematica one, but the speed difference is huge. Matlab code: ...
153 views

### Small mismatch in theoretical vs MMA solutions of a damped harmonic oscillator differential equation

I solved the differential equation $$\ddot y + 0.43 \dot y + y =0.1 \cos(2x), \quad y(0)=1,\ \dot y(0)=1 \quad(0)$$ using both the theoretical results from wikipedia and using MMA (I also tested ...
14k views

### Is it possible to export the equations from Mathematica to MATLAB?

Is it possible to export the output expressions from Mathematica computations (e.g., equations) in valid MATLAB syntax?
298 views

### Using the variable in the MATLAB workspace using MATLink or any other packages

I have a program in MATLAB and after I run the program, I get some results in MATLAB's workspace. Now, I need to use these results in Mathematica. What I currently do is that I save the workspace as a ...
412 views

### Import symbolic variables from Matlab with MATLink

I'm trying to manipulate with Mathematica symbolic expression created in Matlab. I'm using the MATLink package, and I've succedeed in importing numerical variables, but not symbolic ones : ...
417 views

### ContourPlot3D using a Matlab function through MATLink

I have a Matlab function which accepts a 3 dimensional vector and returns a single number. I want to use this through MATLink to make a 3d plot. A unit sphere: ...
198 views

### 'eps' equivalent in Mathematica

In Matlab there is a function 'eps'. eps Spacing of floating point numbers. D = eps(X), is the positive distance from ABS(X) to the next larger in magnitude floating point number of ...
185 views

### Importing data from Matlab, using data in “NSolve” and send the results back to Matlab

I have generated an image processing code in Matlab. It has several subroutines and in one of them, I should solve a system of 7 nonlinear equations. I use "fsolve" in Matlab to solve this system, ...
246 views

### Generate Matlab figure

I am currently working on a project. Because of lack of communication between my team mates and I, I did most of the work (and the graphical figures) in mathematica. Now, I have to pass all the ...
116 views

### Converting code from Matlab to Mathematica [duplicate]

I have the following piece of code: ...
989 views

### Converting a matlab program into Mathematica 10

I sought help from this entry at Calling MATLAB from Mathematica to see if I could CONVERT a mathlab program which simulates polymer dynamics that is provided at the download section at ...
5k views

### Calling MATLAB from Mathematica

How can I call MATLAB functions directly from Mathematica and transfer data/variables between the two systems?
341 views

### Automatically growing lists as in MATLAB?

Is there a way to add elements to a list at positions outside the current list's length? Something equivalent to the following MATLAB code snippet: ...
326 views

### Porting code from MATLAB

I'd like to switch from MATLAB to Mathematica for my research in digital signal processing. I used Mathematica a lot during the '90s but I haven't used it since then, so I might as well be a complete ...
138 views

### plot totally fragmented, WorkingPrecision,matlab comparison

I am trying to plot ...
322 views

### How to prepare (copy/paste) data from Matlab?

What is the best way to get data from Matlab to Mathematica? For a new project I want to copy/paste a table (or part of it) of datas from Matlab to Mathematica. Copyed from Matlab it is: ...
393 views

### Approximate minimum degree permutation algorithm in Mathematica

In MATLAB there is a nice implementation of the so called AMD (approximate minimum degree permutation) algorithm named amd (see Online MATLAB Documentation). There is an alternative algorithm called ...
131 views

### Writing equations from Mathematica in Matlab [duplicate]

I would like to use mathematical equations directly in Matlab. I found one thread describing about a built in Matlab file i.e. ToMatlab.m. I am able to download this file, however, I could n't able to ...
482 views

### Mathematica-To-MATLAB Dictionary!

Is there a dictionary to translate Mathematica functions and commands to MATLAB?