* fichier : c2d93.dgibi ************************************************************************ ************************************************************************ *********************************************************************** * * 2D AXISYMMETRIC MAGNETIC FIELD COMPUTATION * * Formulation : VECTOR POTENTIAL * * NON LINEAR MATERIAL * *********************************************************************** GRAPH ='N' ; * ------------------------Mesh -------------------------------------- R1 =20. ; R2= 25. ; R3= 27. ; R4= 29. ; R5=39.;R6 = 130.; Z1= 2.5; Z2= 5. ; Z3= 20. ; Z4= 130.;Z31=30.;Z32=50.; DI1= 1.; DI2=5.;DI3=60. ;DI4= 10.;NET2= 6; DENS DI1 ; OZ3= 0. Z3; OZ2= 0. Z2;OZ1= 0. Z1;OZ4=0. Z4; OO= 0. 0.;R0Z0= DI1 0 ; R1Z0= R1 0. ;R2Z0= R2 0. ;R3Z0 = R3 0. ;R4Z0 = R4 0.; R0Z2= DI1 Z2 ; R4Z2 = R4 Z2 ; DENS DI2 ; R5Z0= R5 0. ;R5Z3= R5 Z3 ;R0Z3 =DI2 Z3 ;OZ3 = 0. Z3 ; DENS DI3 ; R6Z0=R6 0.; R6Z4=R6 Z4 ; R2Z3= R2 Z3 ; R1Z3= R1 Z3; R4Z1 = R4 Z1; R3Z1= R3 Z1 ; DENSITE DI4 ; R0Z4 = DI4 Z4 ; OZ4 = 0. Z4 ; NTRA= 1; *------------------------- COIL SURFACE ------------------------- COUL BLEU ; *----------------------------------------------------------------- *---------------------IRON ------------------------------------------ FER = (D OZ2 R0Z2 D R4Z2 D 6 R4Z0 D R5Z0 D R5Z3 D R0Z3 D OZ3 D OZ2 ) *---------------------EXTERNAL AIR BOX ------------------------------ * COUL VERT ; * *--------------- BOUNDARIES ----------------------------------------- * ENPP = CONTOUR TOUT ; CEXTR=ENPP POINTS DROITE (130. 0.) (130. 100.) .1 ; CEXTH=ENPP POINTS DROITE ( 0. 130.) (10. 130.) .1 ; AXE=ENPP POINTS DROITE ( 0. 0. ) ( 0. 100. ) .1 ; AX1 = (AIRIN ET FER) POINT DROITE ( 0. 0. ) ( 0. 100. ) .1 ; * *---------------------------------------------------------------------- * FORMER DESCRIPTION IN MILLIMETRES *--------------- SHIFT FOR METERS ------------------------------------ * * SI (NEG GRAPH N ) ; TITRE ' MESH 2D ' ; TRAC tout ; FINSI ; *---------------------------------------------------------------------- MU0= 4. * PI * 1.E-7 ; * *------------------CURENT DESCRIPTION --------------------------------- TABCOUR= TABLE ; TABB = TABLE ; *----------------- AXISYMMETRIC PROBLEM ------------------------------ TABB.'AXI'= VRAI ; *------------------MATERIALS ----------------------------------------- TABMAT = TABLE ; STN = TABLE ; STN.EV1 = KEVOL ; TABMAT.OBFER1 = STN ; STN = TABLE ; STN.EV1 = KEVOL ; TABMAT.OBFER2 = STN ; TABB.'TABNUSEC' = TABMAT ; TABB.'MUAIR' =MU0 ; *------- LINEAR MATERIAL CAN BE TRAITED AS A SUPER ELEMENT OR NOT * isuper= 1 ; 'SI' ('EGA' isuper 1 ) ; TABB.'AIRSUP' = AIREXT ; TABB.'ENCS' = CEXTR ET CEXTH ET AX2 ; TABB.'BLOQUE' = BLOQUER 'T' AX1 ; TABB.'AIR' = AIRIN ; 'SINON' ; TABB.'AIR' = (AIRIN ET AIREXT) ; TABB.'BLOQUE' = BLOQUER 'T' (CEXTR ET CEXTH ET AXE ) ; 'FINSI' ; * * ------POTENTIAL COMPUTATION OR FIRST STEP IF NON LINEAR PROBLEM --- *------ POT_VECT TABB 'SOLIN' ; *----- *------------------------------------------------------------------ SOL1 = (TABB.'POTENTIEL' ) ENLEVER LX ; RAY2 = D 10 (0. .0001) ( .020 .0001) ; * -------------SOME POST TRAITMENT B COMPUTATION ---------------- PREF = AIRIN POINT PROCHE ( 0. 0. ) ; TITRE ' COMPOSANTE BY AVANT ET APRES LISSAGE ' ; *---------- polynomial smothing if wanted -------------------- BAT1 = 800.e6 * 5.e-3 * 5.e-3 * MU0 /10.e-3 ; option echo 0 ; MESS ' NUMERICAL DERIVATION BY AU CENTRE ' BY0 ; MESS ' SMOTHED SOLUTION BY AU CENTRE ' BY01 ; ******************************************************************* RAP = ABS ((BY01 - bat1 ) / bat1 ); SI ( RAP > .01 ) ; ERREUR 5 ; FINSI ; ******************************************************************* SI (NEG GRAPH N ) ; TITRE ' POTENTIAL BEFORE AND AFTER SMOTHING ' ; TITRE ' BY COMPONENT BEFORE AND AFTER SMOTHING ' ; FINSI ; * **----------------- NON LINEAR COMPUTATION ------------------- * filling TABB.SOUSTYPE='THERMIQUE' ; TABB.CRITERE =1.E-4 ; TABB.NITER =1; TABB.'OME' = .1 ; *----------- test shortened to 2 iterations ---------------------- TABB.ITERMAX=2; TABB.NIVEAU =1; * *------------------------------- MAG_NLIN TABB ; *------------------------------- * SOL2 = enlever (TABB.'POTENTIEL' ) LX ; BAT = 2.4106 ; MESS ' EXPECTED SOLUTIONS AT CENTER BY ' BAT ; MESS ' NUMERICAL DERIVATION BY ' BY02 ; MESS ' SMOTHED SOLUTION BY ' BY03 ; itest = 1 ; *--------------------GOOD WORKING MESSAGE ----------------------- SI (EGA ITEST 1 ) ; *------- test shortened --------------------------------------- RAP = ABS ((BY03 - BAT ) / BAT); SI ( RAP > .01 ) ; ERREUR 5 ; FINSI ; *---------------------------------------------------------------- SINON ; *------ COMPUTATION TILL CONVERGENCE OR UP TO 100 MORE ITERATION TABB.ITERMAX=100; MAG_NLIN TABB ; *---------------------------------------------------------------- SOL2 = enlever (TABB.'POTENTIEL' ) LX ; BAT = 2.3468 ; MESS ' EXPECTED SOLUTION ON AXIS BY ' BAT ; MESS ' NUMERICAL DERIVATION BY AU CENTRE ' BY02 ; MESS ' SMOTHED SOLUTION BY AU CENTRE ' BY03 ; * ******************************************************************* RAP = ABS ((BY03 - BAT ) / BAT ); SI ( RAP > .01 ) ; ERREUR 5 ; FINSI ; ******************************************************************* SI (NEG GRAPH N ) ; TITRE ' POTENTIAL BEFORE AND AFTER SMOTHING ' ; TITRE ' BY COMPONENT BEFORE AND AFTER SMOTHING ' ; FINSI ; FINSI ; FIN ; ;
© Cast3M 2003 - Tous droits réservés.
Mentions légales