import visad.*; public class dataex5 { public static void main (String arg[]) { try { Real t1,t2,sum; Unit degC = visad.data.netcdf.units.Parser.parse("degC"); RealType tc = new RealType("tempsC",degC,null); t2 = new Real(tc,10.); RealType k = new RealType("kelvin",SI.kelvin,null); t1 = new Real(k,255.); sum = (Real) t1.add(t2); System.out.println("sum = "+sum+" "+sum.getUnit()); } catch (Exception e) {System.out.println(e);} } }