Azzera filtri
Azzera filtri

How to write this b in matrix form

1 visualizzazione (ultimi 30 giorni)
Sam
Sam il 22 Apr 2014
Commentato: Sam il 23 Apr 2014
Can anyone help me write this b in matrix form in matlab?

Risposte (1)

Joseph Cheng
Joseph Cheng il 22 Apr 2014
Modificato: Joseph Cheng il 22 Apr 2014
Look for the patterns and you can build these efficiently.
n=100;
b=1:n;
b=b.^2;
b=b/(n+1)^4;
b(1)=b(1)+1;
b(end)=b(end)+6;
  3 Commenti
Joseph Cheng
Joseph Cheng il 22 Apr 2014
Modificato: Joseph Cheng il 22 Apr 2014
well i can't do everything for you. Talk about looking at a gift horse in the mouth. just transpose what i wrote or initialize b to be the correct size.
Sam
Sam il 23 Apr 2014
Wow chill man. I wasn't telling you to do everything. I just didn't know how to write this as a matrix form in matlab, that's all.

Accedi per commentare.

Categorie

Scopri di più su Get Started with MATLAB in Help Center e File Exchange

Tag

Community Treasure Hunt

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

Start Hunting!

Translated by