A computational investigation of optimal control problems which are constrained by hyperbolic
systems of conservation laws is presented. The general framework is to employ the adjoint-based optimization
to minimize the cost functional of matching-type between the optimal and the target solution. Extension
of the numerical schemes to second-order accuracy for systems for the forward and backward problem are
applied. In addition a comparative study of two relaxation approaches as solvers for hyperbolic systems is
undertaken. In particular optimal control of the 1-D Riemann problem of Euler equations of gas dynamics
is studied. The initial values are used as control parameters. The numerical ow obtained by optimal initial
conditions matches accurately with observations.