已回答
Uninterrupted segment length?
For a number that has longer digits, I am not sure. However, if it is within acceptable number of digits format long I...

8 years 前 | 0

| 已接受

已回答
Hi I need help with this problem in MATLAB CODE!
Loop version: function Y = coffee(X) Y = zeros(length(X)-1,1); for i=1:(length(X)-1) if X(i+1) >= X(i) ...

8 years 前 | 1

| 已接受

提问


Random Question: If MATLAB disappears tomorrow, what would be the immediate effect?
I had a heavy discussion with my colleague the other day about how our lives would change if MATLAB ceases to exist. Since we ar...

8 years 前 | 0 个回答 | 0

0

个回答

已回答
How Can i sum same values in an arry untill it change to a diffrent number and sum these aswell
TeamPasses = [26 25 25 25 25 26 26 26 26 25 25 25 25 26 26 26 25 25 25 25 26 26 26 25 25 26 26 26 26 26]; coffee = find(di...

8 years 前 | 0

| 已接受

已回答
Using an ELSEIF statement under another IF
Here is an example: input = input('Please insert an integer\n'); if input < 10 if input < 5 fprintf('You...

8 years 前 | 0

| 已接受

已回答
How do I split double-digit elements in a vector into two separate elements?
Simple approach would be: v = [1 18 9 8]; for i = 1 : length(v) new_vec{i} = num2str(v(i)) - '0' end ...

8 years 前 | 0

已回答
new to matlab simple question
Yes it will, assuming that you have previously defined the values for |a,b,c| obviously. If you write semicolon at the end of...

8 years 前 | 0

| 已接受

已回答
Help with my program in MATLAB CODE:
coffee = 0; while ~coffee G = input('Please insert the limit number that is greater than 4\n'); if G <= 4 coffee ...

8 years 前 | 0

| 已接受

已回答
How can I repeat question until valid input is entered?
What if you implement it using a |while| loop? %Input clc; clear all; close all; fpc = input('Enter specified compressi...

8 years 前 | 1

| 已接受

提问


Reading combinations of strings and numbers from a text file
I have a text file of a TLE as shown below. 1 24652U 96063A 96318.74847837 -.00000020 00000-0 00000+0 0 2 24652 ...

8 years 前 | 1 个回答 | 0

1

个回答

提问


Generating a random number inside a function decleration
I am trying to solve a first order differential equation using |ode45|. My function declaration is as follows. function dx =...

8 years 前 | 4 个回答 | 0

4

个回答

已回答
How to normalize data.
There are different methods you can use. One is the <http://www.mathworks.com/help/finance/tsmovavg.html moving average>. Howe...

9 years 前 | 0

已回答
How to plot the graph as function of three variables t=f(x,y,z)
You can use <http://www.mathworks.com/help/matlab/ref/mesh.html mesh> to plot the function. However, I need further details if i...

9 years 前 | 0

已回答
I need to add numbers in an array using a for loop...plz help
The problem with your code is |sum = sum + i|. Your |i| is defined as |i = 1:b = 1:length(A)|. You are summing the index numbers...

9 years 前 | 1

已回答
deleting words from a cell array
x={'areach';'aread';'areal';'areality';'arean';'arear';'areasoner';'areaway';'areca';'arecaceae'}; for n = 1 : length(x) ...

9 years 前 | 0

已回答
simulate dynamic response to a state space differential equation
How about defining your input like this. u = [t <= 1 & t >= 0; zeros(size(t));]; I also have few comments. * I don't ...

9 years 前 | 0

| 已接受

提问


Plotting a set of unit vectors in 2-D
I am trying to figure out what is the best way to plot a set of unit vectors in 2-D anchored at |(0,0)|. I am defining my rotati...

9 years 前 | 1 个回答 | 0

1

个回答

已回答
Weird discrepancy while plotting solutions of ode systems
Without looking at the code, I don't think it is possible for us to answer your question. Judging from the graphs, I can onl...

9 years 前 | 0

提问


Is there any way to import back figures that you initially exported from MATLAB?
I have used the "Copy Figure" on several plots I made on MATLAB and pasted it into Microsoft Word. I have accidentally deleted t...

9 years 前 | 1 个回答 | 0

1

个回答

提问


Ignoring empty arrays when using arrayfun on a structure?
I have |1x2269| structure with 20 fields called |data|. I am trying to extract with a condition using |arrayfun|. west_eas...

9 years 前 | 1 个回答 | 0

1

个回答

已回答
How to plot part of the data from larger data file?
A = rand(63, 5); sub_A = A(1:21, [1 2]); You can extract the 21 rows of the first two columns like this and proceed with...

9 years 前 | 0

| 已接受

提问


Is it possible to combine two structures saved in two different .mat files?
I have two structures, both named 'data' with 17 same fields. They are basically measured data of two different dates, and I wou...

9 years 前 | 1 个回答 | 0

1

个回答

已回答
Gradient of Substituted Symbolic Variables
It is because your function |f| is not updated. Here is what you need to do. syms x y z f = x^2 + x + y^2 - y; f = su...

9 years 前 | 0

| 已接受

已回答
Progress/percent complete bar
Take a look at the <http://www.mathworks.com/help/matlab/ref/waitbar.html |waitbar()|>. It displays a figure that shows what per...

9 years 前 | 2

已回答
Find given element in column 1 with "find" function.
A = [ 1 1 3;1 2 3;1 2 1]; P = find(A(:,1)==1);

9 years 前 | 0

| 已接受

已回答
Matlab index (I tried to name a matrix to use in a loop like variables.)
You can use cell arrays to do the task. Simple example is, A{1} = [1 2; 3 4]; for j = 2 : 10; A{j} = A{j-1} * 2; ...

9 years 前 | 0

已回答
Change Matrix dimension with NaN
One possible solution is to use <http://www.mathworks.com/matlabcentral/fileexchange/22909-padcat |padcat|> function from file e...

9 years 前 | 0

已回答
How can I convert a variable whose value is double to integer or to float?
z1 = rand(2601,1); int_z1 = int8(z1); I don't really understand what you mean by "float". Are you refering to single-pre...

9 years 前 | 0

| 已接受

已回答
how to use matlab image in MS documents
Could you explain what you mean by image? If it is a simple figure (.fig), you can save it as a .JPG (.JPEG) format and insert t...

9 years 前 | 0

已回答
How to delete workspace empty variables
a=who; for var=1:length(a) b=eval([a{var}]); if isempty(b) eval(['clear ' a{var} ';']) end en...

9 years 前 | 1

加载更多