This archive contains answers to questions sent to Unidata support through mid-2025. Note that the archive is no longer being updated. We provide the archive for reference; many of the answers presented here remain technically correct, even if somewhat outdated. For the most up-to-date information on the use of NSF Unidata software and data services, please consult the Software Documentation first.
Dave, Attached is the source code for $GARPHOME/object/displayvprof.c Replace the existing copy, and then: cd $GARPHOME make clean make all make install make clean Steve Chiswell **************************************************************************** Unidata User Support UCAR Unidata Program 303 497 8643 P.O. Box 3000 address@hidden Boulder, CO 80307 ---------------------------------------------------------------------------- Unidata WWW Service http://my.unidata.ucar.edu/content/support **************************************************************************** On Wed, 9 Nov 2005, David S. Nolan wrote: > > Dear Steve, > > Thank you for your very fast reply. I believe we compiled > the code, so please send me the link to the fix. Some brief > instructions on how to install it would help, because the > person who installs these things is out of town right now. > > Best regards, > > Dave Nolan > > > > > > > David, > > > > This "new" bug in model soundings is caused by gcc's handling of string > > constants > > when passed to a Fortran routine. The code hasn't changed in many years, > > but now > > gcc is having trouble. I have patched this routine for the upcoming 5.8.4 > > release > > but you can update your current version as needed. It you want to patch > > the source code, > > I can send you the reference to our site where I posted the fix. If you > > are running > > a binary release, I can send you the new executable. > > > > Steve Chiswell > > Unidata User Support > > > > > > > >>From: "David Nolan" <address@hidden> > >>Organization: UCAR/Unidata > >>Keywords: 200511081743.jA8HhDCs014535 > > > >>Institution: University of Miami > >>Package Version: 2.1 > >>Operating System: Linux > >>Hardware Information: x86 > >>Inquiry: Greetings from Miami. > >> > >>I'm using GARP to teach a course on Weather Analysis here at the > >> University of > >> Miami. The program works quite well, but I just discovered that it > >> crashes e > >> very time I try to plot a model forecast sounding - either Skew-T or > >> Stuve. I > >> t works if I choose Linear or Logarithmic vertical coordinates - but > >> those ar > >> e hard to infer stability from. > >> > >>When it crashes, it gives the "Segmentaion Error" message. > >> > >>Do you have any suggestions? > >> > >>Thanks! > >> > >>Dave Nolan > >> > >> > >> > > -- > > **************************************************************************** > > Unidata User Support UCAR Unidata > > (303)497-8643 P.O. Box > > address@hidden Boulder, CO > > ---------------------------------------------------------------------------- > > Unidata WWW Service > > ---------------------------------------------------------------------------- > > NOTE: All email exchanges with Unidata User Support are recorded in the > > Unidata inquiry tracking system and then made publicly available > > through the web. If you do not want to have your interactions made > > available in this way, you must let us know in each email you send to us. > > > > > -- > David S. Nolan > Assistant Professor > Division of Meteorology and Physical Oceanography > Rosenstiel School of Marine and Atmospheric Science > University of Miami > 4600 Rickenbacker Causeway > Miami, FL 33149 > 305-421-4930 > address@hidden > http://www.rsmas.miami.edu/personal/dnolan > > "Comprehensive complexity is no virtue in modeling, > but rather, an admission of failure." - Ian James. > >
/***********************************************************************
*
* Copyright 1996, University Corporation for Atmospheric Research.
*
* displayprof.c
*
* Vertical profile display driver.
*
* History:
*
* 12/96 COMET Original copy
* 1/97 COMET Use title string in mot for consistency across
* data types.
* 3/97 COMET Added wind position indicator.
* 3/97 COMET Added frame number
* 11/97 COMET Added titleIndex to pvprof arg list.
*
***********************************************************************/
#include "underscore.h"
#include "winobj.h"
#include "wincb.h"
#include "genglobs.h"
int DisplayVerticalProfile( WindowObjectType *wo, MetObjectType *mot )
{
char title[FILENAMESTRING], wind[GEMPAKSTRING];
char tmp_datim[GEMPAKSTRING];
char line[GEMPAKSTRING];
char file[GEMPAKSTRING];
char sizestr[GEMPAKSTRING], widthstr[GEMPAKSTRING];
char fontstr[GEMPAKSTRING];
int size, width, font_size;
int i, verbose, frame, iret;
char gfunc[GEMPAKSTRING], gvect[GEMPAKSTRING];
VertProfileObjectType *pot;
MetObjectType *gmobj;
verbose = GetVerboseLevel();
if( verbose > VERBOSE_0 )
printf ( "DisplayVerticalProfile\n" );
frame = GetActivePixmapObjectIndex (wo) + 1;
pot = (VertProfileObjectType *) mot->metObjectContent;
assert( pot );
/*
* Save original FDF settings.
*/
strcpy ( sizestr, pot->symbol_size );
strcpy ( widthstr, pot->symbol_width );
strcpy ( fontstr, pot->text );
/*
* Set plotting parameters according to generalized values.
*/
GetDepictableValue ( "SYMBOLSIZE", &size );
GetDepictableValue ( "SYMBOLWIDTH", &width );
GetDepictableValue ( "FONTSIZE", &font_size );
SetGemFloatVar (TIMEHEIGHTOBJECT, sizestr, "SYMBOLSIZE", size );
SetGemFloatVar (TIMEHEIGHTOBJECT, widthstr, "SYMBOLWIDTH", width );
SetGemText (TIMEHEIGHTOBJECT, fontstr, "FONTSIZE", font_size );
/*
* Set contour line characteristics.
*/
sprintf ( line, "%s/%s/%s", pot->line_color, pot->line_type,
pot->line_width );
sprintf ( wind, "%s%s/%s/%s/%s/%s",
pot->wind_symbol, pot->line_color,
sizestr , widthstr ,
pot->symbol_type, pot->symbol_headsize );
strcpy ( title, mot->titleString );
SetGemTitle ( line, mot->titleIndex, title );
if(strcspn(pot->ftime,"/") > 6)
strcpy(tmp_datim,pot->ftime+2);
else
strcpy(tmp_datim,pot->ftime);
/*
* Gempak driver.
*/
if ( strstr ( pot->ptype, "skewt" ) ||
strstr ( pot->ptype, "stuve" ) ) {
/*
* Use red for the TMPC line color for the first plot.
*/
if ( strcmp ( pot->winpos, "1" ) == 0 )
sprintf ( line, "2/%s/3", pot->line_type );
else
sprintf ( line, "%s/%s/3", pot->line_color, pot->line_type );
sprintf(gfunc,"tmpc"); sprintf(gvect,"wind");
pvprof( mot->filename, tmp_datim,
pot->vcoord, gfunc,
pot->point, gvect,
pot->ptype, pot->xaxis,
pot->yaxis, line,
wind, pot->refvec,
pot->winpos, pot->thtaln,
pot->thteln, pot->mixrln,
pot->filter, title,
pot->scale, fontstr,
&frame, &(mot->titleIndex),
&verbose, &iret,
strlen(mot->filename), strlen(tmp_datim),
strlen(pot->vcoord), strlen(gfunc),
strlen(pot->point), strlen(gvect),
strlen(pot->ptype), strlen(pot->xaxis),
strlen(pot->yaxis), strlen(line),
strlen(wind), strlen(pot->refvec),
strlen(pot->winpos), strlen(pot->thtaln),
strlen(pot->thteln), strlen(pot->mixrln),
strlen(pot->filter), strlen(title),
strlen(pot->scale), strlen(fontstr) );
/*
* Use green for the DWPC line color for the first plot.
*/
if ( strcmp ( pot->winpos, "1" ) == 0 )
sprintf ( line, "3/%s/3", pot->line_type );
else
sprintf ( line, "%s/%s/3", pot->line_color, pot->line_type );
sprintf(gfunc,"dwpc"); sprintf(gvect," ");
pvprof( mot->filename, tmp_datim,
pot->vcoord, gfunc,
pot->point, gvect,
pot->ptype, pot->xaxis,
pot->yaxis, line,
wind, pot->refvec,
pot->winpos, pot->thtaln,
pot->thteln, pot->mixrln,
pot->filter, title,
pot->scale, fontstr,
&frame, &(mot->titleIndex),
&verbose, &iret,
strlen(mot->filename), strlen(tmp_datim),
strlen(pot->vcoord), strlen(gfunc),
strlen(pot->point), strlen(gvect),
strlen(pot->ptype), strlen(pot->xaxis),
strlen(pot->yaxis), strlen(line),
strlen(wind), strlen(pot->refvec),
strlen(pot->winpos), strlen(pot->thtaln),
strlen(pot->thteln), strlen(pot->mixrln),
strlen(pot->filter), strlen(title),
strlen(pot->scale), strlen(fontstr) );
}
else
pvprof( mot->filename, tmp_datim,
pot->vcoord, pot->field,
pot->point, pot->vector,
pot->ptype, pot->xaxis,
pot->yaxis, line,
wind, pot->refvec,
pot->winpos, pot->thtaln,
pot->thteln, pot->mixrln,
pot->filter, title,
pot->scale, fontstr,
&frame, &(mot->titleIndex),
&verbose, &iret,
strlen(mot->filename), strlen(tmp_datim),
strlen(pot->vcoord), strlen(pot->field),
strlen(pot->point), strlen(pot->vector),
strlen(pot->ptype), strlen(pot->xaxis),
strlen(pot->yaxis), strlen(line),
strlen(wind), strlen(pot->refvec),
strlen(pot->winpos), strlen(pot->thtaln),
strlen(pot->thteln), strlen(pot->mixrln),
strlen(pot->filter), strlen(title),
strlen(pot->scale), strlen(fontstr) );
SetMetObjectDrawnFlag( mot, True );
return(0);
}