Risposto
error in envelope function
Let's make sure you're using the findpeaks function included as part of Signal Processing Toolbox. What does this command show w...

quasi 2 anni fa | 1

| accettato

Risposto
dictionary() question: "Error: Output argument not assigned a value in the execution with 'x' function" - works with some inputs and not others even though code is identical.
What value is assigned to the output argument variable numout if the value in the input argument variable convtype doesn't match...

quasi 2 anni fa | 0

| accettato

Risposto
Vector norms not interacting with dlarrays as documented
According to the Release Notes, support for dlarrays in vecnorm was added in release R2023b.

quasi 2 anni fa | 0

| accettato

Risposto
Matlab logic of plotting meshgrid formula
See this documentation page for a description of the difference between the * and .* operators (and similarly / and ./, etc.)

quasi 2 anni fa | 0

Risposto
Create a solid line instead of single points in the plot
Rather than plotting individual points inside a loop (as @VBBV and I both suspect you are doing) you could pull the plot command...

quasi 2 anni fa | 0

Risposto
Modifying the search path is not supported by Matlab Compiler?
See the "Do Not Rely on Changing Directory or Path to Control the Execution of MATLAB Files" section on this documentation page....

quasi 2 anni fa | 0

Risposto
Incompatible Sizes for ode45 Output Assignment
Rather than plotting the orbit after the fact, why not use an OutputFcn to plot while the ODE solver is solving? The ballode and...

quasi 2 anni fa | 0

Risposto
How can I write a set of first order ODEs with two variables?
In this case, the second input to your ODE function will have four elements. Using a slight variant (to avoid using y in two dif...

quasi 2 anni fa | 1

| accettato

Risposto
Create Class that is both Heterogeneous and a Handle class
I am looking to create a class that is both a handle class object which allows reference copies of that first object to be distr...

quasi 2 anni fa | 0

| accettato

Risposto
how to convert text file as it was written .m file to call functions?
If all the text in the file consists of valid MATLAB code and comments, just change the extension from .txt to .m.

quasi 2 anni fa | 0

Risposto
datetime adjustment in x-axis plot
Stop using datenum. If you have the text form of a date and time, use datetime instead of creating a serial date number array. Y...

quasi 2 anni fa | 1

Risposto
Why is it that Line objects can be instances of two different classes? How can I use findobj to detect only chart primitives?
Handle Graphics objects support the creation of heterogeneous arrays. So for example you can store a figure handle and an axes h...

quasi 2 anni fa | 2

| accettato

Risposto
How to sort table more than one variable with specified condition ?
See the "Sort Rows of Table by Variables" example on the documentation page for the sortrows function.

quasi 2 anni fa | 0

Risposto
Can't get matrix to populate first column
The smallest value in z is 1. Because you add 1 to z to generate z1, that means the smallest value in z1 is 2. You use z1 to det...

quasi 2 anni fa | 0

Risposto
description of highlighted code
From the variable names and the signature, this looks like a function you wrote or were given as part of solving a system of ODE...

quasi 2 anni fa | 0

Risposto
Possible to iterate over table rows without a loop index variable?
To perform an operation on all rows of a table array you could use rowfun, but that isn't the same as writing a general for loop...

quasi 2 anni fa | 0

| accettato

Risposto
pcregistericp using GPU Support
Note that "GPU Code Generation" and "GPU Arrays" are two different Extended Capabilities. For example, in MATLAB there are 200 f...

quasi 2 anni fa | 1

| accettato

Risposto
ode45 invalid parameter 981/100
When you call odeFunction with g as part of the third input, it is not a symbolic variable. You originally defined it using syms...

quasi 2 anni fa | 0

| accettato

Risposto
I need to Fix an Error For Lines 34 & 126
Let's look at your cal_obj function. function z = cal_obj(A,B,MB) n = length(MB); z = 0; for i = 1:n z = z + B(MB(i))*A(i);...

quasi 2 anni fa | 0

Risposto
I get an error using fsolve but I don't understand why?
Look at the description of the fun input argument on the documentation page for the fsolve function. The relevant part of that d...

quasi 2 anni fa | 0

| accettato

Risposto
Problem with solve() and "Empty sym: 0-by-1".
Let's look at the systems of equations you're trying to solve. Ax = [0 1 0 0; 0 -0.1 0 0.8; 0 0 -4 9; -1 -9 2 -8]; Bx = [0 0 0...

quasi 2 anni fa | 1

Risposto
Error using fclose in MATLAB on Mac: "Invalid file identifier. Use fopen to generate a valid file identifier.
When you call fopen you should call it with two output arguments and check if the first is -1. If it is, that means MATLAB and/o...

quasi 2 anni fa | 0

Risposto
how do I get my license number?
See this Answers post for instructions on how to determine your license number either from within MATLAB or without having MATLA...

quasi 2 anni fa | 1

Risposto
I have a code in python and want to convert it in matlab format
Do you need to convert the code or would being able to run the code in MATLAB be sufficient? If the latter, see the documentatio...

quasi 2 anni fa | 0

Risposto
How to Get one Property of a Structure Array Using a Property on the Same Line
You could do what you described by making a non-scalar struct, each element of which has three fields, each of which has a piece...

quasi 2 anni fa | 0

Risposto
How to extract numerator and denominator coeficients from polynomial function to array
Do you have separate symbolic expressions for the numerator and denominator or do you have the fraction created by dividing nume...

quasi 2 anni fa | 1

Risposto
Error in matlab.internal.doc.csh.DocPageTopicMap/parseTopicPath
Likely you've written your own split.m function that takes precedence over the split function included in MATLAB. What does this...

quasi 2 anni fa | 0

| accettato

Risposto
Trouble labeling x and y axis
Do you have a variable named xlabel in the workspace? If you do, you cannot call the xlabel function. Clear or rename the variab...

quasi 2 anni fa | 0

Risposto
Maximum recursion limit is reached when I try to open any script
Did you create an open.m file that tries to call open? What does this command show? which -all open

quasi 2 anni fa | 0

Risposto
convert a range vector of bin centers to bin edges. Bin Centers and edges are non-uniform
If you know one of the edges of the region you're trying to bin, either the left-most or right-most edge, you can do this. Let's...

quasi 2 anni fa | 0

Carica altro