{"action":"created","issue":{"url":"https://api.github.com/repos/libMesh/libmesh/issues/460","labels_url":"https://api.github.com/repos/libMesh/libmesh/issues/460/labels{/name}","comments_url":"https://api.github.com/repos/libMesh/libmesh/issues/460/comments","events_url":"https://api.github.com/repos/libMesh/libmesh/issues/460/events","html_url":"https://github.com/libMesh/libmesh/pull/460","id":57459558,"number":460,"title":"New candidate example: systems_of_equations_ex8","user":{"login":"dknez","id":3017801,"avatar_url":"https://avatars.githubusercontent.com/u/3017801?v=3","gravatar_id":"","url":"https://api.github.com/users/dknez","html_url":"https://github.com/dknez","followers_url":"https://api.github.com/users/dknez/followers","following_url":"https://api.github.com/users/dknez/following{/other_user}","gists_url":"https://api.github.com/users/dknez/gists{/gist_id}","starred_url":"https://api.github.com/users/dknez/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dknez/subscriptions","organizations_url":"https://api.github.com/users/dknez/orgs","repos_url":"https://api.github.com/users/dknez/repos","events_url":"https://api.github.com/users/dknez/events{/privacy}","received_events_url":"https://api.github.com/users/dknez/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":41,"created_at":"2015-02-12T13:25:54Z","updated_at":"2015-02-17T05:38:59Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/libMesh/libmesh/pulls/460","html_url":"https://github.com/libMesh/libmesh/pull/460","diff_url":"https://github.com/libMesh/libmesh/pull/460.diff","patch_url":"https://github.com/libMesh/libmesh/pull/460.patch"},"body":"This code implements linear elasticity with contact using a penalty approach. I think this demonstrates some interesting capabilities which may be of broad interest, so I thought it'd make a good libMesh example. Note: I haven't tried to optimize this for efficiency at all at this stage; I just wanted to get something working.\r\n\r\nThe example basically works, e.g. see the attached screenshots that compare the \"without contact penalty\" vs the \"with contact penalty\" cases.\r\n\r\n![without_contact_penalty](https://cloud.githubusercontent.com/assets/3017801/6167853/a8232210-b2fa-11e4-8645-4579252bc831.png)\r\n\r\n![with_contact_penalty](https://cloud.githubusercontent.com/assets/3017801/6167858/b063ae22-b2fa-11e4-9f09-3122e01ebf3b.png)\r\n\r\nHowever, there are a few problems with this code as it is now, so I was hoping to get a bit of feedback via a PR. The problems are as follows:\r\n\r\n* (Minor issue) Apparently I haven't set up the Makefiles correctly yet since when I do \"make\" I get this error:\r\n\r\n> Making all in systems_of_equations/systems_of_equations_ex8\r\n> /bin/bash: line 21: cd: systems_of_equations/systems_of_equations_ex8: No such file or directory\r\n> make[1]: *** [all-recursive] Error 1\r\n> make[1]: Leaving directory `/home/dknez/software/libmesh_build/opt_real/examples'\r\n\r\nI'm sure this is easy to fix, can someone point me in the right direction on this? By the way, are the Makefile changes required for adding a new example documented anywhere?\r\n\r\n* This example requires the sparsity pattern to be augmented, since the contact force depends on the solution on either side of the contact surface. I added code to augment the sparsity pattern (commented out code around line 447 of linear_elasticity_with_contact.C), but it causes the jacobian matrix to be in an invalid state which leads to a crash. I looked into PetscNonlinearSolver, but it wasn't clear to me what was going wrong. For now, as a temporary hack, I just turned off the PETSc error on allocating new non-zeros (line 455 of linear_elasticity_with_contact.C), but allocating extra non-zeros is slow, so I'd like to get this issue fixed.\r\n\r\n* The nonlinear solver appears to converge to reasonable solutions, e.g. as per the screenshots above. But the residual stagnates, and the nonlinear solve terminates due to \"DIVERGED_LINE_SEARCH\". However, I have a feeling this might be the expected behavior in this case since a contact penalty is non-smooth and hence causes problems for nonlinear solvers.\r\n\r\n* I haven't tested this in parallel yet. That will probably require augmenting the send_list as well. I wanted to resolve the augment_sparsity issue before I look into that.\r\n\r\n"},"comment":{"url":"https://api.github.com/repos/libMesh/libmesh/issues/comments/74619549","html_url":"https://github.com/libMesh/libmesh/pull/460#issuecomment-74619549","issue_url":"https://api.github.com/repos/libMesh/libmesh/issues/460","id":74619549,"user":{"login":"moosebuild","id":6702118,"avatar_url":"https://avatars.githubusercontent.com/u/6702118?v=3","gravatar_id":"","url":"https://api.github.com/users/moosebuild","html_url":"https://github.com/moosebuild","followers_url":"https://api.github.com/users/moosebuild/followers","following_url":"https://api.github.com/users/moosebuild/following{/other_user}","gists_url":"https://api.github.com/users/moosebuild/gists{/gist_id}","starred_url":"https://api.github.com/users/moosebuild/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/moosebuild/subscriptions","organizations_url":"https://api.github.com/users/moosebuild/orgs","repos_url":"https://api.github.com/users/moosebuild/repos","events_url":"https://api.github.com/users/moosebuild/events{/privacy}","received_events_url":"https://api.github.com/users/moosebuild/received_events","type":"User","site_admin":false},"created_at":"2015-02-17T05:38:59Z","updated_at":"2015-02-17T05:38:59Z","body":"Results of testing 12e7480cc36f4175555e51529ad15ca971966280 using libmesh_PR_test_dbg recipe:\n\nPassed on: linux-gnu\n\nView the results here: https://www.moosebuild.com/view_job/11760"}}