Hi Mohammad, If you just wish to load in one sphere or a small amount of spheres which you know explicitly the locations of, then you can just explicitly give the positions and don't have to use a sampler: after all, a sampler just gives a vector the XYZ (coordinates) of spheres filling up the domain anyway. You can do something like this for example, to add 2 spheres:
ChVector<float> Sphere1(X1, Y1, Z1); ChVector<float> Sphere2(X2, Y2, Z2); std::vector<ChVector<float>> initialPos; initialPos.push_back(Sphere1); initialPos.push_back(Sphere2); gpu_sys.SetParticles(initialPos); Thank you, Ruochun On Wednesday, August 24, 2022 at 1:11:33 AM UTC-5 [email protected] wrote: > Hello, > > I am trying to perform a simulation where I create two spheres that can be > used to obtain the forces that these spheres experience when pushed towards > or pulled from each other. Initially, I tried to initiate a GPU bed with > only one sphere in it, then import another sphere using a mesh object, and > then try to drop the mesh sphere on the other share generated by the > sampler. However, it seems that samplers such as the PD sampler are not > able to generate one sphere only. I was wondering if there is a sample code > that could help with this simulation or if anyone could suggest some ways > to do that, > > Thank you so much in advance, > -- You received this message because you are subscribed to the Google Groups "ProjectChrono" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/projectchrono/eb2c8883-63d4-423e-9a4e-bdb7f3a2c7c8n%40googlegroups.com.
