Solution of poisson's equation in cylindrical coordinates

Solution of poisson's equation in cylindrical coordinates

C-76 C O M P U T E R PHYSICS COMMUNICATIONS 2 (1971) 157-167. N O R T H - H O L L A N D PUBLISHING COMPANY SOLUTION OF POISSON'S EQUATION IN CYLIND...

55KB Sizes 1 Downloads 73 Views

C-76 C O M P U T E R PHYSICS COMMUNICATIONS 2 (1971) 157-167. N O R T H - H O L L A N D PUBLISHING COMPANY

SOLUTION

OF

POISSON'S EQUATION IN CYLINDRICAL COORDINATES M. H. HUGHES UKAEA, Culham Laboralory, Abingdon, B e r k s h i r e , UK R e c e i v e d 4 D e c e m b e r 1970

PROGRAM

SUMMARY

Title of program (32 c h a r a c t e r s m a x i m u m ) : DELSQRZ Catalogue number: ABUC Computer f o r which tire program is designed and others upon u'hich it is operable Computer: ICL KDF9. Installation: UKAEA, Culh,~m L a b o r a t o r y Operating s y s t e m or monitor under u,hich tire program is execuled: Egdon 3 P r o g r a m m i n g languages used: ASA F O R T R A N High speed store required: 5K w o r d s . No. of bits in a word:48 Is the program overlaid? No No. of magnetic tapes required: None What other peripherals are used? L i n e P r i n t e r (for t e s t only) No. of cards in combined program and test deck: 1131 CPC L i b r a r y subprograms used Catalogue number: ABUA; Title: FOUR67; Ref. in CPC: 2 (1971) 127. Keywords descriptive o f problem and method of solution: P l a s m a P h y s i c s , M.H.D., F l u i d D y n a m i c s . P o i s s o n , Cylindrical, Fast Fourier Tranform.

Nature of the physical problem T h e D E L S Q R Z p a c k a g e o b t a i n s a r a p i d s o l u t i o n of P o i s s o n ' s e q u a t i o n in the (% z} p l a n e s u b j e c t to the f o l lowing b o u n d a r y c o n d i t i o n s : 1. T h e p o t e n t i a l s on the a x i s and at s o m e r a d i u s r = r o a r e always g i v e n , 2. E i t h e r (i) the potential is g i v e n on the z - b o u n d a r i e s , o r (ii) p e r i o d i c z - g e o m e t r y .

Method of solution P o i s s o n ' s equation is r e p l a c e d by a 5 - p o i n t finite d i f f e r e n c e a p p r o x i m a t i o n and the r e s u l t i n g e q u a t i o n s a r e s o l v e d by a m e t h o d b a s e d on F o u r i e r a n a l y s i s [1-3]. T h e FOUR67 p a c k a g e is u s e d for t h i s [4].

R e s t r i c t i o n s on the complexity o f the problem T h e (% z) p l a n e is divided into a u n i f o r m r e c t a n g u l a r m e s h of d i m e n s i o n s NR and NZ (not n e c e s s a r i l y equal). To s i m p l i f y the F o u r i e r a n a l y s i s NZ is r e s t r i c t e d to be a p o w e r of two.

Typical running time On the C u l h a m KDF9 loading and c o m p i l a t i o n t a k e s T h e r u n n i n g t i m e d e p e n d s on the m e s h s i z e

250 see.

and on the z - b o u n d a r y c o n d i t i o n s . T y p i c a l l y . on a 64 64 m e s h the t i m e s a r e 20 s e c when the potenti,~l is given on the z - b o u n d a r i e s , and 15 s e c when the z - g e o m e t r y is p e r i o d i c .

Unusual f e a t u r e s of the program T h e p r o g r a m is w r i t t e n in ASA F O R T R A N a p a r t f r o m the u s e of s y m b o l i c d i m e n s i o n s , which on c e r t a i n c o m p u t e r s y s t e m s m u s t be r e p l a c e d by a c t u a l n u m e r i cal v a l u e s . T h e P R E L U D E s e c t i o n s h o u l d then be r e moved.

References [1] R. W. Hoekney, J. A s s o c . C o m p u t i n g M a c h i n e r y 12 (1965) 95. [2] R. W. Hockney, A . P . S . T o p i c a l Conf. on N u m e r i c a l S i m u l a t i o n of P l a s m a s , L o s A l a m o s (1968). [3] R. W. Hoekney, in: M e t h o d s of c o m p u t a t i o n a l p h y s i c s . Vot. 9, e d s . B. A i d e r and S. F e r n b a e h ( A c a d e m i c P r e s s , New York, 19 70) p. 135. [4] J . P. C h r i s t i a n s e n and R. W. Hockney, C o m p u t e r P h y s . C o m m u n . 2 (1971) 127.