<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="https://communities.bentley.com/cfs-file/__key/system/syndication/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/"><channel><title>Python Script: How to locally refine the mesh for lines?</title><link>https://communities.bentley.com/products/geotech-analysis/f/forum/202058/python-script-how-to-locally-refine-the-mesh-for-lines</link><description>Hello, 
 In my python script I would like to locally refine the mesh for some lines. 
 I had a look in the Plaxis command index via the Scripting reference and from what I understand there is only a python command for global refinement. 
 So is there</description><dc:language>en-US</dc:language><generator>Telligent Community 12</generator><item><title>RE: Python Script: How to locally refine the mesh for lines?</title><link>https://communities.bentley.com/thread/607498?ContentTypeID=1</link><pubDate>Thu, 03 Sep 2020 15:17:06 GMT</pubDate><guid isPermaLink="false">6dad98f5-dbc9-4c4d-a9ba-e9da8dc6aa8e:4222bf76-6e95-45cb-80c6-48c84d7ad08c</guid><dc:creator>Pascal Schauber</dc:creator><description>&lt;p&gt;Thanks a lot Stefanos that is definitely working. Next time I will strongly think about this case sensitivity... Thanks again!&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Python Script: How to locally refine the mesh for lines?</title><link>https://communities.bentley.com/thread/607476?ContentTypeID=1</link><pubDate>Thu, 03 Sep 2020 14:08:21 GMT</pubDate><guid isPermaLink="false">6dad98f5-dbc9-4c4d-a9ba-e9da8dc6aa8e:a0cd1f67-19c3-47be-9a4d-a35dfd3bccfc</guid><dc:creator>Stefanos Papavasileiou</dc:creator><description>&lt;p&gt;Dear Pascal,&lt;/p&gt;
&lt;p&gt;I would write it as follows:&lt;/p&gt;
&lt;p&gt;for line in g_i.Lines:&lt;br /&gt;&amp;nbsp; &amp;nbsp; factor = 0.5&lt;br /&gt;&amp;nbsp; &amp;nbsp; line.CoarsenessFactor =&amp;nbsp;&lt;span&gt;factor&amp;nbsp;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="font-family:inherit;"&gt;If you want to use the set command with Python, then you would say:&amp;nbsp;&lt;/span&gt;&lt;span style="font-family:inherit;"&gt;g_i.set(line.CoarsenessFactor, factor)&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="font-family:inherit;"&gt;Note that Python is case sensitive and very strict with it. The property in PLAXIS is .&lt;span&gt;CoarsenessFactor and you need to be exact when addressing objects (g_i.Lines) and parameter names.&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>