Answered
I haven't defined syms x but solve function gives me values depend on x
The solutions are most naturally parameterized by e2, but you have specified that you want to solve for e2. So solve() has to in...

2 months ago | 1

| accepted

Answered
Create a 2D plot with irregular axes
pointsize = 20; scatter(x, y, pointsize, Dataset(:)) This will produce colored round dots at the given locations. Producing s...

2 months ago | 0

Answered
Question about sprintf not handling list{:} properly
X = ["a","b","c"] Y = [1, 2, 3] catinated = [X;Y] Look carefully at the output and notice that it is a string array. The nume...

2 months ago | 1

| accepted

Answered
Using fprintf in a for loop to display the output as a set of coordinate points
The basic problem is that fprintf() consumes all of each argument before going on to the next argument. Combine that with the fa...

2 months ago | 0

Answered
How to ensure Matrixes are matching size
K = zeros(4, 1,n); K is initialized to 4 x 1 by something. K(:,:,n)=P(:,:,n-1)*A.'*inv(A*P(:,:,n-1)*A.'+R); P is 4 x 4 b...

2 months ago | 0

Answered
Format currency in a uitable in app designer
You need to specify the uitable FontName property, supplying a fixed-width font. Your current problem is that spaces in propor...

2 months ago | 0

| accepted

Answered
How can I change timetable to timeseries?
timeseries() does not accept duration or datetime times. "Sample times, specified as a numeric scalar or vector, or a cell arr...

2 months ago | 0

Answered
How do I change default plot colors to green and blue for multiple patternCustom polar plots?
patternCustom() returns an object handle to lines or else to a surface() object. When you are plotting multiple patternCustom()...

2 months ago | 0

| accepted

Answered
How can I pass a variable (numeric) through a callback event when I pressed a key in my figure?
set(gcf, 'KeyPressFcn', {@GetData, calibration}); That code does not bind "calibration" to whatever the then-current value of t...

2 months ago | 1

Answered
Add fixed colorbar to volshow
You cannot do that. volshow() creates a standalone chart object. There is an internal vol_hbt.Parent.Axes property but it is a ...

2 months ago | 0

Answered
optical design add on can't be installed with matlab 2025a.
I am not able to locate a toolbox with the name 'Optical Design and Simulation Library for Image Processing Toolbox' anywhere at...

2 months ago | 0

Answered
Extract consecutive elements from a vector in a sliding manner
A = [1 ;2 ;3 ;4 ;5 ;6]; A_slice = buffer(A, 2) now do things with the columns. buffer() requires the Signal Processing Toolbo...

2 months ago | 0

Answered
How to get real root of a function using fminbnd?
x=-1:0.01:8; y=@(x) (x).^(4/3); yinv=@(x) -((x).^(4/3)); x_1=-1; x_2=8; [xmin, ymin]=fminbnd(y,x_1,x_2); [xmax, ymax]=fminbnd(...

2 months ago | 0

Answered
"I want to use a struct that includes pointers in Embedded Coder."
You may need to use something like coder.ceval() in order to be able to use the pointers. MATLAB and Simulink do not support poi...

2 months ago | 0

Answered
Setting size of a figure
You are not exporting the figures: you are exporting the axes, and the axes are different size. The one without the axes does no...

2 months ago | 1

Answered
Is the Ordering of the Output from combinations() Documented, Repeatable, and Sensible?
The source code for combinations is readable. The output order is not documented. The calculation is determinstic, so the ord...

2 months ago | 0

Answered
Sort vector based on another - How?
l = [ 5 3 2 1] k = [ 2 3 4 1] [l_sorted, l_sortidx] = sort(l); k_sorted = k(l_sortidx); l_sorted k_sorted

2 months ago | 1

| accepted

Answered
3D bar plot, does not show solid bars
You have negative z data. When you set(gca,'ZScale', 'log') then any shape that has a vertex with negative Z cannot be rendered....

2 months ago | 1

Answered
Is it possible to copy/paste myself data ? clipboard ? Shared Memory ?
See https://www.mathworks.com/matlabcentral/answers/534528-how-to-save-serialize-matlab-variables-to-a-byte-string#answer_439768...

2 months ago | 0

Answered
Force quit Matlab Online
You can close the browser tab, and then follow these instructions for killing the session: https://www.mathworks.com/matlabcentr...

2 months ago | 0

| accepted

Answered
Can you use command prompt to input a nifti file?
See uigetfile to prompt for the file name. After you have the file name, you would need to take appropriate importing steps, su...

2 months ago | 0

Answered
How to find correct "feature" name for parallel computing toolbox?
license('test', 'Distrib_Computing_Toolbox') See https://www.mathworks.com/matlabcentral/answers/449314-how-do-features-from-li...

2 months ago | 1

| accepted

Answered
How do I access an element in an answer array directly?
Two approaches: First = @(V) V(1); snsr_name = "Diff sensor A1"; snsr_type1 = First(split(snsr_name,' ')) snsr_type2 = s...

2 months ago | 0

Answered
My 6x6 symbolic Jacobian matrix is massive, and matlabFunction( ) is having trouble writing the corresponding numerical function file.
Use children() to get a 6 x 6 cell array (or simply loop over the contents of the array); matlabFunction() each one seperately ....

2 months ago | 1

Answered
Change variable value in the workspace using switch
Send the output of the Switch block into a To Workspace block.

2 months ago | 0

Answered
Inverting an 8x8 symbolic matrix
Start with a generic symmetric matrix, A11 A12 A13 A14 ... A18 A12 A22 A23 A24 ... A13 A23 A33 A34 ... inv() that. Expect it...

2 months ago | 1

Answered
How can I find the installation path for Simulink Support Package for Arduino Hardware
matlabshared.supportpkg.getSupportPackageRoot() It will be in a directory underneath there. In particular, ./3P.instrset/ardu...

2 months ago | 0

Answered
I have matlab2022b update10 installed, how do I install matlab2022b update6 instead?
https://www.mathworks.com/downloads/ . Select R2022b near the upper left side. Now, in the upper middle, select the "I want t...

2 months ago | 1

Answered
exporting-to-excel-spreadsheets
datadir = '.'; %path to data files dinfo = dir(fullfile(datadir, '*.xslx')); filenames = fullfile({dinfo.folder}, {dinfo.name...

2 months ago | 0

Answered
Can I download the latest version of Matlab if I renew the maintenance service?
Updating Software Maintenance Service gives you the right to update to any version of MATLAB that is released during the time th...

2 months ago | 0

Load more