Maybe it's really simple but I compute the first 10 eigval with
set lambda [eigen 10]
now I can write lambda with
puts $lambda
but how can I assign each eigval to a different variable?
I can't use lambda(i) because lambda is not an array.
endryus
How to manage eigenvalues
Moderators: silvia, selimgunay, Moderators
-
- Posts: 68
- Joined: Fri Jul 02, 2004 6:10 am
- Location: Computers and Structures, Inc.
eigen command returns a Tcl list, not an array. The following code should print all of the eigenvalues to screen...
Code: Select all
for {set i 0} {$i < 10} {incr i} {
puts [lindex $lambda $i]
}
Berk Taftali
Georgia Institute of Technology
Ph.D. Candidate, Structural Engineering, Mechanics, and Materials
School of Civil and Environmental Engineering
Atlanta, GA 30332 USA
Email: gte994y@mail.gatech.edu
Georgia Institute of Technology
Ph.D. Candidate, Structural Engineering, Mechanics, and Materials
School of Civil and Environmental Engineering
Atlanta, GA 30332 USA
Email: gte994y@mail.gatech.edu