A répondu

How to delete rows from a cell array that do not satisfy a certain condition?

Hi, things get much easier, if you use arrays instead of individual variable names: % combine names and scores into a ta...

How to delete rows from a cell array that do not satisfy a certain condition?

Hi, things get much easier, if you use arrays instead of individual variable names: % combine names and scores into a ta...

plus de 5 ans il y a | 2

| A accepté

A répondu

Graph plotting of dy by dx

Hi Kabit, if you have only the data (I assume a time vector and the corresponding values), the simplest is to use the functio...

Graph plotting of dy by dx

Hi Kabit, if you have only the data (I assume a time vector and the corresponding values), the simplest is to use the functio...

plus de 5 ans il y a | 0

A répondu

S-Function String Parameter C++

Hi Nils, I didn't take a look into the zip file but could it be that you did the same mistake as I, namely, really passing a ...

S-Function String Parameter C++

Hi Nils, I didn't take a look into the zip file but could it be that you did the same mistake as I, namely, really passing a ...

plus de 5 ans il y a | 1

| A accepté

A répondu

Changing file directories under C:\Program Files

Hi, when you open the desktop shortcut properties you should be able to set the "working folder" to the folder you like. Then...

Changing file directories under C:\Program Files

Hi, when you open the desktop shortcut properties you should be able to set the "working folder" to the folder you like. Then...

plus de 5 ans il y a | 0

A répondu

difference in ode45 and rk4 code

Hi Debashis, I think there is a misunderstanding: ode45 uses the result from the 5th order RK method for the solution, wherea...

difference in ode45 and rk4 code

Hi Debashis, I think there is a misunderstanding: ode45 uses the result from the 5th order RK method for the solution, wherea...

plus de 5 ans il y a | 2

| A accepté

A répondu

Is it possible to create a UI around MATLAB functions in C++?

Hi Ivan, there are several possibilities: you can use <https://uk.mathworks.com/products/matlab-compiler-sdk.html MATLAB Comp...

Is it possible to create a UI around MATLAB functions in C++?

Hi Ivan, there are several possibilities: you can use <https://uk.mathworks.com/products/matlab-compiler-sdk.html MATLAB Comp...

plus de 5 ans il y a | 0

| A accepté

A répondu

Matrix dimensions and unbalanced bracket problem

Hi Jeff, I would rather use indexing instead of multiplication, something like u = zeros(size(t)); % first 2 micros...

Matrix dimensions and unbalanced bracket problem

Hi Jeff, I would rather use indexing instead of multiplication, something like u = zeros(size(t)); % first 2 micros...

plus de 5 ans il y a | 0

A répondu

S-Function String Parameter C++

Hi Nils, just to be sure: did you check the number of parameters you passed? I guess you are sure that there is at least one ...

S-Function String Parameter C++

Hi Nils, just to be sure: did you check the number of parameters you passed? I guess you are sure that there is at least one ...

plus de 5 ans il y a | 0

A répondu

Convert data type from int to double in Matlab app designer

Hi Abdulla, generally speaking by using "double": x = int32(42); % x is an integer xd = double(x); % x is a double ...

Convert data type from int to double in Matlab app designer

Hi Abdulla, generally speaking by using "double": x = int32(42); % x is an integer xd = double(x); % x is a double ...

plus de 5 ans il y a | 4

| A accepté

A répondu

Web app not able to perform xlsread/xlswrite

Hi Giulio, have you tried to first build up the full path to the Excel file? So instead of only the file name provide the ful...

Web app not able to perform xlsread/xlswrite

Hi Giulio, have you tried to first build up the full path to the Excel file? So instead of only the file name provide the ful...

plus de 5 ans il y a | 0

A répondu

How can I turn a string into a function and obtain the result?

Hi Brent, maybe you can describe a little more what you are trying to achieve? Your "function" has no input, so you could bas...

How can I turn a string into a function and obtain the result?

Hi Brent, maybe you can describe a little more what you are trying to achieve? Your "function" has no input, so you could bas...

plus de 5 ans il y a | 0

| A accepté

A répondu

How to run no longer supported P-Code for newer version of Matlab?

Hi, unfortunately no. You will need to ask the author to re-create the p-coded file in a newer version of MATLAB. Titus

How to run no longer supported P-Code for newer version of Matlab?

Hi, unfortunately no. You will need to ask the author to re-create the p-coded file in a newer version of MATLAB. Titus

plus de 5 ans il y a | 1

A répondu

Timer stops randomly in the middle of its callback

Hi, what did you write into your timer function, directly some code or the call of a MATLAB (.m) file? If you put your code i...

Timer stops randomly in the middle of its callback

Hi, what did you write into your timer function, directly some code or the call of a MATLAB (.m) file? If you put your code i...

plus de 6 ans il y a | 0

A répondu

MATLAB Fcn not yet supported by Simulink coder

Hi, are you using the "Fcn" block or the "MATLAB Fcn" block? I.e., the one with "f(u)" displayed on the block or the MATLAB l...

MATLAB Fcn not yet supported by Simulink coder

Hi, are you using the "Fcn" block or the "MATLAB Fcn" block? I.e., the one with "f(u)" displayed on the block or the MATLAB l...

plus de 6 ans il y a | 0

| A accepté

A répondu

Input values must be binary (0 or 1)

Hi, I admit I don't know this block. But the error tells you that only values zero and one are allowed. So you need to change...

Input values must be binary (0 or 1)

Hi, I admit I don't know this block. But the error tells you that only values zero and one are allowed. So you need to change...

plus de 6 ans il y a | 0

