100% tevredenheidsgarantie Direct beschikbaar na je betaling Lees online óf als PDF Geen vaste maandelijkse kosten
logo-home
MATLAB Basic Programming New Exam With Verified Solutions Latest Update €14,78
In winkelwagen

Tentamen (uitwerkingen)

MATLAB Basic Programming New Exam With Verified Solutions Latest Update

 0 keer verkocht
  • Vak
  • MATLAB Basic Programming
  • Instelling
  • MATLAB Basic Programming

MATLAB Basic Programming New Exam With Verified Solutions Latest Update...

Voorbeeld 3 van de 21  pagina's

  • 11 november 2024
  • 21
  • 2024/2025
  • Tentamen (uitwerkingen)
  • Vragen en antwoorden
  • MATLAB Basic Programming
  • MATLAB Basic Programming
avatar-seller
MATLAB Basic Programming New Exam With Verified
Solutions Latest Update


What would the statement "myNum = 2 + 2" store in myNum? - ANSWER 4



Consider you want to generate, programmatically a vector of with 2 entries; whose 1st
entry starting at 0 and ends at 1. How would you create this vector in MATLAB? -
ANSWER x = linspace(0,1,2)



Whats another way to do this? - ANSWER 0:1:2



Now Suppose you want to automatically create a vector of 11 entries; the 1st entry
starting at 0 and ends at 1. How would you accomplish this in MATLAB? - ANSWER x =
linspace(0,1,11)



Whats another way to do this? - ANSWER 0:1:11



Now Suppose you want to automatically generate a vector with 8 entries; the 1st entry
starting at 0 and ends at 3. How would you create this vector in MATLAB? - ANSWER x =
linspace(0,3,8) or x = 0:3:8



How would you access the first twelve elements for y? - ANSWER y = (1:12);

x(1:12)



OR



y = (1:12);

x(1:12)

,How would you access the 1st four multiples of 3 specified in a vector? - ANSWER y([3 6
9 12])



Write a statement transposing x - ANSWER x'



Write two statements that notes the difference in tranpose of z - ANSWER z' and z.'



Elementary functions in MATLAB



Use the following few commands (a script) to make a plot. The evaluation of v=cos(u)
creates a vector whose elements are:

v(k) = cos(u(k)) where k = 1, 2, .n - ANSWER n = anu number;

u = linspace(0, 2*pi*n);

v = cos(u);

plot(u,v)



How would you clean up this plot? - ANSWER By plotting axis label and a title; the text
inside the single quotes is a string which we intend to be the labels.



xlabel('u');

ylabel('v');

title('v = cos(u)');



command "help plot" would be very helpful



Give a statement that would transpose a 3x4 matrix - ANSWER x = [1 2 3 4; 5 6 7 8; 9 10
11 12]; x' 1 2 3 4 5 6 7 8 9 10 11 12 ans = 1 5 9 2 6 10 3 7 11 4 8 12

, If the prior statement was "num1 = 5", how many will be in num2 after the sets of
statements "num1 = num1 + num1" "num2 = num1 + 3" What value is in num2? -
ANSWER 13; The interpreter determines the value of 5 + 5 to be 10 and assigns the 10 to
num1. The interpreter then determines the value of num1 + 3 to be 10 + 3 or 13 and
assigns 13 to num2.



If the statement entered prior to this was "num1 = 9", what would the value of num2 be
after the statement "num2 = num1 * num1"? - ANSWER 81



If all previous statements have dealt only with num1, num2, and num3, what value will
the statement "num4" print? - ANSWER error



If all previous statements have dealt only with num1, num2, and num3, what value will
the statement "num4" print? - ANSWER error



What symbol at the end of a statement suppresses printing of the result? - ANSWER ;
(semicolon)



Test your understanding of what will be output to the command window as a result of
entering the following lines.



1)

X = 14; Y = 2, Z = 5



Only X will display.

Only Y and Z will display.

None of the above. ANSWER Only Y and Z will display.



The semicolon inhibits the printing of X, commas don't inhibit printing.



C = 100 K = C + 273

Dit zijn jouw voordelen als je samenvattingen koopt bij Stuvia:

Bewezen kwaliteit door reviews

Bewezen kwaliteit door reviews

Studenten hebben al meer dan 850.000 samenvattingen beoordeeld. Zo weet jij zeker dat je de beste keuze maakt!

In een paar klikken geregeld

In een paar klikken geregeld

Geen gedoe — betaal gewoon eenmalig met iDeal, Bancontact of creditcard en je bent klaar. Geen abonnement nodig.

Focus op de essentie

Focus op de essentie

Studenten maken samenvattingen voor studenten. Dat betekent: actuele inhoud waar jij écht wat aan hebt. Geen overbodige details!

Veelgestelde vragen

Wat krijg ik als ik dit document koop?

Je krijgt een PDF, die direct beschikbaar is na je aankoop. Het gekochte document is altijd, overal en oneindig toegankelijk via je profiel.

Tevredenheidsgarantie: hoe werkt dat?

Onze tevredenheidsgarantie zorgt ervoor dat je altijd een studiedocument vindt dat goed bij je past. Je vult een formulier in en onze klantenservice regelt de rest.

Van wie koop ik deze samenvatting?

Stuvia is een marktplaats, je koop dit document dus niet van ons, maar van verkoper Easton. Stuvia faciliteert de betaling aan de verkoper.

Zit ik meteen vast aan een abonnement?

Nee, je koopt alleen deze samenvatting voor €14,78. Je zit daarna nergens aan vast.

Is Stuvia te vertrouwen?

4,6 sterren op Google & Trustpilot (+1000 reviews)

Afgelopen 30 dagen zijn er 69411 samenvattingen verkocht

Opgericht in 2010, al 15 jaar dé plek om samenvattingen te kopen

Start met verkopen
€14,78
  • (0)
In winkelwagen
Toegevoegd