I want to change the constraint handler for eigenvalue analysis in my code. For this I opened file OpenSees\SRC\tcl\commands.cpp and replaced the line (line no. 4563):
or, declare two doubles in the code:
double alphasp = 1.0;
double alphamp = 1.0;
then use this in your declaration in your original post: PenaltyConstraintHandler(alphasp, alphamp);
The constructor shows that it wants two double arguments, passed by value and not by address so you shouldn't use any pointer dereferencing unless you defined pointers which point to alphasp and alphamp.
Try both of those and see if they work. I'm rusty on my C++ so the casting may not be correct. You should google it if what I said doesn't work and you still want to go that route.
ConstraintHandler *theEigenHandler = new LagrangeConstraintHandler(double(1.0), double(1.0));
Above codes can be used to successfully compile and build the opensees.exe, but when used it does not give any of the eigenvalue (not even first). I think it is because with eigenvalue analysis Lagrange or Penalty constraint handlers are not allowed. (The code works with Transformation constraint handler)