Questions tagged [matlab]

Programming questions about MATLAB are off topic and should be asked on Stack Overflow. MATLAB is a high-level language and interactive programming environment developed by MathWorks. It is the foundation for a number of other tools, including Simulink and various toolboxes that extend the core capabilities.

Filter by
Sorted by
Tagged with
0 votes
1 answer
4k views

Matlab figure graph color

I have installed Matlab 2013a in my system. When plotting a graph by "ezplot" command, the color of the graphs in the figure is by default set as green. I want to change the color in Deep blue. How is ...
61 votes
12 answers
59k views

Can I run my CPU at 100% usage for a long time?

I have a Dell XPS 15 9570, 32 GB ram, 2.2 ghz and 6 cores. When i use an application (The parsim command on MATLAB) (for more details) then my fan starts running fast , during this my PC doesn't seem ...
1 vote
2 answers
703 views

Normal distribution for a given range of numbers in Matlab

My question is about estimating a normal distribution for a row of points of an interval that are extracted from the data, just knowing the maximum (xmax = 200) and minimum (xmin = 100), to distribute ...
1 vote
1 answer
87 views

How to add a label below polar histogram

I would like to add a text below polar histogram text. Originally, I have a regular histogram and I can use xlabel to put a text as follows: histogram_orientation_of_blobs = histogram(orientation, '...
0 votes
1 answer
1k views

Is it possible using Matlab to draw a trading graph with deals?

In my trading software I write myself logs like this: 634782126998342815 q 0.0156327559515302 634782126998966816 q 0.0156323845819952 634782126999122816 q 0.0156323423136646 634782126999278816 q 0....
3 votes
1 answer
6k views

is it possible to install matlab on an external hdd and use it with any computer?

I'm looking for a portable solution to using matlab on any computer.I tried to install matlab on the hdd and found that it wouldn't work on other computers. What can I do to make it work? Is it even ...
0 votes
1 answer
593 views

how to multiply a matrix by its transposed?

I want to multiply a matrix by its transposed in order to knwo if it verify QtQ=I. Yet when I compute it on matlab I get something strange using a concept I'm not aware of: conj(x). Therefore, how ...
1 vote
0 answers
973 views

How to download and install MATLAB in Ubuntu with no GUI?

I am working inside a docker container, and the only interface I have is the terminal. I used pip install matlab and it does install the version 0.1, but when I write matlab --version, the message is ...
1 vote
1 answer
180 views

How do you use git from matlab online?

I'm using matlab from https://matlab.mathworks.com/ Is there any way to use git from there? the interface doesn't seem very enlightning. Matlab help assumes you have a local matlab installation.
4 votes
3 answers
26k views

How to configure GPU to work in TCC mode on Windows 10?

I'm using Windows 10, and I want my GPU to dedicate itself to computing, instead of graphics. Here is the information on MATLAB: >> gpuDevice ans = CUDADevice with properties: ...
0 votes
0 answers
39 views

Matlab exits during installation without any prompt or error hint

I was installing matlab 2021b using the online installer. At first, everything went well and it began the installation process. But at some point, when the progress bar is at 15%, 40% or so, it exits ...
0 votes
0 answers
184 views

Mathmatica saving Matlab files as Mathmatica as Wolfram Mathmatica Package

I have used Matlab for years and had to download Mathmatica for a class. However when I saved a Matlab file I think I accidently gave Mathmatica permission to be the defualt for .m files.I have ...
user avatar
0 votes
2 answers
3k views

How to locate Matlab installation?

I need to locate my MATLAB installation. I find out that I need to type matlabroot at the MATLAB command prompt. As I understand MATLAB command prompt means open cmd at the root where matlab is ...
0 votes
0 answers
192 views

Want to have further segment from another pie chart

I hope the picture is self-explanatory. I have already a pie chart I have to have a further segment in the chart but it has to keep the previous parent segment intact. I have tried this in Excel and ...
0 votes
1 answer
301 views

How to use full 256GB RAM of my work station? MATLAB only seems to be using 75GB of RAM and not the 256GB that is available

I have a workstation that has 256GB RAM and 32 cores. However, when I am running some high-end simulations, the maximum used memory by the MATLAB is 33% (75 GB) and it never increases. The simulations ...
0 votes
1 answer
1k views

Matlab fit function not accepting "numeric" data type

This is driving me crazy, I'm just trying to fit a gaussian curve to some data using Matlab's fit function (r2017a). gaussEqn = 'a*exp(-((x-b)/c)^2)+d' f = fit(x,y,gaussEqn); But I get this error: ...
-1 votes
1 answer
173 views

How can I solve the Error: 358 when activating MATLAB R2019b?

"Error 358: The license file expiration date has passed. In order to activate this license, the license file expiration date must be set to a future date."
7 votes
5 answers
5k views

Matlab *.mat files associated with MS Office

When MATLAB creates a binary file with extension .mat on my Windows 7 (64 bit) computer, Windows declares it in a directory as a "Microsoft Office Access Table Shortcut". Windows also does not provide ...
0 votes
1 answer
65 views

MatLab showing different plots on different zoom level

I ran this code on MatLab: function main fimplicit (@(x,y)f(x,y),[2 5]) end function fun = f(x,y) nc=1.45; %cladding nf=1.5; ns=1.4; %substrate h=5; %width of waveguide kappa=sqrt(x^2*nf^2-y.^...
2 votes
2 answers
485 views

Simulink - running parallel simulations

Is it possible to run Simulink calculations in parallel mode on cluster? And if its possible then what actually Simulink do when number of processes that i need is more than cluster has nodes? Thank ...
1 vote
1 answer
672 views

Merge 3 .csv into one file with different number of columns

I have 3 .csv files and I want to merge them together to one .csv file which can be in R or Matlab. The files are: 1597 obs of 167 variables; 160 obs of 167 variables; 533 obs of 146 variables I ...
1 vote
1 answer
434 views

How to remove the bland space to the left of ylabel in Matlab figure when using long string for ylabel?

I'm doing some plots in Matlab 2014b, in one them I'm plotting 5 variables versus time over there and want to specify 5 names like, speed (rad/sec), voltage (V), ... etc. on the y-label, however, as ...
1 vote
0 answers
34 views

Matlab refuses to compute a limit [closed]

I have some function handle which has a variable input x, along with some parameters. I am trying to compute the limit when x goes to zero from above of that function, for different values of the ...
1 vote
1 answer
1k views

How to revert GCC installation on Centos 7

I recently installed gcc 6.3.0 following the instructions on this site as it is the supported compiler for the 2018b release of Matlab and Simulink. However due to compatibility issues with other ...
0 votes
1 answer
277 views

Values of Components in a Matlab app are not updated while a loop is running

I have created an app using the App Designer in Matlab. I have a check box called CheckBox and want to access its value from inside a loop, e.g. display it in the console. The way this could be done ...
0 votes
1 answer
58 views

MATLAB: recall previous command and ADD it to what I typed (similar to bash)

On the MATLAB commandline, I can recall the previous command with the UP arrow. However, if I already have typed something and then hit UP arrow, only commands beginning with what I already typed will ...
2 votes
1 answer
595 views

How to get different color for different branches in a plot in MatLab, Mathematica and Desmos

I am trying to obtain slab-waveguide dispersion plot like this (dashed line): I tried following code in Matlab: function main fimplicit (@(x,y)f(x,y),[0 10]) end function fun = f(x,y) nc=1.45; %...
2 votes
1 answer
36 views

Linking JVM languages other than Java with Matlab

I'm aware that it's possible to link Java programs with Matlab. Is it therefore possible to link any JVM languages with Matlab? I would suspect that's the case -- presumably Matlab can't tell and ...
0 votes
1 answer
211 views

MATLAB: Growing an array and logical indexing

I create the following array in MATLAB: Now I find which elements of x are greater than 4: So far so good. Now I create an array of length 8: And now I execute this command: I am very confused as ...
0 votes
2 answers
552 views

Matlab solve command gives four equations instead of 2 real solutions

I am trying to solve the following equation:x^4 - 3*x^3 + x^2 - 1 by doing: solve(x^4 - 3*x^3 + x^2 - 1 == 0) I am expecting either two real solutions or four solutions where two of them are real and ...
0 votes
1 answer
79 views

"gcs" returns nothing in MATLAB

After I restarted my PC and then re-opened a .m script I was working on, that for some reason broke it. gcs for some reason returns 0×0 empty char array when it's supposed to return the pathname of ...
0 votes
1 answer
291 views

Matlab syntax (1:end-1) - Explanation

Could someone explain me this code? meas.jerk.time = (meas.acc.time(1:end-1) + meas.acc.time(2:end)) ./ 2; Assuming that meas.acc.data and meas.acc.time are vectors with the same number of elements, ...
0 votes
0 answers
485 views

MATLAB - Error using interp1>reshapeAndSortXandV X and V must be of the same length

I geht this error message when I try to derive my acceleration of the car. I think there is a size problem, but I don't know how to solve it. The data is measured from a car. meas.jerk.data = diff(...
1 vote
0 answers
46 views

Opening MATLAB scripts by double click on linux

I associated '.m scripts with Matlab, but still, I have a problem. When I open two files of this type, I open 'two Matlabs' also. I want to have a similar result as in Windows. I open two scripts, ...
0 votes
0 answers
21 views

MATLAB output array

I'm a beginner and I got a Script and I have to out put RES{1} and RES{2} RES{ii,1} = measure; RES{ii,2} = measure_filter; measure and measure_filter will be filled before. But I don't know how to ...
0 votes
1 answer
342 views

MathWorks is written for Lego firmware V1.03, but Lego is up to V1.10

MathWorks (MATLAB and Simulink) is/are written for Lego firmware 1.03! (with no TelNet ID/passkey) Versions 1.07 and 1.08 also do not require the ID/passkey. Versions 1.09 and 1.10 do require an ID/...
0 votes
1 answer
36 views

How to make an application "recognized" as an application

I'm using ubuntu and i3 window manager. To launch matlab I have to navigate to /usr/local/MATLAB/R2019a/bin and type ./matlab. Other applications like firefox and atom are recognized as ...
1 vote
0 answers
84 views

Here HDLM in Matlab, App ID and App code credentials validation

I created a Freeminum account in Here technologies website and generated the App ID and App code. I tried to use those credentials in the HERE HDLM feature in the Automated driving Toolbox in Matlab. ...
0 votes
0 answers
648 views

MATLAB crashing system (gentoo linux)

First let me preface this by stating that I'm pretty new to MATLAB and Linux, perhaps I'm missing something obvious, if that's the case please be patient with me. I've been asked to help with a ...
20 votes
4 answers
43k views

How to release/reset serial port FTDI devices - Mac OSX

I am trying to work with a custom PCB that uses an FTDI FT232RL to talk to my computer (MacBookPro running OSX 10.11 El Capitan) for a hardware project. I am using Matlab to send serial commands, ...
0 votes
1 answer
105 views

Is there any way to tell MATLAB to close/exit all open executables/MEX files?

I am currently working on a project that uses MATLAB and MEX files. I frequently make changes to the MEX source files for testing, and then go to replace these files with my newly-compiled ones. ...
0 votes
1 answer
309 views

Editing Individual Bar Colors in MATLAB

I am writing a sample code in MATLAB to display profit of a business over a certain amount of time. So far I have plotted the following with relative ease. time = {'4 weeks','12 weeks','24 weeks','27 ...
0 votes
1 answer
89 views

Parametric plotting on MATLAB

I am working on a quantitative finance problem, and I wish to plot the following functions: mu= 0.1*w+0.14*(1-w) and sigma = (0.12^2)*w^2+0.4*0.12*0.2*2*w(1-w)+(0.2^2)*(1-w)^2; for w between 0 and 1. ...
0 votes
1 answer
45 views

Assistance with forming normal vectors on the graph

I am doing an assignment question link to image I am trying to find the normal vectors to my 'ice-cream' cone curve, which consists of a part cone and part sphere. I need help with the code because I ...
9 votes
7 answers
43k views

Where is my software installed in Linux?

I use whereis matlab and find: /usr/local/bin/matlab , which is a very long bash file. How can I find where matlab is installed, I mean, its installed folder. EDIT: I used the following method: ...
1 vote
0 answers
249 views

How to create a 3D plot with orthographic projections – Matlab

How can I generate a 3D plot with the orthographic projections of a parametric curve on the inside walls of the 3D plot, as shown in this youtube video? I can generate a 3D plot of the curve using ...
1 vote
1 answer
4k views

Is MATLAB performance increased if it is on SSD

I have a 256gb SSD which has my OS (windows 8) and Office on it. I also have a 4TB USB3.0 external hard drive. I do a fair bit of image and signal analysis using MATLAB. Will there be performance ...
1 vote
0 answers
112 views

Create a 3D space for dots moving in a given direction

I have written a code that animates 2d dots moving in a certain direction. I tried to create a 3rd dimension using spherical coordinates, and for that I used two times the psychtoolbox function Screen(...
0 votes
1 answer
34 views

When I try to install matplotlab library getting the error mentioned in the description

When I try to install matplotlab library in my python 3.7.3, I am getting the below error, Could not find a version that satisfies the requirement matplotlab (from versions: ) No matching ...
0 votes
2 answers
240 views

Windows: make application installed in Program Files seen like it has no spaces

I have Matlab installed in 'Program Files', and I need to install the toolbox that requires a path without any spaces. The problem is I can't perform reinstallation of that program in another location....

1
2 3 4 5 6