FEAP User Forum
FEAP => Input File Issues => Topic started by: R2197 on February 03, 2024, 03:22:28 AM
-
Hi, I am trying to input a variable which is parametrized according to the height of the domain. How can I achieve this through the input file. It seems quite possible but I am not sure which variable to use. My geometry description is this.
parameter
nx = 5
ny = 5
nz = 5
lx = 0.5
ly = 0.5
lz = 0.5
block 1
cartean nx ny nz 0 0 1 0 10
1 0.0 0.0 0.0
2 lx 0.0 0.0
3 lx ly 0.0
4 0.0 ly 0.0
5 0.0 0.0 lz
6 lx 0.0 lz
7 lx ly lz
8 0.0 ly lz
parameter
P = Contant* height
how can I achieve this?
Thanks
-
I assume you want to vary 'lz' as the height of the problem. You can run several different values for this using two input files: (1) the file for analysis (which I name Iprob below - replace by the name you have). In this file set the parameter as "lz = 0.5*p" (but do not define "p").
In the second file (I name Irun) you set "p" and run the problem using
param
p = 1
include Iprob
If "p" can be a multiple this file can use a loop form after
loop
param
p = p*2
include Iprob
next
If you want to increment p then in the Iprob file you could set lz = 0.5 + p and then increment in the second file.
To execute you use
feap -iIrun
or give the file "Irun" the way you currently execute feap.
-
If on the other had you want P to be equal to a multiple of lz, then you can simple write something like
PARAmeter
P = 5*lz
-
Hello Profs.
Thanks for the replies.
I think I didnt explain what I want exactly. I want a parameter that changes with the vertical position and not the overall height. An example would be.
Lz=0.5
P=0 at z=0
P=0.1 at z=0.1
P=0.2 at z=0.2
P=0.3 at z=0.3
P=0.4 at z=0.4
P=0.5 at z=0.5
and so on. But as I understand the suggestions that were given were based on the overall height Lz. I apologise for the miscommunication.
Thanks
-
param
p = 0
dz = 0.1
loop,,6
include Isolve -- problem to solve or solution you want to do
param
p = p + dz
next
Otherwise explain what you want to do with the parameter "p"
-
Hello Prof. Taylor
I am trying to simulate algal photosynthesis on the ocean surface. The phenomena is dependent on light, which in turn looses its intensity as we go below the surface. Now to create such a simulation, I need a domain with height Lz, in which the parameter for light intensity, P is a function of vertical position. So, at the top surface P is highest and at the bottom, it is lowest.
I want to achieve something like this.
-
How do you wish to use the parameter p in your simulation?
Without that information is it hard to make a good suggestion.
-
Hello Prof.
I am attaching a picture of the equation that I want to solve. The function E_Par(Z) is dependent on the vertical position in the domain. The differential equation for S_c is solved in my simulation.
-
Does this appear in the constitutive equation or element loading? If so you can compute the location from element nodal values and shape functions. Or tell us where you need to compute it.
-
The S_c has its own degree of freedom. It is not a constitutive equation and I am not entirely sure what you mean by element loading.
Yes, element nodal values would be reasonable and that's also what I thought but I am not sure how to access that. And if I can, would it be in the input file, the material or the element file.
-
If. you want to know the value of a parameter in your routine you can use
call getparam( par, p_value, error, prt
par = name of parameter, eg, 'p' (in quotes)
p_value = real*8 value returned (always real, can cast as integer)
error = logical -- true if error in getting, otherwise false
par = logical, print value found if .true.