From: KIRK, BENJAMIN (JSCEG) (NASA) <benjamin.kirk1@na...>  20050608 19:37:10

Thanks for that. One question in System::project_solution(...); FEType provides default_quadrature_order() which should define the mininmum quadrature rule needed to integrate a mass matrix exactly, assuming a n_qp rule integrates (2*n_qp  1) degree polynomials exactly. Do you want to use that in there? As for slowing the example down, I really don't care. I think it would be worth extending these examples a bit to show how easy it would be to use arbitrary finite element families (not just Lagrange), and this is a necessary step. The other step would be replacing the meshes with QUAD9/TRI6 equivalents. Then, something like this would be nice: ./ex10 fe=Lagrange order=1 ./ex10 fe=Lagrange order=2 ./ex10 fe=Hierarchic order=4 ... and probably introduce the exact_solution for this case. Thoughts? Ben Original Message From: libmeshdeveladmin@... [mailto:libmeshdeveladmin@...] On Behalf Of Roy Stogner Sent: Wednesday, June 08, 2005 12:31 PM To: KIRK, BENJAMIN (JSCEG) (NASA) Cc: libmeshdevel@... Subject: Re: [Libmeshdevel] nonLagrange elements for ex9,10,14 On Wed, 8 Jun 2005, KIRK, BENJAMIN (JSCEG) (NASA) wrote: > One issue, though... ex9 & ex10 require an initial condition, and > right now this is assigned at the nodes 'cus it assumes a Lagrangian > basis. We need exactly what we were discussing yesterday: a generic > projection capability for a usersupplied function. I added it last night. The wrapper to make ex9's solution compatible with System::project_solution() is: Number exact_value (const Point& p, const Parameters& parameters, const std::string&, const std::string&) { return exact_solution(p(0), p(1), parameters.get<Real> ("time")); } and the new init_cd is: void init_cd (EquationSystems& es, const std::string& system_name) { // It is a good idea to make sure we are initializing // the proper system. assert (system_name == "ConvectionDiffusion"); // Get a reference to the ConvectionDiffusion system object. TransientLinearImplicitSystem & system = es.get_system<TransientLinearImplicitSystem> ("ConvectionDiffusion"); // Project initial conditions at time 0 es.parameters.set<Real> ("time") = 0; system.project_solution(exact_value, NULL, es.parameters); } I haven't committed any ex10 changes to CVS yet; I've been using them for private testing and didn't want to commit less efficient code (that initial project_solution takes like half a second and doesn't optimize for the Lagrange case) without running it by everyone first.  Roy  This SF.Net email is sponsored by: NEC IT Guy Games. How far can you shotput a projector? How fast can you ride your desk chair down the office luge track? If you want to score the big prize, get to know the little guy. Play to win an NEC 61" plasma display: http://www.necitguy.com/?r=20 _______________________________________________ Libmeshdevel mailing list Libmeshdevel@... https://lists.sourceforge.net/lists/listinfo/libmeshdevel 