On Thu, 28 Mar 2013, Manav Bhatia wrote:
I had essentially started with the transient Navier-Stokes system example, and
had modified it
to do what I needed. The behavior that I was seeing was that after the call to
UnsteadySolver::reinit(), the old_local_nonlinear_solution was zero (as opposed
to projecting
the solution before refinement), and this was directly used in calculating the
dU in
euler_solver.
I will try to create a small example code and send it your way.
Thanks! So far my best theory is that I was always doing an
advance_timestep() right after the final refinement step in my own
codes, in which case what you're seeing is a real bug that I'd just
been avoiding through dumb luck. Your fix would be half-right, if
that's what's going on: we would want to localize
old_local_nonlinear_solution from _old_nonlinear_solution; we just
wouldn't want to copy solution to _old_nonlinear_solution first.
In fact, would you try that fix and see if it works for you?
Instead of adding:
+ // copy the system solution to the current vector
+ // this assumes that the syste vector has already been resized
and projected
+ NumericVector<Number> &old_nonlinear_soln =
+ _system.get_vector("_old_nonlinear_solution");
+ NumericVector<Number> &nonlinear_solution =
+ *(_system.solution);
+
+ old_nonlinear_soln = nonlinear_solution;
+
+ old_nonlinear_soln.localize
+ (*old_local_nonlinear_solution,
+ _system.get_dof_map().get_send_list());
just add:
+ // localize the old solution vector
+ NumericVector<Number> &old_nonlinear_soln =
+ _system.get_vector("_old_nonlinear_solution");
+
+ old_nonlinear_soln.localize
+ (*old_local_nonlinear_solution,
+ _system.get_dof_map().get_send_list());
If it works, then we'll add that and no need to worry about the
example.
---
Roy
------------------------------------------------------------------------------
Own the Future-Intel® Level Up Game Demo Contest 2013
Rise to greatness in Intel's independent game demo contest.
Compete for recognition, cash, and the chance to get your game
on Steam. $5K grand prize plus 10 genre and skill prizes.
Submit your demo by 6/6/13. http://p.sf.net/sfu/intel_levelupd2d
_______________________________________________
Libmesh-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/libmesh-users