subject

Consider a planet that follows an elliptical orbit. The perimeter of an ellipse with a major axis a and minor axis b is 4a V1 - k-sin-e do where k = Va? – b?. For a given a major axis a and minor axis b, calculate the distance the planet travels, by completing: a 1. the subfunction TrapzPlanet that uses trapeziodal numerical integration (using the internal function trapz) and a given number of discrete points.
2. the subfunction IntegratePlanet that uses the internal function integral.
Ex:
a = 3.01*10^ 9; b = 2.74*10^9; [trapzApprox, numIntegrate] = PlanetDistance(a, b, 1000) produces trapzApprox = 1.8074e+10 numIntegrate = 1.8074e+10 Function Save C Reset MATLAB Documentation 2 1 function [trapz Approx, numIntegrate] PlanetDistance(a, b, points) trapzApprox=TrapzPlanet(a, b, points); numIntegrate=IntegratePlanet(a, b); 4 end 3 5 6 function trapzApprox=TrapzPlanet(a, b,points) 7 8 % Your code goes here 9 10 end 11 12 function numIntegrate=IntegratePlanet(a, b) 13 14 % Your code goes here 15 16 end Code to call your function C Reset 1 a = 3.01*10^9; b = 2.74*10^9; 2 [trapzApprox, numIntegrate] = PlanetDistance(a, b, 1000)

ansver
Answers: 2

Another question on Computers and Technology

question
Computers and Technology, 21.06.2019 14:30
Including a space in the file name causes problems on all operating systems?
Answers: 1
question
Computers and Technology, 23.06.2019 01:20
Me with this program in c++ ! computers represent color by combining sub-colors red, green, and blue (rgb). each sub-color's value can range from 0 to 255. thus (255, 0, 0) is bright red. (130, 0, 130) is a medium purple. (0, 0, 0) is black, (255, 255, 255) is white, and (40, 40, 40) is a dark gray. (130, 50, 130) is a faded purple, due to the (50, 50, 50) gray part. (in other word, equal amounts of red, green, blue yield gray).given values for red, green, and blue, remove the gray part. ex: if the input is 130 50 130, the output is: 80 0 80. thus, find the smallest value, and then subtract it from all three values, thus removing the gray.
Answers: 3
question
Computers and Technology, 23.06.2019 02:30
These factors limit the ability to attach files to e-mail messages. location of sender recipient's ability to open file size of file type of operating system used
Answers: 2
question
Computers and Technology, 24.06.2019 03:00
What is one potential problem associated with an organization purchasing new technology early in its lifecycle
Answers: 1
You know the right answer?
Consider a planet that follows an elliptical orbit. The perimeter of an ellipse with a major axis a...
Questions
question
English, 21.10.2019 20:00
Questions on the website: 13722360