Skip to content

Extract the Real and Imag part of the displacement from Harmonic analysis without using get() command #3504

Answered by mikerife
Victor-Kao asked this question in Q&A
Discussion options

You must be logged in to vote

Hi @Victor-Kao & @germa89
A faster way would be to VGET the real and imaginary part of the NSOL variable to their own arrays. Then use them as you see fit. So something like:

## POST #######################################################
mapdl.post26()
acc_z_1F = mapdl.nsol("2","2","U","Z")

freq_values = np.unique(mapdl.post_processing.frequency_values)

# put the real and imaginary parts of acc_z_1F into unique mapdl array parameters
mapdl.vget(acc_z_1F_R, 2, '', 0)
mapdl.vget(acc_z_1F_IM, 2, '', 1)

Then when you want to work with them, just use mapdl.parameter["acc_z_1F_R"] for the real part and similar for the imaginary.
Mike

Replies: 1 comment 3 replies

Comment options

You must be logged in to vote
3 replies
@mikerife
Comment options

Answer selected by Victor-Kao
@Victor-Kao
Comment options

@germa89
Comment options

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
3 participants