Awning Problem 4

a = 1;
b = 1;
lambda = 2/Sqrt[3];
mu = 1/Sqrt[3];

bdyval[x_,y_]=(1-y) (a^2/4-x^2) + y (a^2/16-x^2/4);

wminus[sigma_]=bdyval[-a/2,-lambda (-a/2)/mu+  sigma/mu];
wzero[tau_]=bdyval[tau,0];
wplus[sigma_]=bdyval[a/2, -lambda (a/2)/mu + sigma/mu ];
wone[tau_]=bdyval[tau,b];

uminus[s_]=bdyval[-a/2,s];
uzero[t_]=bdyval[t,0];
uplus[s_]=bdyval[a/2,s];
uone[t_]=bdyval[t,b];

vminus[y_]=D[bdyval[x,y],x]/.x->-a/2;
vzero[x_]= D[bdyval[x,y],y]/.y->0;
vplus[y_]= D[bdyval[x,y],x]/.x->a/2;
vone[x_]=D[bdyval[x,y],y]/.y->b;

phiminus[sigma_]=vminus[(lambda a/2+sigma)/mu]-(lambda/mu) uminus'[(lambda a/2+sigma)/mu];
phizero[tau_]=(1/mu) vzero[tau];
phiplus[sigma_]=vplus[(-lambda a/2+sigma)/mu]-(lambda/mu) uplus'[(-lambda a/2+sigma)/mu];
phione[tau_]=(1/mu) vone[tau];

integralzerobottom[xi_,eta_]=-(mu/2) Integrate[vminus[s],{s,0,((lambda-1) a/2-(xi-eta))/mu}];
integralzeroleft[xi_,eta_]=-(lambda^2-1) Integrate[vzero[t],{t,-a/2,(xi+eta)/(lambda+1)}]/(2 mu);
fullintegralzeroleft=-(lambda^2-1) Integrate[vzero[t],{t,-a/2,a/2}]/(2 mu);

wz[xi_,eta_]=(lambda+1) uminus[((lambda-1) a/2-(xi-eta))/mu]/2+integralzeroleft[xi,eta]-(lambda/2) (uminus[0]+uzero[-a/2])+(lambda-1) uzero[(xi+eta)/(lambda+1)]/(2 mu)+integralzerobottom[xi,eta]

wregionzeroplot=Plot3D[wz[xi,eta],{xi,-a/2,a/2},{eta,-lambda a/2,lambda a/2+mu b},ViewPoint->{1.3, 0.9, 1.},RegionFunction->Function[{x,y,z},lambda x<y<Min[x-(lambda-1) a/2+mu b,(lambda+1) a/2-x]] ]

uz[x_,y_]=wz[x,lambda x+mu y];

Plot3D[uz[x,y],{x,-a/2,a/2},{y,0,b},ViewPoint->{1.3, 0.9, 1.},RegionFunction->Function[{x,y,z},lambda y<Min[(-lambda x+x-(lambda-1) a/2+mu b)/mu,(-lambda x+(lambda+1) a/2-x)/mu]] ]

Plot3D[{uz[x,y],bdyval[x,y]},{x,-a/2,a/2},{y,0,b},ViewPoint->{1.3, 0.9, 1.},RegionFunction->Function[{x,y,z},lambda y<Min[(-lambda x+x-(lambda-1) a/2+mu b)/mu,(-lambda x+(lambda+1) a/2-x)/mu]] ]

integralplusright[xi_,eta_]=(mu/2) Integrate[vplus[s],{s,0,(xi+eta-(lambda+1) a/2)/mu}];

wo[xi_,eta_]=(lambda+1) uminus[((lambda-1) a/2-(xi-eta))/mu]/2+fullintegralzeroleft-(lambda/2) (uminus[0]+uzero[-a/2])+(lambda/2) (uzero[a/2]+uplus[0])-(lambda-1) uplus[(xi+eta-(lambda+1) a/2)/mu]/(2)+integralzerobottom[xi,eta]+integralplusright[xi,eta]

wregion1plot=Plot3D[wo[xi,eta],{xi,-a/2,a/2},{eta,-lambda a/2,lambda a/2+mu b},ViewPoint->{1.3, 0.9, 1.},RegionFunction->Function[{x,y,z},Max[lambda x, x-(lambda-1) a/2+mu b]< y <Min[(lambda+1) a/2-x,lambda x + mu b]],BoxRatios->Automatic ]

Show[wregionzeroplot,wregion1plot,PlotRange->All]