Tuesday, February 25, 2020

Matlab Assignment Example | Topics and Well Written Essays - 1250 words - 1

Matlab - Assignment Example This was confirmed through comparing the result with that of the plot. 5. The area of the land above the planned road was obtained using integration method (trapezoid method) to find the total area under the curve and subtracting the total area of the area of land under the planned road. This was achieved through the matlab trapz () On using the d =diff(sign(y-s)) function where s was the equation for the best fit and y was for the terrain curve the non zero points were obtained.-2 and 2 were the non zero points which corresponded to respective x points.those x points are as shown below It was noted that those points corresponded with the x points where the two curves intersected.These points were displayed in pairs(first one showing the x point for the start of the region and second one showing the end point for the region)e.g Next the program requests the user to enter the number of regions in the graph. In our case they were 7.This was made in order to allow the user more control over the area calculation and reduce errors. The program calculates the area of the region under the curve subtracts the region under the best fit then sums it up. It then asks for the second points. Calculates the area then adds it to the total. At the end of the last region it multiplies the area with 10(road width and gives the total volume Thread Subject: How to find position of specific vector value. (n.d.). How to find position of specific vector value. Retrieved May 8, 2014, from

Saturday, February 8, 2020

The Substance Abuse Treatment Program in North Dakota Assignment

The Substance Abuse Treatment Program in North Dakota - Assignment Example As such, DCS does not have the instruments of coercion with which to handle violent outbreaks and acts of lawlessness which characterize incarceration. Offenders facing drug charges are to be treated immediately they are established to be addicted to hard drugs such as narcotics and are brought under prison custody. What informs this proposition is the need to foster public and prison health and safety. It is dangerous to have cocaine addicts in prison. The addict may have a violent predisposition or die because of the inability to access the drugs. Drug treatment for hard-drug addicted offenders will also help win the war on drugs. Drugs such as cigarettes may not fall within this rubric due to their relatively mild effects. Ideally, people facing drug charges are to be incarcerated when they are: peddling the hard drugs and substances; engaging in and abetting criminal activities such as forceful conscription into drugs; proven to be dangerous to others and to public order. From a personal standpoint, the most effective drug treatment method is the administration of psychosocial therapy. This is because psychosocial therapy factors the role of the individual and the strength of his will in defeating addiction. According to Gladding, and Wallace, psychosocial therapy in drug rehabilitation is vindicated by the fact that most people have recovered from drug addiction on their own and that the success or failure of any drug rehabilitation program pivots on personal will (Gladding and Wallace, 22, 23).  Ã‚