A method, comprising: in a semiconductor wafer comprising a first semiconductor layer and a second semiconductor layer adjoining the first semiconductor layer, forming a porous region extending from a first surface into the first semiconductor layer; and removing the porous region by an etching process, wherein a doping concentration of the second semiconductor layer is less than 10 -2 times a doping concentration of the first semiconductor layer and/or a doping type of the second semiconductor layer is complementary to a doping type of the first semiconductor layer, wherein forming the porous region comprises: bringing in contact a porosifying agent with the first layer; and applying a voltage between the first layer and a first electrode that is in contact with the porosifying agent, wherein bringing in contact the porosifying agent with the first layer comprises: attaching a tubular element to the first surface; partially filling a reservoir formed by the tubular element and the first surface with the porosifying agent, and wherein the reservoir further comprises at least one insulating element arranged above an edge region of the first semiconductor layer and configured to reduce an active height of the porosifying agent above the edge region as compared to the center of the first semiconductor layer, whereby a current density, associated with the applied voltage, is reduced in the edge region. in a semiconductor wafer comprising a first semiconductor layer and a second semiconductor layer adjoining the first semiconductor layer, forming a porous region extending from a first surface into the first semiconductor layer; and removing the porous region by an etching process, wherein a doping concentration of the second semiconductor layer is less than 10 -2 times a doping concentration of the first semiconductor layer and/or a doping type of the second semiconductor layer is complementary to a doping type of the first semiconductor layer, wherein forming the porous region comprises: bringing in contact a porosifying agent with the first layer; and applying a voltage between the first layer and a first electrode that is in contact with the porosifying agent, wherein bringing in contact the porosifying agent with the first layer comprises: attaching a tubular element to the first surface; partially filling a reservoir formed by the tubular element and the first surface with the porosifying agent, and wherein the reservoir further comprises at least one insulating element arranged above an edge region of the first semiconductor layer and configured to reduce an active height of the porosifying agent above the edge region as compared to the center of the first semiconductor layer, whereby a current density, associated with the applied voltage, is reduced in the edge region. bringing in contact a porosifying agent with the first layer; and applying a voltage between the first layer and a first electrode that is in contact with the porosifying agent, wherein bringing in contact the porosifying agent with the first layer comprises: attaching a tubular element to the first surface; partially filling a reservoir formed by the tubular element and the first surface with the porosifying agent, and wherein the reservoir further comprises at least one insulating element arranged above an edge region of the first semiconductor layer and configured to reduce an active height of the porosifying agent above the edge region as compared to the center of the first semiconductor layer, whereby a current density, associated with the applied voltage, is reduced in the edge region. attaching a tubular element to the first surface; partially filling a reservoir formed by the tubular element and the first surface with the porosifying agent, and wherein the reservoir further comprises at least one insulating element arranged above an edge region of the first semiconductor layer and configured to reduce an active height of the porosifying agent above the edge region as compared to the center of the first semiconductor layer, whereby a current density, associated with the applied voltage, is reduced in the edge region.