Wikiposts
Search

Notices
Private Flying The forum for discussion and questions about any form of flying where you are doing it for the sheer pleasure of flight, rather than being paid!

Rainy day tasks

Thread Tools
 
Search this Thread
 
Old 28th April 2014 | 13:42
  #1 (permalink)  
Thread Starter
 
Joined: Apr 2008
Posts: 1,086
Likes: 36
From: France
Rainy day tasks

Greetings to all ppruning in this foul weather. I am trying in my fumbling way to automate a spreadsheet that will give me heading to fly (true is fine) and groundspeed given TAS, wind, and track required. My problem is not the formula as such but how to insert the variables on an .xls spreadsheet. Is there anyone here with a higher geek rating who could show me an example?
The actual spreadsheet is done as far as pretty goes but isn't much use as it doesn't yet do the calculations. Here is the link to it in my dropbox....

A6 Plog

In case anyone is feeling kind. I realise I will need two cells for wind speed and direction, but that is as far as my brain takes me.
Piper.Classique is offline  
Reply
Old 28th April 2014 | 15:27
  #2 (permalink)  
 
Joined: Jul 2010
Posts: 2,807
Likes: 10
From: Ansião (PT)
Mine has a second tab with a list of possible waypoints.
When I reference these in the main calc sheet, their coordinates are looked up from the list and serve as the base for calculations.
Jan Olieslagers is offline  
Reply
Old 28th April 2014 | 20:34
  #3 (permalink)  
Thread Starter
 
Joined: Apr 2008
Posts: 1,086
Likes: 36
From: France
Sorry Jan, I'm not following you there. I just want my spreadsheet to solve a wind triangle using the cosine rule, given the known vectors of track and distance required, wind, and TAS. But I don't know how to integrate this into a spreadsheet. The layout suits me, but I don't want to have to do a manual calculation. I can't possibly put in a list of waypoints in advance of knowing where I intend to go.
Piper.Classique is offline  
Reply
Old 28th April 2014 | 20:46
  #4 (permalink)  
20 Anniversary
 
Joined: Jul 2005
Posts: 99
Likes: 0
From: LFBO
Try Ed Williams' Aviation formulary. I think it has some examples already set out in excel. http://williams.best.vwh.net/ftp/avsig/avform.xls
Been Accounting is offline  
Reply
Old 28th April 2014 | 20:46
  #5 (permalink)  
Administrator
 
Joined: Mar 2001
Aviation Qualifications: PPL
Posts: 8,121
Likes: 686
From: Twickenham, home of rugby
You may struggle to do an iterative calculation like this one accurately in a spreadsheet.

Not wanting to teach grandma to suck eggs, but have a look at this thread from last year: http://www.pprune.org/private-flying...elocities.html

SD
Saab Dastard is offline  
Reply
Old 28th April 2014 | 22:13
  #6 (permalink)  
 
Joined: Feb 2007
Posts: 4,598
Likes: 0
From: Amsterdam
Or is your question just a basic Excel usage one?

Excel doesn't do "variables" as such. Instead, you put a value in a cell. And that cell is referenced later on.

Here's an example. Your "advertised" stall speed (Vs, or the bottom of the green arc) is in cell B2. You now want to know your stall speed under a certain load factor (which, itself, may be derived from the angle of bank.) Say, the load factor (G) is stored in cell B3 and the result should be in cell B4. Then B4 should have the contents

=B2*SQRT(B3)

It's that simple. If the contents of a cell start with an equal sign, it means it's a formula. And within that formula you can use the normal mathematical operators (+, -, *, / and so forth), functions such as SQRT, SUM and a whole library of others, numerical values and references to other cells.

There is a little known catch though. You can refer to a cell as B2, or as $B$2 (or as B$2 or $B2 - it depends on what you want to achieve). In the first case, if you copy and paste cell B4 (the formula) to cell C4, then the formula will automatically be changed into =C2*SQRT(C3). In the second case, $B will remain $B despite the downwards copy & paste. So if you are referring to cells that hold constants or one-time values in your formula, best to refer to them as $B$2 so if you copy & paste any formulas, the cell reference will remain unchanged. But if you copy and paste formulas that refer to values that are stored in tables themselves, it's better to refer to them as B2. The dollar sign sort-of "locks" the row or column, so it doesn't change when doing a cut&paste.
BackPacker is offline  
Reply
Old 29th April 2014 | 04:55
  #7 (permalink)  
 
