Answered

How to find which of my computers have Matlab installed?

See this Answers post for instructions on how to deactivate MATLAB on a machine that you cannot access.

How to find which of my computers have Matlab installed?

See this Answers post for instructions on how to deactivate MATLAB on a machine that you cannot access.

13 days ago | 0

Answered

Select data from timetable according to date and time

If you want to determine if the time portion of a datetime falls in a certain window (regardless of the date portion) I recommen...

Select data from timetable according to date and time

If you want to determine if the time portion of a datetime falls in a certain window (regardless of the date portion) I recommen...

13 days ago | 0

Answered

Not all graphs appear at the same time

%%%%%Condiciones iniciales Phi=0.95; n=50; P0=1; x0=sqrt(P0)*randn(1,1); Q0=0.1; w0=sqrt(Q0)*randn(1,1); x(1)=Phi*x0+w0; ...

Not all graphs appear at the same time

%%%%%Condiciones iniciales Phi=0.95; n=50; P0=1; x0=sqrt(P0)*randn(1,1); Q0=0.1; w0=sqrt(Q0)*randn(1,1); x(1)=Phi*x0+w0; ...

15 days ago | 0

Answered

How can I get permutations of a vector satisfying the given condition?

My first thought would be to construct a digraph from your data then try to find Hamiltonian paths in that digraph. Or there may...

How can I get permutations of a vector satisfying the given condition?

My first thought would be to construct a digraph from your data then try to find Hamiltonian paths in that digraph. Or there may...

15 days ago | 0

Answered

How do I set coefficient variables in Fittype that was generated in Fitting toolbox?

On the documentation page for the fittype function, see the "Use Anonymous Functions to Work with Problem Parameters and Workspa...

How do I set coefficient variables in Fittype that was generated in Fitting toolbox?

On the documentation page for the fittype function, see the "Use Anonymous Functions to Work with Problem Parameters and Workspa...

16 days ago | 0

Answered

Calculating the value, excluding nan

Consider storing your data in a timetable array, with the dates associated with your data stored as a datetime array. If you do ...

Calculating the value, excluding nan

Consider storing your data in a timetable array, with the dates associated with your data stored as a datetime array. If you do ...

16 days ago | 0

Answered

Function listed in Data Acquisition Toolbox is not available after installing toolbox

According to the information at the end of the documentation page for the tdmsinfo function in Data Acquisition Toolbox, it was ...

Function listed in Data Acquisition Toolbox is not available after installing toolbox

According to the information at the end of the documentation page for the tdmsinfo function in Data Acquisition Toolbox, it was ...

16 days ago | 1

| accepted

Answered

question about command 'mat2cell'

Use repmat to build your vector of tile heights or widths. A = ones(8); n = 2; v = repmat(n, 1, 4) % You could compute the 4 ...

question about command 'mat2cell'

Use repmat to build your vector of tile heights or widths. A = ones(8); n = 2; v = repmat(n, 1, 4) % You could compute the 4 ...

16 days ago | 0

Answered

Getting the error. "index exceeds the number of array elements".

When i is 2, you assign to h(2) but then on the next line you attempt to access h(3). That element doesn't exist yet. I suggest...

Getting the error. "index exceeds the number of array elements".

When i is 2, you assign to h(2) but then on the next line you attempt to access h(3). That element doesn't exist yet. I suggest...

16 days ago | 0

| accepted

Answered

Function call another function

If you only want functions in the directory containing your main file1 and file2 functions to be able to call your helpers, cons...

Function call another function

If you only want functions in the directory containing your main file1 and file2 functions to be able to call your helpers, cons...

18 days ago | 0

Answered

How do I assign result array of a loop to a variable name?

Can you dynamically create variables with numbered names like uniqueCost1, uniqueCost2, uniqueCost3, etc.? Yes. Should you do t...

How do I assign result array of a loop to a variable name?

Can you dynamically create variables with numbered names like uniqueCost1, uniqueCost2, uniqueCost3, etc.? Yes. Should you do t...

18 days ago | 0

| accepted

Answered

download the projects in examples

