Answered

How can I make the mask more beautiful?

Lu, you can create your own <https://blogs.mathworks.com/simulink/2008/07/27/how-to-make-your-own-simulink-block/ mask icon>. Do...

How can I make the mask more beautiful?

Lu, you can create your own <https://blogs.mathworks.com/simulink/2008/07/27/how-to-make-your-own-simulink-block/ mask icon>. Do...

meer dan een jaar ago | 0

| accepted

Answered

How to specify which output will be recorded from a for loop?

Louisa, how about P2(j,i) = 1 / (1 + exp(-B*(V2-V1))); Careful with var names, though. |i,j| are also used as the imagin...

How to specify which output will be recorded from a for loop?

Louisa, how about P2(j,i) = 1 / (1 + exp(-B*(V2-V1))); Careful with var names, though. |i,j| are also used as the imagin...

meer dan een jaar ago | 0

Answered

Using ODE45 to solve 2 dependent ODE: dX/dt (mass transfer) and dT/dt (heat transfer) of a particle during fluidized bed drying process.

jean, check out <https://www.mathworks.com/matlabcentral/answers/142957-solving-two-systems-of-des-using-the-ode45-function#answ...

Using ODE45 to solve 2 dependent ODE: dX/dt (mass transfer) and dT/dt (heat transfer) of a particle during fluidized bed drying process.

jean, check out <https://www.mathworks.com/matlabcentral/answers/142957-solving-two-systems-of-des-using-the-ode45-function#answ...

meer dan een jaar ago | 0

Answered

Runga Kutta numerical integration

numnum, check out <https://www.mathworks.com/matlabcentral/answers/360751-solving-lorenz-attractor-equations-using-runge-kutta-r...

Runga Kutta numerical integration

numnum, check out <https://www.mathworks.com/matlabcentral/answers/360751-solving-lorenz-attractor-equations-using-runge-kutta-r...

meer dan een jaar ago | 0

| accepted

Answered

how to solve 3 equations in 1 st order using rk4 method

Mallikarjun, check out <https://www.mathworks.com/matlabcentral/answers/360751-solving-lorenz-attractor-equations-using-runge-ku...

how to solve 3 equations in 1 st order using rk4 method

Mallikarjun, check out <https://www.mathworks.com/matlabcentral/answers/360751-solving-lorenz-attractor-equations-using-runge-ku...

bijna 2 jaar ago | 0

Answered

Creating a rectangular pulse

captain, how about plot(x,f(x-0.5,a1,b1),'b--');

Creating a rectangular pulse

captain, how about plot(x,f(x-0.5,a1,b1),'b--');

bijna 2 jaar ago | 0

| accepted

Answered

I have several columns of data of different length, how can I combine them all into one continuous column?

Tyson, use x = [a; b; c]

I have several columns of data of different length, how can I combine them all into one continuous column?

Tyson, use x = [a; b; c]

bijna 2 jaar ago | 1

| accepted

Answered

I get different results using the step response function only changing the order of the products of some parameters

Hi Mattin, welcome to the world of numerical analysis. While wn = x*R/L; WN = R/L*x; are the same expressions symbo...

I get different results using the step response function only changing the order of the products of some parameters

Hi Mattin, welcome to the world of numerical analysis. While wn = x*R/L; WN = R/L*x; are the same expressions symbo...

bijna 2 jaar ago | 1

Answered

replace values by the previous value

Not quite sure if I understand what you are trying to do, but how about data = 10*rand(5) old = data(data(:,1)<=6,1) ...

replace values by the previous value

Not quite sure if I understand what you are trying to do, but how about data = 10*rand(5) old = data(data(:,1)<=6,1) ...

bijna 2 jaar ago | 0

Answered

Solving Lorenz attractor equations using Runge kutta (RK4) method

The only bug that I can see at first glance is here y(i+1) = y(i) + h*(1/6)*(l1+2*l2+2*l3+l4); % replace ki by li You als...

Solving Lorenz attractor equations using Runge kutta (RK4) method

The only bug that I can see at first glance is here y(i+1) = y(i) + h*(1/6)*(l1+2*l2+2*l3+l4); % replace ki by li You als...

bijna 2 jaar ago | 1