Joined: Jul 2010
Posts: 2,807
Likes: 10
From: Ansião (PT)
If BackPacker's answer is what you needed, let me re-phrase it: if you need extra intermediate variables, the only way is to have an extra column for them. Mind you these "intermediate variables" columns would be confusing the presentation, BUT they can be hidden from view (select column(s) , right click, "hide" ).

In my own, only columns A-H-K-L-M-U-V-W-X show, all others are hidden.
Jan Olieslagers is offline  
Reply
Old 29th April 2014 | 06:51
  #8 (permalink)  
Thread Starter
 
Joined: Apr 2008
Posts: 1,086
Likes: 36
From: France
Thank you all for the help and advice. Yes, it is really the use of formulae in excel that is confusing me. But I am easily confused when it comes to excel.......
Jan, could you let me see a copy of your spreadsheet? I would really like to get to grips with this, as I am trying to keep my brain from freezing up with old age, not to mention the speed of use if I ever get it done. Saab, thank you for the link, but not really what I am looking for.
Piper.Classique is offline  
Reply
Old 2nd May 2014 | 00:57
  #9 (permalink)  
 
Joined: Feb 2013
Posts: 41
Likes: 0
From: New Zealand
Piper Classique

Did you find what you were looking for?

If you open excel Press ALT-F11, this will open a visual basic screen, then choose insert > module.

Then paste the following


Function GROUNDSPEED(TAS, WINDSPEED, WINDDIRECTION, TRACK)
GROUNDSPEED = Sqr((TAS * TAS) + (WINDSPEED * WINDSPEED) - (2 * TAS * WINDSPEED * Cos(WorksheetFunction.Radians(TRACK - WINDDIRECTION + 180))))
End Function

Function HEADING(TAS, WINDSPEED, WINDDIRECTION, TRACK)
HEADING = TRACK + WorksheetFunction.Degrees(WorksheetFunction.Asin(WINDSPEED / TAS * Sin(WorksheetFunction.Radians(TRACK - WINDDIRECTION + 180))))
End Function



Then close the module and visual basic.

You will now have 2 user defined functions which you can use for your formulas. You can use these like other formulas.

So if you have 100knts TAS, 20knots windspeed, 030 wind direction, 260 track.

=GROUNDSPEED(TAS, WINDSPEED, WINDDIRECTION, TRACK)
=HEADING(TAS, WINDSPEED, WINDDIRECTION, TRACK)

If you type =HEADING(100,20,030,260) the you will the answer 268.8
If you type =GROUNDSPEED(100,20,30,260) you will get 88.5

Just replace with references as required eg. =HEADING(B6,B7,B8,B9)

You can also use fx in the formula bar to remind you what goes where.

You will need to save the excel as macro enabled or the functions will not save
500ft is offline  
Reply
Old 2nd May 2014 | 05:47
  #10 (permalink)  
 
Joined: Jul 2010
Posts: 2,807
Likes: 10
From: Ansião (PT)
It is certainly received here with great interest, 500ft, many thanks!
Jan Olieslagers is offline  
Reply
Old 2nd May 2014 | 13:26
  #11 (permalink)  
Thread Starter
 
Joined: Apr 2008
Posts: 1,086
Likes: 36
From: France
Oh, nice! Thank you very much. I must say the task is far more complicated than I first thought. I've used Jan's spreadsheet as a basis, but will continue with 500's as well. Excellent stuff.
Piper.Classique is offline  
Reply
Old 2nd May 2014 | 13:55
  #12 (permalink)  
 
Joined: Jul 2010
Posts: 2,807
Likes: 10
From: Ansião (PT)
but will the VisualBasic stuff work in OpenOffice/LivreOffice too?
Jan Olieslagers is offline  
Reply
Old 2nd May 2014 | 22:12
  #13 (permalink)  
 
Joined: Feb 2013
Posts: 41
Likes: 0
From: New Zealand
but will the VisualBasic stuff work in OpenOffice/LivreOffice too?
Not sure what functionality OpenOffice /LiveOffice has, wouldn't be surprised if it didn't work.

You can just write formulas into the cells rather than creating functions. Just makes it bit more cumbersome.
500ft is offline  
Reply

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off



Contact Us - Archive - Advertising - Cookie Policy - Privacy Statement - Terms of Service

Copyright © 2026 MH Sub I, LLC dba Internet Brands. All rights reserved. Use of this site indicates your consent to the Terms of Use.