I found this level shifting circuit online. When I simulated this on Multisim, it works fine, but how do I find the relationship between the output and the input. Here is the circuit.
MultiSim uses input and output nodes to display signals.
However I recognize this circuit is simply a poor R divide by 2 that will dissipate too much power ( 100k ~1M is better) will clip the 700Vpp grid voltage via Schottky diodes with a unity gain Op Amp that (98% of) 10Vpp output.
A better way would Ac couple with 1M to 10k then use a comparator with 1% positive gain feedback for hysteresis using Vin- =0V and signal input via series 10K with 1M feedback on Vin+
simulate this circuit You can string series 500V thru-hole parts for safety to achieve 3kV BDV rating. C shunt across 10K filters out transients that may cause false triggers.
R2 and R3 make a Thevenin equivalent voltage and resistor. Apply this to your 10k input resistor and you should find the relationship between V1 and the output, since the op amp is configured as a voltage follower, and the output will be very close to the input.
That said, the circuit as shown will almost never produce anything other than a 50 Hz more-or-less square wave at 0 and 5 volts. The rise and fall times will not be terribly fast, since the linear portion of the output is the +/- 15 volt portion of the 120 volt line voltage swing (the input 240 VAC is cut in half by the 1M resistors, assuming no connection to ground at the AC).