Discussion Closed This discussion was created more than 6 months ago and has been closed. To start a new discussion with a link back to this one, click here.
Higher Order Spatial Derivatives
Posted 2010年9月28日 GMT-4 17:29 9 Replies
Please login with a confirmed email address before reporting spam
I am trying to use a third order spatial derivative in an equation for a variable, but it does not seem to be working out. For example, I want to know d(d(d(A, x),x),x) to obtain the third derivative of A in the x direction, but keep getting 0 when I know what isn't the answer.
I have tried the PDE solver, to no avail. And, I have tried substituting a variable name for a lower derivative, via
B = d(d(A,x),x)
d(B,x)
But that produced an answer of zero also. What to do?
Please login with a confirmed email address before reporting spam
have you tried to plot d(A,x), and then d(d(A,x),x) ... just to see how they look ?
--
Good luck
Ivar
Please login with a confirmed email address before reporting spam
Please login with a confirmed email address before reporting spam
Attachments:
Please login with a confirmed email address before reporting spam
However, you just get zeros while deriving spatial derivatives in postprocessing mode?
May be this is because COMSOL gets these derivatives out of the shape functions. E.g. if you are using second order shape functions, the third derivative would be always zero, just due to the fact, that the third derivation of this 2.order polynom is always zero. In COMSOL V3.5a you can use "Recover" option in postprocessing options. Then COMSOL calculates the spatial derivativs in another (slower) more accurate (may be not zero) way (new approximation of the depedent variable to another polynom). See the doc.
Another option would be, if you increase the order of your shape/basis functions. This will increase your DoF, too.
Please login with a confirmed email address before reporting spam
Please login with a confirmed email address before reporting spam
but the argument advanced: that with second order elements (the default of COMSOL) we can get out at most the second derivative (any higher derivatives are equal = 0) is clearly a good argument.
There is some remarks in the doc reminding this, but I havent manaage to find it back just now ;)
--
Good luck
Ivar
Please login with a confirmed email address before reporting spam
What's interesting is that I HAVE been able to get third order derivatives in a 2D model, but not a 3D one.
Please login with a confirmed email address before reporting spam
I always get zero for d(Txx,x), altough Txx is definitely not constant. Even when i use "recover" or quintic elements. (I'm using V3.5a)
A quick workaround is to calculate the derivative with an extern program - matlab connection or other Math tools (there are many: Octave, Origin, ....)
Please login with a confirmed email address before reporting spam
Nonetheless, this seems like a relatively straightforward issue and there ought to be a way to figure it out within Comsol alone. I have no clue why/ how I got it to work in 2D when it doesn't in 3D or 1D. Odd.
Note that while COMSOL employees may participate in the discussion forum, COMSOL® software users who are on-subscription should submit their questions via the Support Center for a more comprehensive response from the Technical Support team.
Suggested Content
- BLOG Plotting Spatial Derivatives of the Magnetic Field
- FORUM How can I convert Comsol3.5 matlab script to a higher version?
- FORUM Contact model stiffness much higher than expected
- KNOWLEDGE BASE How do I solve a PDE with space derivatives of order higher than two?
- KNOWLEDGE BASE Understanding, and changing, the element order