已回答
How to select a value in filter dropdown in excel
You might find it a lot easier to just write this specific functionality as an Excel macro, and then invoking the macro from MA...

10 years 前 | 1

已回答
i want to change the value in some specific rows how can i do it
A = [1 2 3; 1 2 3; 1 2 3; 1 2 3; 1 2 3; 1 2 3] % Change Row 2 A(2,:) = [9 8 7]; % Change Row 5 A(5,:) = [5 5 ...

10 years 前 | 0

已回答
Why can I not get the modaldlg function to work? eg. user_response = modaldlg('Title','Confirm Close');
Try one of the following, depending on the type of dialog you want: user_response = errordlg('Error','Confirm Close', 'moda...

10 years 前 | 0

| 已接受

已回答
remove first s and last t rows of a matrix containing NaN, leave lows in the middle containing NaN.
Nobody should ever need more than one line: A = [[NaN;NaN;NaN;4;1;NaN;5;6;8;NaN;NaN],[NaN;NaN;2;7;6;5;NaN;6;18;2;NaN]]; ...

10 years 前 | 0

已回答
using add_block in a for loop
I see you have defined a source block ('NPC_MMC_Library/Submodule'), however your destination doesn't appear to include the mode...

10 years 前 | 0

| 已接受

已回答
Vehicle dynamics model simulink
1. Make sure all your inport are connected to a source (signal generator, constant, etc). 2. Make sure all your outports are ...

10 years 前 | 0

| 已接受

已回答
Select elements of Matrix?
Like so: P = magic(20); Q = P(end-17:end,end-17:end); Or this, as I assume you mean rows/columns 3 to 20 - otherwise...

10 years 前 | 0

已回答
How can I find the max of two vectors?
Do you actually want to sort by sum of columns? For example: a = [4.84 3.55 2.09 4.20 1.14 5.15 2.45 3.41 1.66 2.75 3.8...

10 years 前 | 1

| 已接受

已回答
Delete rows that have the first same value and keep one row in matrix with 2 colums?
Do you mean something like this? x = [0,0 ; 250,1050 ; 250,1051 ; 1173,3050 ; 1173 3150]; [~,idx] = unique(x(:,1)); ...

10 years 前 | 2

已回答
how do i fix "inner matrix dimensions must agree" in this formula?
Some of your defined vectors are of a fixes size, for example: rad=(0:0.01:0.15); theta=(0:24:360); Therefore your ...

10 years 前 | 0

| 已接受

已回答
Recreating the debouncer example in Simulink
You can use integrators as counters. Check for your desired state (TRUE or FALSE), then convert this TRUE signal into a double/s...

10 years 前 | 4

| 已接受

已回答
Error with mvnrnd function?
The function *mvnrnd* is part of the statistics toolbox. Firstly, in order to use this function you have to have the Statistics ...

10 years 前 | 0

| 已接受

已回答
Timer to send a new message?
I would probably use a resettable integrator for this task. Feed the integrator a constant value of '1', that way it will act as...

10 years 前 | 1

| 已接受

已回答
Insert Values of a Matrix from row 2 using XLSWRITE
A = ones(5,20); xlswrite('Workbook.xls',A,'Sheet1','A2')

10 years 前 | 0

| 已接受

已回答
How can I avoid infinite while loop?
You have an infinity loop because your seed (N) is starting at one. Note that your equation ((N*2)+(N+1))/N is in fact equal to ...

10 years 前 | 0

已回答
Simulink const block referencing changing variable doesn't update during simulation
Unfortunately unless you call 'set_param' the value of the variable will not be re-evaluated. Therefore calling 'set_param' is t...

10 years 前 | 1

| 已接受

已回答
How can i run two different clock at different (desired) times in simulink?
You can create a 'clock' using a discrete integrator. For example if you can set the time-step of the integrator equal to model ...

10 years 前 | 1

| 已接受

已回答
Undefined function 'tr' for input arguments of type 'double
The error is pretty self-explanatory, you are missing the function 'tr'. The function needs to be on your path (if it exists), o...

10 years 前 | 0

| 已接受

已回答
Convert variable-width text file numbers to UINT8 table?
It's not very elegant, and it's not very efficient - so enjoy: nRaw = {'130 216 165 154 233 210 209 129' ' 63 ...

10 years 前 | 0

已回答
The data is not correctly written with CSVWRITE, after 100000 rows
You could use fprintf instead. fid = fopen('test.csv','w'); fprintf(fid,'%0.2f\n', [0:0.01:1100]);

10 years 前 | 0

已回答
Out of memory issue
For large CSV files you are less likely to run into memory issues if you read it line by line, for example: nFile = 'file.c...

10 years 前 | 0

已回答
S-function dimension matching problem with lots of "Terminator" blocks
_"we all know that in S-function block, the input dimension must be SAME as output dimension"_ I'm really not sure where you ...

11 years 前 | 0

已回答
when i run the below code i get an error picture1 does not exist..where should i save the image to get the results
From the MATLAB help relating to imread: _If the file is not in the current directory or in a directory in the MATLAB path, s...

11 years 前 | 0

已回答
Function 'ss' implicitly resolved in the MATLAB workspace. Implicit evaluation in MATLAB is not supported. Please declare this function extrinsic using eml.extrinsic('ss'), or call it using feval.
What this error message is saying is that in order to use the state space function (ss) Simulink has to call the MATLAB workspac...

11 years 前 | 1

已回答
Axis dimensions in points
Here is an example of what I think you want to do: plot(1:10,1:10); h = gca; set(h, 'Units', 'Points'); nPos = get...

11 years 前 | 0

| 已接受

已回答
Error when using the same program on an other computer
The 'parfor' functionality is part of the Parallel Processing Toolbox. I would assume that second computer doesn't have this too...

11 years 前 | 0

已回答
"plus/minus" sign operator
Not exactly elegant, but it works: A = [1 2 3]; B = (dec2bin(0:2^length(A)-1) - '0'); C = sum(B .* repmat(A, 2^length...

11 years 前 | 0

已回答
Dos command gives error
If you want to send commands to an executable you need to modify the call slightly. Try this: dos('"C:\Program Files\Or...

11 years 前 | 1

| 已接受

已回答
what does this instruction means?
It means sfdr will take on the maximum value contained in the array ptot between element number nper+4 and element number N/2. ...

11 years 前 | 0

| 已接受

加载更多