Answered
Unrecognized function or variable 'nc'.
I think at one point a number of years ago, nc used to be a package to deal with NetCDF files. These days you would use ncread o...

4 years ago | 0

Answered
Bi Level Optimization (solve unable to obtain explicit solution)
syms x y z t s; %x y z upper level optmization variables and t s are lower levels % Upper Level Optimization f=-0.008*x^2*y - ...

4 years ago | 0

| accepted

Answered
Convert cell to matrix
C = {'00000000', '00000010', '00000011'}; E = char(C) - '0'

4 years ago | 0

Answered
How to convert Non Image data to images for use in CNN
You can use an arrayDatastore after reading in the files, or perhaps a tabularTextDatastore . You probably do not need to conver...

4 years ago | 0

Answered
How do I use two vectors of velocity and time and a for loop to find distance?
If the time vector is the times at which events start, then you need to take the differences in time in order to find out the du...

4 years ago | 0

Answered
Experiment with a random presentation of images from a folder
http://matlab.wikia.com/wiki/FAQ#How_can_I_process_a_sequence_of_files.3F shows how you can read a series of files. assign them ...

4 years ago | 0

| accepted

Answered
Problem is unbounded with linprong
The constraints are used as A*x <= b. The boundary condition would be A*x = b which you could solve with A\b. But if A*x <= b...

4 years ago | 0

Answered
I'm trying to Plot Pt against length , it's not plotting
Pt= Sr + Ltx + f*L + n*j + Lrx + Ma; all of the values are scalars. Your computation is independent of OLR

4 years ago | 0

| accepted

Answered
I want to use arduino in [appdesigner].
function app = arduino You are defining a method named arduino for your class, which is interfering with calling the arduino...

4 years ago | 0

| accepted

Answered
error help in my code
That code is fine under the following conditions: * data is a cell array * s is a positive integer no greater than the numbe...

4 years ago | 0

| accepted

Answered
how to fix index error from urlread
You are using an http url. The result of the query is a 301 "moved permanently". You need to use https and the appropriate readi...

4 years ago | 0

Answered
How to plot cos(x)*cosh(x) to find the 5 interception point with horizontal line at y=-1?
You cannot do that. cosh(x) grows without bound as x tends to positive or negative infinity. cos(h) oscillates between -1 ...

4 years ago | 0

Answered
Why this piece of code gives error?
Positions=rand(30,3); Three columns Fit(i) = fobj(Positions(i,:)); You pass in one row at a time, so you pass in a v...

4 years ago | 0

| accepted

Answered
Do we need license for downloading Matlab runtime (r2022a (9.12) windows 64 bit)
Technically, Yes, you need to agree to some terms and conditions to download the Runtime, and those are considered a "license". ...

4 years ago | 0

Answered
How to use textscan for multiple variables
a=importdata(filename); d=char(a) Okay, so d is a character vector or character array -- in particular, d is not a file id. Yo...

4 years ago | 0

| accepted

Answered
liscence chekout error -21
You are using a network license but your version of MATLAB is newer than the license manager on the license server. Your IT peo...

4 years ago | 0

Answered
Can I get every combination of groups of data in a matrix
A = magic(3).^2 p = perms(uint8(1:numel(A))).'; B = reshape(A(p), size(A,1), size(A,2), []); %verify size(B) B(:,:,...

4 years ago | 0

| accepted

Answered
How to obtain inflection points for a curve ?
use gradient() to take numeric derivative. Use gradient() again to get second derivative. Search the second derivative for zeros...

4 years ago | 0

Answered
how to laplace(exp(-2t)u(t-4))
syms t u(t) = heaviside(t); f = exp(-2*t)*u(t-4) ; F = laplace(f)

4 years ago | 0

| accepted

Answered
How to adjust the size of a uifigure when using uialert to display alert dialog box?
uialert() does not have any provision for that. My tests show that the message is taken and wrapped in lines of at most 44 char...

4 years ago | 1

| accepted

Answered
How to split multiple numbers which is one number from data file?
D = 202021031200; T = datetime(string(D), 'InputFormat', 'uuuuddMMHHmm')

4 years ago | 0

Answered
Creating an array which has the linear index of the element left of each position.
I am not clear as to what you want to do, but L = reshape(1:90,9,10); L = [zeros(size(L,1),1), L]

4 years ago | 0

| accepted

Answered
Determine in an interpolation the contribution of each node nearby
As an approximation, and restricted to the case where the x coordinates of the spline are strictly increasing: If you were to i...

4 years ago | 0

Answered
How to use switch statement
https://www.mathworks.com/help/matlab/ref/double.discretize.html and switch on the bin number.

4 years ago | 0

Answered
Import multiple functions to Simulink
You cannot import those into Simulink. Those are not functions, those are symbolic expressions, but nothing in the symbolic tool...

4 years ago | 0

Answered
What is the algorithim the [Q,R] = qr() function uses?
https://netlib.org/lapack/explore-html/dd/d9a/group__double_g_ecomputational_ga3766ea903391b5cf9008132f7440ec7b.html has the sou...

4 years ago | 0

Answered
What type of entropy encoder does the MATLAB save() function use? I.e. how does that function work?
https://www.mathworks.com/matlabcentral/answers/93868-is-there-documentation-on-the-structure-of-mat-files-in-matlab#answer_1032...

4 years ago | 1

Answered
Two similar elements in legend, when they should differ
plot3(2,2,z(z<2),'o','MarkerFaceColor','g','MarkerSize',10); That does not mean to draw the selected z values with constant x ...

4 years ago | 1

| accepted

Answered
how to read a text file as datetime input?
filename = 'https://www.mathworks.com/matlabcentral/answers/uploaded_files/1156138/tt.txt'; t1 = readtable(filename, 'ReadVaria...

4 years ago | 1

| accepted

Load more