EP WEBASSIGN FOR MOAVENI'S ENGINEERING
EP WEBASSIGN FOR MOAVENI'S ENGINEERING
6th Edition
ISBN: 9780357126592
Author: MOAVENI
Publisher: CENGAGE CO
bartleby

Concept explainers

Question
Book Icon
Chapter 15, Problem 1P

(a)

To determine

Using the MATLAB Help menu discuss how the function ABS(X) used.

(a)

Expert Solution
Check Mark

Explanation of Solution

In MATLAB, go to Help, it shows the documentation, examples, wed support, and academy symbols. Open the documentation then search for the specific functions, it will provides the syntax function then click on it, will shows the information about each of the function.

Search for the function ABS(X), the function ABS(X) is used to display the absolute value of the real values and complex values.

Example 1:

In the MATLAB command window type the code as follows,

X=-5;

abs(X)

The output will be displayed as follows,

ans =

     5

Example 2:

In the MATLAB command window type the code as follows,

X=-5+6*i;

abs(X)

The output will be displayed as follows,

ans =

    7.8102

Conclusion:

Thus, the function ABS(X) has been explained.

(b)

To determine

Using the MATLAB Help menu discuss how the function TIC, TOC used.

(b)

Expert Solution
Check Mark

Explanation of Solution

Now Search for the command, it is TIC is used to start a stopwatch timer and the command TOC is used to print the number of seconds required for the operation. Both are used to find the program elapsed time.

Example:

In the MATLAB command window write the code as follows,

tic

P = rand(1000,300);

Q = rand(1000,300);

toc

C = P'.*Q';

toc

Its output displays as below, but it is changes every time as the execution time elapsed different time length for each execution,

Elapsed time is 0.049194 seconds.

Elapsed time is 0.067125 seconds.

Conclusion:

Thus, the function TIC, TOC has been explained.

(c)

To determine

Using the MATLAB Help menu discuss how the function SIZE(x) used.

(c)

Expert Solution
Check Mark

Explanation of Solution

Now search for the SIZE (x), it is the two vector function which determines the number of rows and columns in the M by N matrix.

Example:

Consider the matrix as follows:

x=[123456789]

In the MATLAB command window write the code as follows,

x=[1 2 3;4 5 6;7 8 9];

D=size(x)

The output will be displayed as follows,

D =

     3     3

Conclusion:

Thus, the function SIZE(x) has been explained.

(d)

To determine

Using the MATLAB Help menu discuss how the function FIX(x) used.

(d)

Expert Solution
Check Mark

Explanation of Solution

Now search for the command FIX(x) in Help tab, it is used to round the element of x to the nearest integer towards zero.

Example:

In the MATLAB command window write the code as follows,

x=3.48;

fix(x)

The output will be displayed as follows:

ans =

     3

Conclusion:

Thus, the function FIX(x) has been explained.

(e)

To determine

Using the MATLAB Help menu discuss how the function FLOOR(x) used.

(e)

Expert Solution
Check Mark

Explanation of Solution

The command FLOOR(x) is used to round the element of x to the nearest integer towards negative infinity.

Example:

In the MATLAB command window write the code as follows,

x=-3.67;

floor(x)

The output will be displayed as follows,

ans =

    -4

Conclusion:

Thus, the function FLOOR(x) has been explained.

(f)

To determine

Using the MATLAB Help menu discuss how the function CEIL(x) used.

(f)

Expert Solution
Check Mark

Explanation of Solution

In MATLAB Help tab search the function, the command CEIL(x) is used to round the element of x to the nearest integer towards infinity.

Example:

In the MATLAB command window write the code as follows,

x=3.67;

ceil(x)

The output will be displayed as follows,

ans =

     4

Conclusion:

Thus, the function CEIL(x) has been explained.

(g)

To determine

Using the MATLAB Help menu discuss how the function CALENDAR used.

(g)

Expert Solution
Check Mark

Explanation of Solution

The CALENDAR function is a 6×7 matrix used to display the calendar for a specified or current month. The first column ‘S’ of the matrix is corresponds to Sunday. It is also expressed as CALENDAR(DATE) by default displays January month date, CALENDAR(Year, Month) and CALENDAR(Month, date).

Example 1:

In the MATLAB command window write the code as follows,

calendar (1989,10)

