<div dir="ltr">Thanks. Also, the physics seems to be controlled by the "op" variable? <br>Is there an interface to change the physics from the user code ?<br><br><a href="https://bitbucket.org/petsc/petsc/src/fb3a4ffdea0449562fb0f58dad4b44552b6d3589/src/dm/dt/interface/dtfe.c?at=master#cl-5028">https://bitbucket.org/petsc/petsc/src/fb3a4ffdea0449562fb0f58dad4b44552b6d3589/src/dm/dt/interface/dtfe.c?at=master#cl-5028</a><br>
<br><pre>switch (op) {
<a name="cl-5029"></a> case LAPLACIAN:
<a name="cl-5030"></a> if (useF0) {ierr = PetscSNPrintfCount(string_tail, end_of_buffer - string_tail, " f_0[fidx] = 4.0;\n", &count);STRING_ERROR_CHECK("Message to short");}
<a name="cl-5031"></a> if (useF1) {
<a name="cl-5032"></a> if (useAux) {ierr = PetscSNPrintfCount(string_tail, end_of_buffer - string_tail, " f_1[fidx] = a[cell]*gradU[cidx];\n", &count);STRING_ERROR_CHECK("Message to short");}
<a name="cl-5033"></a> else {ierr = PetscSNPrintfCount(string_tail, end_of_buffer - string_tail, " f_1[fidx] = gradU[cidx];\n", &count);STRING_ERROR_CHECK("Message to short");}
<a name="cl-5034"></a> }
<a name="cl-5035"></a> break;
<a name="cl-5036"></a> case ELASTICITY:
<a name="cl-5037"></a> if (useF0) {i</pre><br></div><div class="gmail_extra"><br><br><div class="gmail_quote">On Tue, Apr 22, 2014 at 5:03 AM, Karl Rupp <span dir="ltr"><<a href="mailto:rupp@iue.tuwien.ac.at" target="_blank">rupp@iue.tuwien.ac.at</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hi David,<div class=""><br>
<br>
> I'm trying to use<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<br>
-variable_coefficient field with -petscfe_type opencl -mat_petscfe_type<br>
opencl<br>
<br>
constant coefficients "-variable_coefficient none" works fine, but I am<br>
getting NaN in my residual vector for spatially varying coefficients.<br>
<br>
I tried changing N_t manually for N_comp_aux =1, also tried setting my<br>
variable coefficient field to a constant at each quadrature point to see<br>
if any difference.<br>
</blockquote>
<br></div>
This is - unfortunately - a known issue, where we currently don't know whether this is a race condition in the OpenCL kernel, or something goes wrong with the data setup. I expect this to require rather more elaborate debugging, so unfortunately I can only advise you to wait until this is fixed...<br>
<br>
Best regards,<br>
Karli<br>
<br>
</blockquote></div><br></div>