}
}
}
+
+ //================================================================================
+ /*!
+ * \brief Return number of nodes in sonId-th son of a Dynamic() cell
+ */
+ //================================================================================
+
+ unsigned CellModel::getNumberOfNodesConstituentTheSon2(unsigned sonId, const int *nodalConn, int lgth) const
+ {
+ if(!isDynamic())
+ return getNumberOfNodesConstituentTheSon(sonId);
+
+ if(_dim==2)//polygon
+ {
+ return 2;
+ }
+ else
+ {//polyedron
+ const int *where=nodalConn;
+ for(int i=0;i<sonId;i++)
+ {
+ where=std::find(where,nodalConn+lgth,-1);
+ where++;
+ }
+ const int *where2=std::find(where,nodalConn+lgth,-1);
+ return where2-where;
+ }
+ }
+
}
unsigned getNumberOfSons() const { return _nb_of_sons; }
unsigned getNumberOfSons2(const int *conn, int lgth) const;
unsigned getNumberOfNodesConstituentTheSon(unsigned sonId) const { return _nb_of_sons_con[sonId]; }
+ unsigned getNumberOfNodesConstituentTheSon2(unsigned sonId, const int *nodalConn, int lgth) const;
NormalizedCellType getSonType(unsigned sonId) const { return _sons_type[sonId]; }
NormalizedCellType getSonType2(unsigned sonId) const;
unsigned fillSonCellNodalConnectivity(int sonId, const int *nodalConn, int *sonNodalConn) const;