Changeset db61bce in git


Ignore:
Timestamp:
Jun 6, 2014, 3:47:10 PM (9 years ago)
Author:
Jakob Kröker <kroeker@…>
Branches:
(u'spielwiese', '8e0ad00ce244dfd0756200662572aef8402f13d5')
Children:
4c0c4a37de4da7bacc5bab644b0efe4197b564e9
Parents:
d7295ff2c24f0d2b03594917a387c981bd47eedd
Message:
handling nonredundant primary decompositions in primDecsAreEquivalent-test
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • Singular/LIB/ehv.lib

    rd7295f rdb61bce  
    13661366//                                                                 //
    13671367/////////////////////////////////////////////////////////////////////
    1368 
     1368proc removeRedundantComponents(list primdecResult)
     1369"USAGE:   removeRedundantComponents(L); L a primary decomposition
     1370RETURN:  an irredundant primary decomposition.
     1371EXAMPLE: example removeRedundantComponents; shows an example"
     1372proc removeRedundantComponents(list primdecResult)
     1373{
     1374   int i,j;
     1375
     1376   i = 1;
     1377   j = 1;
     1378   while  ( i<=size(primdecResult) )
     1379   { 
     1380     ASSUME(1, i>0 &&  i<=size(primdecResult) );
     1381     ASSUME(1, j>0 &&  j<=size(primdecResult) );
     1382
     1383      if (i!=j)
     1384      {
     1385          if ( isSubset( std(primdecResult[j][1]) , std(primdecResult[i][1]) ) )
     1386          {
     1387              primdecResult[i] =  primdecResult[j];
     1388              primdecResult = delete(primdecResult,j);
     1389              j = j - 1; /*correct j due to deletion */
     1390              if ( j<i )  {    i = i -1;   } /*correct i */
     1391          }
     1392      }
     1393      j = j + 1;
     1394      if ( j > size(primdecResult) )
     1395      {
     1396         i = i + 1;
     1397         j = 1;
     1398      }
     1399   }
     1400
     1401   return (primdecResult);
     1402}
     1403example
     1404{
     1405  "EXAMPLE:";
     1406  ring rng = 0,(x,y),dp;
     1407  def L1 = list(list(ideal(x-1),ideal(x-1)),list(ideal(x-1),ideal(x-1)),list(ideal(y-2),ideal(y-2)));
     1408  def L2 = list(list(ideal(x-1),ideal(x-1)),list(ideal(y-2),ideal(y-2)));
     1409  L1;
     1410  L2;
     1411  ASSUME(0, primDecsAreEquivalent( L1, L2 ) );
     1412}
    13691413
    13701414/////////////////////////////////////////////////////////////////////
     
    13741418EXAMPLE: example primDecsAreEquivalent; shows an example"
    13751419{
     1420  L = removeRedundantComponents(L);
     1421  K = removeRedundantComponents(K);
    13761422  int s1 = size(L);
    13771423  int s2 = size(K);
  • Tst/Short/libehv_s.res.gz.uu

    rd7295f rdb61bce  
    11begin 644 libehv_s.res.gz
    2 M'XL("!PS]U(``VQI8F5H=E]S+G)E<P"EDU%KPC`0Q]_]%(?LH842F[3KA&+!
    3 MH0]"-P;=GL:0JG$+U.J:Z&1CWWU7E6NK<R`KE"3-_W_WNRN7/`Y&]P#`(XA'
    4 MM]`VVK!,3=IA*SG<B`CPXUCEREAVV"I7B")`D7S;C#7+Y0?3)C5D\"*@O<_*
    5 ML%8;I;NP=A7WNB8+&*R*Y12,U.:A4(N!G.I^(8?O:[5),YEC9M+>,/BB0Y=!
    6 M^10J?X4"WQZXX&R=V8KR<'<OR90V$','8E'="48,W-_K.IT=!6<P4_.Y+#`Y
    7 M:/4I-0F#O3#FS_P%$Y:!+5`SF6:6:SNT`ZB*Y0?.?I(\W0TMUT',7@]K_JU4
    8 MA(R%77,+MX&&T#I=R!V5`Y.UJ9%.E[G!E9SBP"I.63FQ\@:K\*NFB.!?W-TJ
    9 MDM>LP6,@R7E,[8G+.^SYY!''GBUYMDU/<+X[9SU=\ISD.<?FN\==Y!=TT<=N
    10 F?-.A-EP^EOS'P%0!:I/F8\GE-)<#N];XYT.X"EL_&QXISP4$````
     2M'XL(",C%D5,``VQI8F5H=E]S+G)E<P"E5EUOVD`0?,^O6*$^V,0XOO.W$$AI
     3M$U5(M*H@?6E5(@=?6DM@J.^@AJK_O7M'<CY(24/[@'W&L[NS,^NSQS=7@_<`
     4M0/HP'+R&EN#"G15WK>[9^.$.[0/^>5N4A;#L[ID\0[\/"&+?UK?<+=D/EXM,
     5MZ`"_#WH=N#*MU4*H2FLW>4,#%KFPK!93$(R+$9LOUFS$\E4ILC)_LY@O%R4K
     6M!;=LC8]=^*DO$A</55%^A0I_/?`<JW8VMI,O=3'B24S.[F%($#$KN+#4@8O<
     7M*G*6S:RZ0VS;,=>G`C8=J@%JW31+J*Y/_[7^<^D#G5[U5S42YEDI#`F'Q(B*
     8M9-3E>/SQW;7E.<"++;,P@=WK40.5[*.653&_8E-^6;'K[ZMBG<TPL86Z.K(W
     9M&YI(BJ+KM1*`;[A@<ZM5H:^+><M!XA[Q4AH$L1$6F'Y*N:@O'86-`UO;`<-6
     10MJCI0DL``@6F[;F\FM$,(+K83B@7D:B/7YT&[GM#VUH&.CZ#P'!$=XLF;3;ZD
     11M8>RKD9$>R-Z&F`NET4B?&DBM_DB2D(Y565Y,T:>!89(?&2%*5.65U#-GT[<W
     12MGZS1H$$'JKR:EF,()>DIA@?!4<,C`Q6]S'#E.#$-#UXZ*O!D5D)L]Y>^(,W6
     13M$%)C:_CPQX1Z6PA]8UL(5;/[&P,XM;DKA-$.\F@RDFKN&:,0>3O<Q85B05S(
     14MB_M[5F%QI2'70+H##LEG\N7Q.=_-I^7AZ#ZNP.@\>N#9R.9!KW=$.S6)IFY1
     15MM$<-Z_-LSA0K!^Y6PF`Z790"SSHR>>!*GW(EFBO9XQH;3W1,_X=W'!B9]GM`
     16M$YF./&0=)Z<KG'@ZAA[&U#JFWH^AQ]4Y&A/HF"=UCG*+#E4D)ZB8&$.:JB[U
     17ME;$_I8'Q;*7&:S?%XG]YX^I2:=Q_[A%L<(F1/W75IX/\.EAQG*4NO.J>_08`
     18'#@[Y<@@`````
    1119`
    1220end
  • Tst/Short/libehv_s.stat

    rd7295f rdb61bce  
    1 1 >> tst_memory_0 :: 1391932188:4.0.0, 32 bit:4.0.0:i686-Linux:mamawutz:252836
    2 1 >> tst_memory_1 :: 1391932188:4.0.0, 32 bit:4.0.0:i686-Linux:mamawutz:2240508
    3 1 >> tst_memory_2 :: 1391932188:4.0.0, 32 bit:4.0.0:i686-Linux:mamawutz:2281480
    4 1 >> tst_timer_1 :: 1391932188:4.0.0, 32 bit:4.0.0:i686-Linux:mamawutz:8
     11 >> tst_memory_0 :: 1402062280:4.0.0, 64 bit:4.0.0:x86_64-Linux:andromeda.math.uni-hannover.de:910512
     21 >> tst_memory_1 :: 1402062280:4.0.0, 64 bit:4.0.0:x86_64-Linux:andromeda.math.uni-hannover.de:2650112
     31 >> tst_memory_2 :: 1402062280:4.0.0, 64 bit:4.0.0:x86_64-Linux:andromeda.math.uni-hannover.de:2760704
     41 >> tst_timer_1 :: 1402062280:4.0.0, 64 bit:4.0.0:x86_64-Linux:andromeda.math.uni-hannover.de:21
  • Tst/Short/libehv_s.tst

    rd7295f rdb61bce  
    33
    44LIB("ehv.lib");
     5
     6proc testRemoveReduntandComponents()
     7{
     8  ring rng = 0,(x,y),dp;
     9  def L1 = list(list(std(ideal(x-1)),ideal(x-1)),list(std(ideal(x-1)),ideal(x-1)),list(std(ideal(y-2)),ideal(y-2)));
     10  def L2 = list(list(std(ideal(x-1)),ideal(x-1)),list(std(ideal(y-2)),ideal(y-2)));
     11  def LL1 = removeRedundantComponents(L1);
     12  ASSUME(0, size(LL1)==2);
     13  ASSUME(0, primDecsAreEquivalent( L1, L2 ) );
     14
     15  system("random", 1401092447);
     16  ring rng2 = 23,(x, y, z), dp;
     17  ideal I = 9*x*y^2-11*x*z^2, 11*x*y*z^2+4*x^2*z, -3*y^5+x*z-10*y*z;
     18
     19  list L1,L2, LL1;
     20
     21  def RI = std(radical(I));
     22
     23  L1 = primdecGTZ(RI);
     24  L2 = primdecGTZ(RI);
     25  LL1 = removeRedundantComponents(L1);
     26  ASSUME(0, size(LL1)==6);
     27  ASSUME(0, primDecsAreEquivalent( LL1, L1) );
     28  ASSUME(0, primDecsAreEquivalent( L1 , L2 ) );
     29}
    530
    631proc testPrimDecsAreEquivalent()
     
    2348    L2[2] = list( ideal(0), ideal(0)  );
    2449    ASSUME(0, 1 == primDecsAreEquivalent(L1,L2) );
     50
     51 
     52
    2553}
    2654
     55testRemoveReduntandComponents();
    2756testPrimDecsAreEquivalent();
    2857
Note: See TracChangeset for help on using the changeset viewer.