2nd Order Newtonian Formulation

1 view (last 30 days)
Aisha Shamim
Aisha Shamim on 24 Apr 2019
X = I; % independent variable
Y = J'; % have to transpose the vector
a = length(X) % # of data points given
A - zeros(a) % creates an empty matrix
for c = 1:a
for r =1:a
if c == 1
A(r,c) = 1;
elseif c <= r
A(r,c)
end
end
end
b = A\Y
disp(A)
disp(Y)
disp(b)
_______________________________________________________________________________________________________________________________________
You don't get values for I and J, my teacher only said which one is the independent variable and which one is the dependent variable, so I am confused how you can get real number out of this code.

Answers (0)

Categories

Find more on Language Fundamentals in Help Center and File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!