I'd do a batch file to call Stellarium
then add the redirect the outout to file command.
> myoutput.txt
So
Stellarium.exe > myoutput.txt
Pause
That will cause everything to be written to a text file so you can read it all.
Not saying this is wrong as I've never seen the program but
latitude + wind1 - wind2 + speed1 - speed2
In most programming is written in brackets ()
(((latitude + wind1) - (wind2 + speed1)) - speed2))
Or such. Depends on
exactly how the math needs to be done and the programming language.
You can actually see an example in your script.
((speed + 1) * .0083125))
So
latitude + wind1 - wind2 + speed1 - speed2
throws an error in my mind just trying to figure out the correct math!
No insults intended but the Devil is in the details!