
side = 1. ;
divs = 10 ;

pc = newp ;
Point( pc   ) = { -side/2 , -side/2 , 0. , side/divs } ;
Point( pc+1 ) = {  side/2 , -side/2 , 0. , side/divs } ;
Point( pc+2 ) = {  side/2 ,  side/2 , 0. , side/divs } ;
Point( pc+3 ) = { -side/2 ,  side/2 , 0. , side/divs } ;

lc = newl ;
Line( lc   ) = { pc   , pc+1 } ;
Line( lc+1 ) = { pc+1 , pc+2 } ;
Line( lc+2 ) = { pc+2 , pc+3 } ;
Line( lc+3 ) = { pc+3 , pc   } ;

llc = newll ;
Line Loop( llc ) = { lc:lc+3 } ;

sc = news ;
Plane Surface( sc ) = { llc } ;

Physical Surface( 1 ) = { sc } ;

Mesh 2 ;

Plugin(NewView).View = 0 ;
Plugin(NewView).Run ;

Plugin(MathEval).Expression0 = "Sqrt(x^2+y^2+z^2)" ;
Plugin(MathEval).View = 0 ;
Plugin(MathEval).Run ;

Save View[1] "NodeData.msh" ;
