The following should give you some help.
A question that often arises amongst cruise passengers is how high a building can be seen from a ship at sea? A similar reverse question is how far can one see from the top of a building? An easy way to rephrase the question is to ask what is the distance from the top of a skyscraper to the horizon? Yet another is how high must you be to see a given distance t the horizon? Lets see if we can create a picture of the problem.
Draw yourself as large a circle as possible on a sheet of paper. Label the center O. Draw a vertical line from O to point A on the upper circumference. Extend the line past the circumference slightly to point B. Draw another line from O, upward to the right at an angle of ~30º to the vertical line, and intersecting the circumference at point C, our horizon point. Label OA and OC as r, the radius of the Earth. Label AB as h, the height of our make believe building. Label BC as d, the distance from the top of the building to the horizon or a ship at sea. Angle OCB = 90º.
From the Pythagorean Theorem, we can write that d^2 + r^2 = (r + h)^2 = r^2 + 2rh + h^2.
Simplifying, we get d^2 = 2rh + h^2 or d = sqrt[h(2r + h)].
The mean radius of the Earth is 3963 miles which is 20,924,640 feet.
Therefore, our distance d becomes d = sqrt[h(41,849,280 + h)].
If we wish to determine how far we can see from a building 1000 feet high, we need only compute d = sqrt[1000(41,849,280 + 1000)] = 204,573 feet or 38.7448 miles, ~38.74 miles.
If we were interested in determining how high a building we could see from a distance at sea, we need only solve our expression above for h which must make use of the quadratic formula. Rearranging our expression to h^2 + 2rh - d^2 = 0, we find that h = [-2r+/-sqrt(4r^2 + 4d^2)]/2 which simplifies to h = sqrt(r^2 + d^2) - r. Using our distance of ~38.75 miles calculated above, we can now solve for h = sqrt(20,924,640^2 + (38.75(5280)) - 20,924,640 which turns out to be 1000 feet.
Our expression for d can actually be simplifed somewhat due to the insignificance of h relative to r. We can easily rewrite the expression as d = sqrt(2rh) and not lose any accuracy to speak of. Taking it a step further, and since it is convenient to use h in feet, we can write d = sqrt[2(3963)miles(h)miles] = sqrt[1.5h].
Using our 1000 foot high building again with the simplified expression, we get d = sqrt[1.5(1000)] = 38.7298 miles or ~38.73 miles, or approximately 79 feet difference.
Unfortunately, we cannot simplify the expression for h as r and d are significant numbers.
Therefore, to determine how far in miles we can see from a building of height h ft., we use d = sqrt[1.5h].
To determine the height of a building we can see from a distance d off shore, we use h = sqrt(r^2 + d^2) - r, r and d in feet.
A sampling of some values:
h in feet....6......10.......25.......100......1000......5000....10,000......29,000.......528,000(100miles)
d in miles.188.8.131.52....6.12....12.25....38.75......86.6.....122.5........208.5............890
d in miles.1........5.......10........25.........50.........75........100..........200.............1000
h in feet..2/3...16.66....66.66..416.66..1666.66...3750....6666.66..26,666.66......666,666(126.25miles)
The originally posed question of how high a building one can see from a ship at sea can make use of the same data. For example, if you were on a ship 25 feet above the water, you would be able to see 6.12 miles to the horizon and could possibly just see the tip of buildings 100 feet high, 12.25 miles on the other side of the horizon or one 1000 feet high, 38.75 miles on the other side of the horizon. In other words, since you are looking just over the horizon for the top of the building, any height and distance from the table would be possible as the data represents the distances of a building h feet high to the horizon.
Another way of posing the shipboard sighting scenario is how high a building can one see given the distance of the building from the ship. If the distance is less than the calculated distance from the ship to the horizon for the given height above the water, any height building can be seen. If the distance is greater than the ship to horizon distance, then the other appropriate values of the table apply.