If you have the products that contain those examples installed and licensed (and are using a release that is the one in which th...

download the projects in examples

If you have the products that contain those examples installed and licensed (and are using a release that is the one in which th...

18 days ago | 0

| accepted

Answered

How do I continuously update a figure axis with time values using animatedline?

The problem with this code is that the x-axis only shows the most recently collected timestamp. That is the correct behavior as...

How do I continuously update a figure axis with time values using animatedline?

The problem with this code is that the x-axis only shows the most recently collected timestamp. That is the correct behavior as...

18 days ago | 0

Answered

Error using fit: Index in position 1 is invalid. Array indices must be positive integers or logical values.

I'm guessing you've created a variable named fit that's preventing MATLAB from calling the fit function. You can check this usin...

Error using fit: Index in position 1 is invalid. Array indices must be positive integers or logical values.

I'm guessing you've created a variable named fit that's preventing MATLAB from calling the fit function. You can check this usin...

18 days ago | 0

| accepted

Answered

Simscape Multibody Link download

Are you trying to follow the steps given on this documentation page? If so, at which step or sub-step are you experiencing diffi...

Simscape Multibody Link download

Are you trying to follow the steps given on this documentation page? If so, at which step or sub-step are you experiencing diffi...

19 days ago | 0

Answered

Understanding how testCase.addTeardown works with @path

From the addpath documentation: "oldpath = addpath(___) additionally returns the path prior to adding the specified folders." So...

Understanding how testCase.addTeardown works with @path

From the addpath documentation: "oldpath = addpath(___) additionally returns the path prior to adding the specified folders." So...

19 days ago | 1

| accepted

Answered

Count the number of guesses made by player

Define a variable that records how many guesses the player has made. Each time the player makes a guess, add 1 to that variable...

Count the number of guesses made by player

Define a variable that records how many guesses the player has made. Each time the player makes a guess, add 1 to that variable...

19 days ago | 1

| accepted

Answered

problem in neighbors function

The neighbors function, in this context, requires its first input to be a graph object not an adjacency matrix. Create a graph o...

problem in neighbors function

The neighbors function, in this context, requires its first input to be a graph object not an adjacency matrix. Create a graph o...

19 days ago | 0

Answered

error in table2array - unable toconcatenate the specified table of arrays

You cannot turn this table into an array with table2array. Luckily, you don't need to turn it into an array. The reason you can...

error in table2array - unable toconcatenate the specified table of arrays

You cannot turn this table into an array with table2array. Luckily, you don't need to turn it into an array. The reason you can...

19 days ago | 0

Answered

Class constructor that can create either a single object or an object array depending on number of the argument

Your constructor needs to accept the case where it is called with 0 input arguments. See the section "No Input Argument Construc...

Class constructor that can create either a single object or an object array depending on number of the argument

Your constructor needs to accept the case where it is called with 0 input arguments. See the section "No Input Argument Construc...

20 days ago | 0

| accepted

Answered

Generate Random Number, that is that is repeatable

So you want to replace a certain section of your P_MMSI vector with the same random number? Let's look at your original code: %...

Generate Random Number, that is that is repeatable

So you want to replace a certain section of your P_MMSI vector with the same random number? Let's look at your original code: %...

20 days ago | 0

| accepted

Answered

MATLAB Simulink Model Recovery

Check if any of the Bug Reports related to crashing in the Simulink product in release R2021a seem relevant. If not, please use ...

MATLAB Simulink Model Recovery

Check if any of the Bug Reports related to crashing in the Simulink product in release R2021a seem relevant. If not, please use ...

20 days ago | 0

Answered

How to continue performing this flowchart about Gauss - Jordan method in a matlab code?

That check basically says to skip the first iteration of the loop. You could do this with an if statement and a continue stateme...

How to continue performing this flowchart about Gauss - Jordan method in a matlab code?

That check basically says to skip the first iteration of the loop. You could do this with an if statement and a continue stateme...

20 days ago | 0

Answered

Update doesn't work, is uninstall and reinstall too risky?

Update does not work, "I have no rights to write" to the drive/directory. Did you install MATLAB originally or did someone in y...

Update doesn't work, is uninstall and reinstall too risky?

Update does not work, "I have no rights to write" to the drive/directory. Did you install MATLAB originally or did someone in y...

21 days ago | 0

Answered

Using to the 'fill' function to plot a filled polygon that are confidence intervals

Let's draw the region "around" a simpler line. x = 1:10; y = x; plot(x, y, 'k', 'DisplayName', 'Original Line'); legend show...

Using to the 'fill' function to plot a filled polygon that are confidence intervals

Let's draw the region "around" a simpler line. x = 1:10; y = x; plot(x, y, 'k', 'DisplayName', 'Original Line'); legend show...

21 days ago | 0

Answered

How to code "e" by itself in equation e-1?

@Torsten and @Matt J are correct to suggest the exp function, but if the quantity x/a can be very small you might also want to l...

How to code "e" by itself in equation e-1?

@Torsten and @Matt J are correct to suggest the exp function, but if the quantity x/a can be very small you might also want to l...

22 days ago | 1

Answered

Previous matrix numbers in the formula and creating a new matrix

The arithmetic operators plus, +, minus, -, times, .*, ldivide, .\, rdivide, ./, and power, .^ operate element-wise. x = 1:5 y...

Previous matrix numbers in the formula and creating a new matrix

The arithmetic operators plus, +, minus, -, times, .*, ldivide, .\, rdivide, ./, and power, .^ operate element-wise. x = 1:5 y...

22 days ago | 0

| accepted

Answered

How can I change the variable x0 to x2,x3,x4,...xn . So it still produces the same pattern?

Can you dynamically create variables with numbered names like x1, x2, x3, etc.? Yes. Should you do this? The general consensus ...

How can I change the variable x0 to x2,x3,x4,...xn . So it still produces the same pattern?

Can you dynamically create variables with numbered names like x1, x2, x3, etc.? Yes. Should you do this? The general consensus ...

22 days ago | 0

Answered

I attached an old Matlab man page from 1982.

I haven't looked at that document but since that was prior to the incorporation of MathWorks in 1984, I'm guessing that's a vers...

I attached an old Matlab man page from 1982.

I haven't looked at that document but since that was prior to the incorporation of MathWorks in 1984, I'm guessing that's a vers...

23 days ago | 0

| accepted

Answered

Improve efficiency of for and if loops

I'm not 100% certain but based on the description I think either ismembertol or histcounts2 (specifically the 4th and 5th output...

Improve efficiency of for and if loops

I'm not 100% certain but based on the description I think either ismembertol or histcounts2 (specifically the 4th and 5th output...

24 days ago | 0