Re: [Libmesh-devel] Invalid inital values for scalar variables of higher order

 Re: [Libmesh-devel] Invalid inital values for scalar variables of higher order From: Roy Stogner - 2012-03-28 18:34:10 On Wed, 28 Mar 2012, David Andrs wrote: > We are using scalar variables for solving a system of ODEs along with a system of PDEs. In that ODE system we have a scalar variable of higher > order to represent unknown variable \lambda_i. We set an initial condition for this variable to let's say 5000. Now, all the component of the > variable are set properly except the first one. If the variable is of a first order, its value is ok. > > I tracked the issue down to the one line, see attached patch. It is in WrappedFunction, if the variable has more components the else branch goes > over all but the first component. If that is correct, are we not using the system properly? You're using the system properly; that was just an awful typo (or brain failure? had I been using Matlab and indexing from 1 recently?) in WrappedFunction. It should be fixed in the svn head now; thanks very much for tracking it down. --- Roy 

 [Libmesh-devel] Invalid inital values for scalar variables of higher order From: David Andrs - 2012-03-28 18:23:25 Attachments: text/plain 0001-Fixing-initial-condition-setup-for-scalar-variables-.patch
 Re: [Libmesh-devel] Invalid inital values for scalar variables of higher order From: Roy Stogner - 2012-03-28 18:34:10 On Wed, 28 Mar 2012, David Andrs wrote: > We are using scalar variables for solving a system of ODEs along with a system of PDEs. In that ODE system we have a scalar variable of higher > order to represent unknown variable \lambda_i. We set an initial condition for this variable to let's say 5000. Now, all the component of the > variable are set properly except the first one. If the variable is of a first order, its value is ok. > > I tracked the issue down to the one line, see attached patch. It is in WrappedFunction, if the variable has more components the else branch goes > over all but the first component. If that is correct, are we not using the system properly? You're using the system properly; that was just an awful typo (or brain failure? had I been using Matlab and indexing from 1 recently?) in WrappedFunction. It should be fixed in the svn head now; thanks very much for tracking it down. --- Roy 
 Re: [Libmesh-devel] Invalid inital values for scalar variables of higher order From: David Knezevic - 2012-03-28 18:37:26 On 03/28/2012 02:34 PM, Roy Stogner wrote: > On Wed, 28 Mar 2012, David Andrs wrote: > >> We are using scalar variables for solving a system of ODEs along with a system of PDEs. In that ODE system we have a scalar variable of higher >> order to represent unknown variable \lambda_i. We set an initial condition for this variable to let's say 5000. Now, all the component of the >> variable are set properly except the first one. If the variable is of a first order, its value is ok. >> >> I tracked the issue down to the one line, see attached patch. It is in WrappedFunction, if the variable has more components the else branch goes >> over all but the first component. If that is correct, are we not using the system properly? > You're using the system properly; that was just an awful typo (or > brain failure? had I been using Matlab and indexing from 1 recently?) > in WrappedFunction. It should be fixed in the svn head now; thanks > very much for tracking it down. Coupling ODEs and PDEs via SCALAR --- cool idea! I guess you get "full" rows in your matrices (in terms of the sparsity pattern) corresponding to the SCALAR dofs. Is this a performance issue, particularly since it sounds like you have a high-order SCALAR? David 
 Re: [Libmesh-devel] Invalid inital values for scalar variables of higher order From: John Peterson - 2012-03-28 18:37:03 On Wed, Mar 28, 2012 at 12:34 PM, Roy Stogner wrote: > > On Wed, 28 Mar 2012, David Andrs wrote: > >> We are using scalar variables for solving a system of ODEs along with a system of PDEs. In that ODE system we have a scalar variable of higher >> order to represent unknown variable \lambda_i. We set an initial condition for this variable to let's say 5000. Now, all the component of the >> variable are set properly except the first one. If the variable is of a first order, its value is ok. >> >> I tracked the issue down to the one line, see attached patch. It is in WrappedFunction, if the variable has more components the else branch goes >> over all but the first component. If that is correct, are we not using the system properly? > > You're using the system properly; that was just an awful typo (or > brain failure? had I been using Matlab and indexing from 1 recently?) > in WrappedFunction.  It should be fixed in the svn head now; thanks > very much for tracking it down. What about the one on line 178? -- John 
 Re: [Libmesh-devel] Invalid inital values for scalar variables of higher order From: Roy Stogner - 2012-03-28 18:42:44 On Wed, 28 Mar 2012, John Peterson wrote: > On Wed, Mar 28, 2012 at 12:34 PM, Roy Stogner wrote: >> >> You're using the system properly; that was just an awful typo (or >> brain failure? had I been using Matlab and indexing from 1 recently?) >> in WrappedFunction.  It should be fixed in the svn head now; thanks >> very much for tracking it down. > > What about the one on line 178? Indeed. It's like I was just telling Ben the other day, we need to stop letting this roystgnr jackass commit patches that haven't even been posted to libmesh-devel first... --- Roy