photo

Murad Alzahrani


Last seen: 4 years ago Active since 2019

Followers: 0   Following: 0

Statistics

Feeds

View by

Question


Question about Forward time center space 1D matlab code
Hi. I tried make code I can solve this problem in Forward time center space 1D: As you see, but my code naver show me complet...

4 years ago | 0 answers | 0

0

answers

Question


Out of memory. The likely cause is an infinite recursion within the program.
function [out] = Vout(t) D=5;% feet H=10;% feet yi=7;% ft (initial water level) ysp=5;% ft DT=30; % seconds amount of tim...

5 years ago | 2 answers | 0

2

answers

Question


help for fprintf my code
function [out] = slope(t,G) k1=10;k2=20;m1=2;m2=4; v1=G(1); x1=G(2);v2=G(3);x2=G(4); out(1)=(-k1*x1+k2*(x2-x1))/m1; out(2)=v...

5 years ago | 1 answer | 0

1

answer

Question


how I can delete 1.0e+03 in my answer
clc;clear; tf=10; n=1; dt=0.1; t(n)=0.1; G1(n)=1; G2(n)=0; G3(n)=-1; G4(n)=0; m(n,:)=[1 0 -1 0]; while t(n)<=tf t(n...

5 years ago | 1 answer | 0

1

answer

Question


Index exceeds the number of array elements (1).
clc;clear; tf=10; n=1; t(n)=0.1; dt=0.1; G1(n)=1; G2(n)=0; G3(n)=-1; G4(n)=0; m(n,:)=[1 0 -1 0]; while t(n)<=tf m(n...

5 years ago | 1 answer | 0

1

answer

Question


Array indices must be positive integers or logical values.
function [out] = slope(t,G1,G2,G3,G4) k1=10;k2=20;m1=2;m2=4; out(1)=(-k1*G2+k2(G4-G2))/m1; out(2)=G1; out(3)=-k2(G4-G2)/m2...

5 years ago | 1 answer | 0

1

answer

Question


How make code has 2 vectors as input and make loop than find output as vector
Hi everyone. I need know how I can make code I can put two vectors and use them in loop to find another vector as output. ...

5 years ago | 1 answer | 0

1

answer

Question


How writing code sum 1+2+3+4+...+n
Hi. How I can writing code in MATLAB sum 1+2+3+4+..+n and I can change ( n ) to any numbers and MATLAB can sum for me. Thank y...

5 years ago | 2 answers | 0

2

answers