کمک بسیار فوری !!!!
:سلام من این برنامه رو دارم
BeginPackage["dimanalysis'",{"DiscreteMath`Combinatorica'"}]
dimanalysis::usage = " dimanalysis [ddash,vdash,vdims] generates a complete set of
dimensionless groups relevant to a list of V variables, input with their symbols (vdash)
and dimensions (vdims) and a set of D (ddash) reference dimensions. It checks whether D is
the minimum possible number of dimensions, provides the correct value if not so, completes
the analysis, prints ALL sets of dimensionless groups and the secondary, Dmin dimensions
used."
dimanalysis [ddash_list,vdash_List, vdims_List] :=
(
lenva = Length[vdash];
lenvi = Length[vdims];
lenda = Length[ddash];
If[lenva != lenvi, (Print ["Mismatch in lengths of variable lists"]; Pause[5]; Interrupt[])];
(*the following lines check V and V' input lengths: program stops if error*)
vdimst = Transpose[vdims];
lennul = Length[NullSpace[vdimst]];
rank = lenvi - lennul; (*Rank of vdims must = Dmin*)
(*check that D is minimum, if not provide correct Dmin and continue*)
If[rank != lenda, Print ["Error in number of dimensions, D minimum = ", rank]];
(*the following lines set up a newvdims array, `row reduced', with Dmin rows*)
newvdimst = RowReduce[vdimst];
newvdimst = Take[newvdimst,rank];
newvdims = Transpose[newvdimst];
(*the following lines determine and output the full set of dimensionless groups*)
rnewvdims = Union[newvdims]; (*dimensions of all variables which are distinct*)
qdims = KSubsets[rnewvdims,rank]; (*all possible [Q] combinations of them*)
pos1 = Position[ Map[Det,qdims], 0]; (*locations of [Q] with zero-determinants*)
qdims = Delete[qdims,pos1]; (*all non-zero determinant, DxD sets of [Q]*)
qflat1 = Flatten[qdims,1];
lenq = Length[qflat1];
pos2 = Table[Position[newvdims,qflat1[[i]]],{i,lenq}];
pos2 = Table[pos2[[i,1]],{i,lenq}]; (*positions of [Q] variables in [V]*)
qflat2 = Flatten[pos2]; qflat3 = vdash[[qflat2]];
qdash = Partition[qflat3,rank]; (*Q\[CloseCurlyQuote]= sets of V symbols matching terms in [Q]*)
pos3 = Partition[pos2,rank];
lenqdi = Length[qdims];
nvdims = Table[newvdims,{lenqdi}];
notqdims = MapThread[Delete,{nvdims,pos3},1]; (*sets of [V] not in [Q]*)
nvdash = Table[vdash,{lenqdi}];
notqdash = MapThread[Delete,{nvdash,pos3},1]; (*sets of V\[CloseCurlyQuote] not in Q\[CloseCurlyQuote]*)
matq = Map[Transpose,qdims]; (*sets of A matrices*)
matnotq = Map[Transpose,notqdims]; (*corresponding sets of B matrices*)
dgexp = MapThread[LinearSolve,{matq, -matnotq},1];
(*dgexp is the set of sets of exponents of the symbols in all possible DGs*)
dgs = Apply[Times,(qdash^dgexp),{1}]*notqdash; (*all possible sets of DGs*)
(*the following lines determine the new dimensions in terms of the elements in ddash*)
If[ rank < lenda, (rvdims = Union[vdims];
oldmat = Take[rvdims,-rank];
newmat = Take[rnewvdims,-rank];
mat = LinearSolve[newmat,oldmat];
matt = Transpose[mat];
ddims = Transpose[MapThread[Power,{ddash,matt}]];
dmin = Apply[Times,ddims,{1}];
) ];
(*the following lines provide package output*)
Print["The following is the INPUT DATA"];
Print[ddash];
Print[InputForm[vdash]]; (*echo of vdash, ddash input*)
If[ rank , lenda, Print["Secondary dimensions used = ", dmin] ] ;
Print ["The form of newvdims is "];
Print[]; Print[InputForm[newvdims]];
sets = Length[dgs]; groups = lenva - rank;
Print[]; Print["The ", sets, " sets of ", groups, " Dimensionless Groups are :"];
Print[InputForm[dgs]]; (*printing of all valid DG sets*)
);
EndPackage [ ]
چطوری میشه ازش ران بگیرم؟؟ من Dimanalysis رو که میزنم و توش رو پر می کنم، چه کلیدی رو بزنم که ران شه ؟؟؟ کمک.....