zone.head
z = zone.head
取得第一个模型内的单元的指针。
Get the first zone in the list of all zones in the model. This function should be considered deprecated; it is provided mostly for backward compatibility with old data files. Instead, see the fish_statement_loopforeach statement and the zone.list and zone.next functions.
| Returns: | z - a pointer to the first zone in the list of all zones in the model |
|---|
zone.next
znext = zone.next(z)
返回列表上下一个单元的指针。
Get the next zone after z in the list of all zones in the model. Will return null if no more zones follow. This function should be considered deprecated; it is provided mostly for backward compatibility with old data files. Instead, see the fish_statement_loopforeach statement and the zone.list and zone.head functions.
| Returns: | znext - the next zone in the list, or null |
|---|---|
| Arguments: | z - a pointer to a zone |
zone.state
zone.state(z) = i
Get/set the current plasticity state indicators for the zone.
Tetrahedral subzones comprise a zone in FLAC3D, and each of them has a member variable that maintains its failure state. The member variable has 64 bits that can be used to represent 64 different states. Each constitutive model defines its own list of states, and its own assignment of state names to bits in the state variable. For convenience, however, a convention has been adopted for the most common states. The following table lists failure states and the convention adopted by many of the constitutive models.

The states supported by a constitutive model can be listed with the zone cmodel list state command.
The math.and and math.or intrinsics may be used to check against a specific bit or bit pattern.
Returns: i - the plasticity state indicators, encoded as bits
Accepts: i - the plasticity state indicator, encoded as bits. All tetra in the zone will be assigned this state indicator.
Arguments: z - a zone pointer
bavg - if true, the bit will be set if 50% or more of the volume averaged tetra have that bit set. If false, the bit will be set if any tetra in the zone have that bit set. This value is ignored on assignment.
io.out
v = io.out(a)
输出字符串,变量转化为字符串。
Output a string. The variable is converted to a string if it is not a string, and it is output both to the console and to the log file, if one is open.
Returns: v - void return Arguments: a - text to output
查询变量值
print fish
显示所有的函数和变量
list @变量名
print @变量名
[变量名]
以上三种方式都可以显示查询变量的数值。
math.and
i1=math.and(1,2)
i2=math.and(9,9)
i3=math.and(1,1)
i1=0,i2=9,i3=1,也就是说,当两者相同时,返回该值,当两者不同时,返回0。
Fish代码关键命令学习
1103

被折叠的 条评论
为什么被折叠?



