{"id":170817,"date":"2023-06-05T07:05:11","date_gmt":"2023-06-05T07:05:11","guid":{"rendered":"\/knowledge\/forums\/topic\/how-to-create-zero-length-springs-in-mechanical\/"},"modified":"2023-07-31T12:33:49","modified_gmt":"2023-07-31T12:33:49","slug":"how-to-create-zero-length-springs-in-mechanical","status":"publish","type":"topic","link":"https:\/\/innovationspace.ansys.com\/knowledge\/forums\/topic\/how-to-create-zero-length-springs-in-mechanical\/","title":{"rendered":"How To create zero length springs in Mechanical.?"},"content":{"rendered":"<p>Mechanical does not allow zero length springs so a command object is the only way to create them.  Below is the command object that will create 6 spring elements. Insert the command object Analysis environment level. It requires a named selection for the vertex where it will attach 6 springs.  !!!!!!!! envronment command object to create 6 zero length springs at named selelction spr containing one vertex  fini  \/prep7  *get,ndmax,node,,num,maxd *get,elmax,elem,,num,maxd *get,etmax,etyp,,num,max  cmsel,s,spr                             ! spr is a named selection containing one vertex created in Mechanical ndspr=ndnext(0) n,ndmax+1,nx(ndspr),ny(ndspr),nz(ndspr)   ! *dim,stf,array,6 stf(1)=1,2,3,4,5,6                 ! replace 1 to 6 with your stiffness values    ! *do,kk,1,6 et,etmax+kk,14, ,kk type,etmax+kk mat,etmax+kk r,etmax+kk,stf(kk) real,etmax+kk secn,etmax+kk en,elmax+kk,ndmax+1,ndspr *enddo allsel cmsel,all fini \/solu<\/p>\n","protected":false},"template":"","class_list":["post-170817","topic","type-topic","status-publish","hentry","topic-tag-command-objects","topic-tag-general","topic-tag-macros-scripting","topic-tag-mechanical","topic-tag-structural-mechanics"],"aioseo_notices":[],"acf":[],"custom_fields":[{"0":{"_wp_page_template":["default"],"_bbp_last_active_time":["2\/6\/2023 20:20"],"_bbp_forum_id":["27789"],"_bbp_author_ip":["209.182.204.162"],"_btv_view_count":["1149"],"siebel_km_number":["2051783"],"product_version":[""],"km_published_date":["2017-10-10T00:00:00.000Z"],"family":["Structural Mechanics"],"application_name":["Mechanical"]},"test":"articlesansys-com"}],"_links":{"self":[{"href":"https:\/\/innovationspace.ansys.com\/knowledge\/wp-json\/wp\/v2\/topics\/170817","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/innovationspace.ansys.com\/knowledge\/wp-json\/wp\/v2\/topics"}],"about":[{"href":"https:\/\/innovationspace.ansys.com\/knowledge\/wp-json\/wp\/v2\/types\/topic"}],"version-history":[{"count":0,"href":"https:\/\/innovationspace.ansys.com\/knowledge\/wp-json\/wp\/v2\/topics\/170817\/revisions"}],"wp:attachment":[{"href":"https:\/\/innovationspace.ansys.com\/knowledge\/wp-json\/wp\/v2\/media?parent=170817"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}