brian abraham

599 Reputation

10 Badges

13 years, 283 days

MaplePrimes Activity

These are questions asked by brian abraham

How do I find a point in every region defined by a system of linear equations? I have a system of eight linear equations of the form Ai.x+Bi.y=0 (i=1..8) Ai and Bi are numerical values. If I plot all eight equations on one graph then I get numerous bounded regions defined by three or more of the equations and numerous unbounded regions defined by two or more of the equations. (It is possible – though unlikely - for two of the solutions to be parallel or collinear. ) My aim is to find one point – any point does - within every bounded region and one in every unbounded region. It is easy to do this by inspection.
A,B,C,D,E,F are known numerical values I want to find x and y such that Signum (-x+A).B +(y+C).D = -1 AND x.E-y.F=G AND |G| minimised I think I can see how to write a routine to do this. However, do any of the commands do this? All help much appreciated.
I have an expression of the form A*arctan(B) where A and B are any expressions. How do I assign the B to a variable. I can do this with nops and op but it seem so clumsy. There must be an elegant way to do this.
The code below is just to illustrate the issue. Is there any way to keep the chosen scaling and view when the plots are placed within an array? As the code below will show the scaling and view for a plot in an array has a mind of its own! I tried plotting a and b with both plots in them but with one in white - so it looked as if there was only one plot - but that did not work. restart; > with (plots): a:=plot(x^2/10,x=1..50,scaling=constrained,view=[0..120,0..800]): > b:=plot(-x^2+50*x,x=1..60,color=green,scaling=constrained,view=[0..120,0..800]): > display(a,b); > > g:=array(1..2):
I am writing a large number of variables to file to load into excel - it all works fine - with the code below. But there just has to be a neater way to do it. Can anyone help?
> for t from 1 to nops(files) by 1 do
> fprintf(fd
> ,"%a\t %a\t %a\t %a\t %a\t %a\t %a\t %a\t %a\t %a\t %a\t %a\t %a\t %a\t %a\t %a\t %a\t %a\t %a\t %a\t %a\t %a\t %a\t %a\t %a\t %a\t %a\t %a\t %a\t %a\t %a\t %a\t %a\t %a\t %a\t %a\t %a\t %a\t %a\t %a\t %a\t %a\t %a\t %a\t %a\t %a\t %a\t %a\t %a\t %a\t %a\t %a\t %a\t %a\t \n"
2 3 4 5 6 7 8 Page 4 of 8