Viewing 3 posts - 1 through 3 (of 3 total)
• Author
Posts
• #8470
liu
Participant

In the case of dkt2d, I added two rectangular solid regions and gave the overall rebound boundary conditions, but in the final calculation, why do particles still fall in, because the three rectangular regions overlap?

void prepareGeometry(UnitConverter<T,DESCRIPTOR> const& converter, //几何图形数据
SuperGeometry<T, 2>& superGeometry)
{
OstreamManager clout(std::cout, “prepareGeometry”);
clout << “Prepare Geometry …” << std::endl;

//superGeometry.rename(0, 2); //将超级几何体中的材料编号 0 重命名为 2。这可能是为了指定一种材料类型。
//superGeometry.rename(2, 1, {1, 1}); //将超级几何体中的材料编号 2 重命名为 1,只有边界既是{1，1}命名为材料2

//第一个建筑
std::vector<T> extend1(2, T());
extend1[0] = lengthX1;
extend1[1] = lengthY1;
std::vector<T> origin1(2, T()); //圆心
origin1[0] = 0.02;
origin1[1] = 0;
IndicatorCuboid2D<T> cuboid1(extend1, origin1); //创建长方体

//superGeometry.rename(1, 2,cuboid1);//命名2

//第二个建筑
std::vector<T> extend2(2, T());
extend2[0] = lengthX1;
extend2[1] = lengthY1;
std::vector<T> origin2(2, T()); //圆心
origin2[0] = 0.06;
origin2[1] = 0;
IndicatorCuboid2D<T> cuboid2(extend2, origin2); //创建长方体

superGeometry.rename( 0, 2); //将超级几何体中的材料编号 0 重命名为 2。这可能是为了指定一种材料类型。
superGeometry.rename( 2, 1, {1, 1}); //将超级几何体中的材料编号 2 重命名为 1,只有边界既是{1，1}命名为材料2

superGeometry.rename(1, 2, cuboid1); //命名2

superGeometry.rename(1, 2, cuboid2); //命名2

superGeometry.clean();
superGeometry.innerClean();

superGeometry.checkForErrors();
superGeometry.getStatistics().print();
clout << “Prepare Geometry … OK” << std::endl;
}

#8472
liu
Participant

Dear Community,
I have another simple question how to define its boundary conditions for an edge in a 2D model, thanks!

#8531
jan
Participant

Dear liu,

please make sure that you also extend the `solidBoundaries` vector with the extra boundaries you defined, as this container is used for the contact detection and calculation.

For your second question, could you please elaborate what you’d like to achieve?

Best regards,
Jan

Viewing 3 posts - 1 through 3 (of 3 total)
• You must be logged in to reply to this topic.