An electricity generator comprising: - a converter capable of converting a variation of a magnetic field into a potential difference between two electrical terminals, this converter comprising for this purpose: * an electromechanical transducer capable of directly transforming a mechanical deformation exerted on this electromechanical transducer into a potential difference between the two electrical terminals, and * a magnetostrictive layer extending mainly parallel to a reference plane and fixed with no degree of freedom to the electromechanical transducer, this magnetostrictive layer comprising at least one block made of magnetostrictive material capable of converting a variation of the magnetic field into a mechanical deformation exerted on the electromechanical transducer, - a magnetic field source comprising a group (90-93, 96-99; 130; 140; 160; 196-199, 202-205; 240) of several permanent magnets aligned along an axis of alignment, at least one of the group and of the converter being movable, alternately, between: * a first position wherein the field lines of the group of permanent magnets pass through the same block made of magnetostrictive material and cause a first deformation of this block made of magnetostrictive material, and * a second position wherein the block made of magnetostrictive material has a second deformation, different from the first deformation, characterised in that the group (90-93, 96-99; 130; 140; 160; 196-199, 202-205; 240) of permanent magnets comprises a succession of first permanent magnets (112-115; 142-145) along the axis of alignment, a first permanent magnet being a permanent magnet of the group which has the two following characteristics: - an aspect ratio, defined by the ratio of the thickness thereof over the length thereof in the direction of the magnetic moment thereof, of between 1/10 and ten, and - the main part of the field lines which are looped by way of the block made of magnetostrictive material and of this first permanent magnet in the first position do not pass through another first permanent magnet, these first permanent magnets being arranged against one another such that the magnetic field induces inside the block made of magnetostrictive material in the first position by any one of these first permanent magnets is parallel and in the opposite direction to the magnetic field induced at the same time in this same block by the first permanent magnet immediately consecutive along the axis of alignment. - a converter capable of converting a variation of a magnetic field into a potential difference between two electrical terminals, this converter comprising for this purpose: * an electromechanical transducer capable of directly transforming a mechanical deformation exerted on this electromechanical transducer into a potential difference between the two electrical terminals, and * a magnetostrictive layer extending mainly parallel to a reference plane and fixed with no degree of freedom to the electromechanical transducer, this magnetostrictive layer comprising at least one block made of magnetostrictive material capable of converting a variation of the magnetic field into a mechanical deformation exerted on the electromechanical transducer, * an electromechanical transducer capable of directly transforming a mechanical deformation exerted on this electromechanical transducer into a potential difference between the two electrical terminals, and * a magnetostrictive layer extending mainly parallel to a reference plane and fixed with no degree of freedom to the electromechanical transducer, this magnetostrictive layer comprising at least one block made of magnetostrictive material capable of converting a variation of the magnetic field into a mechanical deformation exerted on the electromechanical transducer, - a magnetic field source comprising a group (90-93, 96-99; 130; 140; 160; 196-199, 202-205; 240) of several permanent magnets aligned along an axis of alignment, at least one of the group and of the converter being movable, alternately, between: * a first position wherein the field lines of the group of permanent magnets pass through the same block made of magnetostrictive material and cause a first deformation of this block made of magnetostrictive material, and * a second position wherein the block made of magnetostrictive material has a second deformation, different from the first deformation, * a first position wherein the field lines of the group of permanent magnets pass through the same block made of magnetostrictive material and cause a first deformation of this block made of magnetostrictive material, and * a second position wherein the block made of magnetostrictive material has a second deformation, different from the first deformation, - an aspect ratio, defined by the ratio of the thickness thereof over the length thereof in the direction of the magnetic moment thereof, of between 1/10 and ten, and - the main part of the field lines which are looped by way of the block made of magnetostrictive material and of this first permanent magnet in the first position do not pass through another first permanent magnet,