已解决


Solve a System of Linear Equations
*Example*: If a system of linear equations in _x&#8321_ and _x&#8322_ is: 2 _x₁_ + _x₂_ = 2 _x₁...

5 years 前

已解决


Verify Law of Large Numbers
If a large number of fair N-sided dice are rolled, the average of the simulated rolls is likely to be close to the mean of 1,2,....

5 years 前

已解决


Find the Oldest Person in a Room
Given two input vectors: * |name| - user last names * |age| - corresponding age of the person Return the name of the ol...

5 years 前

已解决


Convert from Fahrenheit to Celsius
Given an input vector |F| containing temperature values in Fahrenheit, return an output vector |C| that contains the values in C...

5 years 前

已解决


Calculate Amount of Cake Frosting
Given two input variables |r| and |h|, which stand for the radius and height of a cake, calculate the surface area of the cake y...

5 years 前

已解决


Times 2 - START HERE
Try out this test problem first. Given the variable x as your input, multiply it by two and put the result in y. Examples:...

5 years 前

已回答
How to implement a function slideshow to multiple figures ?
Do you want the slideshow to exist only in Matlab, or do you want to be able to share it? Here are my personal suggestions: If ...

5 years 前 | 0

| 已接受

已回答
How to for loop through a function?
To pass/access the elements in a cell array, you need {}. () accesses the cell. Check the difference between what returns from ...

5 years 前 | 0

已回答
Struct to numeric variable
It sounds like you have a 446x1 structure array with 3 fields (each scalar?). Try this: new_var = [structname.fieldname]; ...

5 years 前 | 0

已回答
How I can print out only the numbers over the threshold and keep each number in the same place ?
Plots will exclude NaN values, but keep the rest of the data in place. So, here's a trick: data ./ (condition) Where condition...

5 years 前 | 0

| 已接受

已回答
Array indices must be positive integers or logical values.
(n.*K.*T(K).*ns)) is that supposed to be T*K or T(k)?

5 years 前 | 0

已回答
Not Generating Accurate Elements from Inequality
Feyqlimit = Fezq(abs(Fezq) <= .025)

5 years 前 | 0

| 已接受

已回答
I want to install 2020 matlab win32
https://www.mathworks.com/help/install/?s_cid=doc_ftr

5 years 前 | 0

已回答
Delete part of the third dimension for arrays that store in the cell
to access the data in cells (rather than the cells themselves) and to store data in a new cell array, use {} for i= 1:numel(tma...

5 years 前 | 1

| 已接受

已回答
How do I plot a series of points as a collection of 1x2 arrays?
If you have a cell array of 1x2 arrays like so: points = {[1,2] , [2,6] , [8,3] , [6,9]}; then you can turn it into a 1x (2N) ...

5 years 前 | 0

已回答
How to sum my matrix element?
from sum documentation: "S = sum(A,'all') computes the sum of all elements of A. This syntax is valid for MATLAB® versions R201...

5 years 前 | 1

已回答
How to reorder cell array based on the vector
index = [1; 2; 4; 3; 7; 6; 5]; list = {[1158;1159], [1543;1544], [2020;2096;2173], [2159], [4836], [5374], [5492;5493]}; list_...

5 years 前 | 1

| 已接受

已回答
group in a small vector
Ok, here is a way: A=[1,0,0,1,1,1]; % turn A into a 1x6 string array tmp=string(A); % reshape into a 3xN string array, then ...

5 years 前 | 0

| 已接受

已回答
How to do permutations with conditions
Actually, this should work V= (1:0.5:5); Comb = combvec(V(2:end),V)'; % if you want sorted by first column: Comb = sortrows(...

5 years 前 | 0

| 已接受

已回答
How can I insert data from different table that match a certain value?
% find the index of the offset.FrameNumber row matching each Secc.Seccion element [~,idx] = ismember(Secc.Seccion,offset.FrameN...

5 years 前 | 0

| 已接受

已回答
How to show the negative value on the graph?
If you want to plot both positive and negative data on a log scale, your best bet is to check out symlog: https://www.mathworks....

5 years 前 | 0

已回答
Plot change in heat for a x y position as a function of time
Look at your Temp variable: Temp=zeros(x_nodes+1,y_nodes+1,t_nodes+1); if you want to know the temperature for a specific loca...

5 years 前 | 0

已回答
How to use for loop with xlsread to read multiple sheets in an excel file
from the documentation: num = xlsread(filename,sheet,xlRange) %reads from the specified worksheet and range. so, just loop ove...

5 years 前 | 0

已回答
Combining if and for loop to iterate through a cell array
to access the contents of a cell array, use {} instead of (): for trialnumber = 1 : length(cellfilename) if cellfilename{t...

5 years 前 | 0

| 已接受

已回答
Iterating through 2 Arrays and Performing a Calculation
loop version: for ind=1:length(A2) idx = find(A1 < A2(ind),1,'last'); A3(ind) = A2(ind) - A1(idx); end Another (p...

5 years 前 | 0

已回答
Calculations using for loops
Two problems: parentheses are not multiplication in matlab, you need * you are trying to insert a variable into itself Soluti...

5 years 前 | 2

| 已接受

已回答
save variables to table in for loop
Assuming you just want the final result and don't care about when it prints the filenames: fileID = fopen('filenametable.txt','...

5 years 前 | 0

已回答
how to move label from axis to the center
First, those are called the xtick labels. It turns out moving them is a pain, but I did find a potential solution here: a=gca; ...

5 years 前 | 1

已回答
Main .m file contains sub .m files and if one crashes, I want it to move to the next .m and carry on.
try a catch warning('Problem using script ''a'''); end try b catch warning('Problem using script ''b''')...

5 years 前 | 0

| 已接受

已回答
Cannot express limits in arrays
If the area is fixed, you don't want independent Y and Z: A = 4345; Z = [33:0.000001:sqrt(A)]; Y = A./Z; Note that the condi...

5 years 前 | 0

| 已接受

加载更多