Algorithm for subfunction, MATLAB in Engineering

Algorithm for subfunction:

The algorithm for subfunction askforn is as shown:

  •  Prompt the user for the positive integer n.
  •  Loop to print an error message and reprompt awaiting the user enters a positive integer.
  •  Return the positive integer n.

 

Posted Date: 10/19/2012 8:33:59 AM | Location : United States







Related Discussions:- Algorithm for subfunction, Assignment Help, Ask Question on Algorithm for subfunction, Get Answer, Expert's Help, Algorithm for subfunction Discussions

Write discussion on Algorithm for subfunction
Your posts are moderated
Related Questions
Algorithm for subfunction: The algorithm for subfunction askforn is as shown:  Prompt the user for the positive integer n.  Loop to print an error message and reprom

Vector operations: As vectors are special cases of matrices, the matrix operations elaborated (addition, subtraction, multiplication, scalar multiplication, transpose) work on

Function strncmp: The function strncmp compares only the first n characters in the strings and ignores the rest. The initial two arguments are strings to compare, and third ar

IS Functions in Matlab: There are many functions which are built into MATLAB which test whether or not something is true; these function names start with the word is. As these

Example of file ploting data: As the other example, a data file called 'compsales.dat' stores the sales figures (in millions) for divisions in a company. Each line in the f


Illustration of Set operations: For illustration, given the vectors as shown below: >> v1 = 2:6 v1 = 2  3  4  5  6 >> v2 = 1:2:7 v2 = 1  3  5  7

function imread: The function imread can read an image file, for illustration a JPEG (.jpg) file. The function reads color images into a 3-dimensional matrix. >> myimage1

True color matrice: The true color matrices are the other way to represent images. The true color matrices are 3-dimensional matrices. The first two coordinates are the coordi

Tracing of Square matrices: The trace of a square matrix is the addition of all the elements on the diagonal. For illustration, for the preceding matrix it is 1 + 6 + 11 + 16,