The output will be displayed as follows,

                   Oct 1989

     S     M    Tu     W    Th     F     S

     1     2     3     4     5     6     7

     8     9    10    11    12    13    14

    15    16    17    18    19    20    21

    22    23    24    25    26    27    28

    29    30    31     0     0     0     0

     0     0     0     0     0     0     0

Example 2:

In the MATLAB command window write the code as follows,

calendar (8,10)

The output will be displayed as follows,

                    Oct 0008

     S     M    Tu     W    Th     F     S

     0     0     0     1     2     3     4

     5     6     7     8     9    10    11

    12    13    14    15    16    17    18

    19    20    21    22    23    24    25

    26    27    28    29    30    31     0

     0     0     0     0     0     0     0

Conclusion:

Thus, the function CALENDAR has been explained.

Want to see more full solutions like this?

Subscribe now to access step-by-step solutions to millions of textbook problems written by subject matter experts!
Students have asked these similar questions
Note: (please show handwritten answers, and no AI usage !) Provide a clear, step-by-step handwritten solution (without any detailed explanations). Ensure the work is simplified and completed manually, adhering to expert-level accuracy. Refer to the provided image for clarity and ensure all calculations are double-checked for correctness before submission. Thank you!.   Question 1:  A cylindrical soil sample is connected to two water reservoirs: a) Determine the pressure, elevation, and total head at a point one meter above the bottom of the sample (point A). b) Calculate the pore pressure and effective stress at point A if the soil has a saturated unit weight of 18.7kN/m^3. c) Determine the water flow rate though the sample if the soil has a coefficient of permeability of 0.19 cm/s and the radius of the sample is 20 mm. d) Is it possible for the soil to reach the “quick condition”(zero effective stress) by raising the level of the water in the upper reservoir? Why or why not?. Question…
Note: Please provide a clear, step-by-step simplified handwritten working out (no explanations!), ensuring it is done without any AI involvement. I require an expert-level answer, and I will assess and rate based on the quality and accuracy of your work and refer to the provided image for more clarity. Make sure to double-check everything for correctness before submitting thanks!. Questions 1: A clay rich soil is totally saturated, has a bulk density of 2.12 g/cm3, and a void ratio of 0.33. a) Draw the full three phase diagram for this soil including all the volume and mass quantities. b) Determine the density of the soil solids. c) Determine the total density of the soil if the saturation was reduced to 50%.   Question 2: A soil sample was tested yielding the following grain-size distribution chart: (refer to the image provided) The soil fines (inorganic) were also tested and had a liquid limit of 76 and a plastic limit of 49 Determine the coefficients of uniformity and curvature.…
Note: Provide a clear, step-by-step handwritten solution (without any detailed explanations). Ensure the work is simplified and completed manually, adhering to expert-level accuracy. Refer to the provided image for clarity and ensure all calculations are double-checked for correctness before submission. Thank you!.   Question 1:  A cylindrical soil sample is connected to two water reservoirs: a) Determine the pressure, elevation, and total head at a point one meter above the bottom of the sample (point A). b) Calculate the pore pressure and effective stress at point A if the soil has a saturated unit weight of 18.7kN/m^3. c) Determine the water flow rate though the sample if the soil has a coefficient of permeability of 0.19 cm/s and the radius of the sample is 20 mm. d) Is it possible for the soil to reach the “quick condition”(zero effective stress) by raising the level of the water in the upper reservoir? Why or why not?. Question 2: A new structure is planned to be constructed in…
Knowledge Booster
Background pattern image
Civil Engineering
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, civil-engineering and related others by exploring similar questions and additional content below.
Similar questions
SEE MORE QUESTIONS
Recommended textbooks for you
Text book image
Engineering Fundamentals: An Introduction to Engi...
Civil Engineering
ISBN:9781305084766
Author:Saeed Moaveni
Publisher:Cengage Learning
Text book image
Residential Construction Academy: House Wiring (M...
Civil Engineering
ISBN:9781285852225
Author:Gregory W Fletcher
Publisher:Cengage Learning
Text book image
Fundamentals Of Construction Estimating
Civil Engineering
ISBN:9781337399395
Author:Pratt, David J.
Publisher:Cengage,
Text book image
Architectural Drafting and Design (MindTap Course...
Civil Engineering
ISBN:9781285165738
Author:Alan Jefferis, David A. Madsen, David P. Madsen
Publisher:Cengage Learning