[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Getfem-users] parametric source term
From: |
Alice Nicolas |
Subject: |
[Getfem-users] parametric source term |
Date: |
Mon, 02 May 2011 10:40:56 +0200 |
User-agent: |
Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.2.14) Gecko/20110223 Lightning/1.0b2 Thunderbird/3.1.8 |
Dear all,
I am trying to impose a source term to an elliptic problem, which I
would like to call in the source term brick as a parameter and not with
its numerical value. My problem is 2D, and the constraint is set on a disk.
Using the numerical value of the constraint (f=[0,1]), the program
indeed works fine. mfd is the MeshFem associated to the constraint, md
is the model, mim is the integration method.
#add source term
stress=mfd.eval('[0,1]')
md.add_initialized_fem_data('SurfaceStress', mfd, stress)
md.add_source_term_brick(mim, 'u', 'SurfaceStress',disk)
My attempt to replace the numerical value by a parameter makes the
program fails:
#add source term
f=[0,1]
md.add_fixed_size_data('f',2)
stress=mfd.eval('f')
md.add_initialized_fem_data('SurfaceStress', mfd, stress)
md.add_source_term_brick(mim, 'u', 'SurfaceStress',disk)
Would someone by chance see where I am wrong?
Many thanks in advance,
Alice
- [Getfem-users] parametric source term,
Alice Nicolas <=