Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.
One option of generation of variable 0-40Vac is to use a variable 0-250V auto-transformer and feed its output to 230V-40V step-down transformer .. see picture below ..
More details on this variable AC power supply can be found at: https://www.tequipment.net/pdf/elenco/xp-800.pdf