| accepted

Answered

Is it possible to run 1 license on 2 or more computer?

Benjamin, according to the license agreement (R2017b): 2.3. Student [license use] (i) Student Licenses may be licensed by ...

Is it possible to run 1 license on 2 or more computer?

Benjamin, according to the license agreement (R2017b): 2.3. Student [license use] (i) Student Licenses may be licensed by ...

bijna 2 jaar ago | 0

Answered

SIMULINK | Making a Lego Segway balance on its own two wheels using a gyroscope | PI-controller, help!

Hello Steffen-Andre, there are several entries in File Exchange that should help you get started, see <https://www.mathworks....

SIMULINK | Making a Lego Segway balance on its own two wheels using a gyroscope | PI-controller, help!

Hello Steffen-Andre, there are several entries in File Exchange that should help you get started, see <https://www.mathworks....

bijna 2 jaar ago | 0

Answered

How can I compute the leap years?

Aaron, you could do something like function leapyr = leapyears(startYear, endYear) %UNTITLED8 Summary of this function g...

How can I compute the leap years?

Aaron, you could do something like function leapyr = leapyears(startYear, endYear) %UNTITLED8 Summary of this function g...

bijna 2 jaar ago | 0

Answered

Difference between values and indices?

E.g. A = [1 2; 3 4] Values of/in |A| are |1,2,3,4|. To access the |2| you would use val = A(1,2) |(1,2)| are the ...

Difference between values and indices?

E.g. A = [1 2; 3 4] Values of/in |A| are |1,2,3,4|. To access the |2| you would use val = A(1,2) |(1,2)| are the ...

bijna 2 jaar ago | 1

| accepted

Answered

Problems Indexing an Array

Without seeing the entire code, the only potential issue that I can see is that |t| must be integers starting at |t = 1|.

Problems Indexing an Array

Without seeing the entire code, the only potential issue that I can see is that |t| must be integers starting at |t = 1|.

bijna 2 jaar ago | 0

Answered

I have a latitude vector and I need to rotate it throughout a time t.

Ainoa, how about dt = 60*60; % dt = 1 hr t = 0:dt:24*60*60; % time vector spanning one full day omega =...

I have a latitude vector and I need to rotate it throughout a time t.

Ainoa, how about dt = 60*60; % dt = 1 hr t = 0:dt:24*60*60; % time vector spanning one full day omega =...

bijna 2 jaar ago | 0

Answered

Looking for good example of where numerical integration beats symbolic integration

voxynn, how about a RLC circuit? You could start with the linear DE, show that the DE can be solved symbolically and numerica...

Looking for good example of where numerical integration beats symbolic integration

voxynn, how about a RLC circuit? You could start with the linear DE, show that the DE can be solved symbolically and numerica...

bijna 2 jaar ago | 1

| accepted

Answered

How do I combine two index vectors to form a 2D index matrix?

Would this do the trick? Adx = Amat(Amat(:)>THR(:))

How do I combine two index vectors to form a 2D index matrix?

Would this do the trick? Adx = Amat(Amat(:)>THR(:))

meer dan 2 jaar ago | 0

Answered

vectorization of anonymous function?

