SCRIPT: K Index
SCRIPT: K Index
Quick script to generate K Index for stability monitoring.
Someone check my math...
(T850 - T500)+Td850-(T700-Td700)
Here's the script:
CONT GRTN=10 CINT=1 DASH COLOR=200100 SDIF=7:8 STOR=8 SDIF=6:3 STOR=7 SDIF=4:5 STOR=6 SDIF=1:2 STOR=5 DEGC DWPT H700 STOR=4 TEMP H700 STOR=3 DEGC DWPT H850 STOR=2 TEMP H500 STOR=1 TEMP H850
Writing scripts backwards is *weird*...
Someone check my math...
(T850 - T500)+Td850-(T700-Td700)
Here's the script:
CONT GRTN=10 CINT=1 DASH COLOR=200100 SDIF=7:8 STOR=8 SDIF=6:3 STOR=7 SDIF=4:5 STOR=6 SDIF=1:2 STOR=5 DEGC DWPT H700 STOR=4 TEMP H700 STOR=3 DEGC DWPT H850 STOR=2 TEMP H500 STOR=1 TEMP H850
Writing scripts backwards is *weird*...
SCRIPT: K Index
*sigh*
That's what happens when you write quick scripts..
Corrected version here, substituted SDIF for SSUM in STOR=8.
Still not sure about the precedence.. maybe there's a way of marking up meteo equations, sort of like Mathematica does? Would make it a lot easier to create stability indexes..
If anyone has any ideas for ways to script a CAPE calculation, post them here...
CONT GRTN=0 CINT=1 DASH COLOR=200100 SDIF=7:8 STOR=8 SSUM=6:3 STOR=7 SDIF=4:5 STOR=6 SDIF=1:2 STOR=5 DEGC DWPT H700 STOR=4 TEMP H700 STOR=3 DEGC DWPT H850 STOR=2 TEMP H500 STOR=1 TEMP H850
That's what happens when you write quick scripts..
Corrected version here, substituted SDIF for SSUM in STOR=8.
Still not sure about the precedence.. maybe there's a way of marking up meteo equations, sort of like Mathematica does? Would make it a lot easier to create stability indexes..
If anyone has any ideas for ways to script a CAPE calculation, post them here...
CONT GRTN=0 CINT=1 DASH COLOR=200100 SDIF=7:8 STOR=8 SSUM=6:3 STOR=7 SDIF=4:5 STOR=6 SDIF=1:2 STOR=5 DEGC DWPT H700 STOR=4 TEMP H700 STOR=3 DEGC DWPT H850 STOR=2 TEMP H500 STOR=1 TEMP H850
SCRIPT: K Index
Well, it displays... until the thunderstorm season rolls around, I can't tell if it works... I also managed to generate fills at 25%, 35% and 45%, so it's definitely calculating a value for each point reporting upper air data.
Having problems running it, or having problems with the data it produces?
Having problems running it, or having problems with the data it produces?
SCRIPT: K Index
I should also point out that it's written for a menu entry, which assumes an
ANALYZE at the start... for a script you'll need to add that.
K_Script.dsf
---start here---
ERASE
ANALYZE,CONT GRTN=0 CINT=1 DASH COLOR=200100 SDIF=7:8 STOR=8 SSUM=6:3 STOR=7 SDIF=4:5 STOR=6 SDIF=1:2 STOR=5 DEGC DWPT H700 STOR=4 TEMP H700 STOR=3 DEGC DWPT H850 STOR=2 TEMP H500 STOR=1 TEMP H850
STAMP
EXPORT,C:\WX\DIGATM\TEMP_WIND\@FFZ@MMZ@DDZ@HHZ@NNZ_KIndex.jpg
---end here---
K_Fills_Script.dsf
---start here---
ERASE
ANALYZE,OVER FILL COLOR=255:0:0 FILS=0 GRTN=45 SDIF=7:8 OVER FILL COLOR=255:255:0 FILS=0 GRTN=35 SDIF=7:8 OVER FILL COLOR=0:255:0 FILS=0 GRTN=25 SDIF=7:8 STOR=8 SSUM=6:3 STOR=7 SDIF=4:5 STOR=6 SDIF=1:2 STOR=5 DEGC DWPT H700 STOR=4 TEMP H700 STOR=3 DEGC DWPT H850 STOR=2 TEMP H500 STOR=1 TEMP H850
STAMP
EXPORT,C:\WX\DIGATM\TEMP_WIND\@FFZ@MMZ@DDZ@HHZ@NNZ_KIFills.jpg
---end here---
ANALYZE at the start... for a script you'll need to add that.
K_Script.dsf
---start here---
ERASE
ANALYZE,CONT GRTN=0 CINT=1 DASH COLOR=200100 SDIF=7:8 STOR=8 SSUM=6:3 STOR=7 SDIF=4:5 STOR=6 SDIF=1:2 STOR=5 DEGC DWPT H700 STOR=4 TEMP H700 STOR=3 DEGC DWPT H850 STOR=2 TEMP H500 STOR=1 TEMP H850
STAMP
EXPORT,C:\WX\DIGATM\TEMP_WIND\@FFZ@MMZ@DDZ@HHZ@NNZ_KIndex.jpg
---end here---
K_Fills_Script.dsf
---start here---
ERASE
ANALYZE,OVER FILL COLOR=255:0:0 FILS=0 GRTN=45 SDIF=7:8 OVER FILL COLOR=255:255:0 FILS=0 GRTN=35 SDIF=7:8 OVER FILL COLOR=0:255:0 FILS=0 GRTN=25 SDIF=7:8 STOR=8 SSUM=6:3 STOR=7 SDIF=4:5 STOR=6 SDIF=1:2 STOR=5 DEGC DWPT H700 STOR=4 TEMP H700 STOR=3 DEGC DWPT H850 STOR=2 TEMP H500 STOR=1 TEMP H850
STAMP
EXPORT,C:\WX\DIGATM\TEMP_WIND\@FFZ@MMZ@DDZ@HHZ@NNZ_KIFills.jpg
---end here---
As a beginner in meteorology a question about the formula.
Weather map handbook page 146: T850-T500+Td850-D700
Weather forecasting handb. p.138: T850-T500+Td850-D850.
Who is right?
Greetings
Fred
PS. The script gives a nice output. I changed some colors to match the ranges in the map handbook. As a beginner I don't know if the result of the script is correct.
Weather map handbook page 146: T850-T500+Td850-D700
Weather forecasting handb. p.138: T850-T500+Td850-D850.
Who is right?
Greetings
Fred
PS. The script gives a nice output. I changed some colors to match the ranges in the map handbook. As a beginner I don't know if the result of the script is correct.
I'm sure it's just a typo in the forecasting handbook.
this site covers most any meteorological formula you can think of:
http://www.aprweather.com/pages/calc.htm
this site covers most any meteorological formula you can think of:
http://www.aprweather.com/pages/calc.htm
I also think it's a typo. Thanks for the sites, I added them to my favourites.
Looking to the CAPE formule my first impression is that it's much to complex to calculate with the present set of commands. In my opinion it's the best that CAPE will become a predefined command like TEMP etc..
Greetings
Fred
Looking to the CAPE formule my first impression is that it's much to complex to calculate with the present set of commands. In my opinion it's the best that CAPE will become a predefined command like TEMP etc..
Greetings
Fred