fix domain voxel length bug
This commit is contained in:
@@ -131,7 +131,11 @@ void Domain::initialize( std::shared_ptr<Database> db )
|
||||
outlet_layers_y = OutletCount[1];
|
||||
outlet_layers_z = OutletCount[2];
|
||||
}
|
||||
|
||||
voxel_length = 1.0;
|
||||
if (d_db->keyExists( "voxel_length" )){
|
||||
auto voxel_length = d_db->getScalar<double>("voxel_length");
|
||||
}
|
||||
|
||||
ASSERT( n.size() == 3u );
|
||||
ASSERT( nproc.size() == 3u );
|
||||
int nx = n[0];
|
||||
@@ -158,11 +162,8 @@ void Domain::initialize( std::shared_ptr<Database> db )
|
||||
// Fill remaining variables
|
||||
N = Nx*Ny*Nz;
|
||||
Volume = nx*ny*nx*nproc[0]*nproc[1]*nproc[2]*1.0;
|
||||
voxel_length = 1.0;
|
||||
if (d_db->keyExists( "voxel_length" )){
|
||||
auto voxel_length = d_db->getScalar<double>("voxel_length");
|
||||
if (myrank==0) printf("voxel length = %f micron \n", voxel_length);
|
||||
}
|
||||
|
||||
if (myrank==0) printf("voxel length = %f micron \n", voxel_length);
|
||||
|
||||
id = new signed char[N];
|
||||
memset(id,0,N);
|
||||
|
||||
Reference in New Issue
Block a user