Welcome, Guest

Author Topic: Questions about orientation vector, axial tilt & related in US  (Read 4101 times)

Matyasz

  • *
  • Posts: 6
  • You can never know too much!
Hello everyone!

I actually have tons of questions, ideas etc., but I am kinda tired now, and want to break everything down into smaller bits... so this time, let's start with the most urgent one: axial tilt - or more properly, orientation & angular velocity vectors!

First and foremost, thanks to developers for the amazing (new) features, especially the improved charts and their exports into .csv, and particularly for using XML for savegames (=speaks human & accessible). Both allow extracting crucial information about objects in proper precision!

And this leads us to the topic! One of the most important parameters for an orbiting body is its obliquity (axial tilt), that is, the angle at which an object spins around its axis relative to it a specific reference plane (usually its orbit). In the simulator itself, this value is presented (along with yaw and argument of obliquity) as a calculated angle in the info > motion tab. However, as mentioned, this value must be calculated either from vectors or by other means.

The saves, however, do not present the actual angle (which is actually a good thing when working with state vectors). Instead, there is orientation and angular velocity vector with four and three values respectively. There are also position, velocity and rotational axis vectors. The angular velocity is related to the actual spin, which yields e.g. rotational period. However, I cannot figure out at all how to calculate axial tilt /argument of obliquity and after numerous trials and errors, I cannot wrap my head around it without asking for help.

So my question is, with the given vectors, how do you calculate the axial tilt / argument of obliquity & related values? I think the four-way orientation vector might be quartenion but so far either I'm not really understanding them well or am just completely lost as I never get correct values. Is there anyone who could possibly help me?

Oh, in case you are wondering why I'm doing all this despite having the correct values presented in the simulator... Well, I love learning new things, especially about astronomy!

Thank you for your time and patience! =)

tkulogo

  • *****
  • Posts: 135
Re: Questions about orientation vector, axial tilt & related in US
« Reply #1 on: June 12, 2020, 05:28:17 AM »
You can access save games as .csv and XML files? How do you do that?

Matyasz

  • *
  • Posts: 6
  • You can never know too much!
Re: Questions about orientation vector, axial tilt & related in US
« Reply #2 on: June 12, 2020, 09:39:42 AM »
You can access save games as .csv and XML files? How do you do that?

Yes you can - and that's quite easy to do, too! The .ubox files are essentially XML files, therefore kind of packages, so you can open them practically with any packaging program like 7zip, WinRar, WinZip etc. The only tricky part here is to make your PC/Mac understand that you want to open it that specific program.

When you do this the first time, just in case, make a backup copy so you won't mess up anything important.

1. Go to the savegame folder (User/Documents/Universe Sandbox/Simulations)
2. Open the desired file - if that won't work, I will explain further steps soon
3. In the packager, you should find multiple files/folders. The "simulation.json" contains the info about the bodies in your save, so that's usually the desired file.
4. Open the "simulation.json" by clicking, or dragging it to another folder (=extracting it) etc - several ways to do that really. Often it's easier to copy-paste all the jargon somewhere else.

Now, if opening the .ubox in a packager didn't work immediately (which happened to me), there are a few options:
1. On Windows, when clicking an unknown file type, you get the dialogue asking about the program which you want to use to open it. Select your desired packager and proceed.
2. Open the packager (WinRar, 7Zip etc.) and either drag the package there or open it from within the program
3. On Windows you can right click to properties and set/change the program you want to use. BTW, setting it to the simulator itself forces it to open the file there upon double-clicking, though I recall having some hiccups happening with that.

There are a few variant options to the above, but it's usually quite straightforward. The main trick is to force Windows to open the file (automatically) with the desired packager. Also, it has to be that, because there are indeed multiple files within, which is why directly opening on NotePad and such results in Gibberish.

I hope I all this makes sense and I didn't make this sound too complicated  ::)

tkulogo

  • *****
  • Posts: 135
Re: Questions about orientation vector, axial tilt & related in US
« Reply #3 on: June 15, 2020, 04:52:39 AM »
That wasn't complicated at all. Thank you.

It'll take me some time to write a script to convert my Excel data to the XML, but I think I'm well on my way to building a custom random system generator, and this may be the last piece of that puzzle. It'll still take me some time to put the puzzle together, but I expect I'll get there.

Matyasz

  • *
  • Posts: 6
  • You can never know too much!
Re: Questions about orientation vector, axial tilt & related in US
« Reply #4 on: June 15, 2020, 07:42:17 AM »
Oh, excellent! I am glad that was helpful  :)

I hope you succeed with your project, too! I'm actually doing the exact opposite - hence the whole original post. I am kind of self-learning astrophysics and I find it relaxing to solve complex physics/math problems... so I built an Excel document where I can input basic parameters, either imaginary values or using US/any other simulator suitable for purpose and then Excel calculates a good number of other parameters.

Before knowing about the trick with save files, I could only extract manually (with irregular precision), whatever the ongoing simulator provided, and my options for parameters were much more limited since I lacked the coordinates. This year I "upgraded" to Cartesian coordinates, thanks to the saves... Unfortunately, I got stuck with axial tilt, hence the OP. Technically I could ignore it, but it would be just amazing to include approximations like seasons, more detailed calendar, fun stuff like that, although not as relevant for astronomy itself.

BTW, note that none of the values in saves have units in them. Usually they are in the preferred SI-units, but sometimes it's harder to figure them out, like the preference of gauss over tesla in magnetic strength (tesla in SI, gauss in astrophysics).