This is a read only copy of the old FEniCS QA forum. Please visit the new QA forum to ask questions

Derivatives of coordinates with respect to boundary parameter

+1 vote

Hi everybody,

This may be a completely idiotic question; apologies in advance if it is.

I have a variational form on a boundary that looks something like this:

$$\int_{\partial \Omega}K \cdot \left((X_u \frac{du}{ds} + X_v \frac{dv}{ds}) \times \delta X\right) ds$$

Where $X(u,v)=\left(x(u,v),y(u,v),z(u,v)\right)$ is a (parametric) vector function, $K$ is a 3-vector which does not depend on the solution (i.e. is constant w.r.t variations), $\delta X$ is an arbitrary variation, subscripts indicate partial derivatives.

In the language of FEniCS, the coordinates $(u,v)$ are x[0] and x[1] respectively, $X$ is a Function, $\delta X$ is a TestFunction and $ds$ is a Measure on $\partial \Omega$.

What I want to know is, how can I write the terms $\frac{du}{ds}$ and $\frac{dv}{ds}$ in FEniCS?

Thanks in advance,

Chris

EDIT: This question originally referred to $dt$. I have altered this to $ds$ to make it clear that this is a parameter by which the boundary $\partial \Omega$ is parametrized. Apologies for any confusion.

asked Oct 15, 2013 by christopher.laing FEniCS Novice (290 points)
edited Oct 15, 2013 by christopher.laing

1 Answer

0 votes

Project $u$, $v$ on appropriate FE space and then you can take partial derivatives of the result. Apply some trick (probably differentiation of composed functions) to obtain derivative w.r.t. $s$.

answered Oct 18, 2013 by Jan Blechta FEniCS Expert (51,420 points)
...