1-d version of sdp code now working