Cylinder parameters #617
-
Hello, Thank you for your help. |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
Hi @Kbourbat25, our method just returns a voxel image of cylinders, BUT we do this by first generating lines then fattening them. So maybe you could repurpose our 'line generator' code? There are two functions in the generators module, the public porespy/porespy/generators/_imgen.py Line 832 in 4a786d7 Meanwhile, it might be worth considering adding a comsol capatible cylinders generator. Could you possible post here the file format that comsol wants? |
Beta Was this translation helpful? Give feedback.
Hi @jgostick , thank you for this reply, you found in what follow the difinition of cylinder under comsol :
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% The difinition of cylinder in Comsol
% name cyl1 , type Cylinder
model.component('comp1').geom('geom1').create('cyl1', 'Cylinder');
% radius r=0.01
model.component('comp1').geom('geom1').feature('cyl1').set('r', 0.01);
% position of the center of the base of cylinder
model.component('comp1').geom('geom1').feature('cyl1').set('pos', [0 0 0]);
% height of the cylinder h=2
model.component('comp1').geom('geom1').feature('cyl1').set('h', 2);
% coordinate system = spherical
model.component('comp1').geom('geom1').feature('cyl1').…