Index: cpp/frams/genetics/f4/f4_general.cpp
===================================================================
--- cpp/frams/genetics/f4/f4_general.cpp	(revision 770)
+++ cpp/frams/genetics/f4/f4_general.cpp	(revision 774)
@@ -17,15 +17,15 @@
 #endif
 
-void rolling_dec(double * v)
+void rolling_dec(double *v)
 {
 	*v -= 0.7853;  // 0.7853981  45 degrees
 }
 
-void rolling_inc(double * v)
+void rolling_inc(double *v)
 {
 	*v += 0.7853;  // 0.7853981  45 degrees
 }
 
-int scanrec(const char * s, unsigned int slen, char stopchar)
+int scanrec(const char* s, unsigned int slen, char stopchar)
 {
 	unsigned int i = 0;
@@ -63,5 +63,5 @@
 
 f4_Cell::f4_Cell(int nname,
-	f4_Cell * ndad, int nangle, GeneProps newP)
+	f4_Cell *ndad, int nangle, GeneProps newP)
 {
 	name = nname;
@@ -84,5 +84,4 @@
 	//OM = Orient_1;
 	ctrl = 0;
-	state = 0;
 	inertia = 0.8;
 	force = 0.04;
@@ -102,5 +101,4 @@
 		if (T_NEURON4 == ndad->type)
 		{
-			state = ndad->state;
 			inertia = ndad->inertia;
 			force = ndad->force;
@@ -114,5 +112,5 @@
 
 
-f4_Cell::f4_Cell(f4_Cells * nO, int nname, f4_node * ngeno, f4_node * ngcur, f4_Cell * ndad, int nangle, GeneProps newP)
+f4_Cell::f4_Cell(f4_Cells *nO, int nname, f4_node *ngeno, f4_node *ngcur, f4_Cell *ndad, int nangle, GeneProps newP)
 {
 	name = nname;
@@ -138,5 +136,4 @@
 	//OM = Orient_1;
 	ctrl = 0;
-	state = 0;
 	inertia = 0.8;
 	force = 0.04;
@@ -156,5 +153,4 @@
 		if (T_NEURON4 == ndad->type)
 		{
-			state = ndad->state;
 			inertia = ndad->inertia;
 			force = ndad->force;
@@ -228,5 +224,5 @@
 					GeneProps newP = P;
 					newP.propagateAlong(false);
-					f4_Cell * tmp = new f4_Cell(org, org->nc, genot, gcur->child2, this, commacount, newP);
+					f4_Cell *tmp = new f4_Cell(org, org->nc, genot, gcur->child2, this, commacount, newP);
 					tmp->repeat = repeat;
 					repeat.clear();
@@ -246,5 +242,5 @@
 					tmp->neuclass = neuclass;
 					// duplicate links
-					f4_CellLink * ll;
+					f4_CellLink *ll;
 					for (int i = 0; i < nolink; i++)
 					{
@@ -640,5 +636,5 @@
 
 
-int f4_Cell::addlink(f4_Cell * nfrom, double nw, string nt)
+int f4_Cell::addlink(f4_Cell *nfrom, double nw, string nt)
 {
 	// if incoming neuron does not produce output, return error
@@ -725,5 +721,5 @@
 
 
-f4_CellLink::f4_CellLink(f4_Cell * nfrom, double nw, string nt)
+f4_CellLink::f4_CellLink(f4_Cell *nfrom, double nw, string nt)
 {
 	from = nfrom;
@@ -734,5 +730,5 @@
 
 
-f4_Cells::f4_Cells(f4_node * genome, int nrepair)
+f4_Cells::f4_Cells(f4_node *genome, int nrepair)
 {
 	// create ancestor cell
@@ -862,5 +858,5 @@
 
 
-void f4_Cells::addCell(f4_Cell * newcell)
+void f4_Cells::addCell(f4_Cell *newcell)
 {
 	if (nc >= MAX4CELLS - 1)
@@ -880,5 +876,5 @@
 }
 
-void f4_Cells::setRepairRemove(int nerrpos, f4_node * rem)
+void f4_Cells::setRepairRemove(int nerrpos, f4_node *rem)
 {
 	if (!repair)
@@ -896,5 +892,5 @@
 }
 
-int f4_Cells::setRepairInsert(int nerrpos, f4_node * parent, f4_node * insert)
+int f4_Cells::setRepairInsert(int nerrpos, f4_node *parent, f4_node *insert)
 {
 	if (!repair)
@@ -915,5 +911,5 @@
 }
 
-void f4_Cells::repairGeno(f4_node * geno, int whichchild)
+void f4_Cells::repairGeno(f4_node *geno, int whichchild)
 {
 	// assemble repaired geno, if the case
@@ -921,5 +917,5 @@
 	if ((NULL == repair_remove) && (NULL == repair_insert)) return;
 	// traverse genotype tree, remove / insert node
-	f4_node * g2;
+	f4_node *g2;
 	if (1 == whichchild) g2 = geno->child;
 	else             g2 = geno->child2;
@@ -928,5 +924,5 @@
 	if (g2 == repair_remove)
 	{
-		f4_node * oldgeno;
+		f4_node *oldgeno;
 		geno->removeChild(g2);
 		if (g2->child)
@@ -973,6 +969,6 @@
 {
 	int i, j, ccount;
-	f4_Cell * thisti;
-	f4_Cell * thneu;
+	f4_Cell *thisti;
+	f4_Cell *thneu;
 	char buf[200];
 
@@ -1117,5 +1113,5 @@
 }
 
-f4_node::f4_node(char nname, f4_node * nparent, int npos)
+f4_node::f4_node(char nname, f4_node *nparent, int npos)
 {
 	name = nname;
@@ -1138,5 +1134,5 @@
 }
 
-int f4_node::addChild(f4_node * nchi)
+int f4_node::addChild(f4_node *nchi)
 {
 	if (NULL == child)
@@ -1153,5 +1149,5 @@
 }
 
-int f4_node::removeChild(f4_node * nchi)
+int f4_node::removeChild(f4_node *nchi)
 {
 	if (nchi == child2)
@@ -1190,5 +1186,5 @@
 }
 
-f4_node * f4_node::ordNode(int n)
+f4_node* f4_node::ordNode(int n)
 {
 	int n1;
@@ -1210,5 +1206,5 @@
 }
 
-f4_node * f4_node::randomNode()
+f4_node* f4_node::randomNode()
 {
 	int n = count();
@@ -1217,10 +1213,10 @@
 }
 
-f4_node * f4_node::randomNodeWithSize(int mn, int mx)
+f4_node* f4_node::randomNodeWithSize(int mn, int mx)
 {
 	// try random nodes, and accept if size in range
 	// limit to maxlim tries
 	int i, n, maxlim;
-	f4_node * nod = NULL;
+	f4_node *nod = NULL;
 	maxlim = count();
 	for (i = 0; i < maxlim; i++)
@@ -1285,5 +1281,5 @@
 		{
 			char *temp = (char*)name.c_str();
-			NeuroClass * nc = GenoOperators::parseNeuroClass(temp);
+			NeuroClass *nc = GenoOperators::parseNeuroClass(temp);
 			if (nc != NULL)
 			{
@@ -1326,7 +1322,7 @@
 }
 
-f4_node * f4_node::duplicate()
-{
-	f4_node * copy;
+f4_node* f4_node::duplicate()
+{
+	f4_node *copy;
 	copy = new f4_node(*this);
 	copy->parent = NULL;  // set later
@@ -1356,5 +1352,5 @@
 // scan genotype string and build tree
 // return >1 for error (errorpos)
-int f4_processrec(const char * genot, unsigned pos0, f4_node * parent)
+int f4_processrec(const char* genot, unsigned pos0, f4_node *parent)
 {
 	int i, j, res, t;
@@ -1363,5 +1359,5 @@
 	double w;
 	unsigned gpos, oldpos;
-	f4_node * node1, *par;
+	f4_node *node1, *par;
 	unsigned beginindex;
 	string neutype = "";
@@ -1409,5 +1405,5 @@
 			// repetition marker, 1 by default
 			ExtValue val;
-			const char * end = val.parseNumber(genot + gpos + 1, ExtPType::TInt);
+			const char* end = val.parseNumber(genot + gpos + 1, ExtPType::TInt);
 			if (end == NULL) i = 1;
 			else i = val.getInt();
@@ -1499,5 +1495,5 @@
 			gpos += 2; //skipping "N:"
 			beginindex = gpos;
-			char * end = (char*)genot + beginindex;
+			char* end = (char*)genot + beginindex;
 			GenoOperators::parseNeuroClass(end);
 			gpos += end - genot - beginindex;
@@ -1602,5 +1598,5 @@
 	if (*parser != '[') return NULL;
 	parser++;
-	char * p = (char*)parser;
+	char* p = (char*)parser;
 	if (GenoOperators::parseNeuroClass(p) == NULL) return NULL;
 	neutype = string(parser, (const char *)p);
@@ -1617,7 +1613,7 @@
 }
 
-f4_node * f4_processtree(const char * geno)
-{
-	f4_node * root;
+f4_node* f4_processtree(const char* geno)
+{
+	f4_node *root;
 	int res;
 	root = new f4_node();
@@ -1628,5 +1624,5 @@
 		if (root->child)
 		{
-		char * buf = (char*)malloc(300);
+		char* buf = (char*)malloc(300);
 		DB(printf("(%d) ", root->child->count());)
 			buf[0] = 0;
