Subversion Repositories sifel

Compare Revisions

Ignore whitespace Rev 790 → Rev 791

/trunk/SIFEL/GEFEL/galias.h
275,4 → 275,8
{"resfmt_gid",3}, {"resfmt_vtk",4}, {"resfmt_plain_out",5},
{"resfmt_diag_dat",6}};
const kwdset resfilefmt_kwdset(sizeof(resfilefmtstr)/sizeof(*resfilefmtstr), resfilefmtstr);
 
enum timespectype {no_tspec=0, tspec_per, tspec_udt, tspec_tabper, tspec_selid};
const enumstr timespectypestr[] = {{"no_tspec",0}/*, tspec_per, tspec_udt, tspec_tabper, tspec_selid*/};
const kwdset timespectype_kwdset(sizeof(timespectypestr)/sizeof(*timespectypestr), timespectypestr);
#endif
/trunk/SIFEL/MEFEL/PREP/hngen.cpp
0,0 → 1,13
#include <float.h>
#include "hngen.h"
#include "vector.h"
 
 
hngen::hngen()
{
x = y = z = 0.0;
xi = eta = zeta = 0.0;
cerr = DBL_MAX;
eid = -1;
et = gtypel(-1);
}
/trunk/SIFEL/MEFEL/PREP/hngen.h
0,0 → 1,20
#ifndef HNGEN_H
#define HNGEN_H
 
#include "galias.h"
#include "vector.h"
 
class hngen
{
public:
double x, y, z; // global coordinates of hanging node
double xi, eta, zeta; // natural coordinates of hanging node on element eid
double cerr; // error of computed natural coordinates if they are not in range [-1.0;1.0] exactly
long eid; // master element id on which the hanging node is located eid >=0,
gtypel et; // general element type used for the hanging node assignment
ivector mnodes; /// array of master nodes
hngen();
};
 
#endif
/trunk/SIFEL/TRFEL/PREP/outputt.cpp
824,6 → 824,8
}
}
 
fprintf(out, "# number of nodes with point sources\n0\n"); // not yet implemented
 
fprintf(out, "\n");
 
delete [] nsl;
/trunk/SIFEL/TRFEL/SRC/loadcaset.cpp
16,8 → 16,12
nqs = 0;
// number of nodes with defined source
nnqs = 0;
// number of nodes with defined point source
nnpqs = 0;
// list of nodes with defined source
lnqs = NULL;
// list of nodes with defined point source
lnpqs = NULL;
// number of elements with defined source
neqs = 0;
// list of elements with defined source
75,6 → 79,12
delete [] lnqs[i];
}
delete [] lnqs;
 
// list of nodes with defined point source
for (i=0;i<nnpqs;i++){
delete [] lnpqs[i];
}
delete [] lnpqs;
// list of elements with defined source
for (i=0;i<neqs;i++){
162,6 → 172,9
// list of nodes with defined source
xfscanf (in,"%ld",&nnqs);
if (Mesprt==1)
fprintf (stdout,"\n the number of nodes with source %ld",nnqs);
if (nnqs<0)
print_err("negative number of nodes with defined source",__FILE__,__LINE__,__func__);
 
175,12 → 188,12
// list of elements with defined source
xfscanf (in,"%ld",&neqs);
if (Mesprt==1)
fprintf (stdout,"\n the number of elements with source %ld",neqs);
 
if (neqs<0)
print_err("negative number of elements with defined source",__FILE__,__LINE__,__func__);
 
if (Mesprt==1)
fprintf (stdout,"\n number of defined sources %ld",neqs);
 
leqs = new long* [neqs];
for (i=0;i<neqs;i++){
leqs[i] = new long [2];
188,6 → 201,22
leqs[i][0]--;
leqs[i][1]--;
}
// list of nodes with defined point source
xfscanf (in,"%ld",&nnpqs);
if (Mesprt==1)
fprintf (stdout,"\n the number of point sources %ld",nnpqs);
 
if (nnpqs<0)
print_err("negative number of nodes with defined point source",__FILE__,__LINE__,__func__);
 
lnpqs = new long* [nnpqs];
for (i=0;i<nnpqs;i++){
lnpqs[i] = new long [2];
xfscanf (in,"%ld %ld",&lnpqs[i][0],&lnpqs[i][1]);
lnpqs[i][0]--;
lnpqs[i][1]--;
}
}
// **********************************************
440,6 → 469,13
for (i=0;i<neqs;i++){
fprintf (out,"\n %ld %ld",leqs[i][0]+1,leqs[i][1]+1);
}
// list of nodes with defined point source
fprintf (out,"\n\n %ld",nnpqs);
for (i=0;i<nnpqs;i++){
fprintf (out,"\n %ld %ld",lnpqs[i][0]+1,lnpqs[i][1]+1);
}
}
// **********************************************
1103,5 → 1139,43
}
}
}
if (nnpqs>0){
long ndofn,nid,sid,*cnn;
double s;
cnn = new long [1];
for (i=0;i<nnpqs;i++){
// loop over nodes with prescribed point source
// node id
nid=lnpqs[i][0];
// number of DOFs in the node
ndofn = Tt->give_ndofn (nid);
if (ndofn!=1){
print_err("the number of DOFs in nodes in point sources is not 1", __FILE__, __LINE__, __func__);
abort ();
}
// DOF id
Tt->give_node_code_numbers (nid,cnn);
// point source id
sid = lnpqs[i][1];
// there should be element id as an argument of the function giveval
// in the case of source described by a mathematical function, the argument
// is not used inside
s = sour[sid].giveval (0);
if (cnn[0]>0){
rhs[cnn[0]-1]+=s;
}
 
}
delete [] cnn;
}
}
 
/trunk/SIFEL/TRFEL/SRC/loadcaset.h
68,6 → 68,12
/// number of elements influenced by nodes with prescribed source
long neins;
/// number of nodes with defined point quantity source
long nnpqs;
/// list of nodes with defined point quantity source
/// lnpqs[nid][qsid] - at node nid (node id) is defined point source of quantity with number qsid (quantity source id)
long **lnpqs;
 
/// objects describing sources
sourcet *sour;
/trunk/SIFEL/svndiff
1,2 → 1,2
#!/bin/bash
svn diff --diff-cmd=meld
svn diff --diff-cmd=meld "$@"