답변 있음
Hi I have a basic doubt about the integrator block in simulink
Sreerag, the integral of sine is a negative cosine plus an integration constant. Integrating a sine between 0 and pi results in ...

대략 12년 전 | 1

| 수락됨

답변 있음
i had matrix s of size 4*12540, i want to take power of this matrix raise to 4*12540,how should i do it?
Amina, I am not sure I can follow. In general, if you need to take the nth power simply use n = 3; s3 = s.^n; or s...

대략 12년 전 | 1

| 수락됨

답변 있음
Find the negative entries in a array.
E, use [row col] = find(a<0)

대략 12년 전 | 2

답변 있음
Where or How can I access past editions of the Matlab Digest?
MathWorks only publishes the current MATLAB Digest. All technical articles that have appeared in Digests are live in the <http:...

대략 12년 전 | 0

| 수락됨

답변 있음
Excluding specific elements from matrix index
Jonah, how about A(2,end-2:end) = 2 or, simply, A(2,2:4) = 2

대략 12년 전 | 1

| 수락됨

답변 있음
Solve system of equations when symbolic vector is referencing its own elements?
Michael, use syms a1 a2 a3 a4 a5 a6 a7 a = [a1 a2 a3 a4 a5 a6 a7]'; eq = [ 2610.0 - 0.0001*a5 - 1.0e-6*a7 - 0.01*a3, ...

대략 12년 전 | 0

| 수락됨

답변 있음
How to record excution time of a subfunction during runtime?
Daniel, use <http://www.mathworks.de/de/help/matlab/ref/tic.html |tic|> and |toc|. tic [your subroutine call or commands] ...

대략 12년 전 | 1

| 수락됨

답변 있음
Using An Equation As An Input Argument For A Function
Mike, check out the code below: function fun_test() f = @(x) x^8 - 1.5; xl = 0; xu = 1; sol = fun_solve(f, x...

대략 12년 전 | 2

답변 있음
Can you put a function inside a for loop?
Sure, e.g., a = [5 4 3 2]; for ii = 1:numel(a) b(ii) = times(a(ii),ii); end You can have any other function inst...

대략 12년 전 | 0

답변 있음
how to use a uitable to add two numbers
Sivakumaran, does this do the trick? f = figure('Position',[200 200 350 150]); a = 2; b = 4; dat = [a b a+b]; cna...

대략 12년 전 | 0

| 수락됨

답변 있음
Calculation the coordinate of a point
Mick, x2 = x1 + d*cos(al); y2 = y1 + d*sin(al); where |d| is the distance and |al| is the angle in rad measured between...

대략 12년 전 | 1

| 수락됨

답변 있음
Vectors must be the same lengths
Daan, turn the script into a function and you should be good. As the first line in your code, add function myEuler() % or s...

대략 12년 전 | 0

답변 있음
Adding 3 numbers out of 5
Sarah, you could use data = [A B C D E]; datasum = sum(combnk(data,3),2);

대략 12년 전 | 0

| 수락됨

답변 있음
How to change mathematical symbols of division (/ to ./) and multiplication(* to .*) in a very long formula obtained by symbolic tool.
Mahak, copy-paste the formula into a script/function editor and use CTRL+F to replace the strings.

대략 12년 전 | 0

| 수락됨

답변 있음
Could you please tell me algorithm how to chose numbers in a matrix which is sastified a condition?
Luc, use a = [1 2 3;3 4 6;8 9 13]; [row col] = find(a>= 2 & a<=5); which will give you the row and colum indic...

대략 12년 전 | 0

| 수락됨

답변 있음
sprintf changes in each iteration
Md, do you mean something like for iFile=1:10 sprintf('A_%d_20%4d',iFile,1403-iFile+1) end To load a .mat file in...

대략 12년 전 | 0

| 수락됨

답변 있음
how to give three inputs to a scope block in simulink ?
Kishore, simply use a multiplexer (Mux) block (in > Commonly Used Blocks) to combine the signals into one vector signal. The vec...

대략 12년 전 | 0

답변 있음
How to extract certain rows of a matrix?
Mnr, you could use rows = find(all(data==0,2))

대략 12년 전 | 0

| 수락됨

답변 있음
Finding varible in equation from vectors.
Giuseppe, use c = y - m.*x

대략 12년 전 | 0

| 수락됨

답변 있음
How to Start simulating matlab code using raspberry pi
Nitesh, I recommend watching this <http://www.mathworks.com/videos/raspberry-pi-programming-using-simulink-81996.html?form_seq=c...

대략 12년 전 | 0

답변 있음
how do i change a scientific figures?
YJ, how about this: X = '0.0000012345'; Y = '0.0987654321'; strValues = sprintf('(%4.1e,%4.1e)',str2num(X),str2num(Y)); ...

대략 12년 전 | 0

| 수락됨

답변 있음
How to delete leading zeros in a row vector in MATLAB?
If it's a vector of chars, this should do: data = regexprep(data,'^0*','')

대략 12년 전 | 5

| 수락됨

답변 있음
Circshift not working for values of zero.
Use x_2 = circshift(x',-1,1)'

대략 12년 전 | 1

| 수락됨

답변 있음
Can someone tell me where is the problem? Matlab doesnt want to show me the real and the imag part of equation
Stefan, the problem is that the real and imaginary parts depend on the values of the variables, of course. Let me illustrate wit...

대략 12년 전 | 1

답변 있음
how to construct the matrix of size 10x1000
Asram, by 10x1000 do you mean 10 columns, 1000 rows? mymat = ones(1000,1)*(1:10) or rather 10 rows, 1000 columns, where t...

대략 12년 전 | 1

답변 있음
Creating two vectors from one.
Giuseppe, use xr = x(1:end-1,1).*x(2:end,2) xr = -16 6 4 and equivalent for the other calculation.

대략 12년 전 | 1

| 수락됨

답변 있음
How to cancel the shadow of the blocks in .mdl files? (Matlab 2013a)
Mike, select File > Simulink Preferences > Editor Defaults > Use classic diagram theme (in the Simulink model window).

대략 12년 전 | 0

답변 있음
Undefined function 'qquadrature' for input arguments of type 'double'
Note, that |qquadrature()| is not a built-in MATLAB function. What does MATLAB return for which qquadrature If it is ...

대략 12년 전 | 0

답변 있음
Plots for second order control system in the same graph
Carlos, check out function myDE() prompt = {'xmin:','xmax:'}; name = 'Input x-range'; numlines = 1; xlimits ...

대략 12년 전 | 0

더 보기