Respondida
Locating Libary blocks in a large model
<http://www.mathworks.com/help/simulink/ug/working-with-library-links.html#brknia1-1>

alrededor de 11 años hace | 0

Respondida
problems while exporting figure.
h=bar(1:3,'facecolor','y','edgecolor','k','linewidth',1)

alrededor de 11 años hace | 0

Respondida
How to Nonlinear Equation?
syms h x eq1=h^2*((4*x)/exp(x^2) - 1/2)+ (2*h*x)/(x^4 + 1), eq2=2*h*(4/exp(x^2) - (8*x^2)/exp(h^2)) sol=solve([eq1,eq2]) ...

alrededor de 11 años hace | 1

Respondida
Export multiple figures in a directory
close all; x=(1:1:50); y=x.^2; z=x.^3; t=-10*z; aaa=[y; z; t]; for i=1:size(aaa,1); figure(i); plot(x,aaa(i,:)...

alrededor de 11 años hace | 0

| aceptada

Respondida
How to add multiple axes to a log-log plot?
Look at this example x1=0:0.01:5 x2=10*x1 y1=sin(x1) y2=2*cos(x2) plot(x1,y1,'r') hold on, ax2=axes('xaxislocation','...

alrededor de 11 años hace | 0

Respondida
Problem of Interpolation in matlab
A=[0 0.5000 1.4700 1.2300 4.3700 3.2800 7.2900 5.2800] UM=A(:,1) angle=A(:,2) UM...

alrededor de 11 años hace | 0

| aceptada

Respondida
repeating numbers in matrix
col1=repmat(2:2:6,1,3) col2=reshape(repmat(1:2,6,1),1,[]) col3=5*ones(1,12) Read the documentation doc repmat doc r...

alrededor de 11 años hace | 0

| aceptada

Respondida
affect values to cells without a loop
a{1}=zeros(1,3); a{2}=zeros(1,4); ii{1}=1; ii{2}=3; b{1}=2; b{2}=3; out=cellfun(@(x,y,z) [x(1:y-1) z x(y+1:end)],a,ii,...

alrededor de 11 años hace | 0

Respondida
plot double y axis, 3 curves
If your data are column vector [ax,h1,h2]=plotyy(x1,y1,x2,[y2 y3]) set(h1,'linestyle','none','marker','o','color','b'...

alrededor de 11 años hace | 0

| aceptada

Respondida
How to use use histc in multiple array
You can use a for loop

alrededor de 11 años hace | 0

Respondida
Constraint condition and IF statement
Remove ceq= from your If expression a=(((0.025*(x(1)^2)*(1-exp((-1.025*x(3))/x(1))))/(((x(2)^2)/(x(1)+x(2)))*(1-exp((-0.513...

alrededor de 11 años hace | 0

Respondida
I have code that uses ishift(Kr1')' What is the function of the single quotes?
This line ishift1(Kr1')' Can be written as a=Kr1' % Conjugate transpose of Kr1 b=ishift(a)' % transpose of ishift...

alrededor de 11 años hace | 1

| aceptada

Respondida
how to find strings of varying length within longer strings
str={'HA2.hdhashasdh' 'HA33.dskljdasjkdajkls' 'hh' 'HA80.djklasjdjklads' 'HA81.djkhadsh' 'HA245.fsaldjajdalsj' 'er'} li...

alrededor de 11 años hace | 0

| aceptada

Respondida
Deleting Duplicates from 2 data sets
data=unique([data_1;data_2],'rows')

alrededor de 11 años hace | 0

Respondida
Find the roots of using matlab Help Please
Use <http://www.mathworks.com/help/matlab/ref/roots.html roots function>

alrededor de 11 años hace | 0

| aceptada

Respondida
Difference in simulation results of continuous and discrete transfer function in simulink
Check the poles of your discrete model, they are unstable while your continuous model is stable. That means the discretization ...

alrededor de 11 años hace | 0

| aceptada

Respondida
Matlab find an element in matrix
syms q x=[2*q q^2 5*q] [i,j] = find(x==q^2) The result is i = 1 j = 2

alrededor de 11 años hace | 2

| aceptada

Respondida
Saving data from a loop
data=xlsread('Soil Characterization.xlsx',5,'C17:K23'); L=length(data(1,:)); h=zeros(L,6) for xx=1:L; y=[data(1:6,xx)'...

alrededor de 11 años hace | 0

Respondida
Building Simulink Modell from Matlab Code
get_param('path to block','DialogParameters')

alrededor de 11 años hace | 0

| aceptada

Respondida
How do I input a signal which is not a standard signal (like step or ramp) to a transfer function?
%Example H=tf(1,[1 2]) time=0:0.1:10 input_s=rand(1,numel(time)); output_s=lsim(H,input_s,time) plot(time,output_s)

alrededor de 11 años hace | 0

Respondida
matrix column element limiting
Example A=rand(200,30) idx=A(:,29)>0.5 & A(:,30)<0.7 out=A(idx,:)

alrededor de 11 años hace | 0

| aceptada

Respondida
How to convert a multidimensional cell into a single array of only one column.
a={1 2 3;[] 4 5;6 [] 7} b=a' b=[b{:}] or b=cell2mat(reshape(a',1,[]))

alrededor de 11 años hace | 0

| aceptada

Respondida
Vectorizing Array -- Wrong Dimensions?
Probably, the value of setsize is 2252, or maybe in your code, you have pre-allocated the variable distance with zeros(2252,2252...

alrededor de 11 años hace | 0

Respondida
Error using str2num (line 32), Requires string or character array input. Error in xGridMarkers = str2num(get(gca,'XTicklabel')); how to remove this error??
Use str2double, because get(gca,'XTicklabel') is a cell array xGridMarkers = str2double(get(gca,'XTicklabel')); yGridMarke...

alrededor de 11 años hace | 1

| aceptada

Respondida
I have 21*1 Matrix. i have store it into z. then i have to slice these value as 1*1 Matrix and allocate (z1, z2, z3, z4.......z21) for 21 matrix. how can i allocate. please tell me command or allocation.
I don't know why you need to create all these variables. z=rand(1,21) % Example for k=1:21 assignin('base',sprintf(...

alrededor de 11 años hace | 0

Respondida
Round function with multiple inputs not working in MATLAB function block in Simulink
Instead of round(u,3) use round(u*1000)/1000

alrededor de 11 años hace | 7

| aceptada

Respondida
How to find matrix column & row max & min output as vector?
Read the documentation <http://www.mathworks.com/help/matlab/ref/min.html> <http://www.mathworks.com/help/matlab/ref/max.html>

alrededor de 11 años hace | 0

Respondida
Cell Array Filtering Not Working
A=[1 34 2; 6 4 2; 9 1 0] B=num2cell(A) C=B([B{:,3}]==2,:) If you write B={A}, B is a 1x1 cell array. I think what you are...

alrededor de 11 años hace | 0

| aceptada

Respondida
repeat a vector with a pattern
v=[1 2] k=[1 7 9] out=cell2mat(arrayfun(@(x) v+2*x,k,'un',0)) or out=reshape(bsxfun(@plus,v',2*k),1,[])

alrededor de 11 años hace | 1

Cargar más