Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

This is a program that is designed to be used in the field for # collecting and

ID: 3730145 • Letter: T

Question

This is a program that is designed to be used in the field for # collecting and processing forest inventory data using a GPS unit # capable of running Python scripts. mpozt numpy as np class Plot: PI, 3.14 # sets up the different variables and # assigns them to default values below def (self) : init self.plot ID Plot" self.radius 1 self.units'feet' seif.tree count 100 self.biomass100 self.PI3.14 - def set plot ID (self, plot_id) : # Sets the ·plotID. - self..-plot-ID plot-id Seta the velue of radius' Sets the value of 'units Sets the value of ·tree-count. def set radius (self, radius): self.radiusradius der set units (self, units): self. unit ," unitB def set-tree-count (self, tree-count): self.tree count tree count def set biomass (self, biomasa): t Sets the value of 'biomass' self. biomass - biomass def get plot ID (self): # Gets the ·plot1D' - zeturn self'--plot. ID der get radius (self): def get units (self): def get tree count (selE): def get biomass (self): # Gets the value of 'radius' return self. radius # Gets the value of 'units" return self. units # Gets the value of "cree count. zeturn self.tree count # Gets the value of 'biomass. return self. biomass det get area (self): # Gets the area of the plot in acres. return self.PI loat (self.get radius )) float (self.get_ radius)) def get trees acre (self) : Returns the number of trees per acr. area in feetsquare self.get_area ) area in acre rloat (area in feetsquare / 43560) azea in meteraquare self.get area ()

Explanation / Answer

In the function in get_area(), you need to change the self.__PI to self.PI. The error is because the instance variable names are not matching. In the constructor, you are initializing as self.PI where as in get_area(), you are using self.__PI . So please change the variable name in get_area(). It should work. Hope it helped.

Hire Me For All Your Tutoring Needs
Integrity-first tutoring: clear explanations, guidance, and feedback.
Drop an Email at
drjack9650@gmail.com
Chat Now And Get Quote