Rotating an image


here in the first map i need to plot an image at 25E, 25N and the default of the perspective is [-p180/90] but when i change the azimuth the image leaves its original location and i can’t understand how the perspective work, I need to rotate the image in its location.

here is my script:
gmt begin image png
gmt coast -JM20c -R10/50/10/50 -G120 -A1000000 -Ba1f1g1
gmt image airplane.png -Dg25/25+w2c+jCM -p180/90
gmt end show

the second one:
gmt begin image png
gmt coast -JM20c -R10/50/10/50 -G120 -A1000000 -Ba1f1g1
gmt image airplane.png -Dg25/25+w2c+jCM -p120/90
gmt end show

The perspective is applied around a reference point which is either a corner or the center of the plot. -p accepts a modifier (-p+[…]]) that allows you to rotate the image at a location

1 Like

You would be way better off treating this as a custom symbol that accept an azimuth instead of plotting images on top.

1 Like

I tried +vx0/y0 and it works but it takes x and y values and needs trial and error, I ask if there is way to use long/lat instead

gmt begin image png
gmt coast -JM20c -R10/50/10/50 -G120 -A1000000 -Ba2f1g2
gmt image airplane.png -Dg30/30+w2c+jCM -p100/90+v10/10.80
echo 30 30 | gmt plot -Sc.5c -Gred
gmt end show

Hence my reply to turn this into a custom symbol and it just plotting it like anything else with plot -S.

1 Like

Ok, thank you so much I will try it

I’d be surprised if @KristofKoch doesn’t have a collection of airplains.

@MahmoudMagdy0 you want to take a closer look at plot -Sk and the corresponding chapter in the Cookbook. The easiest way for you is to have your aircraft symbol as an Encapsulated PostScript (.eps) file. Then you have all the possibilities plot -S offers at your fingertips.

107134740-24496c80-68f5-11eb-9038-44e6ad31332a

1 Like

Thank you; I’ll take a look at how to do that.

What’s the curvature of that airplain?

1 Like

More than you would want…

Curvature?

I think @Joaquim refers to the huge size of the plane :wink:

Yeap. A flat plain would have its belay at the Atlantic and Tail & Cockpit in the Stratosphere.

Yay! Time for some totally off-topic, nonsense but hopefully entertaining information and number crunching!

Real world:
According to the standard atmosphere model the tropopause, the atmospheric boundary that demarcates the troposphere from the stratosphere, lies in about 11,000 m or 36,000 ft altitude. The maximum operating altitude for the Boeing B747-8i (depicted in the plot above) is 43,100 ft (13,137 m). So regular commercial real-world flying can take you up into the stratosphere already.

Since the tropopause responds to the average temperature of the entire layer that lies underneath it, it is at its peak levels (up to 18,000 m) over the Equator, and reaches minimum heights (down to 8,000 m) over the poles. So it depends if you really get to fly in the stratosphere.

You can check by looking at the outside air temperature (OAT) shown in your inseat entertainment system. If it indicates at or below -56.5 °C you are at or above the tropopause and in the stratosphere. It usually won’t indicate lower than -56.5 °C as the OAT in the lower stratosphere above the tropopause remains constant for about 10 km.

The usual cautions when comparing a nice model with the harsh real world apply.

Now on to the nonsense fun part:

  • In that plot the aircraft has a length of about 60° of latitude. That translates to an aircraft length of 3,600 NM or 6,667.2 km.
  • NASA says the volumetric mean radius of Earth is 6,371 km and for our little fun here Earth is a sphere.

As the belly touches the surface of Earth, we are only interested in half that aircraft length when we ask that old guy Pythagoras for some help:

sqrt( (Earth radius)² + ((aircraft length) / 2)² ) - (Earth radius) = height of aircraft nose above the surface.

= 819.4 km – space begins at the Kármán line at 100 km

The aircraft nose and tail would be well in space – higher than the International Space Station (orbits Earth in 330-410 km altitude) out in the exosphere!

It would be survivable as the aircraft is rated for a maximum differential pressure of 9.4 psi (0.65 bar). You just need to keep the partial oxygen pressure of the air you breathe above 20 % by donning one of the oxygen masks falling from the panel above you.

And here, for some perspective, a nice graphic from Wikipedia to get an idea of the dimensions of our atmosphere:


Lets see if I made some grave mistake somewhere … please feel free to correct me!

3 Likes

I give you a Honor grade :slight_smile: