Re: [deal.II] fixing one component of solution to the same value

2017-04-20 Thread RAJAT ARORA
Hello Daniel, Thank you so much for pointing this out. I have been stuck here for a long time and could not figure out. I understood that the sparsity pattern class was some how failing to know that space needs to be allocated for coupling with *the_dof even though it was not locally

Re: [deal.II] fixing one component of solution to the same value

2017-04-20 Thread Daniel Arndt
Rajat, It seems that I confused lines and did not express in the code what I wrote above: You have to add that additional index also when initializing the sparsity pattern, i.e. std::cout << " constraints printed " <

Re: [deal.II] fixing one component of solution to the same value

2017-04-20 Thread RAJAT ARORA
Hello Daniel, Thanks for the reply. I am actually doing what you suggested. Please look at the updated code that I had posted earlier and works with deal.ii 8.5. These lines are already there in the code. Surprisingly, such an error is still showing up. I am not sure what is still causing

Re: [deal.II] fixing one component of solution to the same value

2017-04-20 Thread Daniel Arndt
Rajat, What is happening here is that you try to create constraints that include DoFs that are not element of the IndexSet you provided to the DynamicSparsityPattern object. Therefore, all the entries for your "fixed" DoF are ignored if it is not already part of the locally relevant DoFs. Have

Re: [deal.II] fixing one component of solution to the same value

2017-04-17 Thread RAJAT ARORA
Hello Professor, I am now using deal.ii 8.5 and I am attaching the updated code. The error message still remains the same. On Monday, April 17, 2017 at 4:43:35 PM UTC-4, RAJAT ARORA wrote: > > > Hello Professor, > > I have created a test case to show this wierd behaviour (bug ? ). Running >

Re: [deal.II] fixing one component of solution to the same value

2017-04-12 Thread Wolfgang Bangerth
On 04/12/2017 05:03 PM, RAJAT ARORA wrote: I am not sure why such an error is occurring. This shows that sparsity pattern was generated that such a position (2249, 6) will not be filled, so no space was allocated while declaring the Petsc sparse matrix. However, constraints.distribute()

Re: [deal.II] fixing one component of solution to the same value

2017-04-12 Thread RAJAT ARORA
Hello Professor, I did what you suggested above. However, I am facing a problem. Just to repeat, I want to constraint all dofs on the z surface to a single dof (named as *the_dof = 2249*) I apply the constraints the following way. ComponentMask cm(dim, false); cm.set(2,

Re: [deal.II] fixing one component of solution to the same value

2017-03-23 Thread RAJAT ARORA
Thanks Professor. On Wednesday, March 15, 2017 at 3:35:42 PM UTC-4, Wolfgang Bangerth wrote: > > > > I am using deal.ii to solve a 3D solid mechanics problem which uses > > p::d::triangulation. > > > > I am solving equilibrium equations to solve for the displacement in the > domain. > > The

Re: [deal.II] fixing one component of solution to the same value

2017-03-15 Thread Wolfgang Bangerth
I am using deal.ii to solve a 3D solid mechanics problem which uses p::d::triangulation. I am solving equilibrium equations to solve for the displacement in the domain. The domain of the problem is a cylinder with the z-axis aligned along the axis of the cylinder. To avoid the warping, I want