Lars Gregersen
COMSOL Employee
Please login with a confirmed email address before reporting spam
Posted:
8 years ago
19.05.2017, 03:42 GMT-4
Hi Clyde
I'm sure that I fully understand what you are trying to do, but it should be possible to calculate the integral using projection couplings. See this section "EXAMPLES OF PROJECTION COUPLINGS" in the Reference Manual for some examples.
--
Lars Gregersen
Comsol Denmark
Hi Clyde
I'm sure that I fully understand what you are trying to do, but it should be possible to calculate the integral using projection couplings. See this section "EXAMPLES OF PROJECTION COUPLINGS" in the Reference Manual for some examples.
--
Lars Gregersen
Comsol Denmark
Please login with a confirmed email address before reporting spam
Posted:
8 years ago
19.05.2017, 11:27 GMT-4
Updated:
8 years ago
19.05.2017, 13:26 GMT-4
Thanks Lars,
I had reviewed the section on Extrusion, Projection, & Scalar coupling operators; however, the examples in the Reference Manual were a bit vague. Would you know of a good resource showing a practical example?
As for what I'm working with, I have values of ion concentration over a simulated 2D contour over time, using an Extremely Fine Rectangular Mesh. The contour results in a 41 x 41 value matrix at each instance in time. To simply my scenario, let me illustrate with a 3 x 3 matrix: Let c(x,y,t) at t = tn be
| 2.4 4.5 5.1 | = | c(0,2,tn) c(1,2,tn) c(2,2,tn) |
| 1.3 3.6 1.8 | = | c(0,1,tn) c(1,1,tn) c(2,1,tn) |
| 0.7 1.2 0.3 | = | c(0,0,tn) c(1,0,tn) c(2,0,tn) |
Using Coefficient Form PDE, I can calculate the average over y as:
| 1.5 3.1 2.4 | = | <c(x,2,tn)>: this row is the mean of c(x,0,tn), c(x,1,tn), c(x,2,tn)
| 1.0 2.4 1.1 | = | <c(x,1,tn)>: this row is the mean of c(x,0,tn), c(x,1,tn)
| 0.7 1.2 0.3 | = | <c(x,0,tn)>: this row is just c(x,0,tn)
Now, I'd like to take the values of <c(x,2,tn)> copied over all rows to subtract c(x,y,tn), i.e.,
| 1.5 3.1 2.4 | - | 2.4 4.5 5.1 |
| 1.5 3.1 2.4 | - | 1.3 3.6 1.8 |
| 1.5 3.1 2.4 | - | 0.7 1.2 0.3 |
I'm thinking a Linear Extrusion would be the method to use. Would this be the best approach?
Thanks Lars,
I had reviewed the section on Extrusion, Projection, & Scalar coupling operators; however, the examples in the Reference Manual were a bit vague. Would you know of a good resource showing a practical example?
As for what I'm working with, I have values of ion concentration over a simulated 2D contour over time, using an Extremely Fine Rectangular Mesh. The contour results in a 41 x 41 value matrix at each instance in time. To simply my scenario, let me illustrate with a 3 x 3 matrix: Let c(x,y,t) at t = tn be
| 2.4 4.5 5.1 | = | c(0,2,tn) c(1,2,tn) c(2,2,tn) |
| 1.3 3.6 1.8 | = | c(0,1,tn) c(1,1,tn) c(2,1,tn) |
| 0.7 1.2 0.3 | = | c(0,0,tn) c(1,0,tn) c(2,0,tn) |
Using Coefficient Form PDE, I can calculate the average over y as:
| 1.5 3.1 2.4 | = | : this row is the mean of c(x,0,tn), c(x,1,tn), c(x,2,tn)
| 1.0 2.4 1.1 | = | : this row is the mean of c(x,0,tn), c(x,1,tn)
| 0.7 1.2 0.3 | = | : this row is just c(x,0,tn)
Now, I'd like to take the values of copied over all rows to subtract c(x,y,tn), i.e.,
| 1.5 3.1 2.4 | - | 2.4 4.5 5.1 |
| 1.5 3.1 2.4 | - | 1.3 3.6 1.8 |
| 1.5 3.1 2.4 | - | 0.7 1.2 0.3 |
I'm thinking a Linear Extrusion would be the method to use. Would this be the best approach?