Interplane page as plain text, for reading tools and agents. English is the reference text: translate it with your own tool. Text in backticks and in ``` blocks (commands, fingerprints, file names) and link targets in <...> are exact: copy them, never translate them. Page: /drakestapleton/hive-not-swarm/blob/master/sources/verify_main_model.wl # hive-not-swarm aien-dev/hive-not-swarm Brought by drakestapleton Sign in to star 0 stars 0 watching About Files History Releases Proposed changes Issues For developers branch `master` Branches Tags History `hive-not-swarm / sources / verify_main_model.wl` 7 lines ยท 672 bytes Raw Blame History 1 ClearAll[n,s,a,b,c,r0,r]; 2 t=s+a/n+b (n-1)+c n (n-1)/2+r0+r n; 3 rules={s->10,a->120,b->4/5,c->3/20,r0->3,r->1/2}; 4 symbolic={D[t,n],D[t,{n,2}],Expand[n^2 D[t,n]],FullSimplify[(t/.n->n+1)-t],FullSimplify[D[t,{n,2}]>0,Assumptions->{a>0,c>=0,n>0}]}; 5 rows=Table[{n,t/.rules,3+n/2,1-(99/100)^n},{n,1,16}]; 6 feasible=Select[rows,#[[3]]<=6&&#[[4]]<=2/25&]; 7 <|"symbolic"->symbolic,"continuous_stationary_n"->(n/.FindRoot[(D[t,n]/.rules)==0,{n,7}]),"feasible_rows"->feasible,"feasible_optimum"->First[MinimalBy[feasible,#[[2]]&]],"unconstrained_integer_optimum"->First[MinimalBy[rows,#[[2]]&]],"risk_at_six"->N[1-(99/100)^6,16],"speed_ratio"->N[(t/.rules/.n->1)/(t/.rules/.n->6),16]|>