Jan, is the resulting |u(x,y,z)| also a 1-by-4? How about: u = str2func(vectorize('@(x,y,z)sin(x*y*z^2)')); x = [1 2 3 ...

vectorization of anonymous function?

Jan, is the resulting |u(x,y,z)| also a 1-by-4? How about: u = str2func(vectorize('@(x,y,z)sin(x*y*z^2)')); x = [1 2 3 ...

meer dan 2 jaar ago | 1

Answered

Trouble with ODE45, (not enough data of a planet's orbit)

Fabio, you control the number of data points that are returned in [T1,Y1] = ode45('fUranus',tspan,[x00;xp0],options); by...

Trouble with ODE45, (not enough data of a planet's orbit)

Fabio, you control the number of data points that are returned in [T1,Y1] = ode45('fUranus',tspan,[x00;xp0],options); by...

meer dan 2 jaar ago | 1

| accepted

Answered

How can we model this equation in simulink dx/dy + x + y = 1 where x is the input and y is the output.

Re-write as dx/dy = 1 - x - y % y is your independent variable, sort of "t" therefore dy/dx = 1/(1 - x - y) Then,...

How can we model this equation in simulink dx/dy + x + y = 1 where x is the input and y is the output.

Re-write as dx/dy = 1 - x - y % y is your independent variable, sort of "t" therefore dy/dx = 1/(1 - x - y) Then,...

meer dan 2 jaar ago | 1

| accepted

Answered

Changing a graph axis numbers

Burak, use the |axis| command. E.g. t = 0:0.01:2; y = exp(-t).*(sin(20*t).^3); subplot(2,2,1) plot(t,y) axis([0.5 1...

Changing a graph axis numbers

Burak, use the |axis| command. E.g. t = 0:0.01:2; y = exp(-t).*(sin(20*t).^3); subplot(2,2,1) plot(t,y) axis([0.5 1...

meer dan 2 jaar ago | 0

Answered

how to write the equation of this graph

t = 0:0.01:2; y = exp(-t).*(sin(20*t).^3); plot(t,y)

how to write the equation of this graph

t = 0:0.01:2; y = exp(-t).*(sin(20*t).^3); plot(t,y)

meer dan 2 jaar ago | 2

| accepted

Answered

How to fix the superscript in the ticklabels of my boxplot?

Lea, this might help. Add set(gca,'TickLabelInterpreter', 'tex'); before setting the |xticklabel|.

How to fix the superscript in the ticklabels of my boxplot?

Lea, this might help. Add set(gca,'TickLabelInterpreter', 'tex'); before setting the |xticklabel|.

meer dan 2 jaar ago | 3

| accepted

Answered

Subscripted assignement dimension mismatch

How about t = 1:0.1:5; y = t.*(t>=0&t<1) + (-t+2).*(t>=1&t<2) + 0*(t<0&t>=2); plot(t,y)

Subscripted assignement dimension mismatch

How about t = 1:0.1:5; y = t.*(t>=0&t<1) + (-t+2).*(t>=1&t<2) + 0*(t<0&t>=2); plot(t,y)

meer dan 2 jaar ago | 1

| accepted

Answered

How the Self-Paced Training course in matlab academy will be avaiable?

Mattia, you should be able to log in at <https://matlabacademy.mathworks.com/> with your MathWorks account credentials.

How the Self-Paced Training course in matlab academy will be avaiable?

Mattia, you should be able to log in at <https://matlabacademy.mathworks.com/> with your MathWorks account credentials.

meer dan 2 jaar ago | 0

| accepted

Answered

updating handles in gui/guide for webcam

Christian, I solved a similar problem by removing the associated field of the |handles| object. So essentially (and following...

updating handles in gui/guide for webcam

Christian, I solved a similar problem by removing the associated field of the |handles| object. So essentially (and following...

meer dan 2 jaar ago | 0

Answered

how to display all iterations in one matrix...below is the code which i run and get the value of z in separate vectors..how to combine them in one.

Quick and dirty: z = []; for x = E1 for y = E2 f = C*(DP1*x+DP2*y); z = [z; x y f] end end

how to display all iterations in one matrix...below is the code which i run and get the value of z in separate vectors..how to combine them in one.

Quick and dirty: z = []; for x = E1 for y = E2 f = C*(DP1*x+DP2*y); z = [z; x y f] end end

meer dan 2 jaar ago | 1

| accepted

Answered

ode45 Event Option

Duncan, I put the entire code into one file and slightly changed the code (ode calls), see attachment. Works for me. One more...

ode45 Event Option

Duncan, I put the entire code into one file and slightly changed the code (ode calls), see attachment. Works for me. One more...

meer dan 2 jaar ago | 0

Answered

How can I plot a function with parametric if (change between parameters)

Chris, this should do the trick r = 0:0.1:20; r0 = 12.5; t = 39.64*(r<=r0) + 51.4875*exp(0.14*(16.37 - r)).*(r>r0); ...

How can I plot a function with parametric if (change between parameters)

Chris, this should do the trick r = 0:0.1:20; r0 = 12.5; t = 39.64*(r<=r0) + 51.4875*exp(0.14*(16.37 - r)).*(r>r0); ...

meer dan 2 jaar ago | 0

| accepted