In most metaheuristic algorithms like Genetic Algorithm, Simulated Annealing, or particle swarm optimization, it is required to generate random variables under some control parameters. For example, we can generate a sample of z value controlled by % load balancing and its boundary limits using this algorithm:

z1 = z got from % Maximum load balancing, i.e., 120%;

z2 = z got from % Minimum load balancing, i.e., 70%;

To compute z1 and z2, a particular function is required to convert % load balancing and drape value into z value. for example

MATLAB CODE:

%

% compute z from given balance load

% use for generating valid chromosome

%

function o = z_from_wbal (w_bal,F,Area,h,zend,ispan)

global L b bw

num_spans = length(L);

drape = w_bal/100*L(ispan)^2*24*Area/8/F;

if ispan == 1 || ispan == num_spans

z = 1/2*(zend+h-0.05)-drape;

else

z = h-0.05-drape;

end

o = z;

end

Then compare z with its boundary values.

% bound of z from wbmin, wbmax, lb_z, ub_z

z_low = max([lb_z, z_from_wbal(wbmax,F,e(i),Area,h,zend,i)]);

z_high = min([ub_z, z_from_wbal(wbmin,F,e(i),Area,h,zend,i)]);

z(i) = max([z_low+(z_high-z_low)*rand,lb_z]);

disp([z_low,z_high,z(i)])

The result of z is guaranteed to lie within the boundary between wb_max and wb_min, but in extreme cases, they are also controlled within the [zmin, zmax] range.

In PT-OP, software for design optimization of PT slab developed for __Posteck Prestressing__, we employ the above method to control the depth of tendon z, so that the % balance load stays within the control parameters.

Figure Percentage of Balance Load control [70%, 120%] in PT-OP