[gradsusr] Function
Jennifer Adams
jma at cola.iges.org
Thu Apr 8 13:57:11 EDT 2010
On Apr 8, 2010, at 9:23 AM, Guilherme Martins wrote:
> Hi users,
>
> I need help.
>
> I did this script below to calculate potential temperature but I
> don't know how to call inside my script.
>
> tempc = variable from my file and 700 level I want theta.
>
> Thanks,
>
> Guilherme.
>
> 'open se_g1.ctl'
> 'set gxout shaded'
>
> gtheta(tempc,700)
>
> function gtheta(temp,niv)
> theta1 = (temp+273.15)*pow(1000/niv,0.286)
> return(theta1)
Try this instead:
'open se_g1.ctl'
'set gxout shaded'
gtheta(tempc,700)
function gtheta(temp,niv)
'd ('temp'+273.15)*pow(1000/'niv',0.286)'
return()
Now you've displayed the variable you called theta1. If you want to
define it instead, change function gtheta to this:
function gtheta(temp,niv)
'define temp1 = ('temp'+273.15)*pow(1000/'niv',0.286)'
return()
--Jennifer
>
>
> --
> -----------------------------------------------------------
> José Guilherme Martins dos Santos
> Grupo de Modelagem da Atmosfera e Interfaces - GMAI
> Divisão de Modelagem e Desenvolvimento - DMD
> Centro de Previsão de Tempo e Estudos Climáticos - INPE
> Rodovia Presidente Dutra, km 39 - CEP 12630-000
> Cachoeira Paulista, SP, Brasil
> Telefone(CP): +55 12 3186 8502
> Celular(SJC): +55 12 91678770 / +55 12 81528580
> E-mail: guilherme.martins at cptec.inpe.br
> E-mail alternativo: jgmsantos at gmail.com
> Homepage: http://guilhermemartins.hd1.com.br/
> -----------------------------------------------------------
> _______________________________________________
> gradsusr mailing list
> gradsusr at gradsusr.org
> http://gradsusr.org/mailman/listinfo/gradsusr
--
Jennifer M. Adams
IGES/COLA
4041 Powder Mill Road, Suite 302
Calverton, MD 20705
jma at cola.iges.org
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://gradsusr.org/pipermail/gradsusr/attachments/20100408/514f9e06/attachment-0003.html
More information about the gradsusr
mailing list