A répondu

mrdivide undocumented feature?

Hi, I think you might have mixed up A and B from the doc with A and x from your computation: A/x In this case your A ...

mrdivide undocumented feature?

Hi, I think you might have mixed up A and B from the doc with A and x from your computation: A/x In this case your A ...

plus de 6 ans il y a | 0

A répondu

Reading a .csv file with datastore in MATLAB R2011b

Hi Patrick, that same person in this case recommends to use textscan, which is available in R2011b and is some sort of a pred...

Reading a .csv file with datastore in MATLAB R2011b

Hi Patrick, that same person in this case recommends to use textscan, which is available in R2011b and is some sort of a pred...

plus de 6 ans il y a | 0

| A accepté

A répondu

When using fmincon can I have a variable be constrainted by either a range OR zero?

Hi, programmatically: yes, you can always formulate something like this as a non linear constraint. But the optimizer (and th...

When using fmincon can I have a variable be constrainted by either a range OR zero?

Hi, programmatically: yes, you can always formulate something like this as a non linear constraint. But the optimizer (and th...

plus de 6 ans il y a | 1

A répondu

Importing large .csv files into MATLAb but confined by limits of excel

Hi Patrick, the importer you mention will use xlsread in the background and yes, would be limited by the same limit. But: ...

Importing large .csv files into MATLAb but confined by limits of excel

Hi Patrick, the importer you mention will use xlsread in the background and yes, would be limited by the same limit. But: ...

plus de 6 ans il y a | 0

| A accepté

A répondu

Give priority to gui callback over code

Hi, the pause allows interruption of the code, so yes, it is needed. You can * use a much smaller time like pause(0.001) ...

Give priority to gui callback over code

Hi, the pause allows interruption of the code, so yes, it is needed. You can * use a much smaller time like pause(0.001) ...

plus de 6 ans il y a | 1

| A accepté

A répondu

MATLAB call compiled MCC program

Hi, unfortunately both will not work. The compiled code will need to run an instance of the MATLAB Compiler Runtime (MCR), bu...

MATLAB call compiled MCC program

Hi, unfortunately both will not work. The compiled code will need to run an instance of the MATLAB Compiler Runtime (MCR), bu...

plus de 6 ans il y a | 1

A répondu

Problem with factorial recursive function

Hi, two minor changes are needed: function x = fact(n) x = ones(size(n)); idx = (n>1); if any(idx) x(idx) = n(...

Problem with factorial recursive function

Hi, two minor changes are needed: function x = fact(n) x = ones(size(n)); idx = (n>1); if any(idx) x(idx) = n(...

plus de 7 ans il y a | 1

A répondu

Readtable 00:00:00 is missing

Hi, I'm not sure if there is really a problem. I think it's just a question of display. Take a look at this code fragment: ...

Readtable 00:00:00 is missing

Hi, I'm not sure if there is really a problem. I think it's just a question of display. Take a look at this code fragment: ...

plus de 7 ans il y a | 0

A répondu

How to use 'jar' in matlab m file?

Hi, this should work right away: pt = CoordPoint(126.97553009053178, 37.56456569639763); ktmPt = TransCoord.getTransCoo...

How to use 'jar' in matlab m file?

Hi, this should work right away: pt = CoordPoint(126.97553009053178, 37.56456569639763); ktmPt = TransCoord.getTransCoo...

plus de 7 ans il y a | 0

A répondu

How can i minimize

Hi Jeffrey, if I'm not mistaken, this should work: % let the vector of unknowns be [u1 u2 u3 u4 lambda], then we % ha...

How can i minimize

Hi Jeffrey, if I'm not mistaken, this should work: % let the vector of unknowns be [u1 u2 u3 u4 lambda], then we % ha...

presque 8 ans il y a | 0

A répondu

How can i minimize

Hi Jeffrey, I'm not sure I fully understand. If u1, u2, u3, u4 and x (=x1,x2,x3) are given, the computing lambda is trivial. ...

How can i minimize

Hi Jeffrey, I'm not sure I fully understand. If u1, u2, u3, u4 and x (=x1,x2,x3) are given, the computing lambda is trivial. ...

presque 8 ans il y a | 0

A répondu

How can i minimize

Hi Jeffrey, there is probably some missing information. I guess it's clear that h>=0. Since there are no restrictions on x1, ...

How can i minimize

Hi Jeffrey, there is probably some missing information. I guess it's clear that h>=0. Since there are no restrictions on x1, ...

presque 8 ans il y a | 0

A répondu

Empirical PDF data?

Hi Bret, what do you mean by "empirical data". Are you looking for a draw of numbers that is e.g. normally distributed? In th...

Empirical PDF data?

Hi Bret, what do you mean by "empirical data". Are you looking for a draw of numbers that is e.g. normally distributed? In th...

presque 8 ans il y a | 0

A répondu

How to implement a set in MATLAB?

Hi, if I see it correctly, your "set" is meant to be a set of numbers? In this case you might simply use a vector in MATLAB. ...

How to implement a set in MATLAB?

Hi, if I see it correctly, your "set" is meant to be a set of numbers? In this case you might simply use a vector in MATLAB. ...

presque 8 ans il y a | 1

A répondu

How to save .mat file as a variable to load for later?

Hi, use the functional form of load. Let's say the images in your .mat file are stored as variables im1, im2, im3, ... then y...

How to save .mat file as a variable to load for later?

Hi, use the functional form of load. Let's say the images in your .mat file are stored as variables im1, im2, im3, ... then y...

presque 8 ans il y a | 0