NOTICE: This version of the NSF Unidata web site (archive.unidata.ucar.edu) is no longer being updated.
Current content can be found at unidata.ucar.edu.

To learn about what's going on, see About the Archive Site.

Re: [visad] Question on TupleTypes

Hi Bill,

Bill Hibbard wrote:
>  How nice to hear from you, Ugo. Hope you are well.

I'm fine, thanks. And how are you doing?

> Your tutorial is still the starting point for VisAD
> documentation.

:-)

> 
> You can call setSamples() for a FlatField with range type:
> 
> ( (x,y) , temp, pressure, ...)
> 
> just as you would for a FlatField with range type:
> 
> ( x,y, temp, pressure, ...)
> 
> That is, setSamples(), getValues() and getFloats() all ignore
> any grouping of subsets of range RealTypes into "inner"
> RealTupleTypes.

But this ignores the topology of my data. X and y might be a line string
 or a polygon (like the region in Region.java).

Sorry, I've been some time away from VisAD. Fortunately there's a tutorial!

> 
> Cheers,
> Bill

Cheers,

Ugo
> 
>   ----- Original Message -----
>   From: "Ugo Taddei"
>   To: visad@xxxxxxxxxxxxxxxx
>   Subject: [visad] Question on TupleTypes
>   Date: Mon, 18 Aug 2008 21:23:55 +0200 (CEST)
> 
> 
>   Hello,
> 
>   I'm using VisAD to model database tables and have a question.
> 
>   Let a db table have an id, an x and an y coord, and a few other
>   fields
>   like temperature, pressure etc.
> 
>   I create a MathType like
> 
>   (id -> (x,y,temp,pressure,...)
> 
>   (that is RealType -> (RealTupleTypes)).
> 
>   Used a Linear1DSet as domain of a FlatField and got the points all
>   right
>   on the display. Here a snippet:
> 
>   TupleType range_tuple = ...;
> 
>   RealType index = RealType.getRealType( "id" );
>   FunctionType func_i_xy = new FunctionType( index, range_tuple );
> 
>   Set index_set = new Integer1DSet(index, count);
>   FlatField vals_ff = new FlatField( func_i_xy, index_set );
> 
>   vals_ff.setSamples( vals);
> 
>   Now I have another type of geometry, rather than single points, much
>   like
>   the 2D Set found in Region.java, which defines a polygon:
> 
>   int[][] tris = DelaunayCustom.fill(samples);
>   DelaunayCustom delaunay = new DelaunayCustom(samples, tris);
> 
>   Irregular2DSet region =
>   new Irregular2DSet(earth, samples, null, null, null, delaunay);
> 
>   which I also want to fill.
> 
>   So I changed the type to
> 
>   (id ->( (x,y) , temp, pressure, ...))
> 
>   (x,y) is a RealTupleType.SpatialCartesian2DTuple, whereas the other
>   fields
>   are RealTypes (defined by float[][]).
> 
>   To the question: what method setSample do I need? If that makes sense
>   at
>   all. Or do I have to wrap ((x,y),temp,pressure,...) in some
>   visad.Data
>   object?
> 
>   Thanks in advance,
> 
>   Cheers,
> 
>   Ugo
>   _______________________________________________
>   visad mailing list
>   visad@xxxxxxxxxxxxxxxx
>   For list information, to unsubscribe, visit:
>   http://www.unidata.ucar.edu/mailing_lists/
> 


-- 
Ugo Taddei

Fraunhofer Institut Intelligente Analyse- und Informationssysteme (FhG IAIS)
http://www.iais.fraunhofer.de
Department Knowledge Discovery - IAIS.KD -
Working Group Spatial Decision Support
http://www.iais.fraunhofer.de/kd.html
phone  (+49)2241-14-2184    fax    (+49)2241-14-2072
Schloss Birlinghoven, D-53754 Sankt Augustin, Germany


  • 2008 messages navigation, sorted by:
    1. Thread
    2. Subject
    3. Author
    4. Date
    5. ↑ Table Of Contents
  • Search the visad archives: