Index: /issm/oecreview/Archive/20496-20544/Date.tex
===================================================================
--- /issm/oecreview/Archive/20496-20544/Date.tex	(revision 20545)
+++ /issm/oecreview/Archive/20496-20544/Date.tex	(revision 20545)
@@ -0,0 +1,1 @@
+Apr-25-2016
Index: /issm/oecreview/Archive/20496-20544/ISSM-20496-20497.diff
===================================================================
--- /issm/oecreview/Archive/20496-20544/ISSM-20496-20497.diff	(revision 20545)
+++ /issm/oecreview/Archive/20496-20544/ISSM-20496-20497.diff	(revision 20545)
@@ -0,0 +1,27 @@
+Index: ../trunk-jpl/test
+===================================================================
+--- ../trunk-jpl/test	(revision 20496)
++++ ../trunk-jpl/test	(revision 20497)
+
+Property changes on: ../trunk-jpl/test
+___________________________________________________________________
+Modified: svn:mergeinfo
+   Merged /issm/trunk/test:r18303-19104,19106-20496
+Index: ../trunk-jpl/src
+===================================================================
+--- ../trunk-jpl/src	(revision 20496)
++++ ../trunk-jpl/src	(revision 20497)
+
+Property changes on: ../trunk-jpl/src
+___________________________________________________________________
+Modified: svn:mergeinfo
+   Merged /issm/trunk/src:r19102-19104,19106-20496
+Index: ../trunk-jpl
+===================================================================
+--- ../trunk-jpl	(revision 20496)
++++ ../trunk-jpl	(revision 20497)
+
+Property changes on: ../trunk-jpl
+___________________________________________________________________
+Modified: svn:mergeinfo
+   Merged /issm/trunk:r19102-19104,19106-20496
Index: /issm/oecreview/Archive/20496-20544/ISSM-20501-20502.diff
===================================================================
--- /issm/oecreview/Archive/20496-20544/ISSM-20501-20502.diff	(revision 20545)
+++ /issm/oecreview/Archive/20496-20544/ISSM-20501-20502.diff	(revision 20545)
@@ -0,0 +1,62 @@
+Index: ../trunk-jpl/src/m/exp/flowlines.m
+===================================================================
+--- ../trunk-jpl/src/m/exp/flowlines.m	(revision 20501)
++++ ../trunk-jpl/src/m/exp/flowlines.m	(revision 20502)
+@@ -36,9 +36,9 @@
+ end
+ precision=1; %division of each segment (higer precision increases number of segments)
+ 
+-%check seed points
+-tria=TriaSearch(index,x,y,x0,y0);
+-%tria=tsearch(x,y,index,x0,y0);
++%Create triangulation once for all and check seed points
++trep = triangulation(index,x,y);
++tria = pointLocation(trep,[x0 y0]);
+ pos=find(isnan(tria));
+ x0(pos)=[];
+ y0(pos)=[];
+@@ -69,8 +69,7 @@
+ 
+ 	%find current triangle
+ 	queue=find(~done);
+-	tria=TriaSearch(index,x,y,X(queue),Y(queue));
+-	%tria=tsearch(x,y,index,X(queue),Y(queue));
++	tria = pointLocation(trep,[X(queue),Y(queue)]);
+ 
+ 	%check that the point is actually inside a triangle of the mesh
+ 	listnan=find(isnan(tria));
+@@ -120,8 +119,7 @@
+ 
+ 	%find current triangle
+ 	queue=find(~done);
+-	tria=TriaSearch(index,x,y,X(queue),Y(queue));
+-	%tria=tsearch(x,y,index,X(queue),Y(queue));
++	tria = pointLocation(trep,[X(queue),Y(queue)]);
+ 
+ 	%check that the point is actually inside a triangle of the mesh
+ 	listnan=find(isnan(tria));
+Index: ../trunk-jpl/src/m/exp/downstreamflowlines.m
+===================================================================
+--- ../trunk-jpl/src/m/exp/downstreamflowlines.m	(revision 20501)
++++ ../trunk-jpl/src/m/exp/downstreamflowlines.m	(revision 20502)
+@@ -37,8 +37,9 @@
+ 	precision=1; %division of each segment (higer precision increases number of segments)
+ end
+ 
+-%check seed points
+-tria=TriaSearch(index,x,y,x0,y0);
++%Create triangulation once for all and check seed points
++trep = triangulation(index,x,y);
++tria = pointLocation(trep,[x0 y0]);
+ pos=find(isnan(tria));
+ x0(pos)=[];
+ y0(pos)=[];
+@@ -69,7 +70,7 @@
+ 
+ 	%find current triangle
+ 	queue=find(~done);
+-	tria=TriaSearch(index,x,y,X(queue),Y(queue));
++	tria = pointLocation(trep,[X(queue),Y(queue)]);
+ 
+ 	%check that the point is actually inside a triangle of the mesh
+ 	listnan=find(isnan(tria));
Index: /issm/oecreview/Archive/20496-20544/ISSM-20502-20503.diff
===================================================================
--- /issm/oecreview/Archive/20496-20544/ISSM-20502-20503.diff	(revision 20545)
+++ /issm/oecreview/Archive/20496-20544/ISSM-20502-20503.diff	(revision 20545)
@@ -0,0 +1,252 @@
+Index: ../trunk-jpl/src/c/modules/TriaSearchx/TriaSearchx.cpp
+===================================================================
+--- ../trunk-jpl/src/c/modules/TriaSearchx/TriaSearchx.cpp	(revision 20502)
++++ ../trunk-jpl/src/c/modules/TriaSearchx/TriaSearchx.cpp	(revision 20503)
+@@ -1,49 +0,0 @@
+-/*!\file TriaSearchx
+- */
+-
+-#include "./TriaSearchx.h"
+-
+-#include "../../shared/shared.h"
+-#include "../../toolkits/toolkits.h"
+-#include "../../bamg/bamgobjects.h"
+-
+-using namespace bamg;
+-using namespace std;
+-
+-void TriaSearchx(double** ptria,int* index,int nel, double* x, double* y, int nods,double* x0, double* y0,int numberofnodes){
+-
+-	/*Output*/
+-	double* tria=NULL;
+-
+-	/*allocate: */
+-	tria=xNew<double>(numberofnodes);
+-
+-	/*Intermediary*/
+-	R2     r;
+-	I2     I;
+-	int    i;
+-	Icoor2 dete[3];
+-
+-	/* read background mesh */
+-	Mesh Th(index,x,y,nods,nel); 
+-	Th.CreateSingleVertexToTriangleConnectivity();
+-
+-	for(i=0;i<numberofnodes;i++){
+-
+-		//Get current point coordinates
+-		r.x=x0[i]; r.y=y0[i];
+-
+-		I=Th.R2ToI2(r);
+-
+-		//Find triangle holding r/I
+-		Triangle &tb=*Th.TriangleFindFromCoord(I,dete);
+-
+-		// internal point 
+-		if (Th.GetId(tb)<nel)tria[i]=(double)Th.GetId(tb);
+-		//external point
+-		else tria[i]=NAN;
+-	}
+-
+-	/*Assign output pointers:*/
+-	*ptria=tria;
+-}
+Index: ../trunk-jpl/src/c/modules/TriaSearchx/TriaSearchx.h
+===================================================================
+--- ../trunk-jpl/src/c/modules/TriaSearchx/TriaSearchx.h	(revision 20502)
++++ ../trunk-jpl/src/c/modules/TriaSearchx/TriaSearchx.h	(revision 20503)
+@@ -1,13 +0,0 @@
+-/*!\file:  TriaSearchx.h
+- * \brief header file for Bamg module
+- */ 
+-
+-#ifndef _TRIASEARCHX_H
+-#define _TRIASEARCHX_H
+-
+-#include "../../classes/classes.h"
+-
+-/* local prototypes: */
+-void TriaSearchx(double** ptria,int* index,int nel, double* x, double* y, int nods,double* x0, double* y0,int numberofnodes);
+-
+-#endif
+Index: ../trunk-jpl/src/c/modules/modules.h
+===================================================================
+--- ../trunk-jpl/src/c/modules/modules.h	(revision 20502)
++++ ../trunk-jpl/src/c/modules/modules.h	(revision 20503)
+@@ -88,7 +88,6 @@
+ #include "./SystemMatricesx/SystemMatricesx.h"
+ #include "./SpcNodesx/SpcNodesx.h"
+ #include "./SurfaceAreax/SurfaceAreax.h"
+-#include "./TriaSearchx/TriaSearchx.h"
+ #include "./TriMeshx/TriMeshx.h"
+ #include "./TriMeshProcessRiftsx/TriMeshProcessRiftsx.h"
+ #include "./ThicknessAbsMisfitx/ThicknessAbsMisfitx.h"
+Index: ../trunk-jpl/src/c/Makefile.am
+===================================================================
+--- ../trunk-jpl/src/c/Makefile.am	(revision 20502)
++++ ../trunk-jpl/src/c/Makefile.am	(revision 20503)
+@@ -533,7 +533,6 @@
+ 			./shared/TriMesh/OrderSegments.cpp\
+ 			./shared/TriMesh/SplitMeshForRifts.cpp\
+ 			./shared/TriMesh/TriMeshUtils.cpp\
+-			./modules/TriaSearchx/TriaSearchx.cpp\
+ 			./modules/TriMeshx/TriMeshx.cpp\
+ 			./modules/TriMeshProcessRiftsx/TriMeshProcessRiftsx.cpp\
+ 			./modules/PointCloudFindNeighborsx/PointCloudFindNeighborsx.cpp\
+Index: ../trunk-jpl/src/wrappers/TriaSearch/TriaSearch.h
+===================================================================
+--- ../trunk-jpl/src/wrappers/TriaSearch/TriaSearch.h	(revision 20502)
++++ ../trunk-jpl/src/wrappers/TriaSearch/TriaSearch.h	(revision 20503)
+@@ -1,56 +0,0 @@
+-/*!\file TriaSearch.h
+- */
+-
+-#ifndef _TRIASEARCH_H
+-#define _TRIASEARCH_H
+-
+-#ifdef HAVE_CONFIG_H
+-	#include <config.h>
+-#else
+-	#error "Cannot compile with HAVE_CONFIG_H symbol! run configure first!"
+-#endif
+-
+-/*For python modules: needs to come before header files inclusion*/
+-#ifdef _HAVE_PYTHON_
+-#define PY_ARRAY_UNIQUE_SYMBOL PythonIOSymbol
+-#endif
+-
+-#include "../bindings.h"
+-#include "../../c/main/globals.h"
+-#include "../../c/modules/modules.h"
+-#include "../../c/shared/shared.h"
+-
+-#undef __FUNCT__ 
+-#define __FUNCT__  "TriaSearch"
+-
+-#ifdef _HAVE_MATLAB_MODULES_
+-/* serial input macros: */
+-#define INDEXHANDLE prhs[0]
+-#define XHANDLE     prhs[1]
+-#define YHANDLE     prhs[2]
+-#define X0HANDLE    prhs[3]
+-#define Y0HANDLE    prhs[4]
+-
+-/* serial output macros: */
+-#define TRIA (mxArray**)&plhs[0]
+-#endif
+-
+-#ifdef _HAVE_PYTHON_MODULES_
+-/* serial input macros: */
+-#define INDEXHANDLE PyTuple _GetItem(args,0)
+-#define XHANDLE     PyTuple _GetItem(args,1)
+-#define YHANDLE     PyTuple _GetItem(args,2)
+-#define X0HANDLE    PyTuple _GetItem(args,3)
+-#define Y0HANDLE    PyTuple _GetItem(args,4)
+-
+-/* serial output macros: */
+-#define TRIA output,0
+-#endif
+-
+-/* serial arg counts: */
+-#undef NLHS
+-#define NLHS  1
+-#undef NRHS
+-#define NRHS  5
+-
+-#endif
+Index: ../trunk-jpl/src/wrappers/TriaSearch/TriaSearch.cpp
+===================================================================
+--- ../trunk-jpl/src/wrappers/TriaSearch/TriaSearch.cpp	(revision 20502)
++++ ../trunk-jpl/src/wrappers/TriaSearch/TriaSearch.cpp	(revision 20503)
+@@ -1,68 +0,0 @@
+-/*\file TriaSearch.c
+- *\brief: TriaSearch module. See TriaSearchx for more details.
+- */
+-#include "./TriaSearch.h"
+-
+-void TriaSearchUsage(void){/*{{{*/
+-	_printf0_("TriaSearch- find triangle holding a point (x0,y0) in a mesh\n");
+-	_printf0_("\n");
+-	_printf0_("   Usage:\n");
+-	_printf0_("         tria=TriaSearch(index,x,y,x0,y0);\n");
+-	_printf0_("      index,x,y: mesh triangulatrion\n");
+-	_printf0_("      x0,y0: coordinates of the point for which we are trying to find a triangle\n");
+-	_printf0_("      x0,y0 can be an array of points\n");
+-	_printf0_("\n");
+-}/*}}}*/
+-WRAPPER(TriaSearch){
+-
+-	int i;
+-
+-	/*input: */
+-	int*    index=NULL;
+-	int     nel;
+-	int     dummy;
+-
+-	double* x=NULL;
+-	double* y=NULL;
+-	int     nods;
+-
+-	double* x0=NULL;
+-	double* y0=NULL;
+-	int     numberofnodes;
+-
+-	/* output: */
+-	double*  tria=NULL;
+-
+-	/*Boot module: */
+-	MODULEBOOT();
+-
+-	/*checks on arguments on the matlab side: */
+-	CheckNumMatlabArguments(nlhs,NLHS,nrhs,NRHS,__FUNCT__,&TriaSearchUsage);
+-
+-	/*Input datasets: */
+-	FetchData(&index,&nel,&dummy,INDEXHANDLE);
+-	FetchData(&x,&nods,XHANDLE);
+-	FetchData(&y,&nods,YHANDLE);
+-	FetchData(&x0,&numberofnodes,X0HANDLE);
+-	FetchData(&y0,&numberofnodes,Y0HANDLE);
+-
+-	/* Run core computations: */
+-	TriaSearchx(&tria,index,nel,x,y,nods,x0,y0,numberofnodes);
+-
+-	/* c to matlab: */
+-	for(i=0;i<numberofnodes;i++)tria[i]++;
+-
+-	/*Write data: */
+-	WriteData(TRIA,tria,numberofnodes);
+-
+-	/*Cleanup*/
+-	xDelete<int>(index);
+-	xDelete<double>(x);
+-	xDelete<double>(y);
+-	xDelete<double>(x0);
+-	xDelete<double>(y0);
+-	xDelete<double>(tria);
+-
+-	/*end module: */
+-	MODULEEND();
+-}
+Index: ../trunk-jpl/src/wrappers/matlab/Makefile.am
+===================================================================
+--- ../trunk-jpl/src/wrappers/matlab/Makefile.am	(revision 20502)
++++ ../trunk-jpl/src/wrappers/matlab/Makefile.am	(revision 20503)
+@@ -60,7 +60,6 @@
+ 						 PointCloudFindNeighbors.la\
+ 						 PropagateFlagsFromConnectivity.la\
+ 						 StringToEnum.la\
+-						 TriaSearch.la\
+ 						 TriMesh.la\
+ 						 TriMeshProcessRifts.la\
+ 						 Scotch.la\
+@@ -249,9 +248,6 @@
+ Shp2Kml_la_SOURCES = ../Shp2Kml/Shp2Kml.cpp
+ Shp2Kml_la_LIBADD = ${deps} $(SHAPELIBLIB) $(MPILIB) $(PETSCLIB) $(GSLLIB) $(PROJ4LIB)
+ 
+-TriaSearch_la_SOURCES = ../TriaSearch/TriaSearch.cpp
+-TriaSearch_la_LIBADD = ${deps} $(MPILIB) $(PETSCLIB) $(GSLLIB) $(PROJ4LIB)
+-
+ TriMesh_la_SOURCES = ../TriMesh/TriMesh.cpp
+ TriMesh_la_LIBADD = ${deps} $(MPILIB) $(PETSCLIB) $(TRIANGLELIB) $(GSLLIB) $(PROJ4LIB)
+ 
Index: /issm/oecreview/Archive/20496-20544/ISSM-20503-20504.diff
===================================================================
--- /issm/oecreview/Archive/20496-20544/ISSM-20503-20504.diff	(revision 20545)
+++ /issm/oecreview/Archive/20496-20544/ISSM-20503-20504.diff	(revision 20545)
@@ -0,0 +1,43 @@
+Index: ../trunk-jpl/test/NightlyRun/test422.m
+===================================================================
+--- ../trunk-jpl/test/NightlyRun/test422.m	(revision 20503)
++++ ../trunk-jpl/test/NightlyRun/test422.m	(revision 20504)
+@@ -10,7 +10,7 @@
+ 
+ %Fields and tolerances to track changes
+ field_names     ={'Vx','Vy','Vz','Vel','Pressure'};
+-field_tolerances={4e-07,4e-07,2e-06,2e-07,5e-07};
++field_tolerances={4e-07,4e-07,2e-06,4e-07,5e-07};
+ field_values={...
+ 	(md.results.StressbalanceSolution.Vx),...
+ 	(md.results.StressbalanceSolution.Vy),...
+Index: ../trunk-jpl/test/NightlyRun/test211.py
+===================================================================
+--- ../trunk-jpl/test/NightlyRun/test211.py	(revision 20503)
++++ ../trunk-jpl/test/NightlyRun/test211.py	(revision 20504)
+@@ -27,9 +27,9 @@
+ 	'Vx2','Vy2','Vz2','Vel2','Pressure2','Bed2','Surface2','Thickness2','Temperature2','BasalforcingsGroundediceMeltingRate2', \
+ 	'Vx3','Vy3','Vz3','Vel3','Pressure3','Bed3','Surface3','Thickness3','Temperature3','BasalforcingsGroundediceMeltingRate3']
+ field_tolerances=[\
+-	2e-08,2e-08,1e-06,2e-08,1e-08,1e-08,1e-08,1e-08,1e-08,1e-08,\
+-	5e-07,5e-07,5e-05,1e-07,1e-08,1e-08,1e-08,1e-08,5e-08,2e-06,\
+-	5e-06,5e-06,5e-05,5e-06,1e-07,5e-07,5e-07,5e-07,5e-06,5e-05]
++	2e-08,2e-08,2e-06,2e-08,1e-08,1e-08,1e-08,1e-08,1e-08,1e-08,\
++	5e-07,5e-07,5e-05,2e-07,1e-08,1e-08,1e-08,1e-08,6e-08,2e-06,\
++	5e-06,5e-06,5e-05,5e-06,5e-07,5e-07,5e-07,5e-07,5e-06,5e-05]
+ field_values=[\
+ 	md.results.TransientSolution[0].Vx,\
+ 	md.results.TransientSolution[0].Vy,\
+Index: ../trunk-jpl/test/NightlyRun/test422.py
+===================================================================
+--- ../trunk-jpl/test/NightlyRun/test422.py	(revision 20503)
++++ ../trunk-jpl/test/NightlyRun/test422.py	(revision 20504)
+@@ -20,7 +20,7 @@
+ 
+ #Fields and tolerances to track changes
+ field_names     =['Vx','Vy','Vz','Vel','Pressure']
+-field_tolerances=[4e-07,4e-07,2e-06,2e-07,5e-07]
++field_tolerances=[4e-07,4e-07,2e-06,4e-07,5e-07]
+ field_values=[\
+ 	md.results.StressbalanceSolution.Vx,\
+ 	md.results.StressbalanceSolution.Vy,\
Index: /issm/oecreview/Archive/20496-20544/ISSM-20504-20505.diff
===================================================================
--- /issm/oecreview/Archive/20496-20544/ISSM-20504-20505.diff	(revision 20545)
+++ /issm/oecreview/Archive/20496-20544/ISSM-20504-20505.diff	(revision 20545)
@@ -0,0 +1,25 @@
+Index: ../trunk-jpl/src/m/classes/model.m
+===================================================================
+--- ../trunk-jpl/src/m/classes/model.m	(revision 20504)
++++ ../trunk-jpl/src/m/classes/model.m	(revision 20505)
+@@ -207,7 +207,6 @@
+ 			elseif isa(md.smb,'SMBhenning') & ~isnan(md.smb.smbref),
+ 				md.smb.smbref=project2d(md,md.smb.smbref,md.mesh.numberoflayers);
+ 			end;
+-			if ~isnan(md.balancethickness.thickening_rate), md.balancethickness.thickening_rate=project2d(md,md.balancethickness.thickening_rate,md.mesh.numberoflayers); end;
+ 
+ 			%results
+ 			if ~isnan(md.initialization.vx),md.initialization.vx=DepthAverage(md,md.initialization.vx);end;
+Index: ../trunk-jpl/src/m/classes/model.py
+===================================================================
+--- ../trunk-jpl/src/m/classes/model.py	(revision 20504)
++++ ../trunk-jpl/src/m/classes/model.py	(revision 20505)
+@@ -686,8 +686,6 @@
+ 		if not numpy.isnan(md.smb.mass_balance).all():
+ 			md.smb.mass_balance=project2d(md,md.smb.mass_balance,md.mesh.numberoflayers) 
+ 		
+-		if not numpy.isnan(md.balancethickness.thickening_rate).all(): md.balancethickness.thickening_rate=project2d(md,md.balancethickness.thickening_rate,md.mesh.numberoflayers) 
+-
+ 		#results
+ 		if not numpy.isnan(md.initialization.vx).all(): md.initialization.vx=DepthAverage(md,md.initialization.vx)
+ 		if not numpy.isnan(md.initialization.vy).all(): md.initialization.vy=DepthAverage(md,md.initialization.vy)
Index: /issm/oecreview/Archive/20496-20544/ISSM-20505-20506.diff
===================================================================
--- /issm/oecreview/Archive/20496-20544/ISSM-20505-20506.diff	(revision 20545)
+++ /issm/oecreview/Archive/20496-20544/ISSM-20505-20506.diff	(revision 20545)
@@ -0,0 +1,13 @@
+Index: ../trunk-jpl/jenkins/jenkins.sh
+===================================================================
+--- ../trunk-jpl/jenkins/jenkins.sh	(revision 20505)
++++ ../trunk-jpl/jenkins/jenkins.sh	(revision 20506)
+@@ -136,7 +136,7 @@
+ 		source $ISSM_DIR/etc/environment.sh
+ 
+ 		#If external package is rebuilt, we also need to recompile
+-		ISSM_COMPILATION = "yes"
++		ISSM_COMPILATION="yes"
+ 	else
+ 		echo "======================================================";
+ 		echo "       Skipping $PACKAGENAME                          ";
Index: /issm/oecreview/Archive/20496-20544/ISSM-20508-20509.diff
===================================================================
--- /issm/oecreview/Archive/20496-20544/ISSM-20508-20509.diff	(revision 20545)
+++ /issm/oecreview/Archive/20496-20544/ISSM-20508-20509.diff	(revision 20545)
@@ -0,0 +1,32 @@
+Index: ../trunk-jpl/jenkins/jenkins.sh
+===================================================================
+--- ../trunk-jpl/jenkins/jenkins.sh	(revision 20508)
++++ ../trunk-jpl/jenkins/jenkins.sh	(revision 20509)
+@@ -114,9 +114,8 @@
+ 
+ 	cd $ISSM_DIR/externalpackages/$PACKAGENAME
+ 
+-	#install if requested or if install does not exist
+-	if [ "$ISSM_EXTERNALPACKAGES" == "install" ] || [ ! -d install ] || [ ! "$(ls -A install)" ];
+-	then
++	#install if requested or if previous install has not been successful
++	if [ "$ISSM_EXTERNALPACKAGES" == "install" ] || [ ! -f SUCCESS ]; then
+ 		echo "======================================================";
+ 		echo "       Installing $PACKAGENAME                        ";
+ 		echo "======================================================";
+@@ -125,13 +124,13 @@
+ 			echo "======================================================";
+ 			echo "    ERROR: installation of $PACKAGENAME failed        ";
+ 			echo "======================================================";
+-			#erase install directory, so that next time, we still try and compile this!
+-			rm -rf install
+ 			echo "<testcase classname=\"externalpackages\" name=\"$PACKAGENAME\">" >> $EXTERNAL_TEST_FILE
+ 			echo '<failure message="failure">External packages did not install right. Check it.</failure>' >> $EXTERNAL_TEST_FILE
+ 			echo '</testcase>' >> $EXTERNAL_TEST_FILE
++			exit 1
+ 		else
+ 			echo "<testcase classname=\"externalpackages\" name=\"$PACKAGENAME\"/>" >> $EXTERNAL_TEST_FILE
++			touch SUCCESS
+ 		fi
+ 		source $ISSM_DIR/etc/environment.sh
+ 
Index: /issm/oecreview/Archive/20496-20544/ISSM-20511-20512.diff
===================================================================
--- /issm/oecreview/Archive/20496-20544/ISSM-20511-20512.diff	(revision 20545)
+++ /issm/oecreview/Archive/20496-20544/ISSM-20511-20512.diff	(revision 20545)
@@ -0,0 +1,22 @@
+Index: ../trunk-jpl/src/m/exp/flowlines.m
+===================================================================
+--- ../trunk-jpl/src/m/exp/flowlines.m	(revision 20511)
++++ ../trunk-jpl/src/m/exp/flowlines.m	(revision 20512)
+@@ -87,7 +87,7 @@
+ 	end
+ 
+ 	%velocity of the current triangle and norm it
+-	ut=u(tria); vt=v(tria); normv=sqrt(ut.^2+vt.^2);
++	ut=u(tria); vt=v(tria); normv=max(eps,sqrt(ut.^2+vt.^2));
+ 	ut=ut./normv;vt=vt./normv;
+ 
+ 	%check counter
+@@ -137,7 +137,7 @@
+ 	end
+ 
+ 	%velocity of the current triangle and norm it
+-	ut=-u(tria); vt=-v(tria); normv=sqrt(ut.^2+vt.^2);
++	ut=-u(tria); vt=-v(tria); normv=max(eps,sqrt(ut.^2+vt.^2));
+ 	ut=ut./normv;vt=vt./normv;
+ 
+ 	%check counter
Index: /issm/oecreview/Archive/20496-20544/ISSM-20512-20513.diff
===================================================================
--- /issm/oecreview/Archive/20496-20544/ISSM-20512-20513.diff	(revision 20545)
+++ /issm/oecreview/Archive/20496-20544/ISSM-20512-20513.diff	(revision 20545)
@@ -0,0 +1,88 @@
+Index: ../trunk-jpl/src/m/plot/plot_unit.js
+===================================================================
+--- ../trunk-jpl/src/m/plot/plot_unit.js	(revision 20512)
++++ ../trunk-jpl/src/m/plot/plot_unit.js	(revision 20513)
+@@ -95,7 +95,7 @@
+ 			}
+ 			else{ //triangular elements	
+ 				caxis = options.getfieldvalue('caxis',[ArrayMin(data),ArrayMax(data)]);
+-				if (options.exist('log')) caxis = [Math.log10(caxis[0])/Math.log10(options.getfieldvalue('log')),Math.log10(caxis[1])/Math.log10(options.getfieldvalue('log'))];
++				if (options.getfieldvalue('log',10)!='off') caxis = [Math.log10(caxis[0])/Math.log10(options.getfieldvalue('log')),Math.log10(caxis[1])/Math.log10(options.getfieldvalue('log'))];
+ 				datamin = caxis[0];
+ 				datamax = caxis[1];
+ 				datadelta = datamax - datamin;
+@@ -203,7 +203,7 @@
+ 				else {
+ 					caxis = [ArrayMin(data[0]),ArrayMax(data[0].slice(0,-1))];
+ 				}
+-				if (options.exist('log')) caxis = [Math.log10(caxis[0])/Math.log10(options.getfieldvalue('log')),Math.log10(caxis[1])/Math.log10(options.getfieldvalue('log'))];
++				if (options.getfieldvalue('log',10)!='off') caxis = [Math.log10(caxis[0])/Math.log10(options.getfieldvalue('log')),Math.log10(caxis[1])/Math.log10(options.getfieldvalue('log'))];
+ 				
+ 				for(var i = 0; i < data.length; i++){					
+ 					datamin = caxis[0];
+Index: ../trunk-jpl/src/m/plot/applyoptions.js
+===================================================================
+--- ../trunk-jpl/src/m/plot/applyoptions.js	(revision 20512)
++++ ../trunk-jpl/src/m/plot/applyoptions.js	(revision 20513)
+@@ -29,7 +29,6 @@
+ 			//Variable options initialization {{{
+ 			
+ 			var caxis = options.getfieldvalue('caxis',[ArrayMin(data),ArrayMax(data)]);
+-			//if (options.exist('log')) options.changefieldvalue('caxis',[ArrayMin(data),ArrayMax(data)]);
+ 			var canvassize = options.getfieldvalue('canvassize',480);
+ 			var cheight;
+ 			var cwidth;
+@@ -48,7 +47,7 @@
+ 			var caxisdelta = caxis[1] - caxis[0];
+ 			var clabelitem;
+ 			var precision=options.getfieldvalue('colorbarprecision',3);
+-			if (options.exist('log')) {
++			if (options.getfieldvalue('log',10)!='off') {
+ 				for (var i = cdivisions; i >= 0; i--) {
+ 					if (caxisdelta*i/cdivisions==caxis[0]) {
+ 						labels[i] = (caxis[0]).toPrecision(precision);
+@@ -229,11 +228,11 @@
+ 		
+ 	var cmap = options.getfieldvalue('cmap','jet');
+ 	var colorbar = colorbars[cmap];
+-	if (options.exist('log')) {
++	if (options.getfieldvalue('log',10)!='off') {
+ 		for (var i = 0; i < colorbar.length; i++) {
+ 			color = colorbar[colorbar.length-i-1];
+ 			color = [Math.round(color[0]*255),Math.round(color[1]*255),Math.round(color[2]*255)];	
+-			tgradient.addColorStop(1.0-Math.exp(Math.log((colorbar.length-i)/colorbar.length)/Math.log(options.getfieldvalue('log',Math.E))*i/colorbar.length),'rgba('+color.toString()+',1.0)');
++			tgradient.addColorStop(1.0-Math.exp(Math.log((colorbar.length-i)/colorbar.length)/Math.log(options.getfieldvalue('log',10))*i/colorbar.length),'rgba('+color.toString()+',1.0)');
+ 		}
+ 	} else {
+ 		for (var i = 0; i < colorbar.length; i++) {
+Index: ../trunk-jpl/src/m/plot/processdata.js
+===================================================================
+--- ../trunk-jpl/src/m/plot/processdata.js	(revision 20512)
++++ ../trunk-jpl/src/m/plot/processdata.js	(revision 20513)
+@@ -142,7 +142,7 @@
+ 		}
+ 
+ 		//log?
+-		if (options.exist('log')){
++		if (options.getfieldvalue('log',10)!='off'){
+ 			var bounds=options.getfieldvalue('caxis',[ArrayMin(data),ArrayMax(data)]);
+ 			for(var i=0;i<md.mesh.numberofelements;i++)if(data[i]<bounds[0])data[i]=bounds[0];
+ 			for(var i=0;i<md.mesh.numberofelements;i++)if(data[i]<=0){
+@@ -183,7 +183,7 @@
+ 		}
+ 
+ 		//log?
+-		if (options.exist('log')){
++		if (options.getfieldvalue('log',10)!='off'){
+ 			var bounds=options.getfieldvalue('caxis',[ArrayMin(data),ArrayMax(data)]);
+ 			for(var i=0;i<md.mesh.numberofvertices;i++)if(data[i]<bounds[0])data[i]=bounds[0];
+ 			for(var i=0;i<md.mesh.numberofvertices;i++)if(data[i]>bounds[1])data[i]=bounds[1];
+@@ -201,7 +201,7 @@
+         datatype=5;
+ 		
+ 		//log?	
+-		if (options.exist('log')){
++		if (options.getfieldvalue('log',10)!='off'){
+ 			var bounds=options.getfieldvalue('caxis',[ArrayMin(data),ArrayMax(data)]);
+ 			for(var i=0;i<md.mesh.numberofvertices;i++) {
+ 				for(var j=0;j<data[i].length;j++) {
Index: /issm/oecreview/Archive/20496-20544/ISSM-20513-20514.diff
===================================================================
--- /issm/oecreview/Archive/20496-20544/ISSM-20513-20514.diff	(revision 20545)
+++ /issm/oecreview/Archive/20496-20544/ISSM-20513-20514.diff	(revision 20545)
@@ -0,0 +1,80 @@
+Index: ../trunk-jpl/src/m/plot/plot_unit.js
+===================================================================
+--- ../trunk-jpl/src/m/plot/plot_unit.js	(revision 20513)
++++ ../trunk-jpl/src/m/plot/plot_unit.js	(revision 20514)
+@@ -95,7 +95,7 @@
+ 			}
+ 			else{ //triangular elements	
+ 				caxis = options.getfieldvalue('caxis',[ArrayMin(data),ArrayMax(data)]);
+-				if (options.getfieldvalue('log',10)!='off') caxis = [Math.log10(caxis[0])/Math.log10(options.getfieldvalue('log')),Math.log10(caxis[1])/Math.log10(options.getfieldvalue('log'))];
++				if (options.getfieldvalue('log','off')!='off') caxis = [Math.log10(caxis[0])/Math.log10(options.getfieldvalue('log',10)),Math.log10(caxis[1])/Math.log10(options.getfieldvalue('log',10))];
+ 				datamin = caxis[0];
+ 				datamax = caxis[1];
+ 				datadelta = datamax - datamin;
+@@ -203,7 +203,7 @@
+ 				else {
+ 					caxis = [ArrayMin(data[0]),ArrayMax(data[0].slice(0,-1))];
+ 				}
+-				if (options.getfieldvalue('log',10)!='off') caxis = [Math.log10(caxis[0])/Math.log10(options.getfieldvalue('log')),Math.log10(caxis[1])/Math.log10(options.getfieldvalue('log'))];
++				if (options.getfieldvalue('log','off')!='off') caxis = [Math.log10(caxis[0])/Math.log10(options.getfieldvalue('log',10)),Math.log10(caxis[1])/Math.log10(options.getfieldvalue('log',10))];
+ 				
+ 				for(var i = 0; i < data.length; i++){					
+ 					datamin = caxis[0];
+Index: ../trunk-jpl/src/m/plot/processdata.js
+===================================================================
+--- ../trunk-jpl/src/m/plot/processdata.js	(revision 20513)
++++ ../trunk-jpl/src/m/plot/processdata.js	(revision 20514)
+@@ -142,7 +142,7 @@
+ 		}
+ 
+ 		//log?
+-		if (options.getfieldvalue('log',10)!='off'){
++		if (options.getfieldvalue('log','off')!='off'){
+ 			var bounds=options.getfieldvalue('caxis',[ArrayMin(data),ArrayMax(data)]);
+ 			for(var i=0;i<md.mesh.numberofelements;i++)if(data[i]<bounds[0])data[i]=bounds[0];
+ 			for(var i=0;i<md.mesh.numberofelements;i++)if(data[i]<=0){
+@@ -150,7 +150,7 @@
+ 			}
+ 			for(var i=0;i<md.mesh.numberofelements;i++){
+ 				if(!IsNaN(data[i])){
+-					data[i]=Math.log10(data[i])/Math.log10(options.getfieldvalue('log'));
++					data[i]=Math.log10(data[i])/Math.log10(options.getfieldvalue('log',10));
+ 				}
+ 			}
+ 		}
+@@ -183,7 +183,7 @@
+ 		}
+ 
+ 		//log?
+-		if (options.getfieldvalue('log',10)!='off'){
++		if (options.getfieldvalue('log','off')!='off'){
+ 			var bounds=options.getfieldvalue('caxis',[ArrayMin(data),ArrayMax(data)]);
+ 			for(var i=0;i<md.mesh.numberofvertices;i++)if(data[i]<bounds[0])data[i]=bounds[0];
+ 			for(var i=0;i<md.mesh.numberofvertices;i++)if(data[i]>bounds[1])data[i]=bounds[1];
+@@ -191,7 +191,7 @@
+ 				throw Error("Log option cannot be applied on negative values. Use caxis option (Rignot''s settings: [1.5 max(data)])");
+ 			}
+ 			for(var i=0;i<md.mesh.numberofvertices;i++){
+-			   data[i]=Math.log10(data[i])/Math.log10(options.getfieldvalue('log'));
++			   data[i]=Math.log10(data[i])/Math.log10(options.getfieldvalue('log',10));
+ 			}
+ 		}
+ 	}
+@@ -201,7 +201,7 @@
+         datatype=5;
+ 		
+ 		//log?	
+-		if (options.getfieldvalue('log',10)!='off'){
++		if (options.getfieldvalue('log','off')!='off'){
+ 			var bounds=options.getfieldvalue('caxis',[ArrayMin(data),ArrayMax(data)]);
+ 			for(var i=0;i<md.mesh.numberofvertices;i++) {
+ 				for(var j=0;j<data[i].length;j++) {
+@@ -222,7 +222,7 @@
+ 			}
+ 			for(var i=0;i<md.mesh.numberofvertices;i++){
+ 				for(var j=0;j<data[i].length;j++) {
+-					data[i][j]=Math.log10(data[i][j])/Math.log10(options.getfieldvalue('log'));
++					data[i][j]=Math.log10(data[i][j])/Math.log10(options.getfieldvalue('log',10));
+ 				}
+ 			}
+ 		}
Index: /issm/oecreview/Archive/20496-20544/ISSM-20514-20515.diff
===================================================================
--- /issm/oecreview/Archive/20496-20544/ISSM-20514-20515.diff	(revision 20545)
+++ /issm/oecreview/Archive/20496-20544/ISSM-20514-20515.diff	(revision 20545)
@@ -0,0 +1,93 @@
+Index: ../trunk-jpl/src/c/classes/Elements/TriaRef.cpp
+===================================================================
+--- ../trunk-jpl/src/c/classes/Elements/TriaRef.cpp	(revision 20514)
++++ ../trunk-jpl/src/c/classes/Elements/TriaRef.cpp	(revision 20515)
+@@ -196,7 +196,7 @@
+ 	int numnodes = this->NumberofNodes(finiteelement);
+ 
+ 	/*Get nodal functions derivatives in reference triangle*/
+-	IssmDouble* dbasis_ref=xNew<IssmDouble>(2*numnodes);
++	IssmDouble dbasis_ref[2*NUMNODESMAX];
+ 	GetNodalFunctionsDerivativesReference(dbasis_ref,gauss,finiteelement); 
+ 
+ 	/*Get Jacobian invert: */
+@@ -211,9 +211,6 @@
+ 		dbasis[numnodes*1+i] = Jinv[1][0]*dbasis_ref[0*numnodes+i]+Jinv[1][1]*dbasis_ref[1*numnodes+i];
+ 	}
+ 
+-	/*Clean up*/
+-	xDelete<IssmDouble>(dbasis_ref);
+-
+ }
+ /*}}}*/
+ void TriaRef::GetNodalFunctionsDerivativesReference(IssmDouble* dbasis,Gauss* gauss_in,int finiteelement){/*{{{*/
+Index: ../trunk-jpl/src/c/classes/Elements/PentaRef.cpp
+===================================================================
+--- ../trunk-jpl/src/c/classes/Elements/PentaRef.cpp	(revision 20514)
++++ ../trunk-jpl/src/c/classes/Elements/PentaRef.cpp	(revision 20515)
+@@ -442,7 +442,7 @@
+ 	int numnodes = this->NumberofNodes(finiteelement);
+ 
+ 	/*Get nodal functions derivatives in reference triangle*/
+-	IssmDouble* dbasis_ref=xNew<IssmDouble>(3*numnodes);
++	IssmDouble dbasis_ref[3*NUMNODESMAX];
+ 	GetNodalFunctionsDerivativesReference(dbasis_ref,gauss,finiteelement);
+ 
+ 	/*Get Jacobian invert: */
+@@ -460,9 +460,6 @@
+ 		dbasis[numnodes*1+i]=Jinv[1][0]*dbasis_ref[0*numnodes+i]+Jinv[1][1]*dbasis_ref[1*numnodes+i]+Jinv[1][2]*dbasis_ref[2*numnodes+i];
+ 		dbasis[numnodes*2+i]=Jinv[2][0]*dbasis_ref[0*numnodes+i]+Jinv[2][1]*dbasis_ref[1*numnodes+i]+Jinv[2][2]*dbasis_ref[2*numnodes+i];
+ 	}
+-
+-	/*Clean up*/
+-	xDelete<IssmDouble>(dbasis_ref);
+ }
+ /*}}}*/
+ void PentaRef::GetNodalFunctionsDerivativesReference(IssmDouble* dbasis,Gauss* gauss_in,int finiteelement){/*{{{*/
+Index: ../trunk-jpl/src/c/classes/Elements/SegRef.cpp
+===================================================================
+--- ../trunk-jpl/src/c/classes/Elements/SegRef.cpp	(revision 20514)
++++ ../trunk-jpl/src/c/classes/Elements/SegRef.cpp	(revision 20515)
+@@ -145,7 +145,7 @@
+ 	int numnodes = this->NumberofNodes(finiteelement);
+ 
+ 	/*Get nodal functions derivatives in reference triangle*/
+-	IssmDouble* dbasis_ref=xNew<IssmDouble>(numnodes);
++	IssmDouble dbasis_ref[1*NUMNODESMAX];
+ 	GetNodalFunctionsDerivativesReference(dbasis_ref,gauss,finiteelement); 
+ 
+ 	/*Get Jacobian invert: */
+@@ -157,10 +157,6 @@
+ 	for(int i=0;i<numnodes;i++){
+ 		dbasis[i] = Jinv*dbasis_ref[i];
+ 	}
+-
+-	/*Clean up*/
+-	xDelete<IssmDouble>(dbasis_ref);
+-
+ }
+ /*}}}*/
+ void SegRef::GetNodalFunctionsDerivativesReference(IssmDouble* dbasis,GaussSeg* gauss,int finiteelement){/*{{{*/
+Index: ../trunk-jpl/src/c/classes/Elements/TetraRef.cpp
+===================================================================
+--- ../trunk-jpl/src/c/classes/Elements/TetraRef.cpp	(revision 20514)
++++ ../trunk-jpl/src/c/classes/Elements/TetraRef.cpp	(revision 20515)
+@@ -224,7 +224,7 @@
+ 	int numnodes = this->NumberofNodes(finiteelement);
+ 
+ 	/*Get nodal functions derivatives in reference triangle*/
+-	IssmDouble* dbasis_ref=xNew<IssmDouble>(3*numnodes);
++	IssmDouble dbasis_ref[3*NUMNODESMAX];
+ 	GetNodalFunctionsDerivativesReference(dbasis_ref,gauss,finiteelement); 
+ 
+ 	/*Get Jacobian invert: */
+@@ -242,9 +242,6 @@
+ 		dbasis[numnodes*1+i]=Jinv[1][0]*dbasis_ref[0*numnodes+i]+Jinv[1][1]*dbasis_ref[1*numnodes+i]+Jinv[1][2]*dbasis_ref[2*numnodes+i];
+ 		dbasis[numnodes*2+i]=Jinv[2][0]*dbasis_ref[0*numnodes+i]+Jinv[2][1]*dbasis_ref[1*numnodes+i]+Jinv[2][2]*dbasis_ref[2*numnodes+i];
+ 	}
+-
+-	/*Clean up*/
+-	xDelete<IssmDouble>(dbasis_ref);
+ }
+ /*}}}*/
+ void TetraRef::GetNodalFunctionsDerivativesReference(IssmDouble* dbasis,GaussTetra* gauss,int finiteelement){/*{{{*/
Index: /issm/oecreview/Archive/20496-20544/ISSM-20515-20516.diff
===================================================================
--- /issm/oecreview/Archive/20496-20544/ISSM-20515-20516.diff	(revision 20545)
+++ /issm/oecreview/Archive/20496-20544/ISSM-20515-20516.diff	(revision 20545)
@@ -0,0 +1,53 @@
+Index: ../trunk-jpl/src/m/plot/manualcb.m
+===================================================================
+--- ../trunk-jpl/src/m/plot/manualcb.m	(revision 20515)
++++ ../trunk-jpl/src/m/plot/manualcb.m	(revision 20516)
+@@ -61,25 +61,39 @@
+ 	end
+ 	ytick  = (ztick-zmin)/(zmax-zmin);
+ else
+-	ztick = getfieldvalue(options,'tick',round(logspace(log(zmin)/log(10),log(zmax)/log(10),8)));
++	%old method
++	ztick = getfieldvalue(options,'tick',round( logspace(log10(zmin),log10(zmax),8) ));
+ 	ytick = linspace(0,1,numel(ztick));
++
++	%New method
++	test=logspace(-10,10,21);
++	pos=find(test>=zmin & test<=zmax);
++	ztick= test(pos);
++	ytick= (log(ztick) - log(zmin))/(log(zmax) - log(zmin));
+ end
+ 
+ %Display colorbar
+ hold on
+ numcolors=size(cmap,1);
+-if strcmpi(getfieldvalue(options,'orientation','vertical'),'vertical'),
+-	image_rgb = ind2rgb(repmat((1:numcolors)',1,2),cmap);
+-else
+-	image_rgb = ind2rgb(repmat((1:numcolors)',1,2)',cmap);
+-end
+ if 1,
+ 	%disappears somtimes
+-	imagesc([0 1],[0 1],repmat(image_rgb,[1 10 1]));
++	if strcmpi(getfieldvalue(options,'orientation','vertical'),'vertical'),
++		image_rgb = ind2rgb(repmat((1:numcolors)',1,10),cmap);
++	else
++		image_rgb = ind2rgb(repmat((1:numcolors),10,1),cmap);
++	end
++
++	imagesc([0 1],[0 1],image_rgb);
+ else
+ 	%Creates triangles when exported as pdf
+-	for i=1:numcolors,
+-		patch([0,0,1,1],[(i-1)/numcolors,i/numcolors,i/numcolors,(i-1)/numcolors],'none','FaceColor',cmap(i,:),'Clipping','off','EdgeColor','none')
++	if strcmpi(getfieldvalue(options,'orientation','vertical'),'vertical'),
++		for i=1:numcolors,
++			patch([0,0,1,1],[(i-1)/numcolors,i/numcolors,i/numcolors,(i-1)/numcolors],0,'FaceColor',cmap(i,:),'Clipping','off','EdgeColor','none')
++		end
++	else
++		for i=1:numcolors,
++			patch([(i-1)/numcolors,i/numcolors,i/numcolors,(i-1)/numcolors],[0,0,1,1],0,'FaceColor',cmap(i,:),'Clipping','off','EdgeColor','none')
++		end
+ 	end
+ end
+ patch([0,0,1,1],[0,1,1,0],'k','FaceColor','none','Clipping','off')
Index: /issm/oecreview/Archive/20496-20544/ISSM-20516-20517.diff
===================================================================
--- /issm/oecreview/Archive/20496-20544/ISSM-20516-20517.diff	(revision 20545)
+++ /issm/oecreview/Archive/20496-20544/ISSM-20516-20517.diff	(revision 20545)
@@ -0,0 +1,15 @@
+Index: ../trunk-jpl/src/c/analyses/LevelsetAnalysis.cpp
+===================================================================
+--- ../trunk-jpl/src/c/analyses/LevelsetAnalysis.cpp	(revision 20516)
++++ ../trunk-jpl/src/c/analyses/LevelsetAnalysis.cpp	(revision 20517)
+@@ -77,10 +77,6 @@
+ /*Finite element Analysis*/
+ void           LevelsetAnalysis::Core(FemModel* femmodel){/*{{{*/
+ 
+-	#if !defined(_DEVELOPMENT_)
+-	_error_("Not implemented yet");
+-	#endif
+-
+ 	/*parameters: */
+ 	int  stabilization;
+ 	bool save_results;
Index: /issm/oecreview/Archive/20496-20544/ISSM-20517-20518.diff
===================================================================
--- /issm/oecreview/Archive/20496-20544/ISSM-20517-20518.diff	(revision 20545)
+++ /issm/oecreview/Archive/20496-20544/ISSM-20517-20518.diff	(revision 20545)
@@ -0,0 +1,15 @@
+Index: ../trunk-jpl/src/m/classes/calving.m
+===================================================================
+--- ../trunk-jpl/src/m/classes/calving.m	(revision 20517)
++++ ../trunk-jpl/src/m/classes/calving.m	(revision 20518)
+@@ -38,8 +38,8 @@
+ 			%Early return
+ 			if (solution~=TransientSolutionEnum() | md.transient.ismovingfront==0), return; end
+ 
+-			md = checkfield(md,'fieldname','calving.calvingrate(1:md.mesh.numberofvertices,:)','>=',0,'timeseries',1,'NaN',1,'Inf',1);
+-			md = checkfield(md,'fieldname','calving.meltingrate(1:md.mesh.numberofvertices,:)','>=',0,'timeseries',1,'NaN',1,'Inf',1);
++			md = checkfield(md,'fieldname','calving.calvingrate','>=',0,'timeseries',1,'NaN',1,'Inf',1);
++			md = checkfield(md,'fieldname','calving.meltingrate','>=',0,'timeseries',1,'NaN',1,'Inf',1);
+ 		end % }}}
+ 		function disp(self) % {{{
+ 			disp(sprintf('   Calving parameters:'));
Index: /issm/oecreview/Archive/20496-20544/ISSM-20518-20519.diff
===================================================================
--- /issm/oecreview/Archive/20496-20544/ISSM-20518-20519.diff	(revision 20545)
+++ /issm/oecreview/Archive/20496-20544/ISSM-20518-20519.diff	(revision 20545)
@@ -0,0 +1,13 @@
+Index: ../trunk-jpl/src/m/miscellaneous/transientrestart.m
+===================================================================
+--- ../trunk-jpl/src/m/miscellaneous/transientrestart.m	(revision 20518)
++++ ../trunk-jpl/src/m/miscellaneous/transientrestart.m	(revision 20519)
+@@ -17,7 +17,7 @@
+ end
+ 
+ %Change time
+-md.timestepping.start_time = results.time/md.constants.yts;
++md.timestepping.start_time = results.time;
+ 
+ %Change initialization fields
+ if isfield(results,'Vx'),          md.initialization.vx=results.Vx; end
Index: /issm/oecreview/Archive/20496-20544/ISSM-20519-20520.diff
===================================================================
--- /issm/oecreview/Archive/20496-20544/ISSM-20519-20520.diff	(revision 20545)
+++ /issm/oecreview/Archive/20496-20544/ISSM-20519-20520.diff	(revision 20545)
@@ -0,0 +1,14 @@
+Index: ../trunk-jpl/src/m/coordsystems/gdaltransform.m
+===================================================================
+--- ../trunk-jpl/src/m/coordsystems/gdaltransform.m	(revision 20519)
++++ ../trunk-jpl/src/m/coordsystems/gdaltransform.m	(revision 20520)
+@@ -22,6 +22,9 @@
+ 	fclose(fid);
+ 
+ 	[s,r]=system(['gdaltransform -s_srs ',proj_in,' -t_srs ',proj_out,'  < ' temproot '/.rand1234.txt > ' temproot '/.rand1235.txt']);
++	if s~=0 | ~isempty(deblank(r)),
++		error(r);
++	end
+ 	A=textread([temproot '/.rand1235.txt']);
+ 	xout=A(:,1);
+ 	yout=A(:,2);
Index: /issm/oecreview/Archive/20496-20544/ISSM-20520-20521.diff
===================================================================
--- /issm/oecreview/Archive/20496-20544/ISSM-20520-20521.diff	(revision 20545)
+++ /issm/oecreview/Archive/20496-20544/ISSM-20520-20521.diff	(revision 20545)
@@ -0,0 +1,17 @@
+Index: ../trunk-jpl/test/NightlyRun/test124.m
+===================================================================
+--- ../trunk-jpl/test/NightlyRun/test124.m	(revision 20520)
++++ ../trunk-jpl/test/NightlyRun/test124.m	(revision 20521)
+@@ -20,9 +20,9 @@
+ 	'Vx2','Vy2','Vel2','Pressure2','Bed2','Surface2','Thickness2',...
+ 	'Vx3','Vy3','Vel3','Pressure3','Bed3','Surface3','Thickness3'};
+ field_tolerances={...
+-	2e-09,3.0e-9,3.0e-9,1e-10,1e-13,1e-12,1e-12,...
+-	1e-09,3e-10,8e-10,1e-10,1e-10,1e-10,1e-10,...
+-	1e-09,3e-10,8e-10,1e-10,1e-10,1e-10,1e-10};
++	2e-09,3e-9,3.0e-9,1e-10,1e-13,1e-12,1e-12,...
++	2e-09,3e-9,8e-10,1e-10,1e-10,1e-10,1e-10,...
++	2e-09,3e-9,8e-10,1e-10,1e-10,1e-10,1e-10};
+ field_values={...
+ 	(md.results.TransientSolution(1).Vx),...
+ 	(md.results.TransientSolution(1).Vy),...
Index: /issm/oecreview/Archive/20496-20544/ISSM-20521-20522.diff
===================================================================
--- /issm/oecreview/Archive/20496-20544/ISSM-20521-20522.diff	(revision 20545)
+++ /issm/oecreview/Archive/20496-20544/ISSM-20521-20522.diff	(revision 20545)
@@ -0,0 +1,37 @@
+Index: ../trunk-jpl/src/m/classes/clusters/lonestar.m
+===================================================================
+--- ../trunk-jpl/src/m/classes/clusters/lonestar.m	(revision 20521)
++++ ../trunk-jpl/src/m/classes/clusters/lonestar.m	(revision 20522)
+@@ -122,10 +122,17 @@
+ 			 for i=1:numel(cluster.modules),
+ 				 fprintf(fid,['module load ' cluster.modules{i} '\n']);
+ 			 end
++
++			 %fprintf(fid,'export KMP_AFFINITY="granularity=fine,compact,verbose" \n\n');
++
+ 			 if length(find(cluster.email=='@'))>0
+-				 fprintf(fid,'#SBATCH --mail-user=%s \n',cluster.email);
+-				 fprintf(fid,'#SBATCH --mail-type=end \n\n');
++				 %fprintf(fid,'#SBATCH --mail-user=%s \n',cluster.email);
++				 %fprintf(fid,'#SBATCH --mail-type=end \n\n');
++
++				 fprintf(fid,'ssh login1 "mail -s ''SLURM Jobid=${SLURM_JOBID} Name=${SLURM_JOB_NAME} Began on Lonestar 5.'' \\ \n');
++				 fprintf(fid,'%s <<< ''Job Started'' " \n\n',cluster.email);
+ 			 end
++
+ 			 fprintf(fid,'export PATH="$PATH:."\n\n');
+ 			 fprintf(fid,'export ISSM_DIR="%s/../"\n',cluster.codepath); %FIXME
+ 			 fprintf(fid,'source $ISSM_DIR/etc/environment.sh\n');       %FIXME
+@@ -134,6 +141,12 @@
+ 			 if ~io_gather, %concatenate the output files:
+ 				 fprintf(fid,'cat %s.outbin.* > %s.outbin',modelname,modelname);
+ 			 end
++
++			 if length(find(cluster.email=='@'))>0
++				 fprintf(fid,'\n');
++				 fprintf(fid,'ssh login1 "mail -s ''SLURM Jobid=${SLURM_JOBID} Name=${SLURM_JOB_NAME} Ended on Lonestar 5.'' \\ \n');
++				 fprintf(fid,'%s <<< ''Job Started'' " \n\n',cluster.email);
++			 end
+ 			 fclose(fid);
+ 
+ 			 %in interactive mode, create a run file, and errlog and outlog file
Index: /issm/oecreview/Archive/20496-20544/ISSM-20522-20523.diff
===================================================================
--- /issm/oecreview/Archive/20496-20544/ISSM-20522-20523.diff	(revision 20545)
+++ /issm/oecreview/Archive/20496-20544/ISSM-20522-20523.diff	(revision 20545)
@@ -0,0 +1,48 @@
+Index: ../trunk-jpl/src/m/coordsystems/gdaltransform.m
+===================================================================
+--- ../trunk-jpl/src/m/coordsystems/gdaltransform.m	(revision 20522)
++++ ../trunk-jpl/src/m/coordsystems/gdaltransform.m	(revision 20523)
+@@ -5,26 +5,33 @@
+ %      [x,y] = gdaltransform(x1,y1,epsg_in, epsg_out);
+ %
+ %   Example: 
+-%      [x,y] = gdaltransform(md.mesh.lat,md.mesh.long,'EPSG:3184','EPSG:3411'); 
++%      [x,y] = gdaltransform(md.mesh.long,md.mesh.lat,'EPSG:4326','EPSG:3031')
+ %
+ %   For reference: 
+-%       EPSG: 4326 (lat,long)
+-%       EPSG: 3411  (greenland, +proj=stere +lat_0=90 +lat_ts=70 +lon_0=-45 +k=1 +x_0=0 +y_0=0 +a=6378273 +b=6356889.449 +units=m +no_defs)
+-%       EPSG: 3031 (antarctica, +proj=stere +lat_0=-90 +lat_ts=-71 +lon_0=0 +k=1 +x_0=0 +y_0=0 +datum=WGS84 +units=m +no_defs)
++%      EPSG: 4326 (lat,long)
++%      EPSG: 3411 (Greenland,  UPS 45W, 70N)
++%      EPSG: 3031 (Antarctica, UPS 0E,  71S)
++%
++%      ll2xy default projection Antarctica:
++%        +proj=stere +lat_0=-90 +lat_ts=-71 +lon_0=0 +k=1 +x_0=0 +y_0=0 +a=6378273 +b=6356889.448564109 +units=m +no_defs
++%      ll2xy default projection Greenland:
++%        +proj=stere +lat_0=90 +lat_ts=70 +lon_0=-45 +k=1 +x_0=0 +y_0=0 +a=6378273 +b=6356889.448564109 +units=m +no_defs
++%      Bamber's Greeland projection
++%        +proj=stere +lat_0=90 +lat_ts=71 +lon_0=-39 +k=1 +x_0=0 +y_0=0 +a=6378273 +b=6356889.448564109 +units=m +no_defs
++%
++%      To get proj.4 string from EPSG, use gdalsrsinfo. Example:    gdalsrsinfo "EPSG:4326" | grep "PROJ.4"
+ 
+ 	%give ourselves a unique temporary directory: 
+ 	temproot=tempname; mkdir(temproot);
+ 
+ 	fid=fopen([temproot '/.rand1234.txt'],'w');
+-	for i=1:length(x),
+-		fprintf(fid,'%g %g\n',x(i),y(i));
+-	end
++	fprintf(fid,'%8g %8g\n',[x(:) y(:)]');
+ 	fclose(fid);
+ 
+ 	[s,r]=system(['gdaltransform -s_srs ',proj_in,' -t_srs ',proj_out,'  < ' temproot '/.rand1234.txt > ' temproot '/.rand1235.txt']);
+ 	if s~=0 | ~isempty(deblank(r)),
+ 		error(r);
+ 	end
+-	A=textread([temproot '/.rand1235.txt']);
+-	xout=A(:,1);
+-	yout=A(:,2);
++	A=load([temproot '/.rand1235.txt']);
++	xout=A(:,1); xout=reshape(xout,size(x));
++	yout=A(:,2); yout=reshape(yout,size(y));
Index: /issm/oecreview/Archive/20496-20544/ISSM-20523-20524.diff
===================================================================
--- /issm/oecreview/Archive/20496-20544/ISSM-20523-20524.diff	(revision 20545)
+++ /issm/oecreview/Archive/20496-20544/ISSM-20523-20524.diff	(revision 20545)
@@ -0,0 +1,24 @@
+Index: ../trunk-jpl/src/m/classes/clusters/lonestar.m
+===================================================================
+--- ../trunk-jpl/src/m/classes/clusters/lonestar.m	(revision 20523)
++++ ../trunk-jpl/src/m/classes/clusters/lonestar.m	(revision 20524)
+@@ -129,8 +129,7 @@
+ 				 %fprintf(fid,'#SBATCH --mail-user=%s \n',cluster.email);
+ 				 %fprintf(fid,'#SBATCH --mail-type=end \n\n');
+ 
+-				 fprintf(fid,'ssh login1 "mail -s ''SLURM Jobid=${SLURM_JOBID} Name=${SLURM_JOB_NAME} Began on Lonestar 5.'' \\ \n');
+-				 fprintf(fid,'%s <<< ''Job Started'' " \n\n',cluster.email);
++				 fprintf(fid,'ssh login1 "mail -s ''SLURM Jobid=${SLURM_JOBID} Name=${SLURM_JOB_NAME} Began on Lonestar 5.'' %s <<< ''Job Started'' " \n\n',cluster.email);
+ 			 end
+ 
+ 			 fprintf(fid,'export PATH="$PATH:."\n\n');
+@@ -144,8 +143,7 @@
+ 
+ 			 if length(find(cluster.email=='@'))>0
+ 				 fprintf(fid,'\n');
+-				 fprintf(fid,'ssh login1 "mail -s ''SLURM Jobid=${SLURM_JOBID} Name=${SLURM_JOB_NAME} Ended on Lonestar 5.'' \\ \n');
+-				 fprintf(fid,'%s <<< ''Job Started'' " \n\n',cluster.email);
++				 fprintf(fid,'ssh login1 "mail -s ''SLURM Jobid=${SLURM_JOBID} Name=${SLURM_JOB_NAME} Ended on Lonestar 5.'' %s <<< ''Job Started'' " \n\n',cluster.email);
+ 			 end
+ 			 fclose(fid);
+ 
Index: /issm/oecreview/Archive/20496-20544/ISSM-20524-20525.diff
===================================================================
--- /issm/oecreview/Archive/20496-20544/ISSM-20524-20525.diff	(revision 20545)
+++ /issm/oecreview/Archive/20496-20544/ISSM-20524-20525.diff	(revision 20545)
@@ -0,0 +1,26 @@
+Index: ../trunk-jpl/test/NightlyRun/test404.m
+===================================================================
+--- ../trunk-jpl/test/NightlyRun/test404.m	(revision 20524)
++++ ../trunk-jpl/test/NightlyRun/test404.m	(revision 20525)
+@@ -9,7 +9,7 @@
+ 
+ %Fields and tolerances to track changes
+ field_names     ={'Vx','Vy','Vz','Vel','Pressure'};
+-field_tolerances={6e-07,6e-07,2e-06,1e-06,3e-07};
++field_tolerances={6e-07,6e-07,2e-06,1e-06,5e-07};
+ field_values={...
+ 	(md.results.StressbalanceSolution.Vx),...
+ 	(md.results.StressbalanceSolution.Vy),...
+Index: ../trunk-jpl/test/NightlyRun/test404.py
+===================================================================
+--- ../trunk-jpl/test/NightlyRun/test404.py	(revision 20524)
++++ ../trunk-jpl/test/NightlyRun/test404.py	(revision 20525)
+@@ -19,7 +19,7 @@
+ 
+ #Fields and tolerances to track changes
+ field_names     =['Vx','Vy','Vz','Vel','Pressure']
+-field_tolerances=[6e-07,6e-07,2e-06,1e-06,3e-07]
++field_tolerances=[6e-07,6e-07,2e-06,1e-06,5e-07]
+ field_values=[\
+ 	md.results.StressbalanceSolution.Vx,\
+ 	md.results.StressbalanceSolution.Vy,\
Index: /issm/oecreview/Archive/20496-20544/ISSM-20525-20526.diff
===================================================================
--- /issm/oecreview/Archive/20496-20544/ISSM-20525-20526.diff	(revision 20545)
+++ /issm/oecreview/Archive/20496-20544/ISSM-20525-20526.diff	(revision 20545)
@@ -0,0 +1,13 @@
+Index: ../trunk-jpl/src/m/classes/independent.py
+===================================================================
+--- ../trunk-jpl/src/m/classes/independent.py	(revision 20525)
++++ ../trunk-jpl/src/m/classes/independent.py	(revision 20526)
+@@ -51,7 +51,7 @@
+ 			if self.nods==0:
+ 				raise TypeError("independent checkconsistency error: nods should be set to the size of the independent variable")
+ 
+-		if self.fov_forward_indices:
++		if len(self.fov_forward_indices) > 0:
+ 			if not strcmpi(driver,'fov_forward'):
+ 				raise TypeError("cannot declare an independent with fov_forward_indices when the driver is not fov_forward!")
+ 			if self.nods==0:
Index: /issm/oecreview/Archive/20496-20544/ISSM-20526-20527.diff
===================================================================
--- /issm/oecreview/Archive/20496-20544/ISSM-20526-20527.diff	(revision 20545)
+++ /issm/oecreview/Archive/20496-20544/ISSM-20526-20527.diff	(revision 20545)
@@ -0,0 +1,26 @@
+Index: ../trunk-jpl/test/NightlyRun/test3020.py
+===================================================================
+--- ../trunk-jpl/test/NightlyRun/test3020.py	(revision 20526)
++++ ../trunk-jpl/test/NightlyRun/test3020.py	(revision 20527)
+@@ -61,8 +61,8 @@
+ md=SetIceShelfBC(md)
+ 
+ md=solve(md,TransientSolutionEnum())
+-V0=md.results.TransientSolution[2].IceVolume
+-MaxV0=md.results.TransientSolution[2].MaxVel
++V0=md.results.TransientSolution[-1].IceVolume
++MaxV0=md.results.TransientSolution[-1].MaxVel
+ 
+ #backward
+ md=copy.deepcopy(md2)
+@@ -73,8 +73,8 @@
+ md=SetIceShelfBC(md)
+ 
+ md=solve(md,TransientSolutionEnum())
+-V2=md.results.TransientSolution[2].IceVolume
+-MaxV2=md.results.TransientSolution[2].MaxVel
++V2=md.results.TransientSolution[-1].IceVolume
++MaxV2=md.results.TransientSolution[-1].MaxVel
+ 
+ #compute resulting derivative
+ dVdh_an=(V2-V0)/deltaH
Index: /issm/oecreview/Archive/20496-20544/ISSM-20527-20528.diff
===================================================================
--- /issm/oecreview/Archive/20496-20544/ISSM-20527-20528.diff	(revision 20545)
+++ /issm/oecreview/Archive/20496-20544/ISSM-20527-20528.diff	(revision 20545)
@@ -0,0 +1,12 @@
+Index: ../trunk-jpl/src/m/classes/independent.py
+===================================================================
+--- ../trunk-jpl/src/m/classes/independent.py	(revision 20527)
++++ ../trunk-jpl/src/m/classes/independent.py	(revision 20528)
+@@ -1,6 +1,7 @@
+ import numpy
+ from pairoptions import pairoptions
+ from fielddisplay import fielddisplay
++from checkfield import checkfield
+ from MatlabFuncs import *
+ from EnumDefinitions import *
+ 
Index: /issm/oecreview/Archive/20496-20544/ISSM-20528-20529.diff
===================================================================
--- /issm/oecreview/Archive/20496-20544/ISSM-20528-20529.diff	(revision 20545)
+++ /issm/oecreview/Archive/20496-20544/ISSM-20528-20529.diff	(revision 20545)
@@ -0,0 +1,16 @@
+Index: ../trunk-jpl/src/c/Makefile.am
+===================================================================
+--- ../trunk-jpl/src/c/Makefile.am	(revision 20528)
++++ ../trunk-jpl/src/c/Makefile.am	(revision 20529)
+@@ -592,8 +592,11 @@
+ if !WINDOWS
+ if !STANDALONE_LIBRARIES
+ libISSMCore_la_LIBADD = $(PETSCLIB) $(TAOLIB) $(M1QN3LIB) $(PLAPACKLIB) $(MUMPSLIB) $(SUPERLULIB) $(SPOOLESLIB) $(SCALAPACKLIB) $(BLACSLIB) $(HYPRELIB) $(SPAILIB) $(PROMETHEUSLIB) $(PASTIXLIB) $(MLLIB) $(DAKOTALIB) $(METISLIB) $(CHACOLIB) $(SCOTCHLIB) $(BLASLAPACKLIB) $(MKLLIB) $(MPILIB) $(MATHLIB) $(GRAPHICSLIB) $(MULTITHREADINGLIB) $(OSLIBS) $(GSLLIB)   $(ADOLCLIB) $(AMPILIB) $(METEOIOLIB) $(SNOWPACKLIB)
++if FORTRAN
++libISSMCore_la_LIBADD += $(FLIBS) $(FORTRANLIB)
+ endif
+ endif
++endif
+ 
+ if WRAPPERS
+ libISSMModules_la_SOURCES = $(modules_sources)
Index: /issm/oecreview/Archive/20496-20544/ISSM-20529-20530.diff
===================================================================
--- /issm/oecreview/Archive/20496-20544/ISSM-20529-20530.diff	(revision 20545)
+++ /issm/oecreview/Archive/20496-20544/ISSM-20529-20530.diff	(revision 20545)
@@ -0,0 +1,35 @@
+Index: ../trunk-jpl/src/c/Makefile.am
+===================================================================
+--- ../trunk-jpl/src/c/Makefile.am	(revision 20529)
++++ ../trunk-jpl/src/c/Makefile.am	(revision 20530)
+@@ -646,7 +646,6 @@
+ 
+ libISSMOverload_la_CFLAGS  = -D_C_ -fPIC $(COPTFLAGS) $(CFLAGS)
+ #}}}
+-
+ #Executable {{{
+ if ANDROID
+ if ANDROIDEXE
+Index: ../trunk-jpl/jenkins/jenkins.sh
+===================================================================
+--- ../trunk-jpl/jenkins/jenkins.sh	(revision 20529)
++++ ../trunk-jpl/jenkins/jenkins.sh	(revision 20530)
+@@ -7,6 +7,9 @@
+ rm -rf $ISSM_DIR/nightlylog
+ mkdir  $ISSM_DIR/nightlylog
+ 
++#Server URI
++SERVER='https://ross.ics.uci.edu:8080'
++
+ #Get configuration
+ #Source config file{{{
+ if [ $# -ne 1 ];
+@@ -43,7 +46,7 @@
+ 
+ 	#Get changes from jenkins itself (svn requires credentials)
+ 	rm -rf changes
+-	wget http://ross.ics.uci.edu:8080/job/$JOB_NAME/$BUILD_NUMBER/changes > /dev/null 2>&1
++	wget $SERVER/job/$JOB_NAME/$BUILD_NUMBER/changes > /dev/null 2>&1
+ 
+ 	#Process html page and get the list of files that has changed (tricky...)
+ 	cat changes | grep 'alt="The file was modified"' |sed -e 's/alt="The file was modified"/\
Index: /issm/oecreview/Archive/20496-20544/ISSM-20530-20531.diff
===================================================================
--- /issm/oecreview/Archive/20496-20544/ISSM-20530-20531.diff	(revision 20545)
+++ /issm/oecreview/Archive/20496-20544/ISSM-20530-20531.diff	(revision 20545)
@@ -0,0 +1,13 @@
+Index: ../trunk-jpl/src/m/classes/clusters/lonestar.m
+===================================================================
+--- ../trunk-jpl/src/m/classes/clusters/lonestar.m	(revision 20530)
++++ ../trunk-jpl/src/m/classes/clusters/lonestar.m	(revision 20531)
+@@ -143,7 +143,7 @@
+ 
+ 			 if length(find(cluster.email=='@'))>0
+ 				 fprintf(fid,'\n');
+-				 fprintf(fid,'ssh login1 "mail -s ''SLURM Jobid=${SLURM_JOBID} Name=${SLURM_JOB_NAME} Ended on Lonestar 5.'' %s <<< ''Job Started'' " \n\n',cluster.email);
++				 fprintf(fid,'ssh login1 "mail -s ''SLURM Jobid=${SLURM_JOBID} Name=${SLURM_JOB_NAME} Ended on Lonestar 5.'' %s <<< ''Job Ended'' " \n\n',cluster.email);
+ 			 end
+ 			 fclose(fid);
+ 
Index: /issm/oecreview/Archive/20496-20544/ISSM-20531-20532.diff
===================================================================
--- /issm/oecreview/Archive/20496-20544/ISSM-20531-20532.diff	(revision 20545)
+++ /issm/oecreview/Archive/20496-20544/ISSM-20531-20532.diff	(revision 20545)
@@ -0,0 +1,209 @@
+Index: ../trunk-jpl/examples/IceflowModels/EISMINT.par
+===================================================================
+--- ../trunk-jpl/examples/IceflowModels/EISMINT.par	(revision 20531)
++++ ../trunk-jpl/examples/IceflowModels/EISMINT.par	(revision 20532)
+@@ -28,7 +28,7 @@
+ smb_max=0.5; %m/yr
+ sb=10^-2/1000.; %m/yr/m
+ rel=450.*1000.; %m
+-md.surfaceforcings.mass_balance=min(smb_max,sb*(rel-radius));
++md.smb.mass_balance=min(smb_max,sb*(rel-radius));
+ 
+ disp('      creating velocities');
+ constant=0.3;
+Index: ../trunk-jpl/examples/IceBridge/Greenland_noOIB.par
+===================================================================
+--- ../trunk-jpl/examples/IceBridge/Greenland_noOIB.par	(revision 20531)
++++ ../trunk-jpl/examples/IceBridge/Greenland_noOIB.par	(revision 20532)
+@@ -39,8 +39,8 @@
+ md.initialization.temperature=InterpFromGridToMesh(x1,y1,temp,md.mesh.x,md.mesh.y,0)+273.15;
+ 
+ disp('   Interpolating surface mass balance');
+-md.surfaceforcings.mass_balance=InterpFromGridToMesh(x1,y1,smb,md.mesh.x,md.mesh.y,0);
+-md.surfaceforcings.mass_balance=md.surfaceforcings.mass_balance*md.materials.rho_water/md.materials.rho_ice;
++md.smb.mass_balance=InterpFromGridToMesh(x1,y1,smb,md.mesh.x,md.mesh.y,0);
++md.smb.mass_balance=md.smb.mass_balance*md.materials.rho_water/md.materials.rho_ice;
+ 
+ disp('   Construct basal friction parameters');
+ md.friction.coefficient=30*ones(md.mesh.numberofvertices,1);
+Index: ../trunk-jpl/examples/IceBridge/Greenland_cheatsheet.par
+===================================================================
+--- ../trunk-jpl/examples/IceBridge/Greenland_cheatsheet.par	(revision 20531)
++++ ../trunk-jpl/examples/IceBridge/Greenland_cheatsheet.par	(revision 20532)
+@@ -65,8 +65,8 @@
+ md.initialization.temperature=InterpFromGridToMesh(x1,y1,temp,md.mesh.x,md.mesh.y,0)+273.15;
+ 
+ disp('   Interpolating surface mass balance');
+-md.surfaceforcings.mass_balance=InterpFromGridToMesh(x1,y1,smb,md.mesh.x,md.mesh.y,0);
+-md.surfaceforcings.mass_balance=md.surfaceforcings.mass_balance*md.materials.rho_water/md.materials.rho_ice;
++md.smb.mass_balance=InterpFromGridToMesh(x1,y1,smb,md.mesh.x,md.mesh.y,0);
++md.smb.mass_balance=md.smb.mass_balance*md.materials.rho_water/md.materials.rho_ice;
+ 
+ disp('   Construct basal friction parameters');
+ md.friction.coefficient=30*ones(md.mesh.numberofvertices,1);
+Index: ../trunk-jpl/examples/IceBridge/Greenland.par
+===================================================================
+--- ../trunk-jpl/examples/IceBridge/Greenland.par	(revision 20531)
++++ ../trunk-jpl/examples/IceBridge/Greenland.par	(revision 20532)
+@@ -61,8 +61,8 @@
+ md.initialization.temperature=InterpFromGridToMesh(x1,y1,temp,md.mesh.x,md.mesh.y,0)+273.15;
+ 
+ disp('   Interpolating surface mass balance');
+-md.surfaceforcings.mass_balance=InterpFromGridToMesh(x1,y1,smb,md.mesh.x,md.mesh.y,0);
+-md.surfaceforcings.mass_balance=md.surfaceforcings.mass_balance*md.materials.rho_water/md.materials.rho_ice;
++md.smb.mass_balance=InterpFromGridToMesh(x1,y1,smb,md.mesh.x,md.mesh.y,0);
++md.smb.mass_balance=md.smb.mass_balance*md.materials.rho_water/md.materials.rho_ice;
+ 
+ disp('   Construct basal friction parameters');
+ md.friction.coefficient=30*ones(md.mesh.numberofvertices,1);
+Index: ../trunk-jpl/examples/IceBridge/runme.m
+===================================================================
+--- ../trunk-jpl/examples/IceBridge/runme.m	(revision 20531)
++++ ../trunk-jpl/examples/IceBridge/runme.m	(revision 20532)
+@@ -45,7 +45,7 @@
+ 	md = loadmodel('./Models/Greenland.Mesh_generation');
+ 
+ 	md = setmask(md,'','');
+-	md = parameterize(md,'./Greenland_cheatsheet.par');
++	md = parameterize(md,'./Greenland.par');
+ 	%md = parameterize(md,'./Greenland_noOIB.par');
+ 	md = setflowequation(md,'SSA','all');
+ 
+@@ -107,7 +107,7 @@
+ 	smb = ncread(ncdata,'smb');
+ 	smb = InterpFromGridToMesh(x1,y1,smb',md.mesh.x,md.mesh.y,0)*1000/md.materials.rho_ice;
+ 	smb = [smb smb smb-1.0];
+-	md.surfaceforcings.mass_balance = [smb;1 10 20];
++	md.smb.mass_balance = [smb;1 10 20];
+ 
+ 	%Set transient options, run for 20 years, saving every year
+ 	md.timestepping.time_step=0.2; %This must be reduced for finer resolutions
+@@ -116,7 +116,7 @@
+ 
+ 	%Additional options
+ 	md.inversion.iscontrol=0;
+-	md.transient.requested_outputs={'IceVolume','TotalSmb','SurfaceforcingsMassBalance'};
++	md.transient.requested_outputs={'IceVolume','TotalSmb','SmbMassBalance'};
+ 	md.verbose=verbose('solution',true,'module',true,'convergence',true);
+ 
+ 	%Go solve
+@@ -133,7 +133,7 @@
+ 	%Planview plots
+ 	plotmodel(md,'data',md.results.TransientSolution(end).Vel,'caxis',[1e-1 6000],...
+ 		'log', 10, 'title', 'Velocity (m/y)','gridded',1, ...
+-		'data', md.results.TransientSolution(end).SurfaceforcingsMassBalance, ...
++		'data', md.results.TransientSolution(end).SmbMassBalance, ...
+ 		'title', 'Surface mass balance (m/y)','gridded',1, ...
+ 		'data',md.results.TransientSolution(end).Thickness,...
+ 		'title','Thickness (m)','gridded',1, ...
+@@ -145,7 +145,7 @@
+ 
+ 	%Plot surface mass balance
+ 	surfmb=[]; for i=1:100; surfmb=[surfmb ...
+-		md.results.TransientSolution(i).SurfaceforcingsMassBalance]; end
++		md.results.TransientSolution(i).SmbMassBalance]; end
+ 	subplot(3,1,1); plot([0.2:0.2:20],mean(surfmb)); title('Mean Surface mass balance');
+ 
+ 	%Plot velocity
+Index: ../trunk-jpl/examples/Greenland/runme.m
+===================================================================
+--- ../trunk-jpl/examples/Greenland/runme.m	(revision 20531)
++++ ../trunk-jpl/examples/Greenland/runme.m	(revision 20532)
+@@ -1,5 +1,5 @@
+ clear all;
+-steps=[1 2 3 4 5];
++steps=[1];
+ 
+ %Location of SeaRISE dataset
+ ncdata='../Data/Greenland_5km_dev1.2.nc';
+@@ -145,7 +145,7 @@
+ 	%Set surface mass balance
+ 	lat  = ncread(ncbox,'lat');
+ 	lon  = ncread(ncbox,'lon');
+-	smbbox = ncread(ncbox,'SMB');
++	smbbox = ncread(ncbox,'MassFlux');
+ 	[x1 y1]=ll2xy(lat,lon,+1,45,70);
+ 
+ 	years_of_simulation = 1840:2012;
+Index: ../trunk-jpl/examples/ISMIP/CheatyRunme.m
+===================================================================
+--- ../trunk-jpl/examples/ISMIP/CheatyRunme.m	(revision 20531)
++++ ../trunk-jpl/examples/ISMIP/CheatyRunme.m	(revision 20532)
+@@ -2,7 +2,7 @@
+ %step 7 is specific to ISMIPA
+ %step 8 is specific to ISMIPF
+ 
+-steps=[1:7];
++steps=[1];
+ 
+ % parameter file to be used, choose between CheatyIsmipA.par or CheatyIsmipF.par
+ ParamFile='CheatyIsmipF.par'
+Index: ../trunk-jpl/examples/UncertaintyQuantification/runme.m
+===================================================================
+--- ../trunk-jpl/examples/UncertaintyQuantification/runme.m	(revision 20531)
++++ ../trunk-jpl/examples/UncertaintyQuantification/runme.m	(revision 20532)
+@@ -1,5 +1,5 @@
+ %PIG Uncertainty Quantification Application
+-steps=[1:3]; 
++steps=[1]; 
+ 
+ if any(steps==1) 
+ 	disp('   Step 1: plot flux gates'); 
+@@ -139,10 +139,19 @@
+ 	md.qmu.params.tabular_graphics_data=true;
+ 
+ 	md.stressbalance.restol=10^-5; %tighten tolerances for UQ analyses
++
++	%Turn off verbosity
++	md.verbose=verbose(0);
+ 	
+ 	%solve
+ 	md.qmu.isdakota=1; md.inversion.iscontrol=0;
+ 	md.cluster=generic('name',oshostname,'np',4);
++
++	%Dakota runs in parallel with a master/slave configuration.
++	% At least 2 cpu's are needed to run the UQ
++	md.qmu.params.evaluation_scheduling='master';
++	md.qmu.params.processors_per_evaluation=md.cluster.np-1;
++
+ 	md=solve(md,StressbalanceSolutionEnum,'overwrite','y');
+ 
+ 	save ./Models/PIG.Sampling md; 
+@@ -216,6 +225,12 @@
+ 	md.qmu.isdakota=1; 
+ 	md.inversion.iscontrol=0;
+ 	md.cluster=generic('name',oshostname,'np',2);
++
++	%Dakota runs in parallel with a master/slave configuration.
++	% At least 2 cpu's are needed to run the UQ
++	md.qmu.params.evaluation_scheduling='master';
++	md.qmu.params.processors_per_evaluation=md.cluster.np-1
++
+ 	md.verbose=verbose('qmu',true);
+ 	md=solve(md,StressbalanceSolutionEnum,'overwrite','y');
+ 	
+Index: ../trunk-jpl/examples/Jakobshavn/runme.m
+===================================================================
+--- ../trunk-jpl/examples/Jakobshavn/runme.m	(revision 20531)
++++ ../trunk-jpl/examples/Jakobshavn/runme.m	(revision 20532)
+@@ -1,4 +1,4 @@
+-steps=[4];
++steps=[1];
+ 
+ if any(steps==1)
+ 	disp('	Step 1: Mesh creation'); 
+Index: ../trunk-jpl/examples/Jakobshavn/Jks.par
+===================================================================
+--- ../trunk-jpl/examples/Jakobshavn/Jks.par	(revision 20531)
++++ ../trunk-jpl/examples/Jakobshavn/Jks.par	(revision 20532)
+@@ -37,8 +37,8 @@
+ md.initialization.temperature=InterpFromGridToMesh(x1,y1,temp,md.mesh.x,md.mesh.y,0)+273.15; %convert to Kelvin
+ 
+ disp('   Interpolating surface mass balance');
+-md.surfaceforcings.mass_balance=InterpFromGridToMesh(x1,y1,smb,md.mesh.x,md.mesh.y,0);
+-md.surfaceforcings.mass_balance=md.surfaceforcings.mass_balance*md.materials.rho_water/md.materials.rho_ice;
++md.smb.mass_balance=InterpFromGridToMesh(x1,y1,smb,md.mesh.x,md.mesh.y,0);
++md.smb.mass_balance=md.smb.mass_balance*md.materials.rho_water/md.materials.rho_ice;
+ 
+ disp('   Construct basal friction parameters');
+ md.friction.coefficient=30*ones(md.mesh.numberofvertices,1);
Index: /issm/oecreview/Archive/20496-20544/ISSM-20532-20533.diff
===================================================================
--- /issm/oecreview/Archive/20496-20544/ISSM-20532-20533.diff	(revision 20545)
+++ /issm/oecreview/Archive/20496-20544/ISSM-20532-20533.diff	(revision 20545)
@@ -0,0 +1,22 @@
+Index: ../trunk-jpl/src/m/classes/clusters/pfe.m
+===================================================================
+--- ../trunk-jpl/src/m/classes/clusters/pfe.m	(revision 20532)
++++ ../trunk-jpl/src/m/classes/clusters/pfe.m	(revision 20533)
+@@ -91,7 +91,16 @@
+ 						 md = checkmessage(md,'cpuspernode should be between 1 and 20 for ''ivy'' processors');
+ 					 end
+ 				 end
+-			 
++			 elseif strcmpi(cluster.processor,'bro'),
++				 if cluster.hyperthreading,
++					 if ((cluster.cpuspernode>56 ) | (cluster.cpuspernode<1)),
++						 md = checkmessage(md,'cpuspernode should be between 1 and 56 for ''bro'' processors in hyperthreading mode');
++					 end
++				 else
++					 if ((cluster.cpuspernode>28 ) | (cluster.cpuspernode<1)),
++						 md = checkmessage(md,'cpuspernode should be between 1 and 28 for ''bro'' processors');
++					 end
++				 end
+ 			 elseif strcmpi(cluster.processor,'has'),
+ 				 if cluster.hyperthreading,
+ 					 if ((cluster.cpuspernode>48 ) | (cluster.cpuspernode<1)),
Index: /issm/oecreview/Archive/20496-20544/ISSM-20533-20534.diff
===================================================================
--- /issm/oecreview/Archive/20496-20544/ISSM-20533-20534.diff	(revision 20545)
+++ /issm/oecreview/Archive/20496-20544/ISSM-20533-20534.diff	(revision 20545)
@@ -0,0 +1,13 @@
+Index: ../trunk-jpl/src/m/boundaryconditions/SetMarineIceSheetBC.m
+===================================================================
+--- ../trunk-jpl/src/m/boundaryconditions/SetMarineIceSheetBC.m	(revision 20533)
++++ ../trunk-jpl/src/m/boundaryconditions/SetMarineIceSheetBC.m	(revision 20534)
+@@ -39,7 +39,7 @@
+ end
+ pos=find(md.mesh.vertexonboundary & ~vertexonicefront);
+ if isempty(pos),
+-	warning('SetMarineIceSheetBC warning: ice front all around the glacier, no dirichlet found. Dirichlet must be added manually')
++	disp('SetMarineIceSheetBC warning: ice front all around the glacier, no dirichlet applied')
+ end
+ md.stressbalance.spcvx=NaN*ones(md.mesh.numberofvertices,1);
+ md.stressbalance.spcvy=NaN*ones(md.mesh.numberofvertices,1);
Index: /issm/oecreview/Archive/20496-20544/ISSM-20534-20535.diff
===================================================================
--- /issm/oecreview/Archive/20496-20544/ISSM-20534-20535.diff	(revision 20545)
+++ /issm/oecreview/Archive/20496-20544/ISSM-20534-20535.diff	(revision 20545)
@@ -0,0 +1,344 @@
+Index: ../trunk-jpl/src/m/exp/downstreamflowlines.m
+===================================================================
+--- ../trunk-jpl/src/m/exp/downstreamflowlines.m	(revision 20534)
++++ ../trunk-jpl/src/m/exp/downstreamflowlines.m	(revision 20535)
+@@ -1,111 +0,0 @@
+-function flowpath=downstreamflowlines(index,x,y,u,v,x0,y0,varargin)
+-%DOWNSTREAMFLOWLINES - compute flowlines from a given set of seed points
+-%
+-%   Usage:
+-%      flowpath=downstreamflowlines(index,x,y,u,v,x0,y0)
+-%
+-%   the velocity field is given by the couple (u,v) and the coordinates
+-%   of the seed points are (x0,y0). One can use one or several seed 
+-%   points
+-%
+-%   Example:
+-%      flowpath=downstreamflowlines(md.mesh.elements,md.mesh.x,md.mesh.y,md.vx,md.initialization.vy,x0,y0)
+-
+-%check input size
+-if nargin>9 | nargin<7,
+-	help flowlines
+-	error('flowlines error message: bad usage');
+-end
+-
+-%check input
+-if (length(x)~=length(y) | length(x)~=length(u) | length(x)~=length(v)),
+-	error('flowlines error message: x,y,u and v must have the same length');
+-end
+-if length(x)<3,
+-	error('flowlines error message: at least one element is required');
+-end
+-if length(x0)~=length(y0),
+-	error('flowlines error message: x0 and y0 do not have the same length');
+-end
+-
+-%get maxiter and precision
+-if nargin==9
+-	maxiter=varargin{1};%maximum number of iterations
+-	precision=varargin{2}; %division of each segment (higer precision increases number of segments)
+-else
+-	maxiter=200; %maximum number of iterations
+-	precision=1; %division of each segment (higer precision increases number of segments)
+-end
+-
+-%Create triangulation once for all and check seed points
+-trep = triangulation(index,x,y);
+-tria = pointLocation(trep,[x0 y0]);
+-pos=find(isnan(tria));
+-x0(pos)=[];
+-y0(pos)=[];
+-
+-%initialize other variables
+-N=length(x0);
+-X=x0; Y=y0;
+-flowpath=struct('x',cell(N,1),'y',cell(N,1),'name','','density',1);
+-for i=1:N,
+-	flowpath(i).x=x0(i);
+-	flowpath(i).y=y0(i);
+-end
+-done=zeros(N,1);
+-
+-%get avegared length of each element
+-length_tria=1/3*(sqrt( (x(index(:,1))-x(index(:,2))).^2+(y(index(:,1))-y(index(:,2))).^2 )+...
+-	sqrt((x(index(:,1))-x(index(:,3))).^2+(y(index(:,1))-y(index(:,3))).^2 )+...
+-	sqrt((x(index(:,2))-x(index(:,3))).^2+(y(index(:,2))-y(index(:,3))).^2 ));
+-
+-%take velocity for each element
+-u=u(index)*[1;1;1]/3;
+-v=v(index)*[1;1;1]/3;
+-
+-%initialization:
+-counter=1;
+-
+-while any(~done) 
+-
+-	%find current triangle
+-	queue=find(~done);
+-	tria = pointLocation(trep,[X(queue),Y(queue)]);
+-
+-	%check that the point is actually inside a triangle of the mesh
+-	listnan=find(isnan(tria));
+-	for i=1:length(listnan)
+-		%remove the last point
+-		flowpath(queue(listnan(i))).x(end)=[];
+-		flowpath(queue(listnan(i))).y(end)=[];
+-		done(queue(listnan(i)))=1;
+-	end
+-	tria(listnan)=[]; 
+-	queue(listnan)=[];
+-
+-	if isempty(tria),
+-		break;
+-	end
+-
+-	%velocity of the current triangle and norm it
+-	ut=u(tria); vt=v(tria); normv=sqrt(ut.^2+vt.^2);
+-	ut=ut./normv;vt=vt./normv;
+-
+-	%check counter
+-	if counter>maxiter
+-		disp(['Maximum number of iterations (' num2str(maxiter) ') reached while going forward'])
+-		break
+-	end
+-	counter=counter+1;
+-
+-	%remove stagnant point
+-	done(queue(find(ut==0 & vt==0)))=1;
+-
+-	%build next point
+-	for i=1:length(queue)
+-		X(queue(i))=flowpath(queue(i)).x(end)+ut(i)*length_tria(tria(i))/precision;
+-		Y(queue(i))=flowpath(queue(i)).y(end)+vt(i)*length_tria(tria(i))/precision;
+-		flowpath(queue(i)).x=[flowpath(queue(i)).x;flowpath(queue(i)).x(end)+ut(i)*length_tria(tria(i))/precision];
+-		flowpath(queue(i)).y=[flowpath(queue(i)).y;flowpath(queue(i)).y(end)+vt(i)*length_tria(tria(i))/precision];
+-	end
+-end
+Index: ../trunk-jpl/src/m/exp/flowlines.m
+===================================================================
+--- ../trunk-jpl/src/m/exp/flowlines.m	(revision 20534)
++++ ../trunk-jpl/src/m/exp/flowlines.m	(revision 20535)
+@@ -2,7 +2,7 @@
+ %FLOWLINES - compute flowlines from a given set of seed points
+ %
+ %   Usage:
+-%      flowpath=flowlines(index,x,y,u,v,x0,y0)
++%      flowpath=flowlines(index,x,y,u,v,x0,y0,varargin)
+ %
+ %   the velocity field is given by the couple (u,v) and the coordinates
+ %   of the seed points are (x0,y0). One can use one or several seed 
+@@ -10,6 +10,12 @@
+ %
+ %   Example:
+ %      flowpath=flowlines(md.mesh.elements,md.mesh.x,md.mesh.y,md.vx,md.initialization.vy,x0,y0)
++%
++%   Options:
++%      - 'maxiter':   how many steps upstream and downstream of the seed points (default: 200)
++%      - 'precision': division of each segment (higer precision increases number of segments, default: 1)
++%      - 'downstream':flow line upstream of the seed points (default: 1)
++%      - 'upstream':  flow line upstream of the seed points (default: 1)
+ 
+ %check input size
+ if nargin>8 | nargin<7,
+@@ -28,13 +34,10 @@
+ 	error('flowlines error message: x0 and y0 do not have the same length');
+ end
+ 
+-%get maxiter and precision
+-if nargin==8
+-	maxiter=varargin{1};
+-else
+-	maxiter=200; %maximum number of iterations
+-end
+-precision=1; %division of each segment (higer precision increases number of segments)
++%process options
++options   = pairoptions(varargin{:});
++maxiter   = getfieldvalue(options,'maxiter',200);
++precision = getfieldvalue(options,'precision',1);
+ 
+ %Create triangulation once for all and check seed points
+ trep = triangulation(index,x,y);
+@@ -62,104 +65,108 @@
+ u=u(index)*[1;1;1]/3;
+ v=v(index)*[1;1;1]/3;
+ 
+-%initialization:
+-counter=1;
++if downstream,
++	%initialization:
++	counter=1;
+ 
+-while any(~done) 
++	while any(~done) 
+ 
+-	%find current triangle
+-	queue=find(~done);
+-	tria = pointLocation(trep,[X(queue),Y(queue)]);
++		%find current triangle
++		queue=find(~done);
++		tria = pointLocation(trep,[X(queue),Y(queue)]);
+ 
+-	%check that the point is actually inside a triangle of the mesh
+-	listnan=find(isnan(tria));
+-	for i=1:length(listnan)
+-		%remove the last point
+-		flowpath(queue(listnan(i))).x(end)=[];
+-		flowpath(queue(listnan(i))).y(end)=[];
+-		done(queue(listnan(i)))=1;
+-	end
+-	tria(listnan)=[]; 
+-	queue(listnan)=[];
++		%check that the point is actually inside a triangle of the mesh
++		listnan=find(isnan(tria));
++		for i=1:length(listnan)
++			%remove the last point
++			flowpath(queue(listnan(i))).x(end)=[];
++			flowpath(queue(listnan(i))).y(end)=[];
++			done(queue(listnan(i)))=1;
++		end
++		tria(listnan)=[]; 
++		queue(listnan)=[];
+ 
+-	if isempty(tria),
+-		break;
+-	end
++		if isempty(tria),
++			break;
++		end
+ 
+-	%velocity of the current triangle and norm it
+-	ut=u(tria); vt=v(tria); normv=max(eps,sqrt(ut.^2+vt.^2));
+-	ut=ut./normv;vt=vt./normv;
++		%velocity of the current triangle and norm it
++		ut=u(tria); vt=v(tria); normv=max(eps,sqrt(ut.^2+vt.^2));
++		ut=ut./normv;vt=vt./normv;
+ 
+-	%check counter
+-	if counter>maxiter
+-		disp(['Maximum number of iterations (' num2str(maxiter) ') reached while going forward'])
+-		break
+-	end
+-	counter=counter+1;
++		%check counter
++		if counter>maxiter
++			disp(['Maximum number of iterations (' num2str(maxiter) ') reached while going forward'])
++			break
++		end
++		counter=counter+1;
+ 
+-	%remove stagnant point
+-	done(queue(find(ut==0 & vt==0)))=1;
++		%remove stagnant point
++		done(queue(find(ut==0 & vt==0)))=1;
+ 
+-	%build next point
+-	for i=1:length(queue)
+-		X(queue(i))=flowpath(queue(i)).x(end)+ut(i)*length_tria(tria(i))/precision;
+-		Y(queue(i))=flowpath(queue(i)).y(end)+vt(i)*length_tria(tria(i))/precision;
+-		flowpath(queue(i)).x=[flowpath(queue(i)).x;flowpath(queue(i)).x(end)+ut(i)*length_tria(tria(i))/precision];
+-		flowpath(queue(i)).y=[flowpath(queue(i)).y;flowpath(queue(i)).y(end)+vt(i)*length_tria(tria(i))/precision];
++		%build next point
++		for i=1:length(queue)
++			X(queue(i))=flowpath(queue(i)).x(end)+ut(i)*length_tria(tria(i))/precision;
++			Y(queue(i))=flowpath(queue(i)).y(end)+vt(i)*length_tria(tria(i))/precision;
++			flowpath(queue(i)).x=[flowpath(queue(i)).x;flowpath(queue(i)).x(end)+ut(i)*length_tria(tria(i))/precision];
++			flowpath(queue(i)).y=[flowpath(queue(i)).y;flowpath(queue(i)).y(end)+vt(i)*length_tria(tria(i))/precision];
++		end
+ 	end
+ end
+ 
+ %same process but reverse (vel=-vel) to have a vcomplete flow line
+-queue=[];
+-counter=1;
+-X=x0; Y=y0;
+-done=zeros(N,1);
++if upstream,
++	queue=[];
++	counter=1;
++	X=x0; Y=y0;
++	done=zeros(N,1);
+ 
+-while any(~done) 
++	while any(~done) 
+ 
+-	%find current triangle
+-	queue=find(~done);
+-	tria = pointLocation(trep,[X(queue),Y(queue)]);
++		%find current triangle
++		queue=find(~done);
++		tria = pointLocation(trep,[X(queue),Y(queue)]);
+ 
+-	%check that the point is actually inside a triangle of the mesh
+-	listnan=find(isnan(tria));
+-	for i=1:length(listnan)
+-		%remove the last point
+-		flowpath(queue(listnan(i))).x(1)=[];
+-		flowpath(queue(listnan(i))).y(1)=[];
+-		done(queue(listnan(i)))=1;
+-	end
+-	tria(listnan)=[]; 
+-	queue(listnan)=[];
++		%check that the point is actually inside a triangle of the mesh
++		listnan=find(isnan(tria));
++		for i=1:length(listnan)
++			%remove the last point
++			flowpath(queue(listnan(i))).x(1)=[];
++			flowpath(queue(listnan(i))).y(1)=[];
++			done(queue(listnan(i)))=1;
++		end
++		tria(listnan)=[]; 
++		queue(listnan)=[];
+ 
+-	if isempty(tria),
+-		break;
+-	end
++		if isempty(tria),
++			break;
++		end
+ 
+-	%velocity of the current triangle and norm it
+-	ut=-u(tria); vt=-v(tria); normv=max(eps,sqrt(ut.^2+vt.^2));
+-	ut=ut./normv;vt=vt./normv;
++		%velocity of the current triangle and norm it
++		ut=-u(tria); vt=-v(tria); normv=max(eps,sqrt(ut.^2+vt.^2));
++		ut=ut./normv;vt=vt./normv;
+ 
+-	%check counter
+-	if counter>maxiter
+-		disp(['Maximum number of iterations (' num2str(maxiter) ') reached while going backward'])
+-		break
+-	end
+-	counter=counter+1;
++		%check counter
++		if counter>maxiter
++			disp(['Maximum number of iterations (' num2str(maxiter) ') reached while going backward'])
++			break
++		end
++		counter=counter+1;
+ 
+-	%remove stagnant point
+-	done(queue(find(ut==0 & vt==0)))=1;
++		%remove stagnant point
++		done(queue(find(ut==0 & vt==0)))=1;
+ 
+-	%build next point
+-	for i=1:length(queue)
+-		X(queue(i))=flowpath(queue(i)).x(1)+ut(i)*length_tria(tria(i))/precision;
+-		Y(queue(i))=flowpath(queue(i)).y(1)+vt(i)*length_tria(tria(i))/precision;
+-		flowpath(queue(i)).x=[flowpath(queue(i)).x(1)+ut(i)*length_tria(tria(i))/precision; flowpath(queue(i)).x];
+-		flowpath(queue(i)).y=[flowpath(queue(i)).y(1)+vt(i)*length_tria(tria(i))/precision; flowpath(queue(i)).y];
++		%build next point
++		for i=1:length(queue)
++			X(queue(i))=flowpath(queue(i)).x(1)+ut(i)*length_tria(tria(i))/precision;
++			Y(queue(i))=flowpath(queue(i)).y(1)+vt(i)*length_tria(tria(i))/precision;
++			flowpath(queue(i)).x=[flowpath(queue(i)).x(1)+ut(i)*length_tria(tria(i))/precision; flowpath(queue(i)).x];
++			flowpath(queue(i)).y=[flowpath(queue(i)).y(1)+vt(i)*length_tria(tria(i))/precision; flowpath(queue(i)).y];
++		end
+ 	end
+ end
+ 
+-%EXP compatibility
++%EXP compatibility (add name)
+ for i=1:length(queue)
+ 	flowpath(queue(i)).name=['flowline' num2str(i)];
+ end
Index: /issm/oecreview/Archive/20496-20544/ISSM-20535-20536.diff
===================================================================
--- /issm/oecreview/Archive/20496-20544/ISSM-20535-20536.diff	(revision 20545)
+++ /issm/oecreview/Archive/20496-20544/ISSM-20535-20536.diff	(revision 20545)
@@ -0,0 +1,26 @@
+Index: ../trunk-jpl/src/m/classes/clusters/generic_static.m
+===================================================================
+--- ../trunk-jpl/src/m/classes/clusters/generic_static.m	(revision 20535)
++++ ../trunk-jpl/src/m/classes/clusters/generic_static.m	(revision 20536)
+@@ -50,10 +50,20 @@
+ 		%}}}
+ 		function BuildQueueScript(cluster,dirname,modelname,solution,io_gather,isvalgrind,isgprof,isdakota) % {{{
+ 
++			%write queuing script
++			%what is the executable being called?
++			executable='issm.exe';
++			if isdakota,
++				version=IssmConfig('_DAKOTA_VERSION_'); version=str2num(version(1:3));
++				if (version>=6),
++					executable='issm_dakota.exe';
++				end
++			end
++
+ 			%write queuing script 
+ 			fid=fopen([modelname '.queue'],'w');
+ 			fprintf(fid,'#!%s\n',cluster.shell);
+-			fprintf(fid,[cluster.codepath '/mpiexec -np %i %s/issm.exe %s %s %s \n'],cluster.np,cluster.codepath,EnumToString(solution),'./',modelname);
++			fprintf(fid,[cluster.codepath '/mpiexec -np %i %s/%s %s %s %s \n'],cluster.np,cluster.codepath,executable,EnumToString(solution),'./',modelname);
+ 			fclose(fid);
+ 
+ 			%in interactive mode, create a run file, and errlog and outlog file
Index: /issm/oecreview/Archive/20496-20544/ISSM-20536-20537.diff
===================================================================
--- /issm/oecreview/Archive/20496-20544/ISSM-20536-20537.diff	(revision 20545)
+++ /issm/oecreview/Archive/20496-20544/ISSM-20536-20537.diff	(revision 20545)
@@ -0,0 +1,26 @@
+Index: ../trunk-jpl/src/m/exp/flowlines.m
+===================================================================
+--- ../trunk-jpl/src/m/exp/flowlines.m	(revision 20536)
++++ ../trunk-jpl/src/m/exp/flowlines.m	(revision 20537)
+@@ -9,7 +9,7 @@
+ %   points
+ %
+ %   Example:
+-%      flowpath=flowlines(md.mesh.elements,md.mesh.x,md.mesh.y,md.vx,md.initialization.vy,x0,y0)
++%      flowpath=flowlines(md.mesh.elements,md.mesh.x,md.mesh.y,md.initialization.vx,md.initialization.vy,x0,y0)
+ %
+ %   Options:
+ %      - 'maxiter':   how many steps upstream and downstream of the seed points (default: 200)
+@@ -17,12 +17,6 @@
+ %      - 'downstream':flow line upstream of the seed points (default: 1)
+ %      - 'upstream':  flow line upstream of the seed points (default: 1)
+ 
+-%check input size
+-if nargin>8 | nargin<7,
+-	help flowlines
+-	error('flowlines error message: bad usage');
+-end
+-
+ %check input
+ if (length(x)~=length(y) | length(x)~=length(u) | length(x)~=length(v)),
+ 	error('flowlines error message: x,y,u and v must have the same length');
Index: /issm/oecreview/Archive/20496-20544/ISSM-20537-20538.diff
===================================================================
--- /issm/oecreview/Archive/20496-20544/ISSM-20537-20538.diff	(revision 20545)
+++ /issm/oecreview/Archive/20496-20544/ISSM-20537-20538.diff	(revision 20545)
@@ -0,0 +1,19 @@
+Index: ../trunk-jpl/src/m/exp/flowlines.m
+===================================================================
+--- ../trunk-jpl/src/m/exp/flowlines.m	(revision 20537)
++++ ../trunk-jpl/src/m/exp/flowlines.m	(revision 20538)
+@@ -29,9 +29,11 @@
+ end
+ 
+ %process options
+-options   = pairoptions(varargin{:});
+-maxiter   = getfieldvalue(options,'maxiter',200);
+-precision = getfieldvalue(options,'precision',1);
++options    = pairoptions(varargin{:});
++maxiter    = getfieldvalue(options,'maxiter',200);
++precision  = getfieldvalue(options,'precision',1);
++downstream = getfieldvalue(options,'downstream',1);
++upstream   = getfieldvalue(options,'upstream',1);
+ 
+ %Create triangulation once for all and check seed points
+ trep = triangulation(index,x,y);
Index: /issm/oecreview/Archive/20496-20544/ISSM-20538-20539.diff
===================================================================
--- /issm/oecreview/Archive/20496-20544/ISSM-20538-20539.diff	(revision 20545)
+++ /issm/oecreview/Archive/20496-20544/ISSM-20538-20539.diff	(revision 20545)
@@ -0,0 +1,19 @@
+Index: ../trunk-jpl/src/m/mesh/patchglobe.m
+===================================================================
+--- ../trunk-jpl/src/m/mesh/patchglobe.m	(revision 20538)
++++ ../trunk-jpl/src/m/mesh/patchglobe.m	(revision 20539)
+@@ -6,6 +6,14 @@
+ 	%recover basic options:
+ 	bandwidth=getfieldvalue(options,'bandwidth',100000);
+ 
++	%some checks on the mesh: 
++	if (isempty(mh.x) | isempty(mh.y) | isempty(mh.z) | isempty(mh.lat) | isempty(mh.long) | isempty(mh.r) ) 
++		error('patchglobe error message: 3D planet mesh has one of the following empty: ''x'',''y'',''z'',''lat'',''long'' or ''r''');
++	end
++	if (isempty(mh2d.x) | isempty(mh2d.y) | isempty(mh2d.lat) | isempty(mh2d.long)) 
++		error('patchglobe error message: 3D planet mesh has one of the following empty: ''x'',''y'',''lat'' or ''long''');
++	end
++
+ 	%give ourselves a unique temporary directory: 
+ 	temproot=tempname; mkdir(temproot);
+ 
Index: /issm/oecreview/Archive/20496-20544/ISSM-20539-20540.diff
===================================================================
--- /issm/oecreview/Archive/20496-20544/ISSM-20539-20540.diff	(revision 20545)
+++ /issm/oecreview/Archive/20496-20544/ISSM-20539-20540.diff	(revision 20545)
@@ -0,0 +1,22 @@
+Index: ../trunk-jpl/src/m/classes/miscellaneous.m
+===================================================================
+--- ../trunk-jpl/src/m/classes/miscellaneous.m	(revision 20539)
++++ ../trunk-jpl/src/m/classes/miscellaneous.m	(revision 20540)
+@@ -38,11 +38,15 @@
+ 			WriteData(fid,'object',self,'fieldname','name','format','String');
+ 		end % }}}
+ 		function savemodeljs(self,fid,modelname) % {{{
+-		
++
+ 			writejsstring(fid,[modelname '.miscellaneous.notes'],self.notes);
+ 			writejsstring(fid,[modelname '.miscellaneous.name'],self.name);
+ 			if strcmpi(class(self.dummy),'double'),
+-				writejs1Darray(fid,[modelname '.miscellaneous.dummy'],self.dummy);
++				if size(self.dummy,2)==1,
++					writejs1Darray(fid,[modelname '.miscellaneous.dummy'],self.dummy);
++				else
++					writejs2Darray(fid,[modelname '.miscellaneous.dummy'],self.dummy);
++				end
+ 			end
+ 
+ 		end % }}}
Index: /issm/oecreview/Archive/20496-20544/ISSM-20540-20541.diff
===================================================================
--- /issm/oecreview/Archive/20496-20544/ISSM-20540-20541.diff	(revision 20545)
+++ /issm/oecreview/Archive/20496-20544/ISSM-20540-20541.diff	(revision 20545)
@@ -0,0 +1,22 @@
+Index: ../trunk-jpl/src/m/plot/applyoptions.js
+===================================================================
+--- ../trunk-jpl/src/m/plot/applyoptions.js	(revision 20540)
++++ ../trunk-jpl/src/m/plot/applyoptions.js	(revision 20541)
+@@ -47,14 +47,11 @@
+ 			var caxisdelta = caxis[1] - caxis[0];
+ 			var clabelitem;
+ 			var precision=options.getfieldvalue('colorbarprecision',3);
++			
+ 			if (options.getfieldvalue('log',10)!='off') {
+ 				for (var i = cdivisions; i >= 0; i--) {
+-					if (caxisdelta*i/cdivisions==caxis[0]) {
+-						labels[i] = (caxis[0]).toPrecision(precision);
+-					}
+-					else {
+-						labels[i] = (Math.exp(Math.log(caxisdelta)*(cdivisions-i)/cdivisions)+caxis[0]).toPrecision(precision);
+-					}
++					var scale = Math.log(caxis[1])-Math.log(caxis[0]);
++					labels[i] = (Math.exp(Math.log(caxis[0])+scale*(cdivisions-i)/cdivisions)).toPrecision(precision);
+ 				}
+ 			} else {
+ 				for (var i = cdivisions; i >= 0; i--) {
Index: /issm/oecreview/Archive/20496-20544/ISSM-20541-20542.diff
===================================================================
--- /issm/oecreview/Archive/20496-20544/ISSM-20541-20542.diff	(revision 20545)
+++ /issm/oecreview/Archive/20496-20544/ISSM-20541-20542.diff	(revision 20545)
@@ -0,0 +1,21 @@
+Index: ../trunk-jpl/src/m/plot/plot_overlay.js
+===================================================================
+--- ../trunk-jpl/src/m/plot/plot_overlay.js	(revision 20541)
++++ ../trunk-jpl/src/m/plot/plot_overlay.js	(revision 20542)
+@@ -126,8 +126,14 @@
+ 		vertices[vertices.length] = vertex[1];
+ 		vertices[vertices.length] = vertex[2];
+ 		
+-		texcoords[texcoords.length] = (x[i] - modelxlim[0]) / xrange;
+-		texcoords[texcoords.length] = (y[i] - modelylim[0]) / yrange;
++		if (md.mesh.classname() == 'mesh3dsurface') {
++			texcoords[texcoords.length] = degrees(Math.atan2(y[i], x[i])) / 360 + 0.5;
++			texcoords[texcoords.length] = degrees(Math.asin(z[i] / magnitude)) / 180 + 0.5;
++		}
++		else {
++			texcoords[texcoords.length] = (x[i] - modelxlim[0]) / xrange;
++			texcoords[texcoords.length] = (y[i] - modelylim[0]) / yrange;
++		}
+ 	}
+ 
+ 	//linearize the elements array:
Index: /issm/oecreview/Archive/20496-20544/ISSM-20542-20543.diff
===================================================================
--- /issm/oecreview/Archive/20496-20544/ISSM-20542-20543.diff	(revision 20545)
+++ /issm/oecreview/Archive/20496-20544/ISSM-20542-20543.diff	(revision 20545)
@@ -0,0 +1,44 @@
+Index: ../trunk-jpl/jenkins/jenkins.sh
+===================================================================
+--- ../trunk-jpl/jenkins/jenkins.sh	(revision 20542)
++++ ../trunk-jpl/jenkins/jenkins.sh	(revision 20543)
+@@ -62,10 +62,10 @@
+ 	echo "Determining installation type"
+ 	if [ ! -z "$(cat $ISSM_DIR/TEMP | grep externalpackages)" ] ; then
+ 		echo "  -- checking for changed externalpackages... yes";
+-		ISSM_EXTERNALPACKAGES="install"
++		ISSM_EXTERNALPACKAGES="yes"
+ 	else
+ 		echo "  -- checking for changed externalpackages... no";
+-		ISSM_EXTERNALPACKAGES="none"
++		ISSM_EXTERNALPACKAGES="no"
+ 	fi
+ 
+ 	#Do we need to reconfigure
+@@ -91,7 +91,7 @@
+ 	echo "  -- checking for changed externalpackages... yes";
+ 	echo "  -- checking for reconfiguration... yes";
+ 	echo "  -- checking for recompilation... yes";
+-	ISSM_EXTERNALPACKAGES="install"
++	ISSM_EXTERNALPACKAGES="yes"
+ 	ISSM_RECONFIGURE="yes"
+ 	ISSM_COMPILATION="yes"
+ fi
+@@ -99,7 +99,7 @@
+ echo "Recording current svn version: $SVN_REVISION_1"
+ echo $SVN_REVISION_1 > $ISSM_DIR/svn_revision_old
+ #}}}
+-#install/none external packages    (ISSM_EXTERNALPACKAGES){{{
++#Install external packages    (ISSM_EXTERNALPACKAGES){{{
+ 
+ #Jenkins xml files for individual packages
+ EXTERNAL_TEST_FILE="$ISSM_DIR/nightlylog/results/external.xml"
+@@ -118,7 +118,7 @@
+ 	cd $ISSM_DIR/externalpackages/$PACKAGENAME
+ 
+ 	#install if requested or if previous install has not been successful
+-	if [ "$ISSM_EXTERNALPACKAGES" == "install" ] || [ ! -f SUCCESS ]; then
++	if [ "$ISSM_EXTERNALPACKAGES" == "yes" ] || [ ! -f SUCCESS ]; then
+ 		echo "======================================================";
+ 		echo "       Installing $PACKAGENAME                        ";
+ 		echo "======================================================";
Index: /issm/oecreview/Archive/20496-20544/ISSM-20543-20544.diff
===================================================================
--- /issm/oecreview/Archive/20496-20544/ISSM-20543-20544.diff	(revision 20545)
+++ /issm/oecreview/Archive/20496-20544/ISSM-20543-20544.diff	(revision 20545)
@@ -0,0 +1,28 @@
+Index: ../trunk-jpl/src/m/classes/clusters/generic_static.m
+===================================================================
+--- ../trunk-jpl/src/m/classes/clusters/generic_static.m	(revision 20543)
++++ ../trunk-jpl/src/m/classes/clusters/generic_static.m	(revision 20544)
+@@ -50,6 +50,14 @@
+ 		%}}}
+ 		function BuildQueueScript(cluster,dirname,modelname,solution,io_gather,isvalgrind,isgprof,isdakota) % {{{
+ 
++			%Check that issm.exe exists in the right path
++			if ~exist([cluster.codepath '/issm.exe'],'file'),
++				error(['File ' cluster.codepath '/issm.exe does not exist']);
++			end
++
++			%Now process codepath and replace empty spaces with \ to avoid errors in queuing script
++			codepath2=strrep(cluster.codepath,' ','\ ');
++
+ 			%write queuing script
+ 			%what is the executable being called?
+ 			executable='issm.exe';
+@@ -63,7 +71,7 @@
+ 			%write queuing script 
+ 			fid=fopen([modelname '.queue'],'w');
+ 			fprintf(fid,'#!%s\n',cluster.shell);
+-			fprintf(fid,[cluster.codepath '/mpiexec -np %i %s/%s %s %s %s \n'],cluster.np,cluster.codepath,executable,EnumToString(solution),'./',modelname);
++			fprintf(fid,['%s/mpiexec -np %i %s/%s %s %s %s \n'],codepath2,cluster.np,codepath2,executable,EnumToString(solution),'./',modelname);
+ 			fclose(fid);
+ 
+ 			%in interactive mode, create a run file, and errlog and outlog file
Index: /issm/oecreview/Archive/20496-20544/ISSM-DocReview-20496-20544.tex
===================================================================
--- /issm/oecreview/Archive/20496-20544/ISSM-DocReview-20496-20544.tex	(revision 20545)
+++ /issm/oecreview/Archive/20496-20544/ISSM-DocReview-20496-20544.tex	(revision 20545)
@@ -0,0 +1,67 @@
+\documentclass[]{report}   % list options between brackets
+\usepackage{graphicx}              % list packages between braces
+
+% type user-defined commands here
+
+\begin{document}
+
+\title{JPL EXPORT ADMINISTRATION \\ DOCUMENT REVIEW RECORD}   % type title between braces
+\author{Tom Scavo}         % type author(s) between braces
+\date{October 27, 1995}    % type date between braces
+%\maketitle
+
+
+\begin{center}
+\begin{tabular}{ |c|c| }
+\hline
+JPL EXPORT ADMINISTRATION \\
+\textit{ DOCUMENT REVIEW RECORD} \\
+\hline
+\end{tabular}
+\end{center}
+
+\hfill Log \#: \underline{\input{LogNumber}}
+
+\vspace{1cm}
+\noindent (Note: This form and process do not replace the procedures described in JPL Policy relating to review and approval of proposals and contractual 
+documents. This process is intended to document the review and coordination of requests to ascertain the export control ramifications relating to specific 
+documents. Export Administration signature does not convey authority to export or release the "Exporter of Record" from any export laws or regulations.)\\
+
+\noindent \textbf{Program:} \underline{ISSM: Ice Sheet System Model} \\ \\
+\noindent \textbf{Person Requesting or Initiating Export}: \underline{Dr. Eric Larour}\\ \\
+\noindent \textbf{Date Received}: \underline{\input{Date}}\\ \\
+\noindent \textbf{Document Title/Description}: ISSM changes from revision \input{r1} to revision \input{r2} \\ \\
+\noindent \textbf{Release to:} \underline{http://issm.ess.uci.edu/svn/issm/issm/trunk on ISSM svn repository}\\ \\
+\noindent \textbf{JPL Intranet:} \underline{murdo.jpl.nasa.gov/proj/ice/larour/issm-uci/trunk-jpl}\\ \\
+
+\noindent \textbf{Disposition: 6 } 
+Does not contain export-controlled information. May be released/disclosed as requested subject to 
+Company guidelines on protection of proprietary information (if applicable). \\
+
+\noindent \textbf{Comments:}  see table of changes below. \\ \\
+\noindent \textbf{Reviewed by ISSM Export Transfer Liaison:} Dr. Eric Larour \hfill \textbf{Date:} \input{Date} \\ 
+\includegraphics[scale=1]{signature}
+
+\noindent JPL Export Administration Form TBS – June 29, 2011
+
+\begin{center}
+\line(1,0){250}
+\end{center}
+
+\noindent \textbf{Disposition:} \\
+1:	  Public Domain Information (Ref ITAR Section 120.11) \\
+2:	  Qualifies for ITAR Exemption				 \\
+3:	  Covered by Department of State License/Agreement Number					  \\
+4:	  Covered by Department of Commerce validated license or exception				 \\
+5:	  New License Required \\
+6:	  Does not contain export-controlled information.  May be released/disclosed as requested subject
+   to Company guidelines on protection of proprietary information (if applicable). \\
+7:	 Other (specify)   
+\begin{center}
+\line(1,0){250}
+\end{center}
+
+
+\input{log}
+
+\end{document}
Index: /issm/oecreview/Archive/20496-20544/LogNumber.tex
===================================================================
--- /issm/oecreview/Archive/20496-20544/LogNumber.tex	(revision 20545)
+++ /issm/oecreview/Archive/20496-20544/LogNumber.tex	(revision 20545)
@@ -0,0 +1,1 @@
+20496-20544
Index: /issm/oecreview/Archive/20496-20544/Makefile
===================================================================
--- /issm/oecreview/Archive/20496-20544/Makefile	(revision 20545)
+++ /issm/oecreview/Archive/20496-20544/Makefile	(revision 20545)
@@ -0,0 +1,8 @@
+TARGET=ISSM-DocReview-20496-20544
+
+all: 
+	pdflatex -interaction=errorstopmode -file-line-error -halt-on-error $(TARGET).tex
+	rm -rf *.log *.aux 
+
+clean:
+	rm -rf *.log *.aux
Index: /issm/oecreview/Archive/20496-20544/log.tex
===================================================================
--- /issm/oecreview/Archive/20496-20544/log.tex	(revision 20545)
+++ /issm/oecreview/Archive/20496-20544/log.tex	(revision 20545)
@@ -0,0 +1,301 @@
+\noindent \textbf{Change \#1} with diff file ISSM-20496-20497.diff: \\
+Function name: \\
+M /issm/trunk-jpl/configure.ac\\
+Export determination: 6. \\
+Rationale: CHG: updating revision number\\
+\vspace{3em}
+
+\noindent \textbf{Change \#2} with diff file ISSM-20497-20498.diff: \\
+Function name: \\
+M /issm/trunk-jpl M /issm/trunk-jpl/src M /issm/trunk-jpl/test\\
+Export determination: 6. \\
+Rationale: merged trunk and trunk-jpl\\
+\vspace{3em}
+
+\noindent \textbf{Change \#3} with diff file ISSM-20501-20502.diff: \\
+Function name: \\
+M /issm/trunk-jpl M /issm/trunk-jpl/src M /issm/trunk-jpl/test\\
+Export determination: 6. \\
+Rationale: Block revision 20500 from being merged into trunk-jpl\\
+\vspace{3em}
+
+\noindent \textbf{Change \#4} with diff file ISSM-20502-20503.diff: \\
+Function name: \\
+M /issm/trunk-jpl/src/m/exp/downstreamflowlines.m M /issm/trunk-jpl/src/m/exp/flowlines.m\\
+Export determination: 6. \\
+Rationale: CHG: speedint up flowlines\\
+\vspace{3em}
+
+\noindent \textbf{Change \#5} with diff file ISSM-20503-20504.diff: \\
+Function name: \\
+M /issm/trunk-jpl/src/c/Makefile.am D /issm/trunk-jpl/src/c/modules/TriaSearchx M /issm/trunk-jpl/src/c/modules/modules.h D /issm/trunk-jpl/src/wrappers/TriaSearch M /issm/trunk-jpl/src/wrappers/matlab/Makefile.am\\
+Export determination: 6. \\
+Rationale: DEL: not needed anymore\\
+\vspace{3em}
+
+\noindent \textbf{Change \#6} with diff file ISSM-20504-20505.diff: \\
+Function name: \\
+M /issm/trunk-jpl/test/NightlyRun/test211.py M /issm/trunk-jpl/test/NightlyRun/test422.m M /issm/trunk-jpl/test/NightlyRun/test422.py\\
+Export determination: 6. \\
+Rationale: CHG: relaxed toleraces\\
+\vspace{3em}
+
+\noindent \textbf{Change \#7} with diff file ISSM-20505-20506.diff: \\
+Function name: \\
+M /issm/trunk-jpl/src/m/classes/model.m M /issm/trunk-jpl/src/m/classes/model.py\\
+Export determination: 6. \\
+Rationale: BUG: balancethickness works only in 2D, so do not attempt to collapse it from 3D\\
+\vspace{3em}
+
+\noindent \textbf{Change \#8} with diff file ISSM-20506-20507.diff: \\
+Function name: \\
+M /issm/trunk-jpl/jenkins/jenkins.sh\\
+Export determination: 6. \\
+Rationale: BUG: too many spaces\\
+\vspace{3em}
+
+\noindent \textbf{Change \#9} with diff file ISSM-20508-20509.diff: \\
+Function name: \\
+A /issm/trunk-jpl/jenkins/macosx\_pine-island\_dakota\_static\\
+Export determination: 6. \\
+Rationale: ADD: New Jenkins configuration script for static Dakota binaries.\\
+\vspace{3em}
+
+\noindent \textbf{Change \#10} with diff file ISSM-20509-20510.diff: \\
+Function name: \\
+M /issm/trunk-jpl/jenkins/jenkins.sh\\
+Export determination: 6. \\
+Rationale: CHG: better way of dealing with externalpackages\\
+\vspace{3em}
+
+\noindent \textbf{Change \#11} with diff file ISSM-20511-20512.diff: \\
+Function name: \\
+M /issm/trunk-jpl/src/m/plot/applyoptions.js M /issm/trunk-jpl/src/m/plot/plot\_unit.js M /issm/trunk-jpl/src/m/plot/processdata.js\\
+Export determination: 6. \\
+Rationale: CHG (javascript): Updating unit plots to handle log scaling. processdata now handle node transients with log scaling.\\
+\vspace{3em}
+
+\noindent \textbf{Change \#12} with diff file ISSM-20512-20513.diff: \\
+Function name: \\
+M /issm/trunk-jpl/src/m/exp/flowlines.m\\
+Export determination: 6. \\
+Rationale: BUG: take care of case vx=vy=0\\
+\vspace{3em}
+
+\noindent \textbf{Change \#13} with diff file ISSM-20513-20514.diff: \\
+Function name: \\
+M /issm/trunk-jpl/src/m/plot/applyoptions.js M /issm/trunk-jpl/src/m/plot/plot\_unit.js M /issm/trunk-jpl/src/m/plot/processdata.js\\
+Export determination: 6. \\
+Rationale: CHG (javascript): log option can now be disabled with 'off' value.\\
+\vspace{3em}
+
+\noindent \textbf{Change \#14} with diff file ISSM-20514-20515.diff: \\
+Function name: \\
+M /issm/trunk-jpl/src/m/plot/plot\_unit.js M /issm/trunk-jpl/src/m/plot/processdata.js\\
+Export determination: 6. \\
+Rationale: CHG (javascript): Resolving options error with incorrect/missing default values.\\
+\vspace{3em}
+
+\noindent \textbf{Change \#15} with diff file ISSM-20515-20516.diff: \\
+Function name: \\
+M /issm/trunk-jpl/src/c/classes/Elements/PentaRef.cpp M /issm/trunk-jpl/src/c/classes/Elements/SegRef.cpp M /issm/trunk-jpl/src/c/classes/Elements/TetraRef.cpp M /issm/trunk-jpl/src/c/classes/Elements/TriaRef.cpp\\
+Export determination: 6. \\
+Rationale: CHG: from Alex Scott, no need to use dynamic allocation for dbasis, static allocation seems to be much faster\\
+\vspace{3em}
+
+\noindent \textbf{Change \#16} with diff file ISSM-20516-20517.diff: \\
+Function name: \\
+M /issm/trunk-jpl/src/m/plot/manualcb.m\\
+Export determination: 6. \\
+Rationale: CHG: fixing colorbar\\
+\vspace{3em}
+
+\noindent \textbf{Change \#17} with diff file ISSM-20517-20518.diff: \\
+Function name: \\
+M /issm/trunk-jpl/src/c/analyses/LevelsetAnalysis.cpp\\
+Export determination: 6. \\
+Rationale: CHG: no need to prevent people from using LSF now\\
+\vspace{3em}
+
+\noindent \textbf{Change \#18} with diff file ISSM-20518-20519.diff: \\
+Function name: \\
+M /issm/trunk-jpl/src/m/classes/calving.m\\
+Export determination: 6. \\
+Rationale: CHG: forcings should only check the first lines\\
+\vspace{3em}
+
+\noindent \textbf{Change \#19} with diff file ISSM-20519-20520.diff: \\
+Function name: \\
+M /issm/trunk-jpl/src/m/miscellaneous/transientrestart.m\\
+Export determination: 6. \\
+Rationale: BUG: output time is already in years\\
+\vspace{3em}
+
+\noindent \textbf{Change \#20} with diff file ISSM-20520-20521.diff: \\
+Function name: \\
+M /issm/trunk-jpl/src/m/coordsystems/gdaltransform.m\\
+Export determination: 6. \\
+Rationale: CHG: added error message in case transformation did not work\\
+\vspace{3em}
+
+\noindent \textbf{Change \#21} with diff file ISSM-20521-20522.diff: \\
+Function name: \\
+M /issm/trunk-jpl/test/NightlyRun/test124.m\\
+Export determination: 6. \\
+Rationale: CHG: relaxing tolerances\\
+\vspace{3em}
+
+\noindent \textbf{Change \#22} with diff file ISSM-20522-20523.diff: \\
+Function name: \\
+M /issm/trunk-jpl/src/m/classes/clusters/lonestar.m\\
+Export determination: 6. \\
+Rationale: CHG: add email workaround\\
+\vspace{3em}
+
+\noindent \textbf{Change \#23} with diff file ISSM-20523-20524.diff: \\
+Function name: \\
+M /issm/trunk-jpl/src/m/coordsystems/gdaltransform.m\\
+Export determination: 6. \\
+Rationale: CHG: faster conversion and more complete documentation\\
+\vspace{3em}
+
+\noindent \textbf{Change \#24} with diff file ISSM-20524-20525.diff: \\
+Function name: \\
+M /issm/trunk-jpl/src/m/classes/clusters/lonestar.m\\
+Export determination: 6. \\
+Rationale: CHG: add email workaround\\
+\vspace{3em}
+
+\noindent \textbf{Change \#25} with diff file ISSM-20525-20526.diff: \\
+Function name: \\
+M /issm/trunk-jpl/test/NightlyRun/test404.m M /issm/trunk-jpl/test/NightlyRun/test404.py\\
+Export determination: 6. \\
+Rationale: CHG: relaxing tolerances\\
+\vspace{3em}
+
+\noindent \textbf{Change \#26} with diff file ISSM-20526-20527.diff: \\
+Function name: \\
+M /issm/trunk-jpl/src/m/classes/independent.py\\
+Export determination: 6. \\
+Rationale: BUG: fixig AD error on python test\\
+\vspace{3em}
+
+\noindent \textbf{Change \#27} with diff file ISSM-20527-20528.diff: \\
+Function name: \\
+M /issm/trunk-jpl/test/NightlyRun/test3020.py\\
+Export determination: 6. \\
+Rationale: minor\\
+\vspace{3em}
+
+\noindent \textbf{Change \#28} with diff file ISSM-20528-20529.diff: \\
+Function name: \\
+M /issm/trunk-jpl/src/m/classes/independent.py\\
+Export determination: 6. \\
+Rationale: BUG: need to import checkfield\\
+\vspace{3em}
+
+\noindent \textbf{Change \#29} with diff file ISSM-20529-20530.diff: \\
+Function name: \\
+M /issm/trunk-jpl/src/c/Makefile.am\\
+Export determination: 6. \\
+Rationale: CHG: Attempt to fix AD issue relating to missing gfortran symbol in libISSMCore.\\
+\vspace{3em}
+
+\noindent \textbf{Change \#30} with diff file ISSM-20530-20531.diff: \\
+Function name: \\
+M /issm/trunk-jpl/jenkins/jenkins.sh M /issm/trunk-jpl/src/c/Makefile.am\\
+Export determination: 6. \\
+Rationale: CHG: Changed address of wget.\\
+\vspace{3em}
+
+\noindent \textbf{Change \#31} with diff file ISSM-20531-20532.diff: \\
+Function name: \\
+M /issm/trunk-jpl/src/m/classes/clusters/lonestar.m\\
+Export determination: 6. \\
+Rationale: CHG: minor update to email when job ends\\
+\vspace{3em}
+
+\noindent \textbf{Change \#32} with diff file ISSM-20532-20533.diff: \\
+Function name: \\
+M /issm/trunk-jpl/examples/Greenland/runme.m M /issm/trunk-jpl/examples/ISMIP/CheatyRunme.m M /issm/trunk-jpl/examples/IceBridge/Greenland.par M /issm/trunk-jpl/examples/IceBridge/Greenland\_cheatsheet.par M /issm/trunk-jpl/examples/IceBridge/Greenland\_noOIB.par M /issm/trunk-jpl/examples/IceBridge/runme.m M /issm/trunk-jpl/examples/IceflowModels/EISMINT.par M /issm/trunk-jpl/examples/Jakobshavn/Jks.par M /issm/trunk-jpl/examples/Jakobshavn/runme.m M /issm/trunk-jpl/examples/UncertaintyQuantification/runme.m\\
+Export determination: 6. \\
+Rationale: CHG: update examples for new code\\
+\vspace{3em}
+
+\noindent \textbf{Change \#33} with diff file ISSM-20533-20534.diff: \\
+Function name: \\
+M /issm/trunk-jpl/src/m/classes/clusters/pfe.m\\
+Export determination: 6. \\
+Rationale: NEW: added new broadband nodes for pleiades\\
+\vspace{3em}
+
+\noindent \textbf{Change \#34} with diff file ISSM-20534-20535.diff: \\
+Function name: \\
+M /issm/trunk-jpl/src/m/boundaryconditions/SetMarineIceSheetBC.m\\
+Export determination: 6. \\
+Rationale: CHG: changed warning to simple display\\
+\vspace{3em}
+
+\noindent \textbf{Change \#35} with diff file ISSM-20535-20536.diff: \\
+Function name: \\
+D /issm/trunk-jpl/src/m/exp/downstreamflowlines.m M /issm/trunk-jpl/src/m/exp/flowlines.m\\
+Export determination: 6. \\
+Rationale: CHG: added more options to flowlines, that can now be used to replace downstreamflowlines.m\\
+\vspace{3em}
+
+\noindent \textbf{Change \#36} with diff file ISSM-20536-20537.diff: \\
+Function name: \\
+M /issm/trunk-jpl/src/m/classes/clusters/generic\_static.m\\
+Export determination: 6. \\
+Rationale: CHG: add dakota 6 exec to generic\_static\\
+\vspace{3em}
+
+\noindent \textbf{Change \#37} with diff file ISSM-20537-20538.diff: \\
+Function name: \\
+M /issm/trunk-jpl/src/m/exp/flowlines.m\\
+Export determination: 6. \\
+Rationale: CHG: fixing nargin\\
+\vspace{3em}
+
+\noindent \textbf{Change \#38} with diff file ISSM-20538-20539.diff: \\
+Function name: \\
+M /issm/trunk-jpl/src/m/exp/flowlines.m\\
+Export determination: 6. \\
+Rationale: CHG: fixing downstream option\\
+\vspace{3em}
+
+\noindent \textbf{Change \#39} with diff file ISSM-20539-20540.diff: \\
+Function name: \\
+M /issm/trunk-jpl/src/m/mesh/patchglobe.m\\
+Export determination: 6. \\
+Rationale: CHG: added checks.\\
+\vspace{3em}
+
+\noindent \textbf{Change \#40} with diff file ISSM-20540-20541.diff: \\
+Function name: \\
+M /issm/trunk-jpl/src/m/classes/miscellaneous.m\\
+Export determination: 6. \\
+Rationale: CHG: minor.\\
+\vspace{3em}
+
+\noindent \textbf{Change \#41} with diff file ISSM-20541-20542.diff: \\
+Function name: \\
+M /issm/trunk-jpl/src/m/plot/applyoptions.js\\
+Export determination: 6. \\
+Rationale: CHG (javascript): Improving log scaling lables.\\
+\vspace{3em}
+
+\noindent \textbf{Change \#42} with diff file ISSM-20542-20543.diff: \\
+Function name: \\
+M /issm/trunk-jpl/src/m/plot/plot\_overlay.js\\
+Export determination: 6. \\
+Rationale: CHG (javascript): adding overlay support for mesh3dsurface.\\
+\vspace{3em}
+
+\noindent \textbf{Change \#43} with diff file ISSM-20543-20544.diff: \\
+Function name: \\
+M /issm/trunk-jpl/jenkins/jenkins.sh\\
+Export determination: 6. \\
+Rationale: CHG: fixing externalpackages\\
+\vspace{3em}
+
Index: /issm/oecreview/Archive/20496-20544/r1.tex
===================================================================
--- /issm/oecreview/Archive/20496-20544/r1.tex	(revision 20545)
+++ /issm/oecreview/Archive/20496-20544/r1.tex	(revision 20545)
@@ -0,0 +1,1 @@
+20496
Index: /issm/oecreview/Archive/20496-20544/r2.tex
===================================================================
--- /issm/oecreview/Archive/20496-20544/r2.tex	(revision 20545)
+++ /issm/oecreview/Archive/20496-20544/r2.tex	(revision 20545)
@@ -0,0 +1,1 @@
+20544
