Ask Question, Ask an Expert

+61-413 786 465

info@mywordsolution.com

Ask Java Expert


Home >> Java

Please Code this in java.

Design and construct a computer program in one of the approved languages (C, C++, C#, Java, Pascal, Python, etc.) that will illustrate the use of a third-order explicit Runge-Kutta method of your own design.

In other words, you will first have to solve the Runge-Kutta equations of condition for the coefficients of a third-order Runge-Kutta method. Then, you will use these coefficients in a computer program to solve the ordinary differential equation below.

The initial value problem to be solved is the following: x'(t) =1 + sin(12 t) x(t) subject to the initial condition: x(0) = 1.0 Obtain a numerical solution to this problem over the range from t=0.0 to t=2.0 for seven different values of the stepsize, h=0.1, 0.05 , 0.025 , 0.0125 , 0.00625 , 0.003125 , and 0.0015625 .

In other words, make seven runs with 20, 40, 80, 160, 320, 640, and 1280 steps, respectively. For each run, print out the value of h and then a table of t and x.

The answer at the end of the integration is about 2.9769173907278

Hint: It is often helpful to test your program on simple differential equations (such as x' = 1 or x'=t or x'=x) as a part of the debugging process.

Once you have worked these simple cases, then try working the nonlinear differential equation given above for the assignment (with a small stepsize).

Also, check your coefficients to make sure that they satisfy the equations of condition and that you have assigned these correct values to the variables or constants in your program properly.

For example, a common error is to write something like: a2 = 1/2; when you meant to write a2 = 1.0/2.0; so please be careful.

Write down (in your output file or in a text file) any conclusions that you can make from these experiments (e.g., what happens as h is decreased?).

Java, Programming

  • Category:- Java
  • Reference No.:- M93082660

Have any Question?


Related Questions in Java

Answer the following question whats the difference public

Answer the following Question : What's the difference public inheritance and private inheritance? What can derived classes inherit from base classes? What cannot be inherited from base classes?

Applied software engineering assignment 1 -learning

Applied Software Engineering Assignment 1 - Learning outcomes - 1. Understand the notion of software engineering and why it is important. 2. Analyse the risk factors associated with phases of the software development lif ...

Project requirementsfor the problem described in the next

Project requirements For the problem described in the next section, you must do the following: 1. include your student ID at the end of all filenames for all java code files. Three classes have been identified in section ...

Assignment - java program using array of objectsobjectives

Assignment - JAVA Program using array of objects Objectives - This assessment item relates to the course learning outcomes as stated in the Unit Profile. Details - For this assignment, you are required to develop a Menu ...

Object-oriented software development1 introduction 11

OBJECT-ORIENTED SOFTWARE DEVELOPMENT 1. Introduction 1.1 Assignment Requirement 1.2 Deliverables and Structure (what to submit) 1.3 Software Restrictions 1.4 How to score high... 1.5 Assumptions 2. System Requirements 2. ...

Part a specification - robot simulationpart a

PART A Specification - Robot Simulation PART A Requirements To complete this assignment you will use the supplied eclipse project Robot P1/. It is already set up to execute a simple arm movement loop which you will build ...

In relation to javaa what is constructor the purpose of

(In relation to Java) A. What is constructor? the purpose of default constructor? B. How do you get a copy of the object but not the reference of the object? C. What are static variables and instance variables? D. Compar ...

Assignment taskwrite a java console application that allows

Assignment task Write a java console application that allows the user to read, validate, store, display, sort and search data such as flight departure city (String), flight number (integer), flight distance (integer), fl ...

Assignment game prototypeoverviewfor this assessment task

Assignment: Game Prototype Overview For this assessment task you are expected to construct a prototype level/area as a "proof of concept" for the game that you have designed in Assignment 1. The prototype should function ...

Assessment database and multithread programmingtasktask 1

Assessment: Database and Multithread Programming Task Task 1: Grade Processing University grading system maintains a database called "GradeProcessing" that contains number of tables to store, retrieve and manipulate stud ...

  • 4,153,160 Questions Asked
  • 13,132 Experts
  • 2,558,936 Questions Answered

Ask Experts for help!!

Looking for Assignment Help?

Start excelling in your Courses, Get help with Assignment

Write us your full requirement for evaluation and you will receive response within 20 minutes turnaround time.

Ask Now Help with Problems, Get a Best Answer

Why might a bank avoid the use of interest rate swaps even

Why might a bank avoid the use of interest rate swaps, even when the institution is exposed to significant interest rate

Describe the difference between zero coupon bonds and

Describe the difference between zero coupon bonds and coupon bonds. Under what conditions will a coupon bond sell at a p

Compute the present value of an annuity of 880 per year

Compute the present value of an annuity of $ 880 per year for 16 years, given a discount rate of 6 percent per annum. As

Compute the present value of an 1150 payment made in ten

Compute the present value of an $1,150 payment made in ten years when the discount rate is 12 percent. (Do not round int

Compute the present value of an annuity of 699 per year

Compute the present value of an annuity of $ 699 per year for 19 years, given a discount rate of 6 percent per annum. As