Problem 336. Similar Triangles - find the height of the tree
Given the height, h1, of a power pole, shorter than a tree, a given distance, x2 away, please find h2, height of the tree. Please note that the angle, phi, is the acute angle measured from the ground to an observer's line of sight aimed to the sucessive peaks of the power pole and the tree, in that order. Also the distance from the observer to the power pole is x1, also a given. x2 is the distance between the tree and the power pole. In all tests x1 is always a multiple of x2.
Inputs: h1, x1, x2
Output: h2
HINT: find phi, given h1 and x1. Phi may be measured in degrees or radians. Note that default trig functions in MATLAB operate in radians.
EX: x1 = 4; x2 = 4; h1 = 3;
>>h2=findHeight(x1,x2,h1)
h2=6
>>
Solution Stats
Problem Comments
-
6 Comments
@GeeTwo, The problem statement perfectly describes the question and what is asked of the user.
What you think is left out, is also mentioned -
"Please note that the angle, phi, is the acute angle measured from the ground to an observer's line of sight aimed to the sucessive peaks of the power pole and the tree, in that order."
mô tả khó hiểu
bài toán rất dễ nhưng lại mô tả rất khó hiểu
Solution Comments
Show commentsGroup

Advent of Code
- 25 Problems
- 5 Finishers
- Calculate days until Christmas
- How many Christmas presents under the tree?
- Snow Accumulation and Structural Risks To Residential Properties
- Scrabble Scores
- The twelve days of Christmas
- Calculate Wind Chill Factor
- Air Mass to Star for an Observer at Mean Sea Level
- Determine when snow started
- Mechanical Advantage of a Gear Train
- Similar Triangles - find the height of the tree
- Sleeping Queens 1
- Solve the Sudoku Row
- Fractal: area and perimeter of Koch snowflake
- Calculate Amount of Cake Frosting
- The cake is a lie...
- You LOVES Matlab 41%
- Minkowski distance
- Where the Four Corners Am I?
- Most Frequent Word - 01
- Design a tubesheet for shell-and-tube heat exchangers
- Lights Out 1 - 5x5, 3 moves
- Why the heck are they blinking!?!?
- Calculate the Distance to Source of Lightning
- Radiation Heat Transfer — View Factors (1)
- How many days?!?
Problem Recent Solvers448
Problem Tags
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!