Arguments a minimum value and a maximum value

Assignment Help JAVA Programming
Reference no: EM13850005

To complete this homework assignment, turn in a m-file containing the MATLAB code that you generate in response to each problem.

1. Write a function that takes as arguments a minimum value and a maximum value and plots sin(x) from the specified minimum to the specified maximum.

2. Write a function that takes as an argument a single vector x. The function should set a new vector y equal to x and plot y as a function of x. Then, it should add noise to the y data points by adding or subtracting a random value between 0 and 25% of the original y value.

The new "noisy" data points should be plotted on the same axes as the original data points, such that both plots appear simultaneously.

3. A bar is a unit of pressure. Polyethylene water pipes are manufactured in pressure grades, which indicate the amount of pressure in bars that the pipe can support for water at a standard temperature. The following script printpressures prints to the screen some common pressure grades, as well as the equivalent pressures in atmospheres (atm) and pounds per square inch (psi). The conversions are:

1 bar = 0.9869 atm = 14.504 psi

The script calls a function to convert from bars to atm and psi and calls another function to print the results. Write these functions. printpressures.m:

%prints common water pipe pressure grades

commonbar = [4 6 10];

for bar = commonbar

[atm, psi] = convertbar(bar);

print_press(bar, atm, psi) end

Reference no: EM13850005

Questions Cloud

Demonstrate strong corporate ethics : lease discuss the ethical lessons that you learned in this class that will help you in the future. Research a company that demonstrates strong corporate ethics and discuss why the company is a good example of corporate ethics, leadership and applic..
How miranda vs arizona and subsequent rulings apply : Students will analyze the following fact pattern and discuss how Miranda v. Arizona and subsequent rulings apply. Four police officers storm an apartment of a suspected drug trafficker with a history of illegal firearm possession
Develop a logical database design : Develop a logical database design (relational schema) for the conceptual data model shown at the end of this document. All relations in your logical database design should be normalized to the third Normal form (3NF).
Develop a health and physical education literature review : Develop Physical Education Literature review - Discuss and conclude by highlighting key -big picture? changes that have taken place in PE/HPE
Arguments a minimum value and a maximum value : Write a function that takes as arguments a minimum value and a maximum value and plots sin(x) from the specified minimum to the specified maximum.
Write a report about tourism in south africa : Write a report about Tourism in South Africa. Introduction (200-250 words) - Should include Justification of choice of region -negatives - political, economical, legal, safety security issues.
Discuss the steps involved in a bill becoming a law : Discuss the steps involved in a Bill becoming a Law. Is the path too arduous or too easygoing? Do such hurdles prevent too many good bills from becoming laws. Are the steps involved in a bill becoming a law necessary and why
Object oriented programming-getting started with classes : Suppose you are car shopping and want to store information about possible choices. Model, and implement an automobile class. Use a UML drawing tool such as Umbrello or Microsoft Visio to create a class diagram. Your class should have at least cons..
Explain aspects of marketing and strategic planning : analyze the connection between these aspects of marketing and strategic planning. Why is it important for these elements of marketing efforts to be tied to a strategic plan

Reviews

Write a Review

JAVA Programming Questions & Answers

  Writing an applet with graphics in this programming

writing an applet with graphics in this programming activity you will write an applet that uses graphics. you will draw

  Write a mathematical recursive definition

Write a mathematical, recursive definition of p(n) - Prove that your answer to Part a is correct by using mathematical induction.

  Reimplement the labeledpoint class of exercise

Reimplement the LabeledPoint class of Exercise P9.12 by storing the location in a java.awt.Point object. Your toString method should invoke the toString method of the Point class.

  Develop the implementation file student.cpp

Required to implement the class to develop the implementation file Student.cpp that conforms to the following specifications

  Creates pet objects from data read from the keyboard

The assignment is to write a program that creates Pet objects from data read from the keyboard. Store these objects into an instance of ArrayList.

  Write a java program that would simulate a number of cars

Write a JAVA program that would simulate a number of cars' (e.g. 4) speed meter using the concept of Multithreading. A car's speed can be both increased and decreased using specified keys from the keyboard

  Create a class that calls that parse method

Use the Java API documentation to examine the SimpleDateFormat class and find the exception thrown by its parse() method. Create a class that calls that parse() method.

  Considered to be an improved version

Part (c) is considered to be an improved version of Part (b). You may use an array (2-dimessional) to store some values that has been computed during the run so that when making recursive calls the program does not compute certain values over and ..

  Write the constructor date which has 3 parameters

The Date.java class. Implement a public class Date that represents a date composed of a month , day, and a year. Declare month, day, and year as integers. Date has a constructor with 3 parameters and 4 methods. Write the constructor Date which has..

  Accepts a scanner representing an input file

Write a method in JAVA called stripHtmlTags that accepts a Scanner representing an input file containing an HTML web page as its parameter, then reads that file and prints the file's text with all HTML tags removed. A tag is any text between the c..

  Design a class named linearequation

(Algebra: 2 X 2 linear equations) Design a class named LinearEquation for a 2 X 2 system of linear equations.

  Java program to read line of text which ends with period

Write down the java program which will read the line of text which ends with the period, which serves as sentinel value. Show all the letters which occur in the